OK Capsule Pamphlets API

Routes to manage pamphlets

Operations 2

GET /v2/pub-specs/{orderLineId}/{type}/{format} Retrieve a pub spec url by order line, type, and format #
GET /v2/pamphlets/{orderLineId} Retrieve a pamphlet url #

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/ok-capsule-pamphlets-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

ok-capsule-pamphlets-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  description: '## Overview


    The OK Capsule API enables you to programmatically create supplement orders, manage consumers, and track shipments.'
  version: 2.0.0
  title: OKC core API V2 Pamphlets API
  contact:
    name: Engineering Department, OKCapsule
    email: lukas@okcapsule.com
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0.html
servers:
- description: Production environment
  url: https://na1-prod.okcapsule.app
- description: Stage/Testing environment
  url: https://na1-stage.okcapsule.app
tags:
- name: Pamphlets
  description: Routes to manage pamphlets
paths:
  /v2/pub-specs/{orderLineId}/{type}/{format}:
    get:
      tags:
      - Pamphlets
      security:
      - bearerAuth:
        - order-lines/read
      summary: Retrieve a pub spec url by order line, type, and format
      operationId: getPubSpec
      description: Retrieve a pub spec url for an order line.
      parameters:
      - $ref: '#/components/parameters/OrderLineIdParameter'
      - in: path
        name: type
        required: true
        schema:
          type: string
        description: Pub spec type. Currently only 'pamphlets' is supported.
      - in: path
        name: format
        required: true
        schema:
          type: string
          enum:
          - pdf
          - html
        description: File format for the generated URL.
      - in: query
        name: q
        description: For internal users only. Use Query DSL *query_string* syntax to send client id.
        schema:
          type: string
      responses:
        '200':
          description: Returns the Pub Spec URL payload for a valid identifier.
          content:
            application/json:
              schema:
                type: object
                properties:
                  pub_spec_url:
                    type: string
                    format: url
                    example: https://okc-pamphlet-bucket.s3.amazonaws.com/fc69b371-0441-4e52-84ed-153c0205e48b.pdf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=REDACTED_AWS_ACCESS_KEY_ID%2F20241016%2Fus-west-2%2Fs3%2Faws4_request&X-Amz-Date=20241016T172121Z&X-Amz-Expires=900
                  s3_key:
                    type: string
                  id:
                    type: string
                    format: uuid
                  created_at:
                    type: string
                    format: date-time
                  updated_at:
                    type: string
                    format: date-time
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          description: Error response.
  /v2/pamphlets/{orderLineId}:
    get:
      tags:
      - Pamphlets
      security:
      - bearerAuth:
        - order-lines/read
      summary: Retrieve a pamphlet url
      operationId: getPamphlet
      description: Retrieve a pamphlet url.
      parameters:
      - $ref: '#/components/parameters/OrderLineIdParameter'
      - $ref: '#/components/parameters/FormatParameter'
      - in: query
        name: q
        description: For internal users only. Use Query DSL *query_string* syntax to send client id.
        schema:
          type: string
      responses:
        '200':
          description: Returns the Pamphlet object for a valid identifier.
          content:
            application/json:
              schema:
                type: object
                properties:
                  pamphlet_url:
                    type: string
                    format: url
                    example: https://okc-pamphlet-bucket.s3.amazonaws.com/fc69b371-0441-4e52-84ed-153c0205e48b.pdf?X-Amz-Algorithm=AWS4-HMAC-SHA256&X-Amz-Content-Sha256=UNSIGNED-PAYLOAD&X-Amz-Credential=REDACTED_AWS_ACCESS_KEY_ID%2F20241016%2Fus-west-2%2Fs3%2Faws4_request&X-Amz-Date=20241016T172121Z&X-Amz-Expires=900
        default:
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorModel'
          description: Error response.
components:
  schemas:
    ErrorModel:
      title: Error Model
      description: An error response from the OK Capsule API
      type: object
      properties:
        error:
          title: Error Model Content
          type: object
          description: Error details object
          required:
          - message
          properties:
            errorCode:
              description: For some errors that could be handled programmatically, a short string indicating the error code.
              maxLength: 5000
              type: string
              example: RESOURCE_NOT_FOUND
            message:
              description: A human-readable message providing more details about the error.
              maxLength: 40000
              type: string
              example: The requested resource was not found
        message:
          description: Top-level error message (present in some error responses)
          type: string
          example: Internal Server Error
      required:
      - error
  parameters:
    FormatParameter:
      in: query
      name: format
      required: true
      schema:
        type: string
        enum:
        - pdf
        - html
    OrderLineIdParameter:
      in: path
      name: orderLineId
      required: true
      schema:
        format: uuid
        type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT