Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

HashiCorp Vault

Connect to HashiCorp Vault to manage identity entities and groups, define and audit ACL policies, and look up or revoke issued tokens by accessor.

Connectors

Choose the connector that matches your authentication method. The options below use the names shown in StackAI.

Connector
Authentication

HashiCorp Vault

API key or token

HashiCorp Vault

Connect to a HashiCorp Vault cluster (HCP Vault Dedicated or self-hosted) to govern access: manage identity entities and groups, author and audit ACL policies, and inspect or revoke issued tokens by accessor. Requires a cluster URL and a Vault token; access is governed by the token's policies.

Set up in HashiCorp Vault

  1. Prepare the HashiCorp Vault account or service that the workflow will access. Grant access to the required resources and operations.

  2. Cluster URL: The Vault cluster address, scheme+host+port only (no '/v1' prefix, no trailing slash). For HCP Vault Dedicated, copy the public cluster URL from the cluster overview page in the HCP portal (port 8200). For self-hosted Vault, use your cluster's address, e.g. 'https://vault.example.com:8200'.

  3. Vault Token: A Vault token, sent as 'X-Vault-Token' on every request. The connection stops working when the token expires, so mint a long-lived token: vault token create -orphan -policy=<your-policy> -ttl=768h. Use -orphan so the token survives the token that minted it (Vault revokes child tokens with their parent); 768h (32 days) is Vault's default maximum TTL — rotate before expiry. Do not paste the HCP portal's 'Generate token' output: it expires within hours and is meant for initial setup or emergency access only.

Set up in StackAI

  1. Open Settings → Connections, add a connection, and select HashiCorp Vault.

  2. Enter the credentials and connection details in the fields below.

  3. Save the connection and check its connection status. Select this saved connection when configuring an action or feature that uses it.

Connection fields

StackAI field
Required
What to enter

Cluster URL

Yes

The Vault cluster address, scheme+host+port only (no '/v1' prefix, no trailing slash). For HCP Vault Dedicated, copy the public cluster URL from the cluster overview page in the HCP portal (port 8200). For self-hosted Vault, use your cluster's address, e.g. 'https://vault.example.com:8200'.

Vault Token

Yes

A Vault token, sent as 'X-Vault-Token' on every request. The connection stops working when the token expires, so mint a long-lived token: vault token create -orphan -policy=<your-policy> -ttl=768h. Use -orphan so the token survives the token that minted it (Vault revokes child tokens with their parent); 768h (32 days) is Vault's default maximum TTL — rotate before expiry. Do not paste the HCP portal's 'Generate token' output: it expires within hours and is meant for initial setup or emergency access only. Provider instructions.

Namespace

Optional / as applicable

HCP Vault users must enter 'admin' (the top-level HCP namespace). Leave blank for open-source Vault, which has no namespaces. Provider instructions.

Custom CA Bundle (optional)

Optional / as applicable

One or more PEM-encoded CA certificates, trusted in addition to the normal roots for this connection only. Use for self-hosted Vault behind a private CA. Certificate and hostname verification stay enabled. When not set, only the system trust store is used.

Verify the connection

Check that the connection is healthy. Then run a read operation against a resource the connected account can access. A successful connection check confirms authentication; it does not guarantee permission for every action.

If access is denied, check the credential or OAuth permissions, the selected account or environment, and access to the specific resource. Update expired credentials or reconnect after permissions change.

Use an action

  1. Add the required HashiCorp Vault action to the workflow.

  2. Select a connection when the action requests one.

  3. Complete the required fields. Use the reference picker when a value comes from another workflow step.

  4. Run the workflow and inspect the action’s output. Check the result before using it in a later step.

Actions

Create or Update Identity Entity

Create an identity entity (a person or application) or update its policies and metadata. Uses the entity name as the key, so calling it again with the same name updates that entity.

Inputs

Field
Type
Required
Description

Entity name

string

Yes

A unique name for the entity, e.g. the person's username or an app id.

Policies

multiple_select (string)

No

Select one or more ACL policy names to attach. Must already exist in Vault. Leave blank to remove all policies; omit to leave them unchanged. Options load from the selected connection.

Metadata (JSON)

textarea

No

Optional labels as a JSON object of string values, e.g. {"team":"finance"}.

Disabled

boolean

No

Disable the entity to block all of its logins, or enable it. Leave unset to keep the current state.

Outputs

Field
Type
Description

Entity ID

string

The entity's unique id.

Entity name

string

The entity name.

Get Identity Entity

Look up an identity entity by name and see its attached policies, status, and metadata.

Inputs

Field
Type
Required
Description

Entity name

select (string)

Yes

The name of the entity to look up. Options load from the selected connection.

Outputs

Field
Type
Description

Entity ID

string

The entity's unique id.

Entity name

string

The entity name.

Policies

string_array

The ACL policies attached to the entity.

Disabled

boolean

Whether the entity is disabled.

