Skip to main content

Quick start

You need a client_id, the one-time-displayed client_secret, and assigned permissions. Credentials are issued through the administrative process, outside the Public API.

1. Obtain a token​

curl --request POST 'https://iiproxy.sekkun.co/oauth2/token' \
--user "$CLIENT_ID:$CLIENT_SECRET" \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data-urlencode 'grant_type=client_credentials' \
--data-urlencode 'scope=invoices:read invoices:draft invoices:issue'

Keep the token on your server. Never embed it in a browser, mobile application, or public repository.

2. Create and immediately issue an invoice​

curl --request POST 'https://iiproxy.sekkun.co/public/v1/outgoing-invoices' \
--header "Authorization: Bearer $ACCESS_TOKEN" \
--header 'Content-Type: application/json' \
--header "Idempotency-Key: invoice-$ERP_DOCUMENT_UUID" \
--data '{
"numberMode": "AUTO", "issueDate": "2026-09-27", "deliveryDate": "2026-09-27",
"dueDate": "2026-10-12", "currency": "EUR", "deliveryChannel": "AS4",
"customer": {"oib": "10987654321", "name": "Customer Ltd", "countryCode": "HR"},
"lines": [{"code": "SVC-01", "name": "Maintenance", "quantity": 1, "unitCode": "H87",
"unitPrice": 100, "taxCode": "VAT25", "taxRate": 25, "ublTaxCategory": "S",
"classification": {"value": "62.01.11", "schemeId": "CG"}}],
"issue": true
}'

202 Accepted includes the invoice and an operationId. issue: true also requires invoices:issue.

3. Track the operation​

curl 'https://iiproxy.sekkun.co/public/v1/operations/OPERATION_ID' \
--header "Authorization: Bearer $ACCESS_TOKEN"

Terminal statuses are ISSUED, CORRECTED, REVERSED, or FAILED. ACTION_REQUIRED means the external outcome is unknown and blind retrying is unsafe.

4. Download the effective UBL​

curl 'https://iiproxy.sekkun.co/public/v1/outgoing-invoices/INVOICE_ID/extract-xml/ubl' \
--header "Authorization: Bearer $ACCESS_TOKEN" --output invoice.xml

For an XML-first integration, continue with Raw UBL.