curl --request GET \
--url https://api.example.com/coupons/{couponId}/usages \
--header 'Authorization: <authorization>'{
"data": [
{
"couponUsageId": "019525fe-6d58-7ed8-d0fc-8a0b2c4e6f8c",
"couponId": "019525fd-d3a4-7baf-a7c3-9d1e3f5b7c9f",
"invoiceId": "019525fd-c290-7a9e-f6b2-8c0d2e4a6b8e",
"organizationId": "019525fd-4c38-7e30-a5c1-b6e3f4d8a9c2",
"externalRef": "ext_ref_abc123",
"amount": 500,
"status": "APPLIED",
"createdAt": "2026-03-01T00:00:00.000Z",
"updatedAt": "2026-03-01T00:00:00.000Z"
}
],
"meta": { "page": 1, "limit": 20, "totalItems": 1, "totalPages": 1 }
}
Recuperar uma lista paginada de todos os usos de um cupom especifico.
curl --request GET \
--url https://api.example.com/coupons/{couponId}/usages \
--header 'Authorization: <authorization>'{
"data": [
{
"couponUsageId": "019525fe-6d58-7ed8-d0fc-8a0b2c4e6f8c",
"couponId": "019525fd-d3a4-7baf-a7c3-9d1e3f5b7c9f",
"invoiceId": "019525fd-c290-7a9e-f6b2-8c0d2e4a6b8e",
"organizationId": "019525fd-4c38-7e30-a5c1-b6e3f4d8a9c2",
"externalRef": "ext_ref_abc123",
"amount": 500,
"status": "APPLIED",
"createdAt": "2026-03-01T00:00:00.000Z",
"updatedAt": "2026-03-01T00:00:00.000Z"
}
],
"meta": { "page": 1, "limit": 20, "totalItems": 1, "totalPages": 1 }
}
coupon:read.Show usage properties
{
"data": [
{
"couponUsageId": "019525fe-6d58-7ed8-d0fc-8a0b2c4e6f8c",
"couponId": "019525fd-d3a4-7baf-a7c3-9d1e3f5b7c9f",
"invoiceId": "019525fd-c290-7a9e-f6b2-8c0d2e4a6b8e",
"organizationId": "019525fd-4c38-7e30-a5c1-b6e3f4d8a9c2",
"externalRef": "ext_ref_abc123",
"amount": 500,
"status": "APPLIED",
"createdAt": "2026-03-01T00:00:00.000Z",
"updatedAt": "2026-03-01T00:00:00.000Z"
}
],
"meta": { "page": 1, "limit": 20, "totalItems": 1, "totalPages": 1 }
}
curl https://api.awsales.io/admin/coupons/019525fd-d3a4-7baf-a7c3-9d1e3f5b7c9f/usages \
-H "Authorization: Bearer YOUR_ACCESS_TOKEN"
| Status | Codigo | Descricao |
|---|---|---|
400 | validation_error | Entrada invalida ou campos obrigatorios ausentes |
401 | unauthorized | Autenticacao ausente ou invalida |
403 | forbidden | Permissoes insuficientes |
500 | internal_server_error | Ocorreu um erro inesperado |