billing
PUT /v1/billing/profile
Replace the organization's billing profile.
Autentizace
Zašlete API klíč jako nosný token (bearer token). Klíč musí mít oprávnění billing.invoice.manage; klíč bez něj je odmítnut s kódem 403, nikoli 404.
Sem patří ID vaší organizace
Tento koncový bod přijímá org_id jako parametr dotazu. Pokud ho vynecháte, volání pokryje celý podstrom vašeho nájemce; jeho odesláním volání zúžíte na jednu organizaci.
ID vaší organizace najdete na obrazovce API klíčů ve vašem přehledu, hned vedle samotného klíče. Je to stále stejné ID v každém volání, které provedete.
Vyzvednout
Nahraďte cokoli v závorkách vlastními hodnotami a zástupný symbol klíče klíčem z vašeho řídicího panelu.
curl -X PUT https://api.zinndigital.com/v1/billing/profile \
-H "Authorization: Bearer zdk_live_…" \
-H "Content-Type: application/json" \
-d '{ "billing_address": <BillingAddress> }'Přihlášeni? Konzole API ve vašem dashboardu automaticky doplní vaše skutečné ID organizace i váš vlastní klíč a odešle požadavek na živé API, abyste viděli reálnou odpověď. Otevřete tento koncový bod v konzoli API
Podrobnosti
A full replace (PUT) of the editable "Bill to" fields; an omitted field resets to blank. `billing_address` (with its required `country`, needed for tax) is the one mandatory member. Editing changes only invoices issued **afterwards** — a past invoice snapshotted the buyer block at issue time and is never rewritten (docs/34 §1.1). `vat_status` is engine-owned (the validate-not-trust flow, §2.3) and is not accepted here; changing `vat_number` resets it to `unvalidated`. Requires `billing.invoice.manage` in the target organization.
Parametry
| Název | Typ | Požadováno | Co to je |
|---|---|---|---|
org_id (query) | Uuid | Ne | The organization whose profile to replace; defaults to the caller's own. |
Tělo požadavku
| Název | Typ | Požadováno | Co to je |
|---|---|---|---|
legal_name | string | Ne | — |
company_name | string | Ne | — |
billing_address | BillingAddress | Ano | A billing address. Everything is optional **except** `country`, which tax determination needs (docs/34 §2.2). `country` is an ISO 3166-1 alpha-2 code, uppercased by the server. |
vat_number | string | Ne | — |
tax_id | LabelValue | Ne | — |
custom_invoice_fields | LabelValue[] | Ne | — |
billing_email | string | Ne | — |
invoice_locale | string | Ne | — |
Odpověď
| Název | Typ | Požadováno | Co to je |
|---|---|---|---|
org_id | string | Ano | — |
legal_name | string | Ano | — |
company_name | string | Ano | — |
billing_address | BillingAddress | Ano | A billing address. Everything is optional **except** `country`, which tax determination needs (docs/34 §2.2). `country` is an ISO 3166-1 alpha-2 code, uppercased by the server. |
vat_number | string | Ano | — |
vat_status | string<unvalidated, pending, valid, invalid> | Ano | State of the validate-not-trust check on `vat_number` (docs/34 §2.3). Read-only; a change to `vat_number` resets it to `unvalidated`. |
tax_id | LabelValue | Ne | A free-label secondary tax id (US EIN, AU ABN, …). Null when unset. |
custom_invoice_fields | LabelValue[] | Ano | Up to five customer-defined `{label, value}` lines, rendered verbatim. |
billing_email | string | Ano | Where invoices are delivered; blank means the account email. |
invoice_locale | string | Ano | Preferred invoice language; blank means the account language. |
updated_at | string | Ne | When the profile was last saved. Null if it has never been saved. |
Chyby, které může tento koncový bod vrátit
401 · 403 · 422 · 429