Zero Hash Organization Token API

The Organization Token API from Zero Hash — 1 operation(s) for organization token.

Documentation

Specifications

Other Resources

OpenAPI Specification

zero-hash-organization-token-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Connect Organization Token API
  description: Session management endpoint for Connect API
  version: 1.0.0
servers:
- url: https://api.sandbox.connect.xyz
  description: Sandbox Environment
tags:
- name: Organization Token
paths:
  /api/v1/oauth/token:
    post:
      tags:
      - Organization Token
      summary: Generate access token
      description: Request an OAuth2 access token for API authentication. Use the returned token in a subsequent /sessions call.
      operationId: getAccessToken
      x-group:
        name: Invoke SDK
      servers:
      - url: https://api.sandbox.connect.xyz
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TokenRequest'
            example:
              client_id: clt_4a7b2f8e9d1c5x6y3z8w2v5u7t9r1q4e
              client_secret: cs_9x8w7v6u5t4r3q2p1o9n8m7l6k5j4i3h2g1f0e9d8c7b6a5z4y3x2w1v0u9
              audience: https://api.cert.connect.xyz
              grant_type: client_credentials
              organization_id: f446f14c-4035-4105-892b-1649bff16424
      responses:
        '200':
          description: Access token generated successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TokenResponse'
              example:
                access_token: eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImlkIn0...
                expires_in: 86400
                token_type: Bearer
        '400':
          description: Bad Request - Invalid client credentials or parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AuthError'
              example:
                error: invalid_client
                error_description: Invalid client credentials
        '401':
          description: Unauthorized - Invalid client credentials
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AuthError'
              example:
                error: invalid_client
                error_description: Client authentication failed
components:
  schemas:
    TokenResponse:
      type: object
      required:
      - access_token
      - expires_in
      - token_type
      properties:
        access_token:
          type: string
          description: JWT access token
          example: eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCIsImtpZCI6ImlkIn0...
        expires_in:
          type: integer
          description: Token expiration time in seconds
          example: 86400
        token_type:
          type: string
          description: Token type
          example: Bearer
    AuthError:
      type: object
      required:
      - error
      properties:
        error:
          type: string
          description: OAuth2 error code
          example: invalid_client
        error_description:
          type: string
          description: Human-readable error description
          example: Invalid client credentials
    TokenRequest:
      type: object
      required:
      - client_id
      - client_secret
      - audience
      - grant_type
      - organization_id
      properties:
        client_id:
          type: string
          description: OAuth2 client ID
          example: clt_4a7b2f8e9d1c5x6y3z8w2v5u7t9r1q4e
        client_secret:
          type: string
          description: OAuth2 client secret
          example: cs_9x8w7v6u5t4r3q2p1o9n8m7l6k5j4i3h2g1f0e9d8c7b6a5z4y3x2w1v0u9
        audience:
          type: string
          description: API audience identifier
          example: https://api.cert.connect.xyz
        grant_type:
          type: string
          description: OAuth2 grant type
          enum:
          - client_credentials
          example: client_credentials
        organization_id:
          type: string
          description: Organization identifier
          example: f446f14c-4035-4105-892b-1649bff16424
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: JWT token with customers:token:issue scope
x-readme:
  explorer-enabled: true
  proxy-enabled: true