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

# Get an Approval Request

> Follow a request held for the merchant's approval.

When a payout or channel change returns `202` with `status: "PENDING_APPROVAL"`, poll this endpoint with the `approvalId`, for example every few seconds.

| `status` | Meaning |
| - | - |
| `PENDING_APPROVAL` | Waiting for the merchant in the console |
| `APPROVED` | Approved and running (brief) |
| `EXECUTED` | Done. `result` is the response the original request would have returned |
| `FAILED` | Approved, but PalPluss couldn't complete it. `error` says why |
| `REJECTED` | The merchant declined. `error.message` may carry their reason |
| `EXPIRED` | Nobody decided within 15 minutes. Nothing happened |

Don't repeat the original request while it's pending. With the same `Idempotency-Key` you'd get the same approval back anyway.


## OpenAPI

````yaml GET /approvals/{id}
openapi: 3.1.0
info:
  title: PalPluss API
  version: '1.0'
  summary: >-
    Payment infrastructure for Kenya — STK Push, B2C payouts, and wallet
    management.
  description: >
    The PalPluss API gives developers programmatic access to M-Pesa STK Push
    collections,

    B2C payouts, service wallet top-ups, and payment channel management.


    **Base URL:** `https://api.palpluss.com/v1`


    All requests must be authenticated with an API key using HTTP Basic Auth.

    All responses are wrapped in a standard envelope. See [Errors](#tag/errors)
    for error codes.


    Amounts are in **KES (Kenyan Shillings)** unless stated otherwise. Phone
    numbers

    are normalized to the `254XXXXXXXXX` format internally.
  contact:
    name: PalPluss Developer Support
    email: developer@palpluss.com
    url: https://palpluss.com/developers
servers:
  - url: https://api.palpluss.com/v1
    description: Production (live and test keys use the same URL)
security:
  - BasicAuth: []
tags:
  - name: STK Push
    description: >
      Initiate M-Pesa STK Push payment prompts. The customer receives a PIN
      prompt on their

      phone and confirms payment. PalPluss delivers the result asynchronously to
      your webhook URL.
  - name: Transactions
    description: >-
      Query the status of any transaction by ID, or list all transactions with
      filters.
  - name: B2C Payouts
    description: >
      Send money directly to a customer's M-Pesa number. Requires KYC approval
      and sufficient

      B2C wallet balance. Payouts are processed asynchronously.
  - name: Service Wallet
    description: >
      The service wallet holds pre-funded tokens used to pay PalPluss
      transaction fees.

      Top up via STK Push. Balance is deducted with each API call.
  - name: Payment Channels
    description: >
      Payment channels represent the M-Pesa shortcodes (Paybill / Till)
      associated with your

      account. Channels are used to route STK Push requests to a specific
      shortcode.
  - name: Payment Links
    description: >
      Hosted pages where a customer enters their number and pays by STK Push.
      Live keys can

      create and disable links; test keys can only read them.
  - name: Account
    description: The calling API key, fee estimates and wallet history.
  - name: Approvals
    description: >
      Payouts and channel changes made with MCP keys that PalPluss holds until
      the merchant

      approves them in the console.
paths:
  /approvals/{id}:
    get:
      tags:
        - Approvals
      summary: Get an approval request
      description: >
        Poll a request returned with `202 PENDING_APPROVAL`. Final states:
        `EXECUTED` (see

        `result`), `REJECTED`, `EXPIRED` (after 15 minutes) or `FAILED` (see
        `error`).
      operationId: getApproval
      parameters:
        - name: id
          in: path
          required: true
          schema:
            type: string
            format: uuid
      responses:
        '200':
          description: The request.
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/SuccessEnvelope'
                  - type: object
                    properties:
                      data:
                        $ref: '#/components/schemas/ApprovalRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
components:
  schemas:
    SuccessEnvelope:
      type: object
      required:
        - success
        - data
        - requestId
      properties:
        success:
          type: boolean
          example: true
        data:
          type: object
          description: Response payload. Shape varies by endpoint.
        requestId:
          type: string
          format: uuid
          description: Unique identifier for this API request. Include in support tickets.
          example: c1b2a3d4-e5f6-7890-abcd-ef1234567890
    ApprovalRequest:
      type: object
      properties:
        id:
          type: string
          format: uuid
        action:
          type: string
          enum:
            - PAYOUT
            - CHANNEL_CREATE
            - CHANNEL_UPDATE
            - CHANNEL_DELETE
            - CHANNEL_SET_DEFAULT
        status:
          $ref: '#/components/schemas/ApprovalStatus'
        summary:
          type: object
          description: What the merchant was shown.
        amount:
          type: number
          nullable: true
        result:
          type: object
          nullable: true
          description: The API response of the executed request (e.g. the payout).
        error:
          type: object
          nullable: true
          properties:
            message:
              type: string
            code:
              type: string
        expiresAt:
          type: string
          format: date-time
          nullable: true
        decidedAt:
          type: string
          format: date-time
          nullable: true
        executedAt:
          type: string
          format: date-time
          nullable: true
        createdAt:
          type: string
          format: date-time
    ApprovalStatus:
      type: string
      enum:
        - PENDING_APPROVAL
        - APPROVED
        - REJECTED
        - EXPIRED
        - EXECUTED
        - FAILED
    ErrorEnvelope:
      type: object
      required:
        - success
        - error
        - requestId
      properties:
        success:
          type: boolean
          example: false
        error:
          type: object
          required:
            - message
            - code
          properties:
            message:
              type: string
              description: Human-readable error description.
              example: Invalid API key
            code:
              type: string
              description: Machine-readable error code.
              example: INVALID_API_KEY
            details:
              type: object
              description: Optional structured details about the error.
        requestId:
          type: string
          format: uuid
          example: c1b2a3d4-e5f6-7890-abcd-ef1234567890
  responses:
    Unauthorized:
      description: Missing, invalid, or revoked API key.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorEnvelope'
          examples:
            invalid_key:
              value:
                success: false
                error:
                  message: Invalid or revoked API key.
                  code: INVALID_API_KEY
                  details: {}
                requestId: a1b2c3d4-0000-0000-0000-000000000000
    NotFound:
      description: The requested resource does not exist.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorEnvelope'
          examples:
            not_found:
              value:
                success: false
                error:
                  message: Transaction not found.
                  code: TRANSACTION_NOT_FOUND
                  details: {}
                requestId: a1b2c3d4-0000-0000-0000-000000000000
  securitySchemes:
    BasicAuth:
      type: http
      scheme: basic
      description: >
        Paste your PalPluss API key in the **username** field and leave the

        **password** field empty — it is ignored.


        Get your key from **console → API Keys**. Live keys start with
        `pp_live_`,

        test keys (simulated money) with `pp_test_`.


        In your own code, send the key directly:

        `Authorization: Basic YOUR_API_KEY`

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.