Share a website by email
share_siteShare a website with specific people by email, whether it is private or password-protected — sharing does not change who else can reach it. Each address is mailed a link from Valet that opens the site; the recipient needs no Valet account of their own, only the link, so anyone holding the email can open the site and forwarding it forwards access. Sharing again with an address that already has access re-sends the same link rather than creating a second one. Requires connecting a Valet account.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | Required. The site's name. | |
| emails | Yes | Required. The email addresses to share the site with, at most 10 at a time. Sharing again with an address that already has access re-sends the same link rather than creating a second one. | |
| message | No | An optional note included in the email, shown to the recipient as a quote beside the link. At most 500 characters. | |
| org_name | No | The Valet organization the site belongs to. Omit to use the organization the account joined first. | |
| access_ttl_seconds | No | How many seconds of access the first open starts, after which the link stops working. Omit, or pass 0, for access that never expires this way. Composes with expires_in_seconds: the unopened deadline governs until the first open replaces it. | |
| expires_in_seconds | No | How many seconds from now the link stops working if nobody has opened it yet. Omit, or pass 0, for a link that never expires this way. |