Skip to content
ReadyZone Docs
API Reference

Promo code validation

Publicly validate a promotional code for a plan.

POST /api/referral/promo-codes/validate

Access: Public

Request body

{
  "code": "WELCOME10",
  "planId": "plan_uuid",
  "companyRef": "readyzone-center-12345"
}

code and planId are required. companyRef is recommended when the code is entered from a zone portal.

AttributeTypeRequiredDescription
codestringYesPromotional code entered by the customer.
planIdstring (UUID)YesTarget plan.
companyIdstring (UUID)NoInternal zone identifier.
companyRefstringNoPublic zone reference.
beneficiaryUserIdstring (UUID)NoBeneficiary, used for example to prevent self-use.

Response

The response indicates whether the code is valid and returns the discount information applicable to the plan.

The portal must treat the response as the eligibility decision and must not calculate the discounted amount itself.

Status codes

  • 200 OK
  • 400 Bad Request (invalid code or plan)
  • 404 Not Found (code not found)
  • 422 Unprocessable Entity (expired, exhausted, or inapplicable code)

On this page