Open Source · Written in Go · AI-Native

Test APIs from
your terminal.

Kest is a CLI tool that turns Markdown into executable API tests. Variable chaining, assertions, session logs — all in one command.

curl -fsSL https://kest.dev/install.sh | sh
terminal — kest replaces curl
# Replace curl with readable commands
$ kest get /api/users
200 OK (34ms) — 12 items
# POST with JSON, capture token, assert status
$ kest post /api/login -d '{"user":"admin","pass":"123"}' -c "token=data.token" -a "status==200"
✅ status == 200 (89ms)
↳ Captured: token = eyJhbGciOi...
# Use captured variables in next request
$ kest get /api/me -H "Authorization: Bearer {{token}}"
200 OK (27ms) — user: admin
# Or run a full flow file
$ kest run auth.flow.md
✨ 6/6 assertions passed, 2 captures
# Every command generates AI-ready session logs
$ cat .kest/logs/session_20250208.log
[11:02:34] POST /api/login → 200 OK (89ms)
[11:02:34] Request: {"user":"admin","pass":"123"}
[11:02:34] Response: {"token":"eyJhbG...","user_id":42}
[11:02:34] ✅ status == 200 | 📌 Captured: token
→ Feed this log to Cursor / Windsurf for AI-powered debugging

Use it right now.

No config files. No setup wizard. Just commands.

Quick GET request
kest get /api/users
POST with JSON body
kest post /api/login -d '{"user":"admin","pass":"123"}'
Capture + Assert
kest post /api/login -c "token=data.token" -a "status=200"
Variable injection
kest get /api/me -H "Authorization: Bearer {{token}}"

Write Markdown. Run Tests.

Define API flows in .flow.md files. Kest executes them with assertions and variable chaining.

auth.flow.md
# Auth & Profile Flow

## 1. Login
```kest
POST /api/v1/login
{
  "username": "admin",
  "password": "secret"
}

[Captures]
token: data.access_token
user_id: data.user.id

[Asserts]
status == 200
body.data.access_token exists
body.data.password !exists
duration < 500ms
```

## 2. Get Profile
```kest
GET /api/v1/users/{{user_id}}
Authorization: Bearer {{token}}

[Asserts]
status == 200
body.data.username != ""
```
kest run auth.flow.md
🚀 Running Flow: Auth & Profile Flow
--- Step 1: POST /api/v1/login ---
✅ status == 200
✅ body.data.access_token exists
✅ body.data.password !exists
✅ duration < 500ms (127ms)
↳ Captured: token = eyJhbGciOi...
↳ Captured: user_id = 42
--- Step 2: GET /api/v1/users/42 ---
✅ status == 200
✅ body.data.username != ""
✨ All steps passed!6/6 assertions, 2 captures
📄 Session log: .kest/logs/session_20250208_001.log
Session Logs

Every request logged.
AI-ready.

Kest automatically generates structured session logs for every command. Feed the log path to Cursor or Windsurf — your AI agent gets full request/response context for instant debugging.

Full request headers, body, and timing
Complete response with status and JSON body
Assertion results with expected vs actual
Variable capture trail across steps
.kest/logs/session_20250208_001.log
[2025-02-08 11:02:34] Flow: auth.flow.md
[2025-02-08 11:02:34] Step 1: POST /api/v1/login
  → Request:
    POST http://localhost:8080/api/v1/login
    Content-Type: application/json
    {"username":"admin","password":"secret"}

  ← Response: 200 OK (127ms)
    {"code":0,"data":{"access_token":"eyJhbG...","user":{"id":42,"username":"admin"}}}

  ✅ status == 200
  ✅ body.data.access_token exists
  ✅ body.data.password !exists
  ✅ duration < 500ms (actual: 127ms)
  📌 Captured: token = eyJhbGciOi...
  📌 Captured: user_id = 42

[2025-02-08 11:02:34] Step 2: GET /api/v1/users/42
  → Request:
    GET http://localhost:8080/api/v1/users/42
    Authorization: Bearer eyJhbGciOi...

  ← Response: 200 OK (43ms)
    {"code":0,"data":{"id":42,"username":"admin","email":"admin@kest.dev"}}

  ✅ status == 200
  ✅ body.data.username != ""

[2025-02-08 11:02:34] Summary: 6/6 passed, 0 failed

More than just requests.

Debug, replay, diff, and manage environments — all from the CLI.

Flow
kest run auth.flow.md

Execute multi-step flow files with assertions and variable chaining

Debug
kest show last -v

Inspect the last request/response with full headers and body

Verify
kest replay last --diff

Re-run the last request and diff the response to detect regressions

History
kest history

Browse all previous requests stored in local SQLite database

Env
kest env use staging

Switch API base URL between local, staging, and production

Docs
kest doc ./api -o docs --ai

Generate API documentation from Go/FastAPI source code

Why Kest?

Built for engineers who ship fast and test harder.

Zero Config

Install and run. No YAML, no project files required for quick tests.

Flow Files

Chain multi-step API tests in Markdown. Variables propagate automatically.

AI-Ready Logs

Structured session logs that AI editors can consume for context-aware debugging.

Hard Assertions

Status codes, field existence, duration thresholds — enforced on every request.

Variable Chaining

Capture response data with -c and inject with {{var}} across requests.

Replay & Diff

Re-run any previous request and diff responses to catch regressions.

Multi-Environment

Switch between dev/staging/prod with kest env. Credentials stay safe.

Git-Native

Flow files live in your repo. Version tests alongside your code.

Start testing in 10 seconds.

One command to install. One command to test.

curl -fsSL https://kest.dev/install.sh | sh