Spec0docsCLI 0.7.0
API Explorer

List mock servers for the calling org

Returns every mock server owned by the calling token's org, with the parent API id/name and the mock's base URL. Backs the spec0 mock list CLI command and is the discovery surface SDK consumers use before deciding whether to point a client at a mock vs. a real environment.

GET
/api/v1/public/mocks

Authorization

BearerAuth
AuthorizationBearer <token>

Bearer token. Either a Personal Access Token (pat_...) or a Service Account Token (sat_...). Issued via the Spec0 dashboard or /me/personal-access-tokens.

In: header

Response Body

application/json

application/json

application/json

curl -X GET "https://app.spec0.io/api/v1/public/mocks"
[
  {
    "mockServerId": "ab6f0051-1ea2-4f26-bcfb-0e9ea431b824",
    "apiId": "2500ac85-f71b-4d01-b32c-62f3af3fe2c5",
    "apiName": "string",
    "name": "string",
    "mockBaseUrl": "string"
  }
]
{
  "error": "string",
  "message": "string"
}
{
  "status": 0,
  "title": "string",
  "detail": "string",
  "type": "string",
  "instance": "string"
}
Was this helpful?