ReqAnthropic.Vaults.Credentials (ReqAnthropic v0.2.1)

Copy Markdown View Source

Credentials nested under a vault. Each credential binds to a single mcp_server_url and provides auth material (static bearer token or OAuth refresh config) that the session runtime injects when the agent connects to the MCP server.

Secret fields (token, access_token, refresh_token, client_secret) are write-only and never returned in responses.

Summary

Functions

Archive a credential. Purges the secret payload while preserving the record for auditing. Frees up the mcp_server_url for a replacement.

Functions

archive(vault_id, id, opts \\ [])

@spec archive(String.t(), String.t(), keyword()) ::
  {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}

Archive a credential. Purges the secret payload while preserving the record for auditing. Frees up the mcp_server_url for a replacement.

create(vault_id, opts)

@spec create(
  String.t(),
  keyword()
) :: {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}

delete(vault_id, id, opts \\ [])

@spec delete(String.t(), String.t(), keyword()) ::
  {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}

get(vault_id, id, opts \\ [])

@spec get(String.t(), String.t(), keyword()) ::
  {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}

list(vault_id, opts \\ [])

@spec list(
  String.t(),
  keyword()
) :: {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}

update(vault_id, id, opts)

@spec update(String.t(), String.t(), keyword()) ::
  {:ok, map()} | {:error, ReqAnthropic.Error.t() | Exception.t()}