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

# Postman

> Ready-to-import collection to try the whole API

export const PostmanFreshness = ({iso, lang = "es"}) => {
  const [now, setNow] = useState(() => Date.now());
  useEffect(() => {
    const t = setInterval(() => setNow(Date.now()), 1000);
    return () => clearInterval(t);
  }, []);
  const ts = new Date(iso).getTime();
  if (!iso || Number.isNaN(ts)) {
    return null;
  }
  const secs = Math.max(0, Math.floor((now - ts) / 1000));
  const UNITS = {
    en: [[31536000, "year", "years"], [2592000, "month", "months"], [86400, "day", "days"], [3600, "hour", "hours"], [60, "minute", "minutes"], [1, "second", "seconds"]],
    es: [[31536000, "año", "años"], [2592000, "mes", "meses"], [86400, "día", "días"], [3600, "hora", "horas"], [60, "minuto", "minutos"], [1, "segundo", "segundos"]],
    zh: [[31536000, "年", "年"], [2592000, "个月", "个月"], [86400, "天", "天"], [3600, "小时", "小时"], [60, "分钟", "分钟"], [1, "秒", "秒"]]
  };
  const units = UNITS[lang] || UNITS.es;
  let rel;
  for (const [size, one, many] of units) {
    if (secs >= size || size === 1) {
      const n = Math.floor(secs / size);
      const unit = n === 1 ? one : many;
      rel = lang === "en" ? `${n} ${unit} ago` : lang === "zh" ? `${n}${unit}前` : `hace ${n} ${unit}`;
      break;
    }
  }
  const label = lang === "en" ? `Updated ${rel}` : lang === "zh" ? `更新于${rel}` : `Actualizada ${rel}`;
  return <p className="text-sm text-gray-500 dark:text-zinc-400">
      <strong>{label}</strong>
    </p>;
};

Download the official CBPay Postman collection, generated from the same
OpenAPI specification behind this documentation: every endpoint, with one
request per use case (each named example in the spec) and one saved
response per operation.

<Card title="CBPay API — Postman collection" icon="download" href="/postman/cbpay-api.postman_collection.json">
  Download `cbpay-api.postman_collection.json` (v2.1)
</Card>

> **Collection updated:** 2026-07-18 19:19 UTC · 252 requests · version `a4f0a3b6ae5b`

<PostmanFreshness iso="2026-07-18T19:19:00Z" lang="en" />

## How to use it

<Steps>
  <Step title="Import the collection">
    In Postman: **Import** → drag the downloaded file.
  </Step>

  <Step title="Set your variables">
    The collection ships with two variables:

    | Variable  | Value                                            |
    | --------- | ------------------------------------------------ |
    | `baseUrl` | `https://api.qbank.cl/platform` (pre-configured) |
    | `token`   | Your session JWT or `pk_...` API key             |
  </Step>

  <Step title="Try it">
    Every request inherits Bearer authentication with `{{token}}`. Start
    with `GET /v1/me` to validate your credential and `GET /v1/balances` to
    see your balance.
  </Step>
</Steps>

<Note>
  The collection is regenerated with every API version — download it again
  after each [changelog](/en/changelog) entry to get the latest endpoints.
</Note>
