---
title: "Get payment by ID"
url: "https://kongair.terwilligar.com/apis/payments-api/versions/f6b27cfe-b147-4a9e-af56-9802bfc4bc86/operations/getPayment"
---

> Full API specification: https://kongair.terwilligar.com/apis/payments-api/versions/f6b27cfe-b147-4a9e-af56-9802bfc4bc86.md

# Get payment by ID

`GET` `/payments/{paymentId}`

Operation ID: `getPayment`

## Path parameters

- `paymentId` (string, required)

## Responses

- `200` - Payment details
- `404` - Payment not found

## OpenAPI definition

```yaml
openapi: 3.0.3
info:
  title: Payments API
  version: 1.0.1
servers:
  - url: https://api.example.com
paths:
  /payments/{paymentId}:
    get:
      summary: Get payment by ID
      operationId: getPayment
      parameters:
        - name: paymentId
          in: path
          required: true
          schema:
            type: string
      responses:
        "200":
          description: Payment details
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Payment"
        "404":
          description: Payment not found
          content:
            application/json:
              schema:
                $ref: "#/components/schemas/Error"
components:
  schemas:
    Payment:
      type: object
      required:
        - id
        - amount
        - currency
        - status
      properties:
        id:
          type: string
          example: pay_12345
        amount:
          type: number
          format: float
          example: 49.99
        currency:
          type: string
          example: USD
        status:
          type: string
          enum:
            - pending
            - completed
            - failed
        created_at:
          type: string
          format: date-time
    Error:
      type: object
      properties:
        message:
          type: string
          example: Resource not found
```
