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

# plerion aws

> AWS integration helpers for external IDs and CloudFormation templates.

With **plerion aws**, you can access AWS integration helpers including external ID retrieval and CloudFormation template generation.

***

## Synopsis

```bash theme={"system"}
plerion aws <subcommand> [options]
```

***

## Subcommands

### get-external-id

Returns the tenant's external ID used for cross-account AWS role trust policies.

```bash theme={"system"}
plerion aws get-external-id
```

### get-cloudformation-template

Returns the CloudFormation template for setting up a Plerion AWS integration.

```bash theme={"system"}
plerion aws get-cloudformation-template --type <type>
```

| Option | Type | Description |
| - | - | - |
| `--type` | string | **(required)** Template type. Allowed values: `AWSAccount` |

### generate-token

Generates a temporary token that grants restricted access to a small set of Plerion APIs.

```bash theme={"system"}
plerion aws generate-token --integration-id <id>
```

<Note>
  The AWS account CloudFormation template no longer takes this token. To launch or update a
  stack, pass your tenant ID instead — run `plerion tenant get` to read it.
</Note>

***

## Examples

```bash theme={"system"}
# Get the external ID for AWS role trust policy
plerion aws get-external-id --output json | jq '.data.externalId'

# Download the CloudFormation template
plerion aws get-cloudformation-template --type AWSAccount > plerion-template.json

# Read the tenant ID to pass to the template
plerion tenant get --output json | jq '.data.tenantId'

# Generate a temporary restricted-access token
plerion aws generate-token --integration-id int-abc123
```

### Example output (get-external-id, JSON)

```json theme={"system"}
{
  "data": {
    "externalId": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
  }
}
```


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