> For the complete documentation index, see [llms.txt](https://docs.samita.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.samita.io/b2b-lock-password-protect/access-rules.md).

# Access rules

- [Access rules overview](https://docs.samita.io/b2b-lock-password-protect/access-rules/overview.md): What an access rule is, how If/Unless matching works, and where to find every rule type the app supports.
- [Combining rules](https://docs.samita.io/b2b-lock-password-protect/access-rules/combining-rules.md): How multiple conditions inside one access key are evaluated together.
- [Logged-in customers](https://docs.samita.io/b2b-lock-password-protect/access-rules/logged-in-customers.md): Restrict a lock to signed-in customers, or the reverse — require visitors to be signed out.
- [Customer tags](https://docs.samita.io/b2b-lock-password-protect/access-rules/customer-tags.md): Restrict a lock to customers whose account carries one or more specific tags.
- [B2B customer](https://docs.samita.io/b2b-lock-password-protect/access-rules/b2b-customer.md): Restrict a lock to customers who belong to a Shopify B2B company account.
- [Email contains](https://docs.samita.io/b2b-lock-password-protect/access-rules/email-contains.md): Match logged-in customers whose email address contains a given string, such as a company domain.
- [Selected customers](https://docs.samita.io/b2b-lock-password-protect/access-rules/selected-customers.md): Hand-pick specific individual customers who can access a lock, without relying on tags or emails.
- [Passcode](https://docs.samita.io/b2b-lock-password-protect/access-rules/passcode.md): Protect content with one or more shared passcodes that shoppers type in to unlock it.
- [Secret link](https://docs.samita.io/b2b-lock-password-protect/access-rules/secret-link.md): Protect content so only visitors arriving via a URL with a valid access token can unlock it.
- [Subscribe to unlock](https://docs.samita.io/b2b-lock-password-protect/access-rules/subscribe.md): Let shoppers unlock content by subscribing with their email, through Shopify, Mailchimp, or Klaviyo.
- [Confirmation prompt](https://docs.samita.io/b2b-lock-password-protect/access-rules/confirmation-prompt.md): Ask a shopper to self-certify with a confirm button before they can access protected content.
- [Custom liquid](https://docs.samita.io/b2b-lock-password-protect/access-rules/custom-liquid.md): Write your own Liquid snippet to decide access, with customer, cart, product, and storefront variables.
- [Date range](https://docs.samita.io/b2b-lock-password-protect/access-rules/date-range.md): Only make a lock active between a fixed start and end date — useful for time-limited promotions and events.
- [Weekly schedule](https://docs.samita.io/b2b-lock-password-protect/access-rules/weekly-schedule.md): Lock content on a recurring, per-day schedule with specific time windows — for example, every weekday 9am-5pm.
- [Storefront language](https://docs.samita.io/b2b-lock-password-protect/access-rules/storefront-language.md): Match visitors based on the storefront language they're currently browsing in.
- [Location](https://docs.samita.io/b2b-lock-password-protect/access-rules/location.md): Match visitors based on their detected country, using a public IP-geolocation lookup.
- [Certain IP addresses](https://docs.samita.io/b2b-lock-password-protect/access-rules/certain-ip-addresses.md): Match visitors whose public IP address exactly matches an address on a merchant-entered list.
- [Shop domain](https://docs.samita.io/b2b-lock-password-protect/access-rules/shop-domain.md): Match visitors based on the exact domain they're currently browsing your store on.
- [Purchased items](https://docs.samita.io/b2b-lock-password-protect/access-rules/purchased-items.md): Match customers who have already purchased specific products or variants, with quantity, lookback, and order-status options.
- [Order quantity](https://docs.samita.io/b2b-lock-password-protect/access-rules/order-quantity.md): Match customers whose total order count meets a minimum — good for loyalty and repeat-buyer perks.
- [Cart conditions](https://docs.samita.io/b2b-lock-password-protect/access-rules/cart-conditions.md): Match visitors based on what's currently in their cart — specific products, variants, item count, or subtotal.


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.samita.io/b2b-lock-password-protect/access-rules.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
