agency-invoicing

PATCH /v1/agency-invoicing/profile

Change your invoicing identity or defaults.

Все эндпоинты agency-invoicing

Аутентификация

Отправьте ключ API в качестве токена носителя (bearer token). Ключ должен иметь разрешение agency.invoicing.manage; ключ без него отклоняется с кодом 403, а не 404.

Идентификатор вашей организации

Этот эндпоинт принимает org_id в качестве параметра запроса. Оставьте его пустым, и вызов охватит все поддерево вашей аренды; передайте его, чтобы сузить область вызова до одной организации.

Идентификатор вашей организации находится на экране ключей API в вашей панели управления, рядом с самим ключом. Это один и тот же идентификатор для каждого вашего запроса.

Попробовать

Замените всё в угловых скобках на собственные значения, а плейсхолдер ключа — на ключ из вашей панели управления.

curl -X PATCH https://api.zinndigital.com/v1/agency-invoicing/profile \
  -H "Authorization: Bearer zdk_live_…" \
  -H "Content-Type: application/json" \
  -d '{  }'

Вошли в систему? Консоль API в вашей панели управления автоматически подставляет реальный идентификатор вашей организации и ваш собственный ключ, а также выполняет запрос к работающему API, чтобы вы могли увидеть актуальный ответ. Откройте эту конечную точку в API-консоли

Подробнее

⛔ `next_number` is deliberately NOT settable. Rewinding a sequence would mint a duplicate number for a document already in a client's hands; advancing it leaves a gap a tax authority will ask about. Requires `agency.invoicing.manage`.

Параметры

ИмяТипОбязательноЧто это
org_id (query)UuidНетWhich of your organizations is invoicing. Required only when you belong to more than one — otherwise it is inferred from your DIRECT membership, never from the subtree-expanded…

Тело запроса

ИмяТипОбязательноЧто это
business_namestringНет
addressstringНет
emailstringНет
phonestringНет
websitestringНет
tax_number_labelstringНет
tax_numberstringНет
payment_instructionsstringНет
logo_sha256stringНет
accent_colourstringНет
default_currencystringНет
default_payment_terms_daysintegerНет
default_footerstringНет
default_notesstringНет
number_prefixstringНет
number_paddingintegerНет

Ответ

ИмяТипОбязательноЧто это
business_namestringНет
addressstringНетThe registered address, one line per newline. Free-form because address shape is a property of a country, not of our schema.
emailstringНет
phonestringНет
websitestringНет
tax_number_labelstringНетWhat the agency calls its tax registration — "VAT number", "ABN", "GSTIN", "EIN". ⛔ Printed only when the number is set too: a label with no number is an empty row, and a number…
tax_numberstringНет
payment_instructionsstringНетBank details or a "PayPal me at …" line, printed on the document verbatim and shown on the payment page. ⭐ Never translated — translating a payment instruction is not a safe act.
logo_sha256stringНетA digest into the content-addressed logo store, never a URL. That is what lets the PDF inline the mark with no network call at render time.
accent_colourstringНет
default_currencystringДа
default_payment_terms_daysintegerНет
default_footerstringНет
default_notesstringНет
number_prefixstringДа
number_paddingintegerНет
next_numberintegerДаThe next sequence number. ⛔ Read-only. Rewinding it would mint a duplicate number for a document already in a client's hands.
next_number_previewstringНетWhat the next invoice will be called, e.g. `INV-0042`.

Ошибки, которые может возвращать этот эндпоинт

401 · 403 · 404 · 422 · 429