Base URLs & Hosts

HL Hunt's API is served from two hostnames that reach the same application. Use whichever you prefer; the paths differ only in the /api prefix.

FamilyOn api.hlhunt.orgOn payments.hlhunt.orgAuth
REST API (charges, customers, payment methods, refunds, checkout, subscriptions, invoices, products, prices, payouts, webhooks, arrangements, billing, portal sessions, capture-session, test-cards, auth/me)https://api.hlhunt.org/v1/... (also /api/v1/...)https://payments.hlhunt.org/api/v1/...API key
Legacy tokenizationhttps://api.hlhunt.org/api/tokenize/session and /api/tokenize/capturehttps://payments.hlhunt.org/api/tokenize/...API key / session secret
Browser scriptsredirected (302) to payments.hlhunt.orghttps://payments.hlhunt.org/js/hlhunt.js, /js/hlhunt-checkout.jspublishable key in the script
Hosted pages (checkout, embed, pay links, invoices, portal)not servedhttps://payments.hlhunt.org/checkout/{session_key}, /embed/checkout/{session_key}, …none
Documentationnot servedhttps://payments.hlhunt.org/docs/..., /api/docs/{slug} (markdown), /openapi.jsonnone

Rules the edge applies:

  • On api.hlhunt.org a request whose path starts with /v1 is rewritten to the same path under /api before routing, so https://api.hlhunt.org/v1/charges and https://payments.hlhunt.org/api/v1/charges hit the same handler.
  • api.hlhunt.org serves only /v1/*, /api/v1/* and /api/tokenize/*. Any other path answers 404 { "error": { "type": "invalid_request_error", "code": "not_found", "message": "No such route: GET /foo. The API base URL is https://api.hlhunt.org/v1/" } }.
  • Any /js/*.js request on api.hlhunt.org is redirected to https://payments.hlhunt.org/js/..., so a script URL derived from your API base still loads.
  • api.hlhunt.com behaves exactly like api.hlhunt.org.
  • There is one base URL for both modes. Test and live are selected by the key prefix (sk_test_ / pk_test_ versus sk_live_ / pk_live_), never by the host.

The reference pages use https://api.hlhunt.org/v1 as the base.