Peach Payments Payment Links API

Shareable, single-use and bulk payment links.

OpenAPI Specification

peachpayments-payment-links-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: Peach Payments Authentication Payment Links API
  description: Payment orchestration APIs for Peach Payments, a pan-African payment gateway (South Africa, Kenya, Mauritius). Covers OAuth authentication, Checkout (Hosted / Embedded / Embedded Express), the Payments API for server-to-server debits and refunds, Payment Links, Payouts, and Reconciliation. Card processing is PCI DSS Level 1 certified. Auth is OAuth 2.0 client-credentials (clientId + clientSecret + merchantId -> Bearer access_token) for Checkout / Payouts / Reconciliation, and an inline authentication object (userId + password + entityId) for the server-to-server Payments API.
  version: '1.0'
  contact:
    name: Peach Payments Developer Support
    url: https://developer.peachpayments.com
  termsOfService: https://www.peachpayments.com/terms-and-conditions
servers:
- url: https://sandbox-dashboard.peachpayments.com
  description: Sandbox authentication host (OAuth token)
- url: https://dashboard.peachpayments.com
  description: Live authentication host (OAuth token)
tags:
- name: Payment Links
  description: Shareable, single-use and bulk payment links.
paths:
  /api/channels/{entityId}/payments:
    servers:
    - url: https://testlinks.ppay.io
      description: Sandbox Payment Links host
    - url: https://links.peachpayments.com
      description: Live Payment Links host
    post:
      operationId: createPaymentLink
      tags:
      - Payment Links
      summary: Generate a payment link.
      description: Create a shareable payment link for a channel (entityId). Requires a Bearer access_token, amount, currency, and an expiry.
      security:
      - bearerAuth: []
      parameters:
      - name: entityId
        in: path
        required: true
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PaymentLinkRequest'
      responses:
        '200':
          description: Payment link created.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PaymentLinkResponse'
    get:
      operationId: listPaymentLinks
      tags:
      - Payment Links
      summary: Retrieve all payment links.
      description: List payment links for a channel (entityId).
      security:
      - bearerAuth: []
      parameters:
      - name: entityId
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Payment links.
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/PaymentLinkResponse'
  /api/payments/{paymentId}:
    servers:
    - url: https://testlinks.ppay.io
    - url: https://links.peachpayments.com
    delete:
      operationId: cancelPaymentLink
      tags:
      - Payment Links
      summary: Cancel a payment link.
      description: Cancel a previously generated payment link.
      security:
      - bearerAuth: []
      parameters:
      - name: paymentId
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Payment link cancelled.
        '404':
          description: Payment link not found.
components:
  schemas:
    PaymentLinkResponse:
      type: object
      properties:
        paymentId:
          type: string
        url:
          type: string
          format: uri
        status:
          type: string
        amount:
          type: string
        currency:
          type: string
    PaymentLinkRequest:
      type: object
      required:
      - amount
      - currency
      properties:
        amount:
          type: string
        currency:
          type: string
          example: ZAR
        expiresAt:
          type: string
          format: date-time
        description:
          type: string
        notificationUrl:
          type: string
          format: uri
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: 'OAuth 2.0 access_token obtained from POST /api/oauth/token, sent as Authorization: Bearer {access_token}.'