> For the complete documentation index, see [llms.txt](https://docs.rewst.help/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.rewst.help/documentation/automations/subworkflows/rewst-task-send-user-password.md).

# \[REWST - TASK] Send User Password

This workflow securely distributes user passwords through multiple channels, SMS to users or email to supervisors, and updates PSA tickets accordingly, serving as a critical security-focused building block that can be incorporated into user onboarding, password reset, or account management processes.

MSPs will find this valuable during client employee onboarding, password resets after security incidents, and regular credential rotation scenarios where secure, documented password delivery is required to maintain compliance and security best practices.

Technically, the workflow first checks for organization variables to determine delivery preferences, then conditionally routes the password either via SMS directly to the end user or through email to a supervisor, followed by automatic PSA ticket updates to document the action and maintain audit trails for compliance purposes.

This workflow contains 10 tasks.

### Inputs

* **email** - string
  * User's email address
* **password** - string
  * User's password to be sent
* **username** - string
  * User's Username
* **ticket\_id** - string
  * Ticket ID
* **first\_name** - string
  * User's First Name
* **supervisor** - string
  * Supervisor's Email Address
* **send\_sms\_to\_user** - boolean
  * Send SMS to user?
  * Default: `{{ false}}`
* **sms\_with\_country\_code** - string
  * SMS Phone Number with Country Code
* **send\_supervisor\_user\_password** - boolean
  * Send Supervisor User's Password
  * Default: `{{ false}}`

### Outputs

* **success** - Boolean; States if workflow was successful.
* **automation\_log**: Standardized Rewst automation log

### Key tasks

* **check\_send\_supervisor\_password**: Communication/notification
* **send\_sms\_to\_user**: Communication/notification
* **sms\_update\_ticket**: Data modification
* **send\_sms\_org\_var\_not\_set**: Communication/notification
* **check\_send\_sms**: Communication/notification

### Jinja examples

#### Example 1

```jinja
{{ CTX.sms_with_country_code|d }}
```

Used in input for `sms_number` for send\_sms\_to\_user task.

#### Example 2

```jinja
{{ CTX.username|d }}
```

Used in input for `username` for send\_password\_to\_supervisor task.


---

# 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 by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.rewst.help/documentation/automations/subworkflows/rewst-task-send-user-password.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

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.
