Cashfree Payments API

Cashfree Payments API as documented publicly: 8 operations. Contract generated from the documentation by API Evangelist (2026-10-07); not the provider's own document.

Operations 8

POST /orders/sessions Create Order #
POST /payout/transfers Process Validated Payout #
POST /pg Create Order #
POST /pg/orders POST /pg/orders #
POST /pg/orders/sessions POST /pg/orders/sessions #
POST /pg/orders/{orderid}/refunds POST /pg/orders/{orderId}/refunds #
GET /pg/orders/{orderid}/{id} GET /pg/orders/{orderId}/payments #
GET /pg/{resource} GET /pg/{resource} #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/cashfree-payments:cashfree-payments-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

cashfree-payments-openapi-generated.yml Raw ↑
openapi: 3.1.0
info:
  title: Cashfree Payments API
  version: '2026-10-07'
  description: 'GENERATED FROM DOCUMENTATION by API Evangelist on 2026-10-07: 8 operation(s) read from 11 public documentation page(s) (each operation
    names its page in x-source). This is not the provider''s published contract; Cashfree Payments has published no machine-readable contract
    that the pipeline could find. Engine: local.'
  x-evidence-tiers:
    code-example: 7
    documentation: 1
    pages-with-code: 9
    pages-read: 11
  x-generated-from: documentation
  x-provenance: generated
  x-authored-by: API Evangelist
  x-generated: '2026-10-07'
  x-generator: generate-contract-from-docs.py
  x-engine: local
  x-sources:
  - https://www.cashfree.com/docs/api-reference/authentication
  - https://www.cashfree.com/docs/api-reference/payments/latest/overview
  - https://www.cashfree.com/docs/api-reference/payments/latest/orders/create
  - https://www.cashfree.com/docs/api-reference/payments/latest/orders/get-order
  - https://www.cashfree.com/docs/api-reference/payments/latest/payments/order-pay
  - https://www.cashfree.com/docs/api-reference/payments/latest/orders/create-order
  - https://www.cashfree.com/docs/api-reference/payments/latest/refunds/create-refund
  - https://www.cashfree.com/docs/api-reference/payments/latest/payments/get-payments-for-an-order
  - https://www.cashfree.com/docs/llms.txt
  - https://www.cashfree.com/docs/payments/online/mobile/ios
  - https://www.cashfree.com/docs/payments/online/mobile/android
