# HashiCorp Based Credential

Create a temporary HashiCorp-based credential as a variable you can inject into later steps. Use it when a flow needs a
short-lived secret from your HashiCorp configuration without storing a permanent credential in the playbook. HashiCorp
Based Credential lives in the **Create temporary credential** category of the `fx` menu.

## Parameter

| Parameter         | Type   | Required | Default | Description                                                                                               |
| ----------------- | ------ | -------- | ------- | --------------------------------------------------------------------------------------------------------- |
| Credential fields | object | yes      | —       | HashiCorp-based credential configuration fields shown in Studio (service credential and related options). |

Studio shows the HashiCorp credential form for this function. Availability can be flag-gated per deployment.

## Returned value

| Type     | Description                                                                |
| -------- | -------------------------------------------------------------------------- |
| `string` | A base64-encoded credential payload the platform can inject as a variable. |

## Limitations

- This function is flag-gated on some platforms — if it does not appear in `fx`, ask your admin or check
  `studio.hiddenFunctions`.
- Credential field values must match what your HashiCorp integration expects; incomplete configuration fails at runtime.

## Example

<details>
<summary>Create an injectable temporary credential</summary>

Configure the HashiCorp fields on the function card, then use the output variable in a later step that needs that
credential.

1. Open **HashiCorp Based Credential** from **Create temporary credential** in the `fx` menu.
2. Fill in the credential fields shown on the card (including the service credential).
3. Confirm **Output value** is a base64 string you can reference as a variable in downstream steps.

</details>
