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

# Cancel a running payment session



## OpenAPI

````yaml /openapi.json post /payment-sessions/{id}/cancel
openapi: 3.0.0
info:
  title: Juicyway API
  version: 1.0.0
servers: []
security: []
tags:
  - description: Payment APIs
    name: payments
  - description: Payouts APIs
    name: payouts
  - description: Exchange APIs
    name: exchange
  - description: Wallets APIs
    name: wallets
paths:
  /payment-sessions/{id}/cancel:
    post:
      tags:
        - payments
      summary: Cancel a running payment session
      operationId: PaymentLifecycle.Web.SessionController.cancel
      parameters:
        - description: Payment Session ID
          example: 2315fca8-9aec-42ee-8bee-a9d10add170e
          in: path
          name: id
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PaymentSessionCancelParams'
        description: Cancel Payment Session Params
        required: false
      responses:
        '204':
          $ref: '#/components/responses/no_content'
        '404':
          $ref: '#/components/responses/not_found'
        '422':
          $ref: '#/components/responses/unprocessable_entity'
      callbacks: {}
components:
  schemas:
    PaymentSessionCancelParams:
      example:
        reason: Some reason
      description: Cancel Payment Session params
      properties:
        reason:
          type: string
  responses:
    no_content:
      description: No Content
    not_found:
      content:
        application/json:
          schema:
            type: string
      description: Not Found
    unprocessable_entity:
      content:
        application/json:
          schema:
            type: object
      description: Unprocessable Entity

````