GitHub auth method (API)
Last updated
Last updated
This is the API documentation for the Vault GitHub auth method. For general information about the usage and operation of the GitHub method, please see the Vault GitHub method documentation.
This documentation assumes the GitHub method is enabled at the /auth/github
path in Vault. Since it is possible to enable auth methods at any location, please update your API calls accordingly.
Configures the connection parameters for GitHub. This path honors the distinction between the create
and update
capabilities inside ACL policies.
Method | Path |
---|---|
organization
(string: <required>)
- The organization users must be part of.
organization_id
(int: 0)
- The ID of the organization users must be part of. Vault will attempt to fetch and set this value if it is not provided.
base_url
(string: "")
- The API endpoint to use. Useful if you are running GitHub Enterprise or an API-compatible authentication server.
VAULT_AUTH_CONFIG_GITHUB_TOKEN
(string: "")
- An optional GitHub token used to make authenticated GitHub API requests. This can be useful for bypassing GitHub's rate-limiting during automation flows when the organization_id
is not provided. We encourage you to provide the organization_id
instead of relying on this environment variable.
@include 'tokenfields.mdx'
Reads the GitHub configuration.
Map a list of policies to a team that exists in the configured GitHub organization.
team_name
(string)
- GitHub team name in "slugified" format
value
(string)
- Comma separated list of policies to assign
Reads the GitHub team policy mapping.
Map a list of policies to a specific GitHub user exists in the configured organization.
user_name
(string)
- GitHub user name
value
(string)
- Comma separated list of policies to assign
The user with username sethvargo
will be assigned the sethvargo-policy
policy in addition to any team policies.
Reads the GitHub user policy mapping.
Login using GitHub access token.
token
(string: <required>)
- GitHub personal API token.
Method | Path |
---|---|
Method | Path |
---|---|
Method | Path |
---|---|
Method | Path |
---|---|
Method | Path |
---|---|
Method | Path |
---|---|
POST
/auth/github/config
GET
/auth/github/config
POST
/auth/github/map/teams/:team_name
GET
/auth/github/map/teams/:team_name
POST
/auth/github/map/users/:user_name
GET
/auth/github/map/users/:user_name
POST
/auth/github/login