--- title: "iamrole create" slug: "iamrole-create" tags: ["5.4"] updated: 2026-10-28T01:53:01Z published: 2026-10-28T01:53:01Z canonical: "docs.vastdata.com/iamrole-create" --- > ## Documentation Index > Fetch the complete documentation index at: https://docs.vastdata.com/llms.txt > Use this file to discover all available pages before exploring further. # iamrole create This command creates an IAM Role. ## Usage ```plaintext iamrole create --name NAME               --trust-policy TRUSTPOLICY              [--tenant-id TENANT]              [--description DESCRIPTION]              [--identity-policies-ids POLICY_IDS]              [--max-session-duration DURATION]     ``` ## Required Parameters | `--name NAME` | Specifies the name of IAM Role. | | --- | --- | | `--trust-policy TRUSTPOLICY` | Specifies the Trust policy, in JSON format. | ## Options | `--tenant-id TENANT` | Specifies the ID of the tenant to which this IAM Role belongs. | | --- | --- | | `--description DESCRIPTION` | Description of the IAM Role. | | `--identity-policies-ids POLICY_IDS` | Specifies the Identity Policy IDs to attach to this role. Specify POLICY_IDS as a comma-separated list of IDs. The policies must belong to the tenant associated with the role Example: `1,2,3` | | `--max-session-duration DURATION` | > [!NOTE] > This option is introduced in VAST Cluster 5.4.3. Limits the maximum duration for which a temporary access key can be granted to a requesting user, in seconds. Maximum (default): 129,600 (36 hours) Minimum: 900 (15 minutes) | ## Example This example creates a new IAM Role named "read-only-role". ```plaintext      vcli: admin> iamrole create --name read-only-role \                                  --trust-policy '{"Version":"2012-10-17","Statement":...}' \                                  --tenant-id 101 \                                  --description "Read-only role for audit" \                                  --identity-policies-ids 5,6     ```