Pomelo Transfers API

Money movement and settlements across card accounts.

OpenAPI Specification

pomelo-transfers-api-openapi.yml Raw ↑
openapi: 3.0.1
info:
  title: Pomelo Authentication Transfers API
  description: REST API for Pomelo (pomelo.la), the Latin American card-issuing and embedded-finance platform. Covers user onboarding and identity verification (KYC/KYB), card issuing and lifecycle management, card accounts and balances, transaction processing and history, transfers and settlements, and the real-time authorizer plus event webhooks. Authentication uses the OAuth 2.0 client-credentials grant; the issued JWT is sent as a Bearer token on every request.
  termsOfService: https://www.pomelo.la
  contact:
    name: Pomelo Developers
    url: https://developers.pomelo.la
  version: '1.0'
servers:
- url: https://api.pomelo.la
  description: Pomelo production API
- url: https://auth.pomelo.la
  description: Pomelo OAuth 2.0 token issuer
security:
- bearerAuth: []
tags:
- name: Transfers
  description: Money movement and settlements across card accounts.
paths:
  /transfers/v1:
    post:
      operationId: createTransfer
      tags:
      - Transfers
      summary: Create a transfer.
      description: Move funds between card accounts to fund or reconcile the program.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TransferRequest'
      responses:
        '201':
          description: Transfer created.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TransferEnvelope'
        '400':
          $ref: '#/components/responses/BadRequest'
    get:
      operationId: searchTransfers
      tags:
      - Transfers
      summary: Search transfers.
      parameters:
      - $ref: '#/components/parameters/PageSize'
      - $ref: '#/components/parameters/PageNumber'
      responses:
        '200':
          description: Matching transfers.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TransferList'
  /transfers/v1/{id}:
    parameters:
    - name: id
      in: path
      required: true
      schema:
        type: string
    get:
      operationId: getTransfer
      tags:
      - Transfers
      summary: Get a transfer.
      responses:
        '200':
          description: The requested transfer.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TransferEnvelope'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  parameters:
    PageNumber:
      name: page[number]
      in: query
      schema:
        type: integer
        default: 0
    PageSize:
      name: page[size]
      in: query
      schema:
        type: integer
        default: 25
  schemas:
    PageMeta:
      type: object
      properties:
        pagination:
          type: object
          properties:
            page_size:
              type: integer
            page_number:
              type: integer
            total_pages:
              type: integer
            total_elements:
              type: integer
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            details:
              type: array
              items:
                type: object
                properties:
                  code:
                    type: string
                  detail:
                    type: string
    TransferRequest:
      type: object
      required:
      - origin_account_id
      - destination_account_id
      - amount
      properties:
        origin_account_id:
          type: string
        destination_account_id:
          type: string
        amount:
          type: number
          format: double
        currency:
          type: string
        description:
          type: string
    TransferEnvelope:
      type: object
      properties:
        data:
          $ref: '#/components/schemas/Transfer'
    Transfer:
      type: object
      properties:
        id:
          type: string
        origin_account_id:
          type: string
        destination_account_id:
          type: string
        amount:
          type: number
          format: double
        currency:
          type: string
        status:
          type: string
          enum:
          - PENDING
          - COMPLETED
          - REJECTED
        created_at:
          type: string
          format: date-time
    TransferList:
      type: object
      properties:
        data:
          type: array
          items:
            $ref: '#/components/schemas/Transfer'
        meta:
          $ref: '#/components/schemas/PageMeta'
  responses:
    NotFound:
      description: Resource not found.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    BadRequest:
      description: Invalid request.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: OAuth 2.0 client-credentials access token issued by /oauth/token.
    oauth2:
      type: oauth2
      flows:
        clientCredentials:
          tokenUrl: https://auth.pomelo.la/oauth/token
          scopes: {}