BillOS v1
Console llms.txt OpenAPI
POST/businesses/{bid}/business-documents

Upload a certificate or licence

POST /businesses/{bid}/business-documents

Requires the businesses scope.

The file bytes are the request body with their own Content-Type: application/pdf, image/jpeg, image/png or image/webp, up to 10MB. Fields you already know ride the query string and are never written over by the reading. The answer comes at once with status: processing; the file is read after it (poll the document). A byte-identical file returns the existing document with duplicate: true and 200. An account pending approval stores its files unread.

Path parameters

NameTypeDescription
bidstringrequiredBusiness id, from POST /businesses.

Query parameters

NameTypeDescription
filenamestringNames the document until it is read.
namestring
categorystring
docNumberstring
issuerstring
issuedOnstring
validUntilstring

Body

Raw bytes. Accepted content types: application/pdf, image/jpeg, image/png, image/webp.

Response

201: { "ok": true, … }

FieldTypeDescription
okboolean
documentBusinessDocumentOne of the business's own certificates, licences or approvals (תעודת עוסק מורשה, אישור ניכוי מס במקור, a licence, insurance). Read on upload: status is processing until the reading lands, and a field you set is never written over by it. Not a ledger record: no report or export reads one.
duplicateboolean

Errors: 400, 401, 403, 404, 413, 429. Every failure answers { "error", "reason", "hint", "param", "doc_url", "retryable", "request_id" }: branch on reason, and read hint for what to change (https://docs.billos.co.il/errors.md).

POST /businesses/{bid}/business-documents
curl -X POST "$BASE/businesses/$BID/business-documents?filename=&name=&category=" \
  -H "X-Api-Key: $KEY" \
  -H "Content-Type: image/jpeg" \
  --data-binary @receipt.jpg
const res = await fetch(`${BASE}/businesses/${BID}/business-documents`, {
  method: 'POST',
  headers: {
    'X-Api-Key': KEY,
  },
})
const data = await res.json()
if (!data.ok) throw new Error(data.reason)
import requests
res = requests.post(
    f"{BASE}/businesses/{BID}/business-documents",
    headers={"X-Api-Key": KEY},
)
data = res.json()
Set BASE to https://api.billos.co.il/v1 and KEY to your bk_live_… key, or a bk_test_… key to run it against the sandbox.
Manage your businesses, keys and webhooks in the BillOS Console.