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

# Unipile: Create Hosted Auth Link

> Creates a Unipile hosted-authentication URL that a person opens to connect a new account or reconnect a disconnected one (LinkedIn, WhatsApp, Google.

Creates a Unipile hosted-authentication URL that a person opens to connect a new account or reconnect a disconnected one (LinkedIn, WhatsApp, Google.

> [!NOTE]
>
> Tool ID: `unipile_create_hosted_auth_link`

## Run this action

Use the TypeScript SDK for one call. Use `ctx.tools.execute(...)` inside a Play for durable calls, scheduled calls, or CSV processing.

```ts theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
import { Deepline } from 'deepline';

const deepline = await Deepline.connect();
const result = await deepline.tools.execute(
  'unipile_create_hosted_auth_link',
  {
    "expiresOn": {},
    "api_url": "https://example.com",
    "type": "create",
    "providers": "*"
  },
);

console.log(result.toolResponse.raw);
```

### CLI

```bash theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
deepline tools execute unipile_create_hosted_auth_link --input '{
  "expiresOn": {},
  "api_url": "https://example.com",
  "type": "create",
  "providers": "*"
}' --json
```

## Example response

The SDK returns this shape at `result.toolResponse.raw`. The example values illustrate the response.

```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
{
  "data": {
    "object": "HostedAuthUrl",
    "url": "https://example.com"
  }
}
```

Use `deepline describe unipile_create_hosted_auth_link --json` for the latest machine-readable contract.

## Input reference

Create a url which redirect to Unipile's hosted authentication to connect or reconnect an account.

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `payload.expiresOn` | `unknown` | Yes | — | An ISO 8601 UTC datetime (YYYY-MM-DDTHH:MM:SS.sssZ). ⚠️ All links expire upon daily restart, regardless of their stated expiration date. A new link must be generated each time a user clicks on your app to connect. Pattern: `^[1-2]\d&#123;3&#125;-[0-1]\d-[0-3]\dT\d&#123;2&#125;:\d&#123;2&#125;:\d&#123;2&#125;.\d&#123;3&#125;Z$`. |
| `payload.name` | `string` | No | — | This field will be sent back to you in the notify\_url to help match the added account with your user. Minimum length: 1. |
| `payload.success_redirect_url` | `unknown` | No | — | A url where you might want to redirect the user in case of a successful authentication. |
| `payload.failure_redirect_url` | `unknown` | No | — | A url where you might want to redirect the user in case of a failed authentication. |
| `payload.bypass_success_screen` | `boolean` | No | — | Whether to bypass the hosted auth success screen before accessing the success\_redirect\_url. |
| `payload.notify_url` | `unknown` | No | — | A url where you can be notified about events related to the authentication process. |
| `payload.disabled_features` | `array` | No | — | An array of features that should be disabled in this account. Accepted values : linkedin\_recruiter \| linkedin\_sales\_navigator \| linkedin\_organizations\_mailboxes. |
| `payload.disabled_options` | `array` | No | — | An array of options that should be disabled in hosted auth interface. Accepted values : proxy \| autoproxy \| cookie\_auth \| credentials\_auth \| qrcode\_auth \| pairing\_code\_auth \| sync\_limit \| language. `qrcode_auth` and `pairing_code_auth` are currently supported for WhatsApp only. |
| `payload.proxy` | `object` | No | — | — |
| `payload.api_url` | `unknown` | Yes | — | The url of your Unipile server : https\://\{subdomain}.unipile.com:\{port} |
| `payload.sync_limit` | `object` | No | — | — |
| `payload.google_scopes` | `string` | No | — | Optional comma-separated list of scopes to use for GOOGLE\_OAUTH accounts Format: `googleScopes`. |
| `payload.microsoft_scopes` | `string` | No | — | Optional comma-separated list of scopes to use for OUTLOOK accounts. To enable delegated mailbox authentication, Include Mail.ReadWrite.Shared, Mail.Send.Shared, Contacts.Read.Shared, and User.ReadBasic.All. Format: `microsoftScopes`. |
| `payload.type` | `"create" \| "reconnect"` | Yes | — | A litteral value to choose between a connection or a reconnection. Allowed: `create`, `reconnect`. |
| `payload.providers` | `"*" \| "*:MAILING" \| "*:MESSAGING" \| "*:CALENDAR" \| array` | No | — | The providers for whom you want to propose to connect an account. |
| `payload.single_use` | `boolean` | No | — | Whether the hosted authentication link can be used to connect only one account. Defaults to false. |
| `payload.reconnect_account` | `string` | No | — | The id of the account to reconnect. Minimum length: 1. |

> [!NOTE]
>
> This input schema is too large for an inline display. Read the complete live contract with `deepline describe unipile_create_hosted_auth_link --json`.

## Output reference

Standard tool result payload.

| Name | Type | Required | Default | Details |
| - | - | - | - | - |
| `result.data` | `object` | Yes | — | Provider response payload. |
| `result.data.object` | `"HostedAuthUrl"` | Yes | — | Allowed: `HostedAuthUrl`. |
| `result.data.url` | `string` | Yes | — | A url redirecting to Unipile's hosted authentication for account connection or reconnection. |
| `result.meta` | `object` | No | — | Additional response metadata (status, paging). |

<details>
  <summary>Show raw output schema</summary>

  ### Output JSON Schema

  ```json theme={"languages":{"custom":["/languages/deepline-prompt.json"]}}
  {
    "type": "object",
    "description": "Standard tool result payload.",
    "properties": {
      "data": {
        "type": "object",
        "description": "Provider response payload.",
        "properties": {
          "object": {
            "type": "string",
            "enum": [
              "HostedAuthUrl"
            ]
          },
          "url": {
            "type": "string",
            "description": "A url redirecting to Unipile's hosted authentication for account connection or reconnection."
          }
        },
        "required": [
          "object",
          "url"
        ],
        "additionalProperties": false
      },
      "meta": {
        "type": "object",
        "description": "Additional response metadata (status, paging).",
        "additionalProperties": true
      }
    },
    "required": [
      "data"
    ],
    "additionalProperties": false
  }
  ```
</details>

## Deepline cost

* Pricing model: `fixed` (per call).
* Estimated Deepline credits: `0` per pricing unit.
* Provider-native pricing may still exist outside Deepline credit billing.

## Related documentation

* [Unipile provider guide](https://deepline.com/docs/providers/unipile/guide.md)
* [SDK V2 quickstart](https://deepline.com/docs/sdk-v2/quickstart.md)
* [SDK reference](https://deepline.com/docs/sdk-v2/sdk-reference.md)
* [Run tools across a CSV](https://deepline.com/docs/sdk-v2/batch-csv.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.