Reject budget execution

Rejects a budget execution that is awaiting an approval decision.

PATCH/api/integration/budget/execution/{budgetExecutionId}/approve

Request

cURL
curl -X PATCH "https://dev.integration.cl.sodtrack-shared.sodtrack.com/api/integration/budget/execution/{budgetExecutionId}/approve" \
  -H "Authorization: Bearer $SODTRACK_TOKEN" \
  -H "origin: dev.api.cl.sodtrack.sodtrack.com"

Base URL: https://dev.integration.cl.sodtrack-shared.sodtrack.com · other environments

Path parameters

NameTypeDescription
budgetExecutionIdrequiredstring

Headers

NameTypeDescription
originstring
dev.api.cl.sodtrack.sodtrack.com

Purpose

Rejects a budget execution that is awaiting an approval decision.

Rejecting closes the budget execution without creating any booking and without triggering its execution. A rejected budget execution can still be edited and resolved again later.

The budget execution is identified by its Sodtrack id in the URL. This endpoint does not take a request body.

code
PATCH /api/integration/budget/execution/{budgetExecutionId}/reject

Field Definitions

🔐 Authentication

FieldTypeRequiredDescription
x-api-keyheaderSodtrack integration API key. Requests without a valid key are rejected.

📦 Path parameters

FieldTypeRequiredDescription
budgetExecutionIdstringSodtrack id of the budget execution to reject.

This endpoint does not accept a request body. Any payload sent is ignored.


Example Request

code
PATCH /api/integration/budget/execution/1234/reject
x-api-key: <your-api-key>

Response

HTTP StatusDescription
200 OKBudget correctly updated to rejected status

Error Responses

HTTP StatusErrorDescription
400 Bad RequestINVALID_STATUS_TO_RESOLVE_APPROVALThe budget execution is not in a status that accepts an approval decision, typically because it was already approved.
401 UnauthorizedThe API key is missing, invalid, or the request origin is not authorized.
404 Not FoundBUDGET_EXECUTION_NOT_FOUNDNo budget execution exists for the given id.
500 Internal Server ErrorUnexpected server error. Contact Sodtrack support.

Business Rules & Constraints

Statuses that accept a rejection

A budget execution can be rejected only while it is still open to a decision. The following statuses are accepted:

StatusMeaning
createdDraft, not yet submitted for approval.
in_progressLegacy equivalent of created.
provider_submittedSubmitted by the provider.
waiting_internal_reviewAwaiting internal review.
waiting_admin_approvalAwaiting administrator approval.
waiting_customer_approvalAwaiting customer approval.
rejectedAlready rejected; rejecting again succeeds and leaves it rejected.
customer_rejectedLegacy equivalent of rejected.

Any other status, in particular a budget execution that is already approved, is rejected with 400 INVALID_STATUS_TO_RESOLVE_APPROVAL. An approved budget execution cannot be reverted through this endpoint.

No execution is triggered

Rejecting never creates execution bookings and never starts the operation, regardless of the approval policy configured for the budget execution. The response is fast and does not depend on the number of milestones.