Then you can use the Vault CLI in your workspaces to fetch secrets from Vault:
```shell
vault kv get secret/my-secret
```
or using the Vault API:
```shell
curl -H "X-Vault-Token: $VAULT_TOKEN" -X GET $VAULT_ADDR/v1/secret/data/my-secret
```

## Configuration
To configure the Vault module, you must setup a Vault [OIDC Provider](https://developer.hashicorp.com/vault/docs/concepts/oidc-provider) and [configure](https://coder.com/docs/v2/latest/admin/external-auth) Coder to use it.
### OIDC Provider in Vault
1. Create a Vault OIDC Application with name `coder` and set the Redirect URI to `https://coder.example.com/external-auth/vault/callback`.
2. MAke note of the Vault OIDC Provider's Client ID and Client Secret.
3. Add a provider to OIDC application with name `coder` and set the "Issuer URL" to `$VAULT_ADDR`.