> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sitestorepro.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Access Control: Users, Gates & Magic Links

> Manage user roles, configure OAuth and email verification, gate CMS pages by purchase or code, and issue secure magic links for post-purchase content access.

Site Store Pro gives you a layered access control system that covers who can log in, what they can see after logging in, and how paying customers — including guests — gain entry to protected content. This page explains each layer, from user role assignments through to UUID-based magic links for member portals.

## User Role Levels

Every Site Store Pro account is assigned one of four role levels. Roles determine which parts of the admin panel and customer-facing portal a user can access.

| ID | Role      | Name                      | Permissions                                                                      |
| -- | --------- | ------------------------- | -------------------------------------------------------------------------------- |
| 1  | Customer  | **Customer**              | Submit support tickets, view order history, manage their own profile             |
| 2  | Wholesale | Wholesale User            | Same access as Customer but is shown wholesale product pricing.                  |
| 3  | Admin     | **Admin**                 | Full system access across catalog, settings, plugins, themes, users, and tickets |
| 4  | Staff     | **Staff / Support Agent** | Access to ticket queues, helpdesk management, and order processing               |

<Info>
  Assign the **Staff / Support Agent** role to team members who handle customer service. They gain helpdesk and order access without the full system privileges of an Admin.
</Info>

***

## Registration & Verification

Site Store Pro supports two registration pathways. Each pathway handles identity verification differently.

<Tabs>
  <Tab title="Social OAuth Login">
    Customers who register via Google, Facebook, or GitHub are automatically verified at the moment they log in. The OAuth provider authenticates their identity, and Site Store Pro grants full account access immediately upon account creation — no additional verification step required.

    **Result:** the customer gains full account access straight away — dashboard, order history, and the ticket portal.
  </Tab>

  <Tab title="Standard Password Registration">
    Customers who register with an email address and password receive a signed verification link by email before gaining full access.

    * Clicking the verification link confirms their email address and unlocks the full account.
    * Until verification is complete, the customer can browse your storefront normally but is redirected to the verification prompt when they attempt to access the dashboard or ticket portal.

    <Warning>
      Remind customers to check their spam or junk folder if they do not receive the verification email within a few minutes of registering.
    </Warning>
  </Tab>
</Tabs>

***

## Guest Checkout & Account Conversion

Customers can complete a purchase without creating a password. Guests receive their order confirmation email and instant download links immediately after checkout, but they cannot log in directly — their account has no password set until they complete the conversion process.

To convert a guest account into a full password account, the customer follows a two-step process:

<Steps>
  <Step title="Verify email">
    The customer clicks the signed verification link included in their order confirmation email. This confirms ownership of the email address.
  </Step>

  <Step title="Set a password">
    The signed link routes the customer to `/account/set-password`. They enter a new password, which converts the guest record into a fully authenticated account with complete login access.
  </Step>
</Steps>

<Info>
  After conversion, the customer's order history, download links, and ticket submissions are all retained and immediately accessible under their new account.
</Info>

***

## CMS Page Access Gating

You can restrict access to any CMS page using one or both of the built-in gate types. Gates are configured per page in the admin panel.

<CardGroup cols={2}>
  <Card title="Product Gate" icon="bag-shopping">
    Require a verified, paid purchase of a specific product before granting access to the page. Ideal for members-only content, course material, or digital downloads tied to a specific purchase.
  </Card>

  <Card title="Code Gate" icon="lock">
    Protect a page with a secret access code. Visitors see a lock screen and must enter the correct code to proceed. Useful for beta access, partner portals, or event-specific content.
  </Card>
</CardGroup>

### Dual-Gate Behaviour

When you enable both a Product Gate and a Code Gate on the same page, Site Store Pro grants access if the visitor satisfies **either** condition — a verified purchase **or** a valid access code. You do not need to satisfy both.

***

## Post-Order Completion Redirects

After a customer completes an order, you can redirect them to a specific destination. Configure the destination in **Admin → Products → Edit → Advanced Settings**.

The redirect field accepts three formats:

| Format        | Example                                  |
| ------------- | ---------------------------------------- |
| Full URL      | `https://yourdomain.com/members/welcome` |
| Relative path | `/members/getting-started`               |
| CMS shortcode | `[page:12]`                              |

### Order Success and Order Confirmation Button Redirect Target

Each product's completion redirect also supports a custom **Button Label**. The label text appears as the call-to-action button inside order confirmation, shipment, and download reminder emails, replacing the generic default button text.

***

## Secure UUID Magic Links

When a customer orders a product that has a completion redirect configured, Site Store Pro automatically generates a secure, UUID-based magic link tied to that order.

**Magic link URL format:**

```text theme={null}
/content-access/{uuid}
```

### How Magic Links Work

<Steps>
  <Step title="Link generated">
    Site Store Pro generates a secure magic link when the order is placed for a product with a completion redirect configured.
  </Step>

  <Step title="Link delivered">
    The UUID link is embedded in the order confirmation email as a call-to-action button and is included in any resent order emails.
  </Step>

  <Step title="Visitor redeems the link">
    When the visitor opens `/content-access/{uuid}`, Site Store Pro validates the link, records the verified purchase in the visitor's session, and redirects them to the protected content page.
  </Step>
</Steps>

### Key Properties

| Property         | Detail                                                                                        |
| ---------------- | --------------------------------------------------------------------------------------------- |
| **Guest access** | Allows guest purchasers to bypass CMS Product Gates without creating an account or logging in |
| **Expiry**       | 90 days by default                                                                            |
| **Regeneration** | A fresh magic link is issued each time an admin resends the order email                       |

<Tip>
  Use magic links as the primary access mechanism for a post-purchase member portal. Because the link bypasses the Product Gate without requiring a login, guests and registered customers alike reach your content in a single click directly from their order email.
</Tip>

<Warning>
  Magic links grant content access to anyone who holds the URL. Advise customers not to forward their order confirmation email to others if the linked content is intended to be personal or single-user.
</Warning>
