---
title: Commands
description: All direct commands available in devv CLI.
---

# Commands

Run any tool directly from your shell without entering the REPL.

## Syntax

```bash
devv <tool> [subcommand] [input] [options]
```

## JSON

```bash
# Format (pretty-print)
devv json format '{"a":1,"b":[2,3]}'
devv json format '{"z":1,"a":2}' --sort-keys
cat data.json | devv json format --indent 4

# Minify
devv json minify '{ "a": 1, "b": 2 }'
cat pretty.json | devv json minify

# Validate
devv json validate '{"valid": true}'
devv json validate '{broken'
```

## Base64

```bash
# Encode
devv base64 encode "hello world"
echo "secret data" | devv base64 encode

# Decode
devv base64 decode "aGVsbG8gd29ybGQ="
echo "c2VjcmV0" | devv base64 decode
```

## URL Encoding

```bash
# Encode
devv url encode "hello world & more"

# Decode
devv url decode "hello%20world%20%26%20more"
```

## Hashing

```bash
# Default is SHA-256
devv hash "hello world"
devv hash "hello world" sha256
devv hash "hello world" sha512
devv hash "hello world" md5

# From stdin
echo "file contents" | devv hash - sha256
cat secret.txt | devv hash - sha512
```

## UUID

```bash
# Generate one
devv uuid

# Generate multiple
devv uuid --count 5
devv uuid -n 10

# Uppercase
devv uuid --uppercase
```

## JWT

```bash
# Decode a JWT token (no verification)
devv jwt decode eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIn0.dozjgNryP4J3jVmNHl0w5N_XgL0n3I9PlFUP0THsR8U
```

Output:
```
Header:
{
  "alg": "HS256",
  "typ": "JWT"
}

Payload:
{
  "sub": "1234567890"
}
```

## Case Conversion

```bash
devv case "hello world" camel      # helloWorld
devv case "hello world" pascal     # HelloWorld
devv case "hello world" snake      # hello_world
devv case "hello world" kebab      # hello-world
devv case "helloWorld" constant    # HELLO_WORLD
```

## Timestamps

```bash
# Current time in all formats
devv timestamp

# Convert epoch to human-readable
devv timestamp 1720396800

# Convert ISO to epoch
devv timestamp "2024-07-08T00:00:00Z"
```

Output:
```
Unix:  1720396800
ISO:   2024-07-08T00:00:00.000Z
UTC:   Mon, 08 Jul 2024 00:00:00 GMT
Local: 7/8/2024, 12:00:00 AM
```

## Password Generator

```bash
devv password                    # 16 chars, all character types
devv password --length 32        # Custom length
devv password -l 24              # Short flag
```

## Lorem Ipsum

```bash
devv lorem                       # 1 paragraph
devv lorem --paragraphs 3        # Multiple paragraphs
```

## Mock Data

```bash
devv mock                        # 5 mock user records
devv mock --count 20             # 20 records
```

## Text Counter

```bash
devv count "hello world"
echo "some text" | devv count
```

Output:
```
Characters: 11
Words: 2
Lines: 1
```

## Global Options

| Flag | Description |
|------|-------------|
| `--version`, `-V` | Print version |
| `--help`, `-h` | Show help |
