{
  "info": {
    "_postman_id": "thai-fx-compare-public-api",
    "name": "Thai FX Compare API",
    "description": "Free beta endpoints for normalized Thai bank TT exchange rates. No API key required.",
    "schema": "https://schema.getpostman.com/json/collection/v2.1.0/collection.json"
  },
  "variable": [
    {
      "key": "baseUrl",
      "value": "https://fxratetracker.njtools.workers.dev"
    },
    {
      "key": "currency",
      "value": "CNY"
    }
  ],
  "item": [
    {
      "name": "Public",
      "item": [
        {
          "name": "Current rates",
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/api/public/rates?currency={{currency}}&side=selling",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "api",
                "public",
                "rates"
              ],
              "query": [
                {
                  "key": "currency",
                  "value": "{{currency}}"
                },
                {
                  "key": "side",
                  "value": "selling"
                }
              ]
            },
            "description": "No API key required. Returns current bank-published TT rates ranked best-first."
          }
        },
        {
          "name": "Banks",
          "request": {
            "method": "GET",
            "header": [],
            "url": {
              "raw": "{{baseUrl}}/api/public/banks",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "api",
                "public",
                "banks"
              ]
            }
          }
        }
      ]
    },
    {
      "name": "Free API v1",
      "item": [
        {
          "name": "Current rates (authenticated)",
          "request": {
            "method": "GET",
            "url": {
              "raw": "{{baseUrl}}/api/v1/rates/{{currency}}?side=selling",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "api",
                "v1",
                "rates",
                "{{currency}}"
              ],
              "query": [
                {
                  "key": "side",
                  "value": "selling"
                }
              ]
            }
          }
        },
        {
          "name": "History",
          "request": {
            "method": "GET",
            "url": {
              "raw": "{{baseUrl}}/api/v1/history/{{currency}}?bank=BOCT&days=30&side=selling",
              "host": [
                "{{baseUrl}}"
              ],
              "path": [
                "api",
                "v1",
                "history",
                "{{currency}}"
              ],
              "query": [
                {
                  "key": "bank",
                  "value": "BOCT"
                },
                {
                  "key": "days",
                  "value": "30"
                },
                {
                  "key": "side",
                  "value": "selling"
                }
              ]
            }
          }
        }
      ]
    }
  ]
}
