{
  "opencollection": "1.0.0",
  "info": {
    "name": "Razorpay Bills Refunds API",
    "version": "1.0.0"
  },
  "request": {
    "auth": {
      "type": "basic",
      "username": "{{username}}",
      "password": "{{password}}"
    }
  },
  "items": [
    {
      "info": {
        "name": "Refunds",
        "type": "folder"
      },
      "items": [
        {
          "info": {
            "name": "Create a refund",
            "type": "http"
          },
          "http": {
            "method": "POST",
            "url": "https://api.razorpay.com/v1/payments/:id/refund",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "Payment ID to refund (pay_*). Payment must be captured."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Initiate a full or partial refund for a captured payment. Use speed=normal (default, 5-7 business days) or speed=optimum for instant refund (falls back to normal if unavailable). Use the X-Refund-Idempotency header with a unique key (>=10 chars) to safely retry without duplicate refunds."
        },
        {
          "info": {
            "name": "Fetch refunds for a payment",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.razorpay.com/v1/payments/:payment_id/refunds",
            "params": [
              {
                "name": "payment_id",
                "value": "",
                "type": "path",
                "description": "Payment ID (pay_*)."
              },
              {
                "name": "from",
                "value": "",
                "type": "query",
                "description": "Unix timestamp (seconds). Fetch records created on or after this time."
              },
              {
                "name": "to",
                "value": "",
                "type": "query",
                "description": "Unix timestamp (seconds). Fetch records created on or before this time."
              },
              {
                "name": "count",
                "value": "",
                "type": "query",
                "description": "Number of records to return per call. Maximum 100. Default 10."
              },
              {
                "name": "skip",
                "value": "",
                "type": "query",
                "description": "Number of records to skip. Use with count for pagination. Default 0."
              }
            ]
          },
          "docs": "Retrieve all refunds issued against a specific payment."
        },
        {
          "info": {
            "name": "Fetch a specific refund for a payment",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.razorpay.com/v1/payments/:payment_id/refunds/:refund_id",
            "params": [
              {
                "name": "payment_id",
                "value": "",
                "type": "path",
                "description": "Payment ID (pay_*)."
              },
              {
                "name": "refund_id",
                "value": "",
                "type": "path",
                "description": "Refund ID (rfnd_*)."
              }
            ]
          },
          "docs": "Retrieve a specific refund by its ID scoped to a particular payment."
        },
        {
          "info": {
            "name": "Fetch all refunds",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.razorpay.com/v1/refunds",
            "params": [
              {
                "name": "from",
                "value": "",
                "type": "query",
                "description": "Unix timestamp (seconds). Fetch records created on or after this time."
              },
              {
                "name": "to",
                "value": "",
                "type": "query",
                "description": "Unix timestamp (seconds). Fetch records created on or before this time."
              },
              {
                "name": "count",
                "value": "",
                "type": "query",
                "description": "Number of records to return per call. Maximum 100. Default 10."
              },
              {
                "name": "skip",
                "value": "",
                "type": "query",
                "description": "Number of records to skip. Use with count for pagination. Default 0."
              }
            ]
          },
          "docs": "Retrieve a paginated list of all refunds across payments. Maximum 100 per call."
        },
        {
          "info": {
            "name": "Fetch refund by ID",
            "type": "http"
          },
          "http": {
            "method": "GET",
            "url": "https://api.razorpay.com/v1/refunds/:id",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "Refund ID (rfnd_*)."
              }
            ]
          },
          "docs": "Retrieve full details and current status of a specific refund."
        },
        {
          "info": {
            "name": "Update a refund",
            "type": "http"
          },
          "http": {
            "method": "PATCH",
            "url": "https://api.razorpay.com/v1/refunds/:id",
            "params": [
              {
                "name": "id",
                "value": "",
                "type": "path",
                "description": "Refund ID (rfnd_*)."
              }
            ],
            "body": {
              "type": "json",
              "data": "{}"
            }
          },
          "docs": "Update the notes field of a refund. Only notes can be modified."
        }
      ]
    }
  ],
  "bundled": true
}