A CoworkerDiscountCode assigns a DiscountCode to a specific customer, allowing the system to track per-customer redemption history and enforce individual validity windows.
Use ValidFrom and ExpiresOn to set customer-specific validity dates. These are distinct from the discount code’s own ValidFrom/ValidTo and ExpirationType/ExpiresIn fields — the system enforces whichever constraint is more restrictive.
When the discount is part of the referral programme, RefererGuid identifies the referring customer. BookingUniqueId links the assignment to the specific booking where the code was originally applied.
Authentication
This endpoint requires OAuth2 authentication. Include a valid bearer token in the Authorization header.
The authenticated user must be a full unrestricted administrator or have the CoworkerDiscountCode-Read role.
Path Parameters
The Id of the CoworkerDiscountCode record to retrieve.
Code Examples
curl -X GET \
"https://spaces.nexudus.com/api/billing/coworkerdiscountcodes/87654321" \
-H "Authorization: Bearer YOUR_TOKEN"
Response
200
ID of the customer this discount code is assigned to.
Whether the customer is an individual or a company.
Full name of the customer this discount code is assigned to.
Billing name of the customer.
Company name of the customer.
ID of the location this assignment belongs to.
Name of the location this assignment belongs to.
ID of the discount code assigned to this customer.
The alphanumeric code customers enter to apply the discount.
Whether the discount code is currently active and can be redeemed.
Start date from which the discount code itself can be redeemed (set on the discount code).
End date after which the discount code itself can no longer be redeemed (set on the discount code).
Optional notes about this discount code assignment.
Number of times this customer has redeemed the discount code.
Customer-specific date from which this discount code assignment becomes valid.
Customer-specific date after which this discount code assignment expires.
Unique identifier of the customer who referred this customer, when the discount is part of the referral programme.
Unique identifier of the booking to which this discount code was applied.
Unique record identifier.
Date and time the record was created (ISO 8601).
Date and time the record was last updated (ISO 8601).
Email of the user who last updated this record.
Whether the record was recently created.
External system identifier.
{
"CoworkerId": 0,
"CoworkerCoworkerType": null,
"CoworkerFullName": null,
"CoworkerBillingName": null,
"CoworkerCompanyName": null,
"BusinessId": 0,
"BusinessName": null,
"DiscountCodeId": 0,
"DiscountCodeCode": null,
"DiscountCodeActive": null,
"DiscountCodeValidFrom": null,
"DiscountCodeValidTo": null,
"Notes": null,
"TimesUsed": 0,
"ValidFrom": null,
"ExpiresOn": null,
"RefererGuid": null,
"BookingUniqueId": null,
"Id": 87654321,
"UpdatedOn": "2025-01-15T10:30:00Z",
"CreatedOn": "2025-01-10T08:00:00Z",
"UniqueId": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
"UpdatedBy": "admin@example.com",
"IsNew": false,
"SystemId": null,
"ToStringText": "CoworkerDiscountCode Example",
"LocalizationDetails": null,
"CustomFields": null
}