postzen-dev API Keys API

Manage PostZen API keys programmatically. Creating and deleting keys requires a read-write key with full profile access.

Operations 3

GET /v1/api-keys List API keys #
POST /v1/api-keys Create an API key #
DELETE /v1/api-keys/{keyId} Delete an API key #

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/postzen-dev:postzen-dev-api-keys-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

postzen-dev-api-keys-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: PostZen Public API Keys API
  version: 1.0.0
  description: The PostZen Public API lets server-side integrations manage profiles, connected social accounts, OAuth connection flows, media uploads, post creation, and outbound webhooks.
servers:
- url: https://api.postzen.dev
  description: Production API
security:
- bearerAuth: []
tags:
- name: API Keys
  x-displayName: API Keys
  description: Manage PostZen API keys programmatically. Creating and deleting keys requires a read-write key with full profile access.
paths:
  /v1/api-keys:
    get:
      tags:
      - API Keys
      operationId: listApiKeys
      summary: List API keys
      description: Returns the API keys for the authenticated account. The full key value is never returned; only a masked `keyPreview` is shown. Read-only and read-write API keys are accepted.
      responses:
        '200':
          description: API keys returned.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiKeysListResponse'
              example:
                apiKeys:
                - id: jk91m3xw7ktr5v2n8q4zs0b6hf1yg3pd
                  name: Production key
                  keyPreview: pzn_live_a1b2c3d4e...
                  createdAt: '2026-06-13T16:00:00.000Z'
                  lastUsedAt: '2026-07-22T09:14:00.000Z'
                  scope: full
                  profileIds: []
                  permission: read-write
                - id: jk52t8nqm4wr9v3c7z1p6bs0dh5fg2yx
                  name: Marketing read-only
                  keyPreview: pzn_live_9f8e7d6c5...
                  createdAt: '2026-06-19T16:00:00.000Z'
                  lastUsedAt: null
                  scope: profiles
                  profileIds:
                  - _id: jh72r5nqk9wx3v8m1t4cz6bs0fy5dg3e
                    name: Marketing Team
                    color: '#4caf50'
                  permission: read
        '401':
          $ref: '#/components/responses/Unauthorized'
        '500':
          description: Unexpected server error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: Failed to list API keys
    post:
      tags:
      - API Keys
      operationId: createApiKey
      summary: Create an API key
      description: Creates an API key and returns the full key value exactly once. This endpoint requires a read-write API key with access to all profiles; profile-scoped keys receive a `403`. Store the returned `key` securely — it cannot be retrieved again after this response.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ApiKeyCreateRequest'
            example:
              name: Production key
              scope: full
              permission: read-write
      responses:
        '201':
          description: API key created.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ApiKeyCreateResponse'
              example:
                message: API key created successfully
                apiKey:
                  id: jk91m3xw7ktr5v2n8q4zs0b6hf1yg3pd
                  name: Production key
                  keyPreview: pzn_live_3f8c1b7d4...
                  createdAt: '2026-07-23T16:00:00.000Z'
                  lastUsedAt: null
                  scope: full
                  profileIds: []
                  permission: read-write
                  key: pzn_live_3f8c1b7d4e90a1b2c3d4e5f6a7b8c9d0e1f2a3b4c5d6e7f8091a2b3c4d5e6f770
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '500':
          $ref: '#/components/responses/InternalError'
  /v1/api-keys/{keyId}:
    parameters:
    - name: keyId
      in: path
      required: true
      description: PostZen API key id.
      schema:
        type: string
    delete:
      tags:
      - API Keys
      operationId: deleteApiKey
      summary: Delete an API key
      description: Permanently revokes and deletes an API key. Requires a read-write key with full profile access. A key may delete itself.
      responses:
        '200':
          description: API key deleted.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessageResponse'
              example:
                message: API key deleted successfully
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          description: No API key exists with the given id.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
              example:
                error: API key not found
        '500':
          $ref: '#/components/responses/InternalError'
components:
  responses:
    Forbidden:
      description: The API key does not have sufficient permission or profile access.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: API key requires read_write permission
    BadRequest:
      description: Invalid request.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: JSON body is required
    Unauthorized:
      description: Missing or invalid API key.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: Unauthorized
    InternalError:
      description: Unexpected server error.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
          example:
            error: Failed to create post
  schemas:
    ApiKeyCreateResponse:
      type: object
      required:
      - message
      - apiKey
      properties:
        message:
          type: string
        apiKey:
          $ref: '#/components/schemas/ApiKeyWithSecret'
    ApiKeysListResponse:
      type: object
      required:
      - apiKeys
      properties:
        apiKeys:
          type: array
          items:
            $ref: '#/components/schemas/ApiKey'
    ApiKeyWithSecret:
      allOf:
      - $ref: '#/components/schemas/ApiKey'
      - type: object
        required:
        - key
        properties:
          key:
            type: string
            description: The full API key. Shown only once in the create response — store it securely, as it cannot be retrieved again.
    ErrorResponse:
      type: object
      required:
      - error
      properties:
        error:
          type: string
        type:
          type: string
        code:
          type: string
        param:
          type:
          - string
          - 'null'
    ApiKeyProfileRef:
      type: object
      required:
      - _id
      - name
      - color
      properties:
        _id:
          type: string
          description: PostZen profile id.
        name:
          type: string
        color:
          type: string
          description: Hex color in `#rrggbb` format.
    MessageResponse:
      type: object
      required:
      - message
      properties:
        message:
          type: string
    ApiKey:
      type: object
      required:
      - id
      - name
      - keyPreview
      - createdAt
      - lastUsedAt
      - scope
      - profileIds
      - permission
      properties:
        id:
          type: string
          description: API key id.
        name:
          type: string
          description: Human-readable label.
        keyPreview:
          type: string
          description: Masked preview of the key, for example `pzn_live_a1b2c3d4e...`. The full key is never retrievable after creation.
        createdAt:
          type: string
          format: date-time
        lastUsedAt:
          type:
          - string
          - 'null'
          format: date-time
          description: Last time the key authenticated a request, or `null` if it has never been used.
        scope:
          type: string
          enum:
          - full
          - profiles
          description: '`full` grants access to all profiles; `profiles` restricts the key to `profileIds`.'
        profileIds:
          type: array
          description: Profiles the key is restricted to. Empty for full-scope keys.
          items:
            $ref: '#/components/schemas/ApiKeyProfileRef'
        permission:
          type: string
          enum:
          - read-write
          - read
          description: '`read` keys may only call `GET` endpoints; `read-write` keys may call every endpoint.'
    ApiKeyCreateRequest:
      type: object
      required:
      - name
      properties:
        name:
          type: string
          minLength: 1
          maxLength: 100
          description: Human-readable label for the key.
        scope:
          type: string
          enum:
          - full
          - profiles
          default: full
          description: '`full` grants access to all profiles; `profiles` restricts the key to `profileIds`.'
        profileIds:
          type: array
          items:
            type: string
          description: PostZen profile ids. Required when `scope` is `profiles`, and forbidden when `scope` is `full`.
        permission:
          type: string
          enum:
          - read-write
          - read
          default: read-write
          description: '`read` keys may only call `GET` endpoints.'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: PostZen API key.