Skip to content

Prudai Developer API: integration administrations

The operations of this part (Integration administrations).

Base URL https://api.prudai.com/v1. Logging in is in Login, scopes in Scopes and permissions, errors in Errors. Overview.

MethodPathWhat it doesState
GET/v1/integrations/{provider}/administrationsList the administrations of a bookkeeping koppelingComing soon
POST/v1/integrations/{provider}/administrationsAdd an administration with its own API token (owner or admin)Coming soon
PATCH/v1/integrations/{provider}/administrations/{administration_id}Link or unlink an administration (owner or admin)Coming soon
DELETE/v1/integrations/{provider}/administrations/{administration_id}Remove an administration the organisation added itself (soft delete)Coming soon
POST/v1/integrations/{provider}/administrations/{administration_id}/restoreRestore a removed administration (owner or admin)Coming soon

List the administrations of a bookkeeping koppeling

GET /v1/integrations/{provider}/administrations

Personal tokens only; every member with MAIA and the koppeling. Per administration (Moneybird) or division (Exact Online): linked, state (active, unlinked, needs_attention, not_connected), source (managed = set up by Prudai, can be switched off but not removed; org = added by the organisation), last_check_at/last_check_status and, for Exact, last_sync_at. can_manage says whether the token user may change anything. API tokens are never returned. Exact divisions are managed on the Exact Online connection page (manage_path).

  • State: coming soon, not in production yet.
  • Scope: prudai:integration_administrations:read
  • Approval: none, no extra step.

Parameters

  • provider path · string required
    One of: moneybird, exact

Responses

StatusMeaning
200OK.
401Missing, malformed, unknown, expired or revoked key, or a key used against the wrong environment.
403Authenticated, but not allowed (missing scope, product not on the key or organisation, organisation suspended, Developer API switched off for the organisation, IP not on the allowlist, depth not permitted, licence does not permit redistribution).
404Unknown model, source or document.
429Rate limit, concurrency limit, Ultra daily quota or fair-use limit of the free sources operations exceeded.
503Temporarily unavailable (maintenance, overload, or the credit check could not be performed). Nothing ran, nothing is charged.
curl
curl -s "https://api.prudai.com/v1/integrations/moneybird/administrations" \
-H "Authorization: Bearer $PRUDAI_TOKEN"
CLI (coming soon)
prudai leo integrations-administrations list

Add an administration with its own API token (owner or admin)

POST /v1/integrations/{provider}/administrations

Moneybird only. Personal tokens only; an owner or admin of your own organisation. Create a personal API token in Moneybird (Instellingen → Koppelingen → Externe applicaties; rights “Alleen lezen” is enough and advised) in the administration you want to link, and send it as token. The token decides which administration it is; when it sees more than one, the answer is 422 administration_choice_required with the choices and you repeat with administration_id. The token is stored encrypted and never returned.

Waits for a human (confirm): the first call answers 202 with an approval request; repeat the exact call with x-prudai-approval: apr_… once approved.

  • State: coming soon, not in production yet.
  • Scope: prudai:integration_administrations:write
  • Approval: confirm, the user confirms exactly this call.

Parameters

  • provider path · string required
    One of: moneybird, exact

Body

JSON, required.

  • token string required
    max length 400
  • administration_id string
    pattern ^\d{1,24}$

Responses

StatusMeaning
201The administration is linked.
202Waiting for human approval (ApprovalRequest).
401Missing, malformed, unknown, expired or revoked key, or a key used against the wrong environment.
403Authenticated, but not allowed (missing scope, product not on the key or organisation, organisation suspended, Developer API switched off for the organisation, IP not on the allowlist, depth not permitted, licence does not permit redistribution).
404Unknown model, source or document.
409A request with the same Idempotency-Key is still running.
422Well-formed request with invalid values (for example an unknown reasoning_effort, empty messages, or an Idempotency-Key reused with a different body).
429Rate limit, concurrency limit, Ultra daily quota or fair-use limit of the free sources operations exceeded.
502An upstream model provider or source failed. Not charged, except work that completed before the failure (reported in details.charged_credits).
503Temporarily unavailable (maintenance, overload, or the credit check could not be performed). Nothing ran, nothing is charged.
curl
curl -s -X POST "https://api.prudai.com/v1/integrations/moneybird/administrations" \
-H "Authorization: Bearer $PRUDAI_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"token": "string",
"administration_id": "string"
}'
CLI (coming soon)
prudai leo integrations-administrations create

Link or unlink an administration (owner or admin)

PATCH /v1/integrations/{provider}/administrations/{administration_id}

Moneybird only. Personal tokens only; an owner or admin of your own organisation. linked: false switches the administration off for MAIA in the whole organisation (chat, reports, source links); true switches it on again.

