How visit limits and expiry work for links
Each Link record stores three access-control fields: maxVisits (cap on per-customer clicks), expiresAfterHours (rolling window from purchase date), and expiresOn (fixed calendar date). When a customer clicks the access link, Alva reads the visit count, compares it against maxVisits, and writes a LinkVisit row inside a Serializable database transaction — two browser tabs racing the final visit cannot both succeed. A blank field means that axis is unlimited.
Set defaults globally
Max visits and expiry live on each Link record — Alva does not store separate global defaults. To apply a consistent baseline across the catalogue, decide on the values once and reuse them.
- Pick baseline numbers. A common starting point is Max visits 5 and Expires after hours 720 (30 days). Use a tighter cap for streaming links (Vimeo, Loom), looser for community links (Discord, Notion).
- Apply the same numbers to every new link as you create it, in the Access controls card on the create page.
- To retrofit existing links, open each Link record and set the values there. Save updates every existing customer access link for that product.
Alva admin → Link edit page → Access controls card. Show the three fields (Max visits, Expires after hours, Expires on) populated with example values (5 / 720 / blank). Highlight the card. No real customer data visible.
Override per link
Override the baseline when one product needs different rules — for example, a one-off masterclass that should expire on a fixed date.
- In the Alva admin, click Links in the left navigation, then click the title of the link to change.
- In the Access controls card, set Max visits, Expires after hours, and Expires on. Leave any field blank to make that axis unlimited.
- Click Save. Existing access links enforce the new values on the next click; future orders pick them up automatically.
Alva admin → Link edit page after Save with a green success toast. Show Max visits filled, Expires after hours filled, Expires on left blank. No real customer data visible.
What customers see when they hit a limit
When a customer clicks an access link that has exceeded maxVisits, expiresAfterHours, or expiresOn, Alva does not redirect to the destination URL. The customer sees the same friendly limit-reached page used for file downloads, with a short message and a contact link. See Why your customer hit the download limit for the full message text and how to reset access for a specific buyer.
Combining with link rotation
If you re-issue the destination URL on the back end — for example, regenerating a private Vimeo Showcase link or moving a folder — edit the Link record and paste the new URL. Every existing customer access link continues to work because Alva proxies through its own access route (/apps/alvadigitaldownloads/link?key=…&linkId=…) rather than handing out the raw URL. Visit counts and expiry timers continue against the same Link record across the rotation.
Frequently asked questions
Per customer. Each Download record has its own visit count against the Link, so customer A using 5 visits does not consume any of customer B's allowance.
Yes. Expires after hours and Expires on are independent. The link fails the moment either one is exceeded — whichever hits first.
Yes. The Link record is the source of truth. Editing Max visits or expiry changes the rules for every existing customer access link on the next click.
See also
Was this helpful?
Last updated 2026-05-06