Postman Server Responses API

Operations for managing mock server responses and examples.

Operations 4

Each operation below carries the questions people ask an LLM about it and the instructions they give an agent to run it. Generated by API Evangelist overlay

GET /mocks/{mockId}/serverResponses List a mock server's custom responses · Postman Get mock server responses #
Ask an LLM
“Which custom server responses override the defaults on my mock server?”
“Can I see every server response configured for a mock?”
Tell an agent
List the server responses on mock {mockId}.
Show the custom overrides configured for mock server {mockId}.
POST /mocks/{mockId}/serverResponses Add a custom response to a mock server · Postman Create a server response #
Ask an LLM
“How do I make my mock server return a 500 error to test failure handling?”
“Can I set custom headers and a body on a mock server response?”
Tell an agent
Create a server response {name} returning status {statusCode} on mock {mockId}.
Add response {name} with status {statusCode} and body {body} to mock server {mockId}.
PUT /mocks/{mockId}/serverResponses/{serverResponseId} Change a mock server's custom response · Postman Update a server response #
Ask an LLM
“How do I change the status code of an existing mock server response?”
“Can I edit the body of a server response I already created?”
Tell an agent
Update server response {serverResponseId} on mock {mockId} to {name} with status {statusCode}.
Change the body of mock {mockId}'s response {serverResponseId} to {body}, keeping name {name} and status {statusCode}.
DELETE /mocks/{mockId}/serverResponses/{serverResponseId} Remove a custom response from a mock server · Postman Delete a server response #
Ask an LLM
“Can I delete a custom server response so the mock falls back to collection examples?”
“Can I remove one server response without deleting the mock?”
Tell an agent destructive · confirm first
Delete server response {serverResponseId} from mock {mockId}.
Remove the custom override {serverResponseId} on mock server {mockId}.

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/postman:postman-server-responses-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

postman-server-responses-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Postman Mock Servers Server Responses API
  description: 'The Postman Mock Servers API enables you to create and manage mock servers

    that simulate API behavior. Mock servers generate responses based on examples

    saved in your Postman collections, allowing frontend and backend teams to

    work in parallel during API development.


    ## Authentication

    All requests require an API key passed in the `x-api-key` header.


    ## Rate Limits

    Mock server calls have separate usage limits based on your Postman plan.

    Free plans include 1,000 mock server calls per month.'
  version: 1.0.0
  contact:
    name: Postman Developer Support
    url: https://learning.postman.com/docs/developer/postman-api/intro-api/
    email: help@postman.com
  license:
    name: Postman Terms of Service
    url: https://www.postman.com/legal/terms/
servers:
- url: https://api.getpostman.com
  description: Postman Production API Server
security:
- apiKeyAuth: []
tags:
- name: Server Responses
  description: Operations for managing mock server responses and examples.
paths:
  /mocks/{mockId}/serverResponses:
    get:
      tags:
      - Server Responses
      summary: Postman Get mock server responses
      operationId: getMockServerResponses
      description: Gets all server responses configured for a mock server. Server responses are custom responses that override the default collection-based responses.
      parameters:
      - $ref: '#/components/parameters/MockIdParam'
      responses:
        '200':
          description: Successful response with list of server responses
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/ServerResponse'
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '404':
          $ref: '#/components/responses/NotFoundError'
        '429':
          $ref: '#/components/responses/RateLimitError'
    post:
      tags:
      - Server Responses
      summary: Postman Create a server response
      operationId: createServerResponse
      description: Creates a new server response for a mock server. Server responses allow you to define custom responses for specific request patterns.
      parameters:
      - $ref: '#/components/parameters/MockIdParam'
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ServerResponseInput'
      responses:
        '200':
          description: Successfully created server response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ServerResponse'
        '400':
          $ref: '#/components/responses/BadRequestError'
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '404':
          $ref: '#/components/responses/NotFoundError'
        '429':
          $ref: '#/components/responses/RateLimitError'
  /mocks/{mockId}/serverResponses/{serverResponseId}:
    put:
      tags:
      - Server Responses
      summary: Postman Update a server response
      operationId: updateServerResponse
      description: Updates an existing server response for a mock server.
      parameters:
      - $ref: '#/components/parameters/MockIdParam'
      - name: serverResponseId
        in: path
        required: true
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ServerResponseInput'
      responses:
        '200':
          description: Successfully updated server response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ServerResponse'
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '404':
          $ref: '#/components/responses/NotFoundError'
        '429':
          $ref: '#/components/responses/RateLimitError'
    delete:
      tags:
      - Server Responses
      summary: Postman Delete a server response
      operationId: deleteServerResponse
      description: Deletes a server response from a mock server.
      parameters:
      - $ref: '#/components/parameters/MockIdParam'
      - name: serverResponseId
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Successfully deleted server response
        '401':
          $ref: '#/components/responses/UnauthorizedError'
        '404':
          $ref: '#/components/responses/NotFoundError'
        '429':
          $ref: '#/components/responses/RateLimitError'
components:
  responses:
    BadRequestError:
      description: Bad request - invalid input
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: object
                properties:
                  name:
                    type: string
                  message:
                    type: string
    NotFoundError:
      description: The requested resource was not found
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: object
                properties:
                  name:
                    type: string
                  message:
                    type: string
    RateLimitError:
      description: Too many requests - rate limit exceeded
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
              message:
                type: string
    UnauthorizedError:
      description: Authentication credentials are missing or invalid
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: object
                properties:
                  name:
                    type: string
                  message:
                    type: string
  parameters:
    MockIdParam:
      name: mockId
      in: path
      required: true
      description: The mock server's unique ID or UID.
      schema:
        type: string
  schemas:
    ServerResponse:
      type: object
      description: A custom server response configured on a mock server.
      properties:
        id:
          type: string
        name:
          type: string
        statusCode:
          type: integer
        headers:
          type: array
          items:
            type: object
            properties:
              key:
                type: string
              value:
                type: string
        body:
          type: string
        language:
          type: string
          enum:
          - text
          - json
          - xml
          - html
          - javascript
        createdAt:
          type: string
          format: date-time
        updatedAt:
          type: string
          format: date-time
    ServerResponseInput:
      type: object
      required:
      - name
      - statusCode
      properties:
        name:
          type: string
        statusCode:
          type: integer
        headers:
          type: array
          items:
            type: object
            properties:
              key:
                type: string
              value:
                type: string
        body:
          type: string
        language:
          type: string
          enum:
          - text
          - json
          - xml
          - html
          - javascript
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      name: x-api-key
      in: header
      description: Postman API key for authentication.