Coupon Types
Discount coupon type catalog (TipoPin / ges_pin_tipo).
📄️ Get coupon type by ID
Returns a single coupon type by its primary key.
📄️ Update coupon type
Full replacement of an existing coupon type.
📄️ Delete coupon type
Deletes a coupon type.
📄️ Merge-patch coupon type
RFC 7396 merge-patch over `application/merge-patch+json`. Send only the fields you want to change; include a field with value `null` to remove it. Use the `If-Match` header for optimistic concurrency control.
📄️ List coupon types
Returns a paginated list of coupon types with envelope `{data, totalCount, skip, limit, hasMore}`. Supports optional RSQL `filter`, `sort` (default `lastModifiedAt:desc`), `skip`/`limit` pagination and `modifiedAfter`/`modifiedBefore` bookends.
📄️ Create coupon type
Creates a new coupon type. Business logic runs in the legacy WAR. `code` and `name` are required.
📄️ Bulk delete coupon types
Removes every id in `ids` as a single all-or-nothing transaction.
📄️ Bulk patch coupon types
Applies the same `patch` to every id in `ids` as a single all-or-nothing transaction. Editable fields: `description`, `categoryIds`.
📄️ Prototype coupon type for a creation form
Returns a non-persisted coupon type pre-populated with backend defaults (current company, `enabled=true`, `allCategories=true`, `discountKind=P`). Optional JSON hints: `companyId`, `copyFromId`. Call `POST /api/v2/coupon-types` to persist.