servers:
- url: https://sandbox.cashfree.com
paths:
  /orders/sessions:
    post:
      operationId: post_orders_sessions
      tags:
      - Orders
      summary: Create Order
      description: Use this API to create orders with Cashfree from your backend and get the payment link.
      x-source: https://www.cashfree.com/docs/api-reference/payments/latest/overview
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /payout/transfers:
    post:
      operationId: post_payout_transfers
      tags:
      - Payout
      summary: Process Validated Payout
      x-source: https://www.cashfree.com/docs/llms.txt
      responses:
        '201':
          description: Success (status as documented)
      x-evidence:
        kind: documentation
  /pg:
    post:
      operationId: post_pg
      tags:
      - Pg
      summary: Create Order
      x-source: https://www.cashfree.com/docs/api-reference/payments/latest/orders/create
      parameters:
      - name: x-client-id
        in: header
        required: true
        schema:
          type: string
        description: Client app ID.
      - name: x-client-secret
        in: header
        required: true
        schema:
          type: string
        description: Client secret key.
      - name: x-api-version
        in: header
        required: true
        schema:
          type: string
        description: API version to be used.
      - name: x-request-id
        in: header
        required: false
        schema:
          type: string
        description: Request ID for the API call.
      - name: x-idempotency-key
        in: header
        required: false
        schema:
          type: string
        description: Idempotency key to avoid duplicate actions.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PostPgRequest'
      responses:
        '200':
          description: Success (status as documented)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PostPgResponse'
      x-evidence:
        kind: documentation
  /pg/orders:
    post:
      operationId: post_pg_orders
      tags:
      - Pg
      summary: POST /pg/orders
      x-source: https://www.cashfree.com/docs/api-reference/payments/latest/orders/create
      responses:
        '201':
          description: Success (shape read from the example response on the page)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PostPgOrdersResponse'
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl order_with_minimum_fields curl --request POST  --url https://sandbox.cashfree.com/pg/orders  --header 'Content-Type: application/json'\
          \  --header 'x-api-version: <x-api-version>'  --header 'x-client-id: <api-key>'  --header 'x-client-secret: <api-key>'  --data ' \n\
          \ { \n \"order_currency\": \"INR\", \n \"order_amount\": 10.34, \n \"customer_details\": { \n \"customer_id\": \"7112AAA812234\", \n\
          \ \"customer_phone\":"
  /pg/orders/sessions:
    post:
      operationId: post_pg_orders_sessions
      tags:
      - Pg
      summary: POST /pg/orders/sessions
      x-source: https://www.cashfree.com/docs/api-reference/payments/latest/payments/order-pay
      responses:
        '201':
          description: Success (shape read from the example response on the page)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PostPgOrdersSessionsResponse'
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl upi_intent curl --request POST  --url https://sandbox.cashfree.com/pg/orders/sessions  --header 'Content-Type: application/json'\
          \  --header 'x-api-version: <x-api-version>'  --data '\n{\n \"payment_session_id\": \"session__someidwhichislongandhasnumbers1232132andcharacterscn\"\
          ,\n \"transaction_expiry_time\": \"2021-07-02T10:20:12+05:30\",\n \"payment_method\": {\n \"upi\": {\n \"channel\": \"link\"\n }\n }\n\
          }\n' 200 ca"
  /pg/orders/{orderid}/refunds:
    post:
      operationId: post_pg_orders_orderid_refunds
      tags:
      - Pg
      summary: POST /pg/orders/{orderId}/refunds
      x-source: https://www.cashfree.com/docs/api-reference/payments/latest/refunds/create-refund
      parameters:
      - name: orderid
        in: path
        required: true
        schema:
          type: string
      responses:
        '201':
          description: Success (shape read from the example response on the page)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PostPgOrdersOrderidRefundsResponse'
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl curl --request POST  --url https://sandbox.cashfree.com/pg/orders/{order_id}/refunds  --header 'Content-Type: application/json'\
          \  --header 'x-api-version: <x-api-version>'  --header 'x-client-id: <api-key>'  --header 'x-client-secret: <api-key>'  --data '\n{\n\
          \ \"refund_amount\": 1,\n \"refund_id\": \"refund_00912\",\n \"refund_note\": \"refund note for reference\",\n \"refund_speed\": \"\
          STANDARD\"\n}\n' import req"
  /pg/orders/{orderid}/{id}:
    get:
      operationId: get_pg_orders_orderid_id
      tags:
      - Pg
      summary: GET /pg/orders/{orderId}/payments
      x-source: https://www.cashfree.com/docs/api-reference/payments/latest/payments/get-payments-for-an-order
      parameters:
      - name: orderid
        in: path
        required: true
        schema:
          type: string
      - name: id
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success (shape read from the example response on the page)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/GetPgOrdersOrderidIdResponse'
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl curl --request GET  --url https://sandbox.cashfree.com/pg/orders/{order_id}/payments  --header 'x-api-version: <x-api-version>'\
          \  --header 'x-client-id: <api-key>'  --header 'x-client-secret: <api-key>' import requests\nurl = \"https://sandbox.cashfree.com/pg/orders/{order_id}/payments\"\
          \nheaders = {\n \"x-api-version\": \"<x-api-version>\",\n \"x-client-id\": \"<api-key>\",\n \"x-client-secret\": \"<api-key>\"\n"
        collapsed_from: 2 example path(s) differing only at id
  /pg/{resource}:
    get:
      operationId: get_pg_resource
      tags:
      - Pg
      summary: GET /pg/{resource}
      x-source: https://www.cashfree.com/docs/api-reference/authentication
      parameters:
      - name: resource
        in: path
        required: true
        schema:
          type: string
      responses:
        '200':
          description: Success (status as documented)
      x-evidence:
        kind: code-example
        language: curl
        snippet: "curl --request {REQUEST-TYPE}  --url https://sandbox.cashfree.com/pg/{resource}  --header 'Content-Type: application/json' \
          \ --header 'x-api-version: 2025-01-01'  --header 'x-client-id: <YOUR_APP_ID>'  --header 'x-client-secret: <YOUR_SECRET_KEY>' \n ...\
          \ \n ... \n ​ Generate API keys \n Each Cashfree product requires its own unique client ID and client secret. For example, if you are\
          \ using both the Pay"
