---
title: "Apply a customer credit to an order"
method: POST
path: "/shop/orders/{orderId}/customer-credits"
tags: ["Orders"]
---

# Apply a customer credit to an order

`POST /shop/orders/{orderId}/customer-credits`

Apply a customer credit balance to an order — for example, redeeming a
refund credit or a gift balance held against the customer's profile.
The updated `Order` is returned so the caller can see the new outstanding
balance after the credit is deducted.

Returns `400 Bad Request` if the credit can't be applied — for example
because it has already been fully redeemed, belongs to a different
customer, or is expired.

## Request body

- object
  - `id` string, required — Identifier of the `CustomerCredit` to apply to this order. Customer credits are managed under the Customers API and must belong to a customer linked (directly or via a guest) to this order.

## Response `201`

The `Order` was successfully retrieved

- object
  - `data` Order, required — A customer order containing items and payments. This format replaces an older version of the order schema, and must be requested explicitly by passing `generic_items_array=true` as a query parameter.
    - `id` string, object-id — The ID of the order.

## Other responses

- `400` — The request failed.
- `404` — The resource couldn't be found
- `422` — The request didn't pass validation

---

[API](https://skmtc.dev/try/apis/trybe-api.md) · [All operations](https://skmtc.dev/try/apis/trybe-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/try/trybe-api/revisions/f37f92702da5/schema)
