Uplaćeno Docs
sr en

API reference

Šabloni profaktura

GET /v1/sabloni

Lista sablona proforma

Šabloni proforma po organization (PDF, mejl, podrazumevane vrednosti). Na pretplati Napredni i više. Unknown email template variables {name} are rejected at save time (422). Allowed: {kupac}, {iznos}, {valuta}, {broj}, {rok}, {link}, {organization}. EN: Organization proforma templates; unknown {variables} in email templates return 422.

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).
limitquerynointeger
kursorquerynostringOpaque cursor from sledeci_kursor

Responses

200 Stranica sablona
default Unexpected error

Example (curl)

curl -sS -X GET "https://api.uplaceno.rs/api/v1/sabloni" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json"
POST /v1/sabloni

Kreiraj sablon proforma

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).
Idempotency-KeyheaderyesstringRequired on every POST. Response cached 24 h (KV); same key + different body → 409 ponovljen_kljuc_idempotentnosti. Response includes Idempotent-Replayed: true on replay. Exceptions (optional key): /v1/nalog/*, /v1/nalog/pristupni-kljucevi/*, /v1/ja/sesije/opozovi-ostale, public /plati/*.

Request body

FieldTypeRequiredDescription
nazivstringno
varijanta_rasporedaenum: sistemski | klasican | moderan | minimalanno
boje.primarnastringno
boje.akcenatstringno
napomenastringno
podnozjestringno
uslovi_placanjastringno
mejl.naslovstringno
mejl.telo_htmlstringno
mejl.telo_tekststringno
podrazumevano.rok_placanja_danaintegerno
podrazumevano.valutastringno
podrazumevano.svrha_uplatestringno
podrazumevano.naslov_dokumentaenum: Predracun | Zahtev za placanjeno
predpopunjene_stavkeniz (object)no

Responses

201 Kreiran sablon
default Unexpected error

Example (curl)

curl -sS -X POST "https://api.uplaceno.rs/api/v1/sabloni" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json" \
  -H "Idempotency-Key: $(uuidgen)" \
  -d '{}'
DELETE /v1/sabloni/{id}

Obriši sablon

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).
idpathyesstring (uuid)UUID v7

Responses

200
default Unexpected error

Example (curl)

curl -sS -X DELETE "https://api.uplaceno.rs/api/v1/sabloni/{id}" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json"
GET /v1/sabloni/{id}

Get template

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).
idpathyesstring (uuid)UUID v7

Responses

200
default Unexpected error

Example (curl)

curl -sS -X GET "https://api.uplaceno.rs/api/v1/sabloni/{id}" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json"
PATCH /v1/sabloni/{id}

Izmeni sablon

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).
idpathyesstring (uuid)UUID v7

Request body

FieldTypeRequiredDescription
nazivstringno
varijanta_rasporedaenum: sistemski | klasican | moderan | minimalanno
boje.primarnastringno
boje.akcenatstringno
napomenastringno
podnozjestringno
uslovi_placanjastringno
mejl.naslovstringno
mejl.telo_htmlstringno
mejl.telo_tekststringno
podrazumevano.rok_placanja_danaintegerno
podrazumevano.valutastringno
podrazumevano.svrha_uplatestringno
podrazumevano.naslov_dokumentaenum: Predracun | Zahtev za placanjeno
predpopunjene_stavkeniz (object)no

Responses

200
default Unexpected error

Example (curl)

curl -sS -X PATCH "https://api.uplaceno.rs/api/v1/sabloni/{id}" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json" \
  -d '{}'
DELETE /v1/sabloni/{id}/logo

Ukloni logo

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).
idpathyesstring (uuid)UUID v7

Responses

200
default Unexpected error

Example (curl)

curl -sS -X DELETE "https://api.uplaceno.rs/api/v1/sabloni/{id}/logo" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json"
GET /v1/sabloni/{id}/logo

Logo šablona (PNG/JPEG/WebP, max 512 KB)

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).
idpathyesstring (uuid)UUID v7

Responses

200 Binarni logo
default Unexpected error

Example (curl)

curl -sS -X GET "https://api.uplaceno.rs/api/v1/sabloni/{id}/logo" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json"
PUT /v1/sabloni/{id}/logo

Otpremi logo

Magic bytes provera (ne Content-Type). SVG odbijen (XSS).

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).
idpathyesstring (uuid)UUID v7

Responses

200
default Unexpected error

Example (curl)

curl -sS -X PUT "https://api.uplaceno.rs/api/v1/sabloni/{id}/logo" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json"
POST /v1/sabloni/{id}/pregled-pdf

Pregled PDF šablona (primer Primer d.o.o.)

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).
idpathyesstring (uuid)UUID v7

Request body

FieldTypeRequiredDescription
formatenum: pdf | htmlno

Responses

200 PDF ili HTML pregled
default Unexpected error

Example (curl)

curl -sS -X POST "https://api.uplaceno.rs/api/v1/sabloni/{id}/pregled-pdf" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json" \
  -d '{}'
GET /v1/sabloni/podrazumevani

Podrazumevani sablon proforma

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).

Responses

200
default Unexpected error

Example (curl)

curl -sS -X GET "https://api.uplaceno.rs/api/v1/sabloni/podrazumevani" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json"
PUT /v1/sabloni/podrazumevani

Postavi podrazumevani sablon

Authentication and scopes

  • Session (HttpOnly cookie)
  • API key (Authorization: Bearer upl_live_…)

Parameters

NameInRequiredTypeDescription
X-Organizacija-Idheadernostring (uuid)Active organization. Required for user OIDC tokens with multiple orgs; for API key/client credentials the org is in the credential (header must match or be omitted).

Request body

FieldTypeRequiredDescription
sablon_idstring (uuid)yes

Responses

200
default Unexpected error

Example (curl)

curl -sS -X PUT "https://api.uplaceno.rs/api/v1/sabloni/podrazumevani" \
  -H "Authorization: Bearer upl_live_VAS_KLJUC" \
  -H "Content-Type: application/json" \
  -d '{}'