assign_code
Assign one available code to one named participant (regular or AMOE) of the SAME sweepstakes who holds no code yet. The code must be unassigned and not redeemed. This does not notify anyone — use send_code afterwards if the participant should receive it. Known API quirk: the echoed code comes back with AssignedTo null even when the assignment succeeded; do NOT report that field as the recipient — re-read with fetch_codes, which returns it correctly. Requires the Codes & Coupons module enabled on the account — on 403 "module not enabled", do NOT retry; tell the user to contact Sweeppea support.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| coupon_token | Yes | The code token (UUID v4) of an unassigned, not-redeemed code | |
| participant_token | Yes | The participant token (UUID v4) of a participant of the same sweepstakes who holds no code |