Need help with your APIs? I offer API discovery, governance & evangelism services. Explore services →
API Evangelist API Evangelist
Discovery
Learnings
Guidance
Toolbox
Alignment
API Evangelist LLC

HashiCorp Vault Token API

Token auth method for token lifecycle management

HashiCorp Vault Token API is one of 28 APIs that HashiCorp Vault publishes on the APIs.io network, described by a machine-readable OpenAPI specification.

Tagged areas include Token. The published artifact set on APIs.io includes an OpenAPI specification, API documentation, and authentication docs.

This API exposes 12 operations across 10 paths, and defines 4 schemas. It is described by OpenAPI 3.1.0, at version 1.0.

Requests are made against a single base URL, https://vault.example.com/v1.

12 operations 10 paths 4 schemas 1 DELETE2 GET9 POST

Metadata

The identity and technical contract details declared by the specification.

Specification
OpenAPI 3.1.0
API Version
1.0
Base URL
https://vault.example.com/v1/sys
Authentication
API Key
Resource Areas
1

Authentication & Security 1

HashiCorp Vault Token API declares 1 security scheme for authenticating requests. An API key is passed in the header as X-Vault-Token (vaultToken). By default, every request must be authenticated.

  • vaultToken — Vault authentication token

Paths & Operations 12

Across 10 paths, the API surfaces 12 operations — 1 DELETE, 2 GET, 9 POST. Each is listed below with its method, path, parameters, and response codes.

Token 12

Token auth method for token lifecycle management

POST
/auth/token/create
HashiCorp Vault Create token
createToken body → 200400403
POST
/auth/token/create-orphan
HashiCorp Vault Create orphan token
createOrphanToken body → 200403
POST
/auth/token/create/{role_name}
HashiCorp Vault Create token with role
createTokenWithRole 1 param body → 200400403
POST
/auth/token/lookup
HashiCorp Vault Lookup token
lookupToken body → 200403
GET
/auth/token/lookup-self
HashiCorp Vault Lookup self token
lookupSelfToken → 200403
POST
/auth/token/renew
HashiCorp Vault Renew token
renewToken body → 200400403
POST
/auth/token/renew-self
HashiCorp Vault Renew self token
renewSelfToken body → 200400
POST
/auth/token/revoke
HashiCorp Vault Revoke token
revokeToken body → 204403
POST
/auth/token/revoke-self
HashiCorp Vault Revoke self token
revokeSelfToken → 204
GET
/auth/token/roles/{role_name}
HashiCorp Vault Read token role
readTokenRole 1 param → 200404
POST
/auth/token/roles/{role_name}
HashiCorp Vault Create or update token role
createOrUpdateTokenRole 1 param body → 204400
DELETE
/auth/token/roles/{role_name}
HashiCorp Vault Delete token role
deleteTokenRole 1 param → 204

Schemas 4

The contract defines 4 schemas that model the data the API accepts and returns. The most detailed are CreateTokenRequest (14 properties), TokenRole (9 properties), AuthResponse (5 properties), TokenLookupResponse (1 property). Each schema is shown below with its type and property counts.

TokenLookupResponse
object
1 property
AuthResponse
object
5 properties
CreateTokenRequest
object
14 properties
TokenRole
object
9 properties

Specification

The full machine-readable OpenAPI contract behind this narrative.

Source

hvault-token-api-openapi.yml Raw ↑

Other APIs HashiCorp Vault publishes across the network.

HashiCorp Vault AppRole API
HashiCorp Vault Audit API
HashiCorp Vault Auth API
HashiCorp Vault AWS API
HashiCorp Vault Configuration API
HashiCorp Vault Database API
HashiCorp Vault Entity Alias API
HashiCorp Vault Entity API
HashiCorp Vault GitHub API
HashiCorp Vault Group Alias API
HashiCorp Vault Group API
HashiCorp Vault Health API