> For the complete documentation index, see [llms.txt](https://docs.paywithflash.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.paywithflash.com/products/editor/getting-started/pre-fill-user-details.md).

# Pre-Fill User Details

The Flash Subscription allows you to streamline user experience by pre-filling subscription forms with data like **email**, **Nostr ID (npub)**, and a unique identifier, **external\_uuid**, when redirecting users to the subscription page. This saves users from re-entering details and enables you to integrate smoothly with your own user management systems.

## **URL Parameters**

When redirecting users to the Flash subscription page, you can pass relevant user information in the URL through a Base64-encoded JSON object. The system will automatically pre-fill the subscription form based on these values.

### **Parameters you can pass:**

* **email**: The user's email address.
* **npub**: The user's Nostr public key (Npub).
* **external\_uuid**: A unique identifier from your system to map users in your backend with Flash APIs. This value is not visible to users and is only used internally for identification.
* **is\_verified**: A boolean value indicating whether the user's email or Npub has already been verified.
  * If set to `false`, Flash will handle the verification process by either sending an email (for email addresses) or a Nostr DM (for Npubs) with a verification token.
  * If set to `true`, no additional verification steps are required, and the subscription process will continue seamlessly.

### **How to Pass Parameters**

You can pass the following parameters by embedding them as a Base64-encoded JSON object in the `params` query string:

```json
{
  "email": "user@example.com",
  "npub": "npub123...",
  "is_verified": false,
  "external_uuid": "your-unique-user-id"
}
```

The resulting URL might look like this:

{% code overflow="wrap" %}

```html
https://app.paywithflash.com/subscription-page?flashId=459&params=<Base64-encoded-JSON>
```

{% endcode %}

When Flash receives this URL, the system decodes the parameters and pre-populates the subscription form with the provided data.

## **How Flash Uses These Parameters:**

* **Pre-Filled Fields**: The user's **email** or **Npub** will be automatically filled into the form.
* **Verification**:
  * If the user is not verified (i.e., `is_verified = false`), Flash will initiate the verification process by sending a verification token:
    * **Email**: The user will receive a token via email.
    * **Npub**: The user will receive a token via Nostr DM.
  * The user will then input the received token into the interface to verify their identity.

> **Note:** The `external_uuid` parameter is designed for developers to map their own user IDs with the Flash system, making it easy to track and manage users across platforms. This value is not shown to users.

***

## **Example Workflow**

1. **Set Up the Redirect**: Pass the user's email, Npub, and external UUID in the URL as described above.
2. **Pre-Filled Form**: The subscription page will pre-fill the user's details.
3. **Verification (if required)**: If the user isn't verified, Flash sends a token via email or Nostr DM, which the user will input to complete verification.
4. **Subscription Completed**: Once verified, the user can complete their subscription without re-entering details.


---

# 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.paywithflash.com/products/editor/getting-started/pre-fill-user-details.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.
