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

# Cancel a payment



## OpenAPI

````yaml /openapi.json post /payments/{paymentId}/cancel
openapi: 3.0.0
info:
  title: Korint Documentation
  description: Korint API Documentation
  version: 1.0.0
  contact: {}
servers: []
security:
  - bearerAuth: []
tags: []
paths:
  /payments/{paymentId}/cancel:
    post:
      tags:
        - payments
        - debug
      summary: Cancel a payment
      operationId: PaymentsController_cancelPayment
      parameters:
        - name: paymentId
          required: true
          in: path
          description: the id of the payment
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CancelPaymentInputBody'
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CancelPaymentOutput'
components:
  schemas:
    CancelPaymentInputBody:
      type: object
      properties:
        reason:
          type: string
          description: the reason of the cancellation
          enum:
            - fraudulent
            - requested_by_customer
            - abandoned
            - duplicate
      required:
        - reason
    CancelPaymentOutput:
      type: object
      properties: {}

````