# hitspec ## Docs - [Assertions](https://hitspec.dev/concepts/assertions.md): Validate HTTP responses with 26 assertion operators covering equality, strings, types, arrays, schemas, and snapshots. - [Captures](https://hitspec.dev/concepts/captures.md): Extract values from HTTP responses and use them in subsequent requests. - [Dependencies](https://hitspec.dev/concepts/dependencies.md): Control execution order with @depends, topological sorting, and request chaining. - [Environments](https://hitspec.dev/concepts/environments.md): Configure variables for dev, staging, and production with environment files and hitspec.yaml. - [File Format](https://hitspec.dev/concepts/file-format.md): Anatomy of .http files -- requests, headers, bodies, assertions, captures, and more. - [Variable Interpolation](https://hitspec.dev/concepts/variable-interpolation.md): Deep-dive into hitspec's {{var}} syntax, $env() references, capture chains, and resolution order. - [Variables](https://hitspec.dev/concepts/variables.md): Define variables, use built-in functions, reference environment values, and interpolate captured data. - [Editor Setup](https://hitspec.dev/editor-setup.md): Configure syntax highlighting, snippets, and shell completions for hitspec. - [Auth Flow](https://hitspec.dev/examples/auth-flow.md): Login to get a token, capture it, and use it in authenticated requests with @auth bearer and @depends. - [Basic CRUD](https://hitspec.dev/examples/basic-crud.md): Walk through a complete CRUD test file that covers GET, POST, PUT, and DELETE operations against a REST API. - [CI/CD Integration](https://hitspec.dev/examples/ci-cd.md): Run hitspec tests in GitHub Actions with JUnit output, environment variables, and pass/fail exit codes. - [Contract Testing](https://hitspec.dev/examples/contract-testing.md): Example: Define and verify API contracts between services. - [Database Assertions](https://hitspec.dev/examples/database-assertions.md): Example: Verify API side effects with database queries. - [GraphQL](https://hitspec.dev/examples/graphql.md): Query a GraphQL API with variables, test nested response fields, and chain mutations with captures. - [Mock Server](https://hitspec.dev/examples/mock-server.md): Example: Generate mock servers from your hitspec test files. - [Stress Testing](https://hitspec.dev/examples/stress-testing.md): Load test your APIs with configurable rate, virtual users, ramp-up phases, and pass/fail thresholds. - [API Coverage](https://hitspec.dev/features/api-coverage.md): Measure how much of your API is covered by tests using OpenAPI spec comparison and coverage reports. - [Authentication](https://hitspec.dev/features/authentication.md): Configure authentication for your API requests using the @auth annotation. hitspec supports 8 authentication methods. - [Contract Testing](https://hitspec.dev/features/contract-testing.md): Verify API contracts against live providers with hitspec's built-in contract testing support. - [Database Assertions](https://hitspec.dev/features/database-assertions.md): Verify database state after HTTP requests with SQL queries and assertions. Supports PostgreSQL, MySQL, and SQLite. - [Hooks](https://hitspec.dev/features/hooks.md): Run setup and teardown scripts before and after HTTP requests using @before and @after annotations. - [Metrics Export](https://hitspec.dev/features/metrics-export.md): Export test metrics to Prometheus, DataDog, or JSON for monitoring and dashboards. - [Mock Server](https://hitspec.dev/features/mock-server.md): Start a mock HTTP server from your .http test files for frontend development and integration testing. - [Multipart and GraphQL](https://hitspec.dev/features/multipart-graphql.md): Send multipart form data with file uploads and execute GraphQL queries using dedicated block syntax. - [Notifications](https://hitspec.dev/features/notifications.md): Send test results to Slack and Microsoft Teams via webhooks. - [Parallel Execution](https://hitspec.dev/features/parallel-execution.md): Run independent API tests concurrently for faster test suites. - [Recording Proxy](https://hitspec.dev/features/recording-proxy.md): Capture HTTP traffic and auto-generate hitspec test files using the recording proxy. - [Shell Commands](https://hitspec.dev/features/shell-commands.md): Run shell commands after HTTP requests for post-processing, notifications, and custom validation. - [Snapshot Testing](https://hitspec.dev/features/snapshot-testing.md): Capture response bodies as baselines and automatically detect regressions with snapshot comparison. - [Server-Sent Events (SSE)](https://hitspec.dev/features/sse.md): Test Server-Sent Events endpoints with hitspec. - [Stress Testing](https://hitspec.dev/features/stress-testing.md): Load test your APIs with configurable rate, virtual users, ramp-up periods, and pass/fail thresholds. - [Watch Mode](https://hitspec.dev/features/watch-mode.md): Automatically re-run tests when files change during development. - [API Client Manager](https://hitspec.dev/guides/api-client-manager.md): Use the hitspec web UI to build, run, and debug HTTP requests - [CI/CD Pipeline Integration](https://hitspec.dev/guides/ci-cd-pipeline.md): Set up hitspec in GitHub Actions, GitLab CI, and other CI/CD systems. - [Contract Testing Guide](https://hitspec.dev/guides/contract-testing.md): Step-by-step guide to consumer-driven contract testing with hitspec. - [Database Testing Guide](https://hitspec.dev/guides/database-testing.md): Use database assertions to verify side effects of API calls against PostgreSQL, MySQL, and SQLite. - [Load Testing Guide](https://hitspec.dev/guides/load-testing.md): Run stress tests with hitspec to validate API performance under load. - [Migrating from Postman](https://hitspec.dev/guides/migrating-from-postman.md): Import Postman collections into hitspec and learn the key differences. - [Regression Testing with hitspec diff](https://hitspec.dev/guides/regression-testing.md): Compare test runs to detect performance regressions and behavior changes. - [Troubleshooting](https://hitspec.dev/guides/troubleshooting.md): Common issues and how to resolve them - [Installation](https://hitspec.dev/installation.md): Install hitspec via Homebrew, Go, or binary download. - [DataDog](https://hitspec.dev/integrations/datadog.md): Send hitspec stress test metrics directly to DataDog for monitoring. - [GitHub Actions](https://hitspec.dev/integrations/github-actions.md): Run hitspec API tests in your GitHub Actions CI/CD pipeline with JUnit reporting, caching, and matrix testing. - [Output Formats](https://hitspec.dev/integrations/output-formats.md): hitspec supports five output formats: console, JSON, JUnit XML, TAP, and HTML. Choose the right format for your workflow. - [Prometheus](https://hitspec.dev/integrations/prometheus.md): Export hitspec stress test metrics to Prometheus for monitoring dashboards. - [Slack & Teams Notifications](https://hitspec.dev/integrations/slack-teams.md): Send hitspec test results to Slack and Microsoft Teams via webhooks. - [Introduction](https://hitspec.dev/introduction.md): Plain text API tests. No magic. Write HTTP tests that look like actual HTTP requests. - [Quickstart](https://hitspec.dev/quickstart.md): Write and run your first API test in under a minute. - [Assertion Operators](https://hitspec.dev/reference/assertion-operators.md): Complete reference for all 26 assertion operators in hitspec, with syntax and examples for each. - [Assertion Subjects](https://hitspec.dev/reference/assertion-subjects.md): Reference for all assertion subjects: status, duration, headers, body paths, and percentiles. - [Authentication Types](https://hitspec.dev/reference/auth-types.md): Reference for all 8 authentication methods supported by hitspec's @auth directive. - [Built-in Functions](https://hitspec.dev/reference/builtin-functions.md): Reference for all 17 built-in functions available in hitspec variable interpolation. - [Configuration Reference](https://hitspec.dev/reference/configuration.md): Complete reference for hitspec.yaml configuration file options with defaults and examples. - [hitspec contract & diff](https://hitspec.dev/reference/contract-diff.md): Contract testing against live providers and comparing test results - [hitspec docs & hitspec serve](https://hitspec.dev/reference/docs-serve.md): Reference for the docs and serve commands -- AI documentation and the web-based API client. - [Environment Variables](https://hitspec.dev/reference/environment-variables.md): Complete list of HITSPEC_* environment variables for configuring hitspec without flags. - [Exit Codes](https://hitspec.dev/reference/exit-codes.md): Reference for all hitspec CLI exit codes for use in scripts and CI/CD pipelines. - [hitspec import & export](https://hitspec.dev/reference/import-export.md): Import from OpenAPI, Postman, curl, and Insomnia; export to curl - [hitspec init](https://hitspec.dev/reference/init.md): Initialize a new hitspec project with a config file and example test. - [hitspec mock & record](https://hitspec.dev/reference/mock-record.md): Start a mock HTTP server or recording proxy from hitspec files - [Output Formats](https://hitspec.dev/reference/output-formats.md): Reference for all 5 output formats supported by hitspec: console, JSON, JUnit XML, TAP, and HTML. - [hitspec run](https://hitspec.dev/reference/run.md): Run HTTP API tests from .http and .hitspec files - [hitspec validate & list](https://hitspec.dev/reference/validate-list.md): Validate syntax and list requests in hitspec files ## OpenAPI Specs - [openapi](https://hitspec.dev/api-reference/openapi.json) ## Optional - [GitHub](https://github.com/abdul-hamid-achik/hitspec)