> ## Documentation Index
> Fetch the complete documentation index at: https://developer.notchpay.co/llms.txt
> Use this file to discover all available pages before exploring further.

# Initialize a payment



## OpenAPI

````yaml openapi.yaml post /payments
openapi: 3.1.0
info:
  title: Notch Pay API
  description: API for integrating payment and money transfer services into applications.
  version: 2.1.0
servers:
  - url: https://api.notchpay.co
    description: Production and Sandbox Environment
security: []
paths:
  /payments:
    post:
      summary: Initialize a payment
      operationId: initializePayment
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                amount:
                  type: number
                  example: 5000
                currency:
                  type: string
                  example: XAF
                email:
                  type: string
                  example: john@example.com
                phone:
                  type: string
                  example: 237600000000
                customer:
                  oneOf:
                    - type: string
                      example: cus_123456789
                    - type: object
                      properties:
                        name:
                          type: string
                          example: John Doe
                        email:
                          type: string
                          example: john@example.com
                        phone:
                          type: string
                          example: 237600000000
                description:
                  type: string
                  example: Paiement pour commande
                reference:
                  type: string
                  example: order_123
                callback:
                  type: string
                  example: https://example.com/callback
                locked_currency:
                  type: string
                  example: XAF
                locked_channel:
                  type: string
                  example: cm.mtn
                locked_country:
                  type: string
                  example: CM
                items:
                  type: array
                  items:
                    type: object
                shipping:
                  type: object
                address:
                  type: object
                customer_meta:
                  type: object
              required:
                - amount
                - currency
              oneOf:
                - required:
                    - email
                - required:
                    - phone
                - required:
                    - customer
      responses:
        '201':
          description: Payment initialized
          content:
            application/json:
              schema:
                type: object
                properties:
                  status:
                    type: string
                    example: Accepted
                  message:
                    type: string
                    example: Payment initialized
                  code:
                    type: integer
                    example: 201
                  transaction: 81fca0c3-5d41-48b6-bb4b-be7bb4a34fa1
                  authorization_url:
                    type: string
                    example: https://pay.notchpay.co/pay_123456789
                required:
                  - status
                  - message
                  - code
                  - transaction
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: b29a71d3-4f97-40ed-a676-731aa1fbe742
        '422':
          description: Unprocessable Entity
          content:
            application/json:
              schema:
                $ref: b29a71d3-4f97-40ed-a676-731aa1fbe742
      security:
        - ApiKeyAuth: []
        - SyncAuth: []
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: Authorization
    SyncAuth:
      type: apiKey
      in: header
      name: X-Sync

````