Skip to main content

hitspec docs

Output AI-readable documentation (llms.txt) for AI agents to learn hitspec syntax.
hitspec docs
This prints the complete hitspec specification in a format optimized for LLM consumption.

hitspec studio

Open the keyboard-first interactive app for working with hitspec files, right in the terminal.
hitspec studio [file|directory] [flags]

What It Provides

  • Inline .http and .hitspec source editing with syntax highlighting and save
  • File tree, request table, response viewer, headers, assertions, and history
  • Stress, mock, contract, record, import, cookies, and settings screens
  • Copy/export as curl, HTTPie, Python, fetch, or Go; workspace search; environment switching
  • Command palette and keyboard-first navigation
  • Real-time file watching and execution progress

Flags

FlagShortDescriptionDefault
--watch-wWatch for file changestrue
--read-onlyDisallow file mutationsfalse
--env-eDefault environmentdev
--configPath to hitspec.yaml
--verbose-vVerbose loggingfalse
--allow-shellAllow shell command executionfalse
--allow-dbAllow database assertionsfalse
--log-formatLog format: text or jsontext
--log-levelLog level: debug, info, warn, errorinfo
--themeColor theme (see below)Nord

Themes

studio ships with five built-in color themes: Nord, Catppuccin Mocha, Dracula, Tokyo Night, and Gruvbox Dark. Switch at any time with ctrl+t (or the command palette), or set one at launch with --theme:
hitspec studio --theme "Tokyo Night"

Examples

# Open the current directory
hitspec studio

# Open a specific workspace
hitspec studio ./tests/

# Open a single file
hitspec studio ./tests/users.http

# Inspect without file mutations
hitspec studio --read-only --env staging

hitspec serve

Start the REST/WebSocket API server for scripts and integrations. With no flags it opens hitspec studio; pass --api-only to run just the API with no interactive UI.
hitspec serve [file|directory] [flags]

What It Provides

  • REST endpoints under /api/v1/*
  • Realtime events over WebSocket at /api/v1/ws
  • The same parser, runner, history store, and engines as the CLI
No web SPA is served; non-API browser routes are not part of serve.

Flags

FlagShortDescriptionDefault
--api-onlyREST/WebSocket API only, no interactive UIfalse
--port-pAPI server port4000
--hostAPI bind addresslocalhost
--corsEnable CORS headersfalse
--watch-wWatch for file changestrue
--read-onlyDisallow mutating actionsfalse
--env-eDefault environmentdev
--configPath to hitspec.yaml
--verbose-vVerbose loggingfalse
--allow-shellAllow shell command executionfalse
--allow-dbAllow database assertionsfalse
--log-formatLog format: text or jsontext
--log-levelLog level: debug, info, warn, errorinfo

Examples

# Start the REST/WebSocket API for integrations
hitspec serve --api-only --port 8080 --cors

# API server bound to localhost
hitspec serve --api-only --host localhost --port 4000