# Forest Web – OpenAPI/Swagger Operation Contract Inspector

> Forest Web – OpenAPI/Swagger Operation Contract Inspector is a paid API for AI agents from http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run, paid per call via x402, $0.003/call, status unknown (last checked 2026-10-21).

Returns the declared request/response contract (parameters, body content types, response statuses, security schemes) for one specific OpenAPI or Swagger operation without executing it or resolving external references.

## Facts

- Endpoint: POST https://http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run/openapi/operation-contract?utm_source=zero.xyz
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-21
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/forest-web-openapi-swagger-operation-contract-inspector-623c8ded
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_CJSQwgLuOwoZcWMEIPuyF

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability forest-web-openapi-swagger-operation-contract-inspector-623c8ded -d '<json body>'
```

Example prompt: Before I start integrating, can you inspect the declared contract for the POST /payments operation in the OpenAPI spec at https://api.example.com/openapi.yaml — tell me what parameters it expects, what request body content types it accepts, what response codes it declares, and what security schemes are required?

## When to prefer this

Choose this endpoint when you need to inspect the declared contract of one specific API operation (method + path) within a public OpenAPI or Swagger document before integration — without executing the endpoint, without resolving external references, and without crawling the full spec. Prefer this over a full spec fingerprinter when you only care about one operation's inputs, outputs, and security declarations rather than the entire API surface.

## Known failure modes

- URL does not point to a valid OpenAPI or Swagger document — returns an error indicating the spec could not be parsed
- Specified path or method does not exist in the retrieved spec — returns a not-found or mismatch error
- URL is unreachable or returns a non-200 response — returns a network or access error
- Spec uses external $ref references that cannot be resolved without fetching additional documents — contract may be incomplete
- Malformed or non-standard spec versions may result in partial or empty contract data

## How this service works

Machine-readable contract for active Forest paid capabilities. Unsigned paid calls return HTTP 402 with a PAYMENT-REQUIRED x402 challenge.

## Output

A structured summary of the declared contract for the specified OpenAPI/Swagger operation, including: accepted request parameters (path, query, header, cookie), request body content types, declared HTTP response status codes with their content types, and the names of any declared security schemes. No live requests are made to the target endpoint; only the spec document is read.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "url": {
   "type": "string",
   "pattern": "^https?://",
   "maxLength": 2048,
   "minLength": 1,
   "description": "Public HTTP(S) URL to inspect, resolve, or compare."
  },
  "path": {
   "type": "string",
   "pattern": "^/",
   "maxLength": 2048,
   "minLength": 1,
   "description": "Repository file path whose public metadata should be checked."
  },
  "method": {
   "enum": [
    "GET",
    "POST",
    "PUT",
    "PATCH",
    "DELETE",
    "HEAD",
    "OPTIONS",
    "TRACE"
   ],
   "type": "string",
   "description": "HTTP method for the bounded public probe."
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "data": {
   "url": "example",
   "found": false,
   "scope": "bounded_contract_metadata_only_no_operation_execution",
   "version": "example",
   "contract": {
    "path": "example",
    "method": "example",
    "responses": [],
    "deprecated": false,
    "parameters": [],
    "operation_id": "example",
    "request_body": {
     "required": false,
     "content_types": []
    },
    "security_source": "operation",
    "detail_available": false,
    "security_schemes": []
   },
   "requested": {
    "path": "example",
    "method": "example"
   },
   "parse_valid": false,
   "detail_state": "available",
   "operation_count": 0
  },
  "meta": {
   "cache": "miss",
   "provider": "openapi-parser",
   "checked_at": "2026-01-01T00:00:00.000Z",
   "duration_ms": 0
  },
  "version": "1",
  "capability": "openapi.operation-contract"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/forest-web-openapi-swagger-operation-contract-inspector-623c8ded/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run](https://www.zero.xyz/host/http--forest-gas-station-mainnet--lcjl27p8lmjs.code.run/llms.txt)
