{
  "info": {
    "name": "XPayr Payment & Webhook API v1",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json",
    "description": "Postman Collection for testing XPayr payment checkout sessions, router conversions, and webhook signatures."
  },
  "item": [
    {
      "name": "Create Payment Session",
      "request": {
        "method": "POST",
        "header": [
          { "key": "Authorization", "value": "Bearer sk_test_...", "type": "text" },
          { "key": "Content-Type", "value": "application/json", "type": "text" }
        ],
        "body": {
          "mode": "raw",
          "raw": "{\n  \"amount\": 50.00,\n  \"currency\": \"USD\",\n  \"order_id\": \"ORD-12345\",\n  \"coupon_code\": \"XPAYR-DEMO\"\n}"
        },
        "url": {
          "raw": "https://xpayr.com/api/v1/payments",
          "protocol": "https",
          "host": ["xpayr", "com"],
          "path": ["api", "v1", "payments"]
        }
      }
    },
    {
      "name": "Test Webhook Endpoint",
      "request": {
        "method": "POST",
        "header": [
          { "key": "X-XPayr-Signature", "value": "sha256=...", "type": "text" },
          { "key": "Content-Type", "value": "application/json", "type": "text" }
        ],
        "body": {
          "mode": "raw",
          "raw": "{\n  \"event\": \"payment.confirmed\",\n  \"order_id\": \"ORD-12345\",\n  \"amount\": \"50.00\",\n  \"status\": \"confirmed\"\n}"
        },
        "url": {
          "raw": "https://xpayr.com/api/webhook_test.php",
          "protocol": "https",
          "host": ["xpayr", "com"],
          "path": ["api", "webhook_test.php"]
        }
      }
    }
  ]
}