Waits for a human (confirm): the first call answers 202 with an approval request; repeat the exact call with x-prudai-approval: apr_… once approved.

  • State: coming soon, not in production yet.
  • Scope: prudai:integration_administrations:write
  • Approval: confirm, the user confirms exactly this call.

Parameters

  • provider path · string required
    One of: moneybird, exact
  • administration_id path · string required
    pattern ^\d{1,24}$

Body

JSON, required.

  • linked boolean required

Responses

StatusMeaning
200OK.
202Waiting for human approval (ApprovalRequest).
401Missing, malformed, unknown, expired or revoked key, or a key used against the wrong environment.
403Authenticated, but not allowed (missing scope, product not on the key or organisation, organisation suspended, Developer API switched off for the organisation, IP not on the allowlist, depth not permitted, licence does not permit redistribution).
404Unknown model, source or document.
409A request with the same Idempotency-Key is still running.
422Well-formed request with invalid values (for example an unknown reasoning_effort, empty messages, or an Idempotency-Key reused with a different body).
429Rate limit, concurrency limit, Ultra daily quota or fair-use limit of the free sources operations exceeded.
503Temporarily unavailable (maintenance, overload, or the credit check could not be performed). Nothing ran, nothing is charged.
curl
curl -s -X PATCH "https://api.prudai.com/v1/integrations/moneybird/administrations/<administration_id>" \
-H "Authorization: Bearer $PRUDAI_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"linked": false
}'
CLI (coming soon)
prudai leo integrations-administrations update

Remove an administration the organisation added itself (soft delete)

DELETE /v1/integrations/{provider}/administrations/{administration_id}

Moneybird only. Personal tokens only; an owner or admin of your own organisation. Only administrations with source: org; one set up by Prudai can be switched off instead (409 managed_cannot_delete). Restorable with restoreIntegrationAdministration.

Waits for a reviewer (review): another owner or admin approves with a reason.

  • State: coming soon, not in production yet.
  • Scope: prudai:integration_administrations:delete
  • Approval: review, a second person or role approves.
  • Deleting is soft; see Conventions.

Parameters

  • provider path · string required
    One of: moneybird, exact
  • administration_id path · string required
    pattern ^\d{1,24}$

Responses

StatusMeaning
200OK.
202Waiting for human approval (ApprovalRequest).
401Missing, malformed, unknown, expired or revoked key, or a key used against the wrong environment.
403Authenticated, but not allowed (missing scope, product not on the key or organisation, organisation suspended, Developer API switched off for the organisation, IP not on the allowlist, depth not permitted, licence does not permit redistribution).
404Unknown model, source or document.
409A request with the same Idempotency-Key is still running.
422Well-formed request with invalid values (for example an unknown reasoning_effort, empty messages, or an Idempotency-Key reused with a different body).
429Rate limit, concurrency limit, Ultra daily quota or fair-use limit of the free sources operations exceeded.
503Temporarily unavailable (maintenance, overload, or the credit check could not be performed). Nothing ran, nothing is charged.
curl
curl -s -X DELETE "https://api.prudai.com/v1/integrations/moneybird/administrations/<administration_id>" \
-H "Authorization: Bearer $PRUDAI_TOKEN"
CLI (coming soon)
prudai leo integrations-administrations delete

Restore a removed administration (owner or admin)

POST /v1/integrations/{provider}/administrations/{administration_id}/restore

Moneybird only. Personal tokens only; an owner or admin of your own organisation. Puts back the last removed administration with this id (with its stored token), linked as it was.

Waits for a human (confirm): the first call answers 202 with an approval request; repeat the exact call with x-prudai-approval: apr_… once approved.

  • State: coming soon, not in production yet.
  • Scope: prudai:integration_administrations:write
  • Approval: confirm, the user confirms exactly this call.

Parameters

  • provider path · string required
    One of: moneybird, exact
  • administration_id path · string required
    pattern ^\d{1,24}$

Body

JSON, optional.

Responses

StatusMeaning
200OK.
202Waiting for human approval (ApprovalRequest).
401Missing, malformed, unknown, expired or revoked key, or a key used against the wrong environment.
403Authenticated, but not allowed (missing scope, product not on the key or organisation, organisation suspended, Developer API switched off for the organisation, IP not on the allowlist, depth not permitted, licence does not permit redistribution).
404Unknown model, source or document.
409A request with the same Idempotency-Key is still running.
422Well-formed request with invalid values (for example an unknown reasoning_effort, empty messages, or an Idempotency-Key reused with a different body).
429Rate limit, concurrency limit, Ultra daily quota or fair-use limit of the free sources operations exceeded.
503Temporarily unavailable (maintenance, overload, or the credit check could not be performed). Nothing ran, nothing is charged.
curl
curl -s -X POST "https://api.prudai.com/v1/integrations/moneybird/administrations/<administration_id>/restore" \
-H "Authorization: Bearer $PRUDAI_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
CLI (coming soon)
prudai leo integrations-administrations restore