Metadata

dict

The entity's metadata labels.

List Entities

List the identity entities in your Vault namespace.

Inputs

No input fields are required in this catalog entry.

Outputs

Field
Type
Description

Entity names

string_array

The names of the identity entities in the namespace.

Create or Update Identity Group

Create an identity group or update its attached policies and members. Grants access to many entities at once. Uses the group name as the key (upsert).

Inputs

Field
Type
Required
Description

Group name

string

Yes

A unique name for the group, e.g. finance-admins.

Policies

multiple_select (string)

No

Select one or more ACL policy names the group grants. Leave blank to remove all; omit to leave unchanged. Options load from the selected connection.

Member entity IDs

string

No

Comma-separated entity IDs to set as members. Get IDs from Get Identity Entity. Leave blank to remove all members; omit to leave unchanged.

Group type

select (string)

No

Internal groups have members you set here; external groups are mapped from an auth source. Omit to leave an existing group's type unchanged (type cannot be changed after a group is created). Available values: Internal, External.

Member group IDs

string

No

Comma-separated group IDs to nest as sub-groups. Leave blank to remove all; omit to leave unchanged.

Metadata (JSON)

textarea

No

Optional labels as a JSON object.

Outputs

Field
Type
Description

Group ID

string

The group's unique id.

Group name

string

The group name.

Get Identity Group

Look up an identity group by name and see its attached policies, members, and metadata.

Inputs

Field
Type
Required
Description

Group name

select (string)

Yes

The name of the identity group to look up. Options load from the selected connection.

Outputs

Field
Type
Description

Group ID

string

The group's unique id.

Group name

string

The group name.

Policies

string_array

The ACL policies attached to the group.

Member entity IDs

string_array

The ids of entities that are direct members of the group.

Member group IDs

string_array

The ids of groups nested under this group.

Group type

string

Whether the group is internal or external (synced from an auth method).

Metadata

dict

The group's metadata labels.

List Groups

List the identity groups in your Vault namespace.

Inputs

No input fields are required in this catalog entry.

Outputs

Field
Type
Description

Group names

string_array

The names of the identity groups in the namespace.

Write ACL Policy

Create or replace an ACL policy: the rules that say which Vault paths a token may access. Uses the policy name as the key.

Inputs

Field
Type
Required
Description

Policy name

string

Yes

A unique name for the policy, e.g. billing-readonly.

Policy document

textarea

Yes

The policy rules in HCL. Each path block lists allowed capabilities.

Outputs

Field
Type
Description

Policy name

string

The policy name that was written.

Written

boolean

Whether the policy was saved.

Read Policy

Look up an ACL policy by name and see its authorization rules.

Inputs

Field
Type
Required
Description

Policy name

select (string)

Yes

The name of the ACL policy to read. Options load from the selected connection.

Outputs

Field
Type
Description

Policy name

string

The policy name.

Policy rules

string

The policy's authorization rules, in HCL format.

List Policies

List the ACL policies in your Vault namespace.

Inputs

No input fields are required in this catalog entry.

Outputs

Field
Type
Description

Policy names

string_array

The names of the ACL policies in the namespace.

Delete Policy

Permanently delete an ACL policy by name. Revokes the access it granted; this cannot be undone.

Inputs

Field
Type
Required
Description

Policy name

select (string)

Yes

The name of the ACL policy to delete. This cannot be undone and revokes the access the policy granted. Options load from the selected connection.

Outputs

Field
Type
Description

Policy name

string

The policy name that was deleted.

Deleted

boolean

Whether the policy was deleted.

Look Up Token Accessor

Look up a token by its accessor and see its display name, attached policies, remaining TTL, and remaining uses, without exposing the token value.

Inputs

Field
Type
Required
Description

Token accessor

string

Yes

The token accessor to look up (not the token value itself).

Outputs

Field
Type
Description

Token accessor

string

The token accessor.

Display name

string

The token's display name.

Policies

string_array

The ACL policies attached to the token.

TTL (seconds)

integer

Seconds remaining before the token expires.

Remaining uses

integer

The number of uses remaining, if the token is use-limited.

Creation path

string

The auth path the token was created against.

Revoke Token Accessor

Revoke a token by its accessor. This is permanent: the token and any child tokens it issued stop working immediately.

Inputs

Field
Type
Required
Description

Token accessor

string

Yes

The token accessor to revoke. This is permanent: the token and any child tokens it issued stop working immediately.

Outputs

Field
Type
Description

Token accessor

string

The token accessor that was revoked.

Revoked

boolean

Whether Vault confirmed the revocation.

Important behavior

Actions that create, update, send, or delete data can change the connected service. Review their inputs before running them. A retry can repeat an operation; consider this when configuring retries for actions that change data.

The catalog lists the fields and capabilities available in the supplied provider definition. Availability can also depend on your deployment and organization’s Feature Access settings.

Last updated

Was this helpful?