components:
  schemas:
    PostPgRequest:
      type: object
      properties:
        order_amount:
          type: number
          description: Bill amount for the order.
        order_currency:
          type: string
          description: Currency for the order.
        order_id:
          type: string
          description: Order identifier present in your system.
        cart_details:
          type: object
          description: The cart details that are necessary like shipping address, billing address and more.
        customer_details:
          type: object
          description: The customer details that are necessary.
        terminal:
          type: object
          description: Use this if you are creating an order for cashfree's softPOS.
        order_meta:
          type: object
          description: Optional meta details to control how the customer pays and how payment journey completes.
        order_expiry_time:
          type: string
          description: Time after which the order expires.
        order_note:
          type: string
          description: Order note for reference.
        order_tags:
          type: object
          description: Custom tags in the form of {"key":"value"}.
        order_splits:
          type: array
          description: If Easy split is enabled, use this to split the order amount.
        products:
          type: object
          description: Configurations for the products like One Click Checkout, Verify and Pay.
      required:
      - order_amount
      - order_currency
    PostPgResponse:
      type: object
      properties:
        cf_order_id:
          type: string
          description: Unique id generated by cashfree for your order.
        order_id:
          type: string
          description: order_id sent during the api request.
        entity:
          type: string
          description: Type of the entity.
        order_currency:
          type: string
          description: Currency of the order.
        order_amount:
          type: number
          description: Order amount.
        order_status:
          type: string
          description: Status of the order.
        payment_session_id:
          type: string
          description: Payment session identifier.
        order_expiry_time:
          type: string
          description: Order expiry timestamp.
        order_note:
          type: string
          description: Additional note for order.
        created_at:
          type: string
          description: When the order was created at cashfree's server.
        customer_details:
          type: object
          description: Customer details returned in the response.
        order_meta:
          type: object
          description: Meta details returned in the response.
        order_tags:
          type: object
          description: Custom tags returned in the response.
        order_splits:
          type: array
          description: Order splits returned in the response.
        cart_details:
          type: object
          description: Cart details returned in the response.
        terminal_data:
          type: object
          description: Terminal data returned in the response.
        products:
          type: object
          description: Product configurations returned in the response.
    PostPgOrdersResponse:
      type: object
      properties:
        cf_order_id:
          type: string
        created_at:
          type: string
          format: date-time
        customer_details:
          type: object
          properties:
            customer_id:
              type: string
            customer_name:
              type: string
            customer_email:
              type: string
            customer_phone:
              type: string
            customer_uid:
              type: string
        entity:
          type: string
        order_amount:
          type: integer
        payment_session_id:
          type: string
        order_currency:
          type: string
        order_expiry_time:
          type: string
          format: date-time
        order_id:
          type: string
        order_meta:
          type: object
          properties:
            return_url:
              type: string
            payment_methods:
              type: string
            notify_url:
              type: string
        order_note:
          type: string
        order_splits:
          type: array
          items: {}
        order_status:
          type: string
        order_tags:
          type: object
          properties:
            name:
              type: string
            age:
              type: string
        terminal_data:
          type:
          - string
          - 'null'
        cart_details:
          type: object
          properties:
            cart_id:
              type: string
    PostPgOrdersSessionsResponse:
      type: object
      properties:
        action:
          type: string
        cf_payment_id:
          type: string
        channel:
          type: string
        payment_amount:
          type: number
        payment_method:
          type: string
        data:
          type: object
          properties:
            url:
              type: string
            payload:
              type:
              - string
              - 'null'
            content_type:
              type:
              - string
              - 'null'
            method:
              type:
              - string
              - 'null'
    PostPgOrdersOrderidRefundsResponse:
      type: object
      properties:
        cf_payment_id:
          type: string
        cf_refund_id:
          type: string
        refund_id:
          type: string
        order_id:
          type: string
        entity:
          type: string
        refund_amount:
          type: number
        refund_currency:
          type: string
        refund_note:
          type: string
        refund_status:
          type: string
        refund_type:
          type: string
        refund_splits:
          type: array
          items: {}
        status_description:
          type: string
        refund_arn:
          type: string
        metadata:
          type:
          - string
          - 'null'
        created_at:
          type: string
          format: date-time
        processed_at:
          type: string
          format: date-time
        refund_charge:
          type: integer
        refund_mode:
          type: string
        forex_conversion_handling_charge:
          type: number
        forex_conversion_handling_tax:
          type: number
        forex_conversion_rate:
          type: number
        charges_currency:
          type: string
    GetPgOrdersOrderidIdResponse:
      type: object
      properties:
        method:
          type: string
        headers:
          type: object
          properties:
            x-api-version:
              type: string
            x-client-id:
              type: string
            x-client-secret:
              type: string
  securitySchemes:
    Merchant_authentication:
      type: apiKey
      in: header
      name: x-client-id
      x-source: https://www.cashfree.com/docs/api-reference/authentication
    Merchant_secret:
      type: apiKey
      in: header
      name: x-client-secret
      x-source: https://www.cashfree.com/docs/api-reference/authentication
    Partner_authentication:
      type: apiKey
      in: header
      name: x-partner-apikey
      x-source: https://www.cashfree.com/docs/api-reference/authentication
    Partner_merchant_ID:
      type: apiKey
      in: header
      name: x-partner-merchantid
      x-source: https://www.cashfree.com/docs/api-reference/authentication
tags:
- name: Orders
- name: Payout
- name: Pg
security:
- Merchant_authentication: []
- Merchant_secret: []
- Partner_authentication: []
- Partner_merchant_ID: []