---
title: "Decide a temporary grant request"
method: POST
path: "/api/v2/usage/admin/temporary-grant-requests/{request_id}/decision"
tags: ["Usage Metering"]
---

# Decide a temporary grant request

`POST /api/v2/usage/admin/temporary-grant-requests/{request_id}/decision`

## Request

- Base URL: `https://api.datadoghq.com`
- URL: `https://api.datadoghq.com/api/v2/usage/admin/temporary-grant-requests/{request_id}/decision`
- Auth: one of:
  - API key in header `DD-API-KEY` and API key in header `DD-APPLICATION-KEY`
  - OAuth 2
    - Authorization code: `/oauth2/v1/authorize`
    - Token URL: `/oauth2/v1/token` scopes: `billing_edit`
- TypeScript: <https://skmtc.dev/datadog/apis/datadog-api-v2-collection/docs/api/v2/usage/admin/temporary-grant-requests/:request_id/decision/post.ts> (a function with typed inputs; its response is checked against the schema)

Approve or deny the submitted terms, which are immutable. Approval atomically writes the grant, audit record, and request decision. An expired request can't be approved. Requires the Billing Edit permission. Requires an authenticated human user. Service-account credentials aren't supported. Request status remains approved after the grant's expiry, revocation, or replacement.

## Path parameters

- `request_id` string, uuid, required: The request UUID.

## Request body

- TemporaryGrantRequestDecisionRequest: Approve or deny a pending request.
  - `data` TemporaryGrantRequestDecisionData, required: A decision on a pending request.
    - `attributes` TemporaryGrantRequestDecisionAttributes, required: Binary decision. Overrides, reason fields, and unknown attributes are rejected, including null values.
      - `decision` 'approved' | 'denied', required: Approve the exact submitted total and expiry, or deny the request.
    - `id` string, uuid, required: Request UUID. Must match request_id in the path. Missing or mismatched IDs return 400 Bad Request.
    - `type` 'temporary_grant_requests', required: The temporary grant request resource type.

## Response `200`

OK

- TemporaryGrantRequestResponse: A single temporary grant request.
  - `data` TemporaryGrantRequestData, required: A temporary grant request resource.
    - `attributes` TemporaryGrantRequestAttributes, required: Request history and the linked grant state. List and detail reads include grant_state for approved requests. Decision responses record the decision. Read the request for current grant state.
      - `created_at` string, date-time, required: When the request was submitted.
      - `decided_at` string, date-time: When the decision or cancellation was recorded.
      - `decided_by_user_id` string, uuid: UUID of the reviewer, or of the requester if the request was canceled.
      - `entity_key` string, required: The requester identity resolved by the server.
      - `expires_at` string, date-time, required: Immutable exclusive expiry, normalized to UTC microsecond precision.
      - `grant_state` 'active' | 'expired' | 'revoked' | 'replaced': Current state of the grant associated with an approved request. Replaced means a newer grant superseded this grant. The newer grant might no longer be active. This field is absent for requests that weren't approved.
      - `justification` string, required: Reason for requesting temporary credits. Trimmed and limited to 4096 UTF-8 bytes.
      - `quota_namespace` string, required: The quota namespace. Only AI credits are supported.
      - `requested_by_user_id` string, uuid, required: UUID of the authenticated requester.
      - `status` 'pending' | 'approved' | 'denied' | 'cancelled', required: The durable request decision, independent of whether its grant is still active.
      - `total` integer, required: Target monthly AI credit limit in positive whole credits, not additional credits. Fractional credits are not accepted.
    - `id` string, uuid, required: Server-generated request UUID.
    - `type` 'temporary_grant_requests', required: The temporary grant request resource type.

## Other responses

- `400`: Bad Request
- `401`: Unauthorized
- `403`: Forbidden
- `404`: Not Found
- `409`: Conflict
- `429`: Too many requests

---

[API](https://skmtc.dev/datadog/apis/datadog-api-v2-collection.md) - [All operations](https://skmtc.dev/datadog/apis/datadog-api-v2-collection/llms.txt) - [OpenAPI document](https://skmtc.dev/datadog/apis/datadog-api-v2-collection/revisions/3f70db624329?raw)
