Restore a saved entity to checkout
Adds a previously selected entity back into the Redis-backed public checkout cart from query/body parameters. The endpoint validates the required ids, amount, frequency, and sponsorship amount, creates a replacement frontend session when the supplied one is expired, and stores the entity amount and default frequency in Redis. Public checkout uses this legacy route when restoring cart state.
Query Parameters
Client id that owns the checkout session and entity. Validator rule: required.
Program id for the selected entity. Validator rule: required.
Entity id to add back to saved_entity_id in Redis. Validator rule: required.
Redis frontend session id for the checkout cart. Validator rule: required; a replacement session is created if it is expired.
Raw amount entered by the donor. Validator rule: required; the controller trims and strips non-numeric characters before storing it as sponsorship_amount.
Frequency value carried by the legacy route. Validator rule: required; used for the saved entity frequency and amount-policy selection.
Sponsorship amount to store in Redis when amount is empty. Validator rule: required.
Response
Entity was restored to the checkout cart.
"<strong>Jane Student</strong> has been added back to your order!"