---
search:
  tags:
    - Operations
    - POST
seo:
  description: >-
    Updates the credit amount on an offer. The offer must be in "pending" or
    "awaiting_customer"… Reference for the POST /{id}/credit endpoint in the
    Offers API.
sidebar:
  label: Update offer credit amount
  badge: POST
title: Update offer credit amount
type: openapi-operation
---
Updates the credit amount on an offer. The offer must be in "pending" or "awaiting_customer" status.

`POST /{id}/credit`

**Request body** (`application/json`)

- `creditAmount` (integer, required) — Credit amount in cents (e.g., 10000 = $100.00). Must be a non-negative integer.

Request body example:

```json
{
  "creditAmount": 10000
}
```

**Responses**

- `200` — Offer credit amount updated successfully
- `400` — Bad request - Offer credit could not be updated
- `401` — Unauthorized - Missing or invalid authentication
- `403` — Forbidden - Caller can view this offer but is not allowed to update it
- `404` — Not found - Offer does not exist or caller is not allowed to view it
- `500` — Internal server error

Response example, 200:

```json
{
  "success": true,
  "creditAmount": 10000,
  "updatedAt": "2024-01-20T12:00:00Z"
}
```

Response example, 400 · offerCreditNotAllowed:

```json
{
  "code": "OFFER_CREDIT_NOT_ALLOWED",
  "message": "Offer credit cannot be updated because it is in \"canceled\" status"
}
```

Response example, 400 · updateCreditAmountError:

```json
{
  "code": "UPDATE_CREDIT_AMOUNT_ERROR",
  "message": "Failed to update offer credit amount"
}
```

Response example, 401:

```json
{
  "code": "UNAUTHORIZED",
  "message": "Missing authentication token"
}
```

Response example, 403 · insufficientScope:

```json
{
  "code": "INSUFFICIENT_SCOPE",
  "message": "The presented token is missing the `write:offers` scope, which this endpoint requires. Create a token with the scopes you need at https://developer.sibipro.com."
}
```

Response example, 403 · permissionDenied:

```json
{
  "code": "FORBIDDEN",
  "message": "User does not have permission to update this offer"
}
```

Response example, 404:

```json
{
  "code": "OFFER_NOT_FOUND",
  "message": "Offer not found"
}
```

Response example, 500:

```json
{
  "code": "INTERNAL_SERVER_ERROR",
  "message": "An unexpected error occurred"
}
```
