Skip to main content
Invoices vs orders: These guides walk through invoices (formal billing, line items, publish). The collect flow is the same for orders — use /v1/orders/* instead of /v1/invoices/* and set source_type: "ORDER" on the checkout session. See Orders and Parties & counterparties.Hosted checkout: To skip party, invoice, session, and execute steps entirely, see Hosted checkout.
End-to-end invoice collection with the standard library net/http and encoding/json.
API Reference: Obtain token · Collect

Prerequisites

  • Go 1.21+
  • os.Getenv for DOLLR_CLIENT_ID and DOLLR_CLIENT_SECRET

Steps

1

Client and token

2

POST helper

Chain: parties → counterparties → invoices → items → publish.
3

Execute with idempotency key

4

Poll status

Try it yourself

Hosted checkout

Mobile money and card on a Dollr-hosted page — fastest path.

Orders

Same collect flow with source_type: ORDER and /v1/orders/*.

Direct checkout

One API call to create source — API-embedded flow.
Last modified on May 22, 2026