# Decide Approvals

> Approve or deny one or more approval requests, with the approver's choices (Task #6191).

Canonical URL: https://docs.botyard.io/docs/api/approvals/decide_approvals_v1_orgs__org_id__approvals_decisions_post

`POST /v1/orgs/{org_id}/approvals/decisions`

Approve or deny one or more approval requests, with the approver's choices (Task #6191).

Each decision runs exactly the checks and writes of
``POST /approvals/{request_id}/decision`` (see :func:`decide_approval`)
and may also carry ``input``: what the approver chose on the card. This is
the only route that takes input, and a server that predates input does not
serve it, so a new client never has its choice silently dropped by an old
server: the request is refused there before anything is decided.

**Per-item results, one transaction each, in request order.** A decision
that is refused (``refused``, with the problem the single route would have
answered) or needs a payment method first (``activation_required``) has
nothing of its own written, and the others are applied regardless. Each
decision commits on its own, so one decision's locks are never held while
another's are taken. Side effects run after the commits: one wake per
asking conversation, carrying every outcome in it, and one provisioner
nudge per fulfilled bot.

**What a decision that has committed is owed, it gets.** Its realtime
events are handed to the request's publisher at its commit, and its wake
and nudge are started even when a later decision fails the request.

Anything other than a refusal fails the whole request, as it would the
single route: an unexpected error, a failed savepoint release or rollback,
or a failed commit. Decisions committed before it stay decided (the card
reads live state). A commit that fails may still have landed, so it is
checked on a fresh connection, and a decision that did land gets its
side effects too.

## Parameters

| Name | In | Required | Type | Description |
| --- | --- | --- | --- | --- |
| `org_id` | path | yes | string |  |

## Request body

`application/json`: ApprovalDecisionsCreate (required)

| Field | Type | Required | Description |
| --- | --- | --- | --- |
| `decisions` | array of ApprovalDecisionItem | yes | The decisions, each for a different request (a repeated request_id is a 422). Each is decided in its own transaction, in this order: one refused decision leaves the others applied. |

## Responses

| Status | Description | Body |
| --- | --- | --- |
| `200` | Successful Response | ApprovalDecisionsResponse |
| `default` | RFC 9457 Problem Details error response | ProblemDetails |

Full schemas: operation `decide_approvals_v1_orgs__org_id__approvals_decisions_post` in the OpenAPI spec at https://api.botyard.io/openapi.json.
