Mocko creating mocks API

Mocko creating mocks API as documented publicly: 8 operations. Contract generated from the documentation by API Evangelist (2026-10-21); not the provider's own document.

Operations 8

GET /files/{path*} Catch-all paths #
POST /orders Templating | Mocko Docs #
GET /orders/{id} Templating | Mocko Docs #
POST /orders/{orderid} POST /orders/{orderId} #
POST /outage/{state} Flags are key-value state that survives across requests. #
GET /passthrough Most of the time you do not want to mock a whole API, just the parts that matter for the scenario at hand. #
POST /payments/9 POST /payments/9 #
GET /payments/{id} Flags are key-value state that survives across requests. #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/mocko:creating-mocks-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

mocko-creating-mocks-openapi-generated.yml Raw ↑
openapi: 3.1.0
info:
  title: Mocko creating mocks API
  version: '2026-10-21'
  description: 'GENERATED FROM DOCUMENTATION by API Evangelist on 2026-10-21: 8 operation(s) read from 4 public documentation page(s) (each operation
    names its page in x-source). This is not the provider''s published contract; Mocko has published no machine-readable contract that the pipeline
    could find. Engine: local.'
  x-evidence-tiers:
    code-example: 14
    documentation: 16
    pages-with-code: 15
    pages-read: 20
  x-generated-from: documentation
  x-provenance: generated
  x-authored-by: API Evangelist
  x-generated: '2026-10-21'
  x-generator: generate-contract-from-docs.py
  x-engine: local
  x-sources:
  - https://mocko.dev/docs/creating-mocks/flags
  - https://mocko.dev/docs/creating-mocks/matching
  - https://mocko.dev/docs/creating-mocks/proxying-and-hosts
  - https://mocko.dev/docs/creating-mocks/templating
  x-docs-section: creating-mocks
servers:
- url: https://demo-api.mockoapp.net
paths:
  /files/{path*}:
    get:
      operationId: get_files_path
      tags:
      - Files
      summary: Catch-all paths
      x-source: https://mocko.dev/docs/creating-mocks/matching
      parameters:
      - name: path*
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /orders:
    post:
      operationId: post_orders
      tags:
      - Orders
      summary: Templating | Mocko Docs
      x-source: https://mocko.dev/docs/creating-mocks/templating
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PostOrdersRequest'
      responses:
        '201':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PostOrdersResponse'
      x-evidence:
        kind: documentation
  /orders/{id}:
    get:
      operationId: get_orders_id
      tags:
      - Orders
      summary: Templating | Mocko Docs
      x-source: https://mocko.dev/docs/creating-mocks/templating
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetOrdersIdResponse'
      x-evidence:
        kind: documentation
  /orders/{orderid}:
    post:
      operationId: post_orders_orderid
      tags:
      - Orders
      summary: POST /orders/{orderId}
      x-source: https://mocko.dev/docs/creating-mocks/templating
      parameters:
      - name: orderid
        in: path
        required: true
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PostOrdersOrderidRequest'
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl http://localhost:8080/orders/31 {\n \"id\": 31,\n \"status\": \"shipped\"\n} The request context Every part of the incoming\
          \ request is available under request : {{request.params.id}} reads path parameters declared with {id} in the route. {{request.query.page}}\
          \ reads query string values, ?page=2 in this case. If the client repeats a key ( ?tag=a&tag=b ), the value is an array instead of a\
          \ string. {{req"
  /outage/{state}:
    post:
      operationId: post_outage_state
      tags:
      - Outage
      summary: Flags are key-value state that survives across requests.
      x-source: https://mocko.dev/docs/creating-mocks/flags
      parameters:
      - name: state
        in: path
        required: true
        schema:
          type: string
      responses:
        '201':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PostOutageStateResponse'
      x-evidence:
        kind: documentation
  /passthrough:
    get:
      operationId: get_passthrough
      tags:
      - Passthrough
      summary: Most of the time you do not want to mock a whole API, just the parts that matter for the scenario at hand.
      x-source: https://mocko.dev/docs/creating-mocks/proxying-and-hosts
      responses:
        '200':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /payments/9:
    post:
      operationId: post_payments_9
      tags:
      - Payments
      summary: POST /payments/9
      x-source: https://mocko.dev/docs/creating-mocks/flags
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl http://localhost:8080/payments/9 {\n \"id\": 9,\n \"status\": \"approved\"\n} $ curl -X POST http://localhost:8080/outage/on\
          \ {\n \"outage\": \"on\"\n} $ curl -i http://localhost:8080/payments/9 HTTP/1.1 503 Service Unavailable\n...\n{\n \"error\": \"Payment\
          \ provider unavailable\"\n} The state changed between two identical requests. That is the whole point of flags, and it works because\
          \ flags are shared by all mocks"
  /payments/{id}:
    get:
      operationId: get_payments_id
      tags:
      - Payments
      summary: Flags are key-value state that survives across requests.
      x-source: https://mocko.dev/docs/creating-mocks/flags
      parameters:
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetPaymentsIdResponse'
      x-evidence:
        kind: documentation
components:
  schemas:
    PostOrdersRequest:
      type: object
      properties:
        items:
          type: array
          description: Array of items with sku
      required:
      - items
    PostOrdersResponse:
      type: object
      properties:
        status:
          type: string
        items:
          type: array
          description: Array of created items with sku and position
    GetOrdersIdResponse:
      type: object
      properties:
        id:
          type: string
        status:
          type: string
    PostOrdersOrderidRequest:
      type: object
      properties:
        items:
          type: array
          items:
            type: object
            properties:
              sku:
                type: string
    PostOutageStateResponse:
      type: object
      properties:
        outage:
          type: string
          description: Echoes the requested state.
    GetPaymentsIdResponse:
      type: object
      properties:
        id:
          type: string
          description: The payment id.
        status:
          type: string
          description: Payment status (e.g., "approved").
        error:
          type: string
          description: Error message when outage flag is set.
  securitySchemes:
    Bearer:
      type: http
      scheme: bearer
      x-source: https://mocko.dev/docs/sdk/auth
tags:
- name: Files
- name: Orders
- name: Outage
- name: Passthrough
- name: Payments
security:
- Bearer: []