Skip to content
Skip to Content
Coder Docs

Get authentication methods

GET
/api/v2/users/authmethods

Authorization

CoderSessionToken
headerCoder-Session-Token<token>

Response Body

OK

application/json
  1. response
github?
oidc?
password?
setup_token_required?boolean

SetupTokenRequired is true when the first user can only be created with a setup token.

terms_of_service_url?string

The samples read CODER_URL and CODER_SESSION_TOKEN: set up your environment.

curl -X GET \	"$CODER_URL/api/v2/users/authmethods" \	-H "Coder-Session-Token: $CODER_SESSION_TOKEN"
Example Response200
{  "github": {    "default_provider_configured": true,    "enabled": true  },  "oidc": {    "enabled": true,    "iconUrl": "string",    "signInText": "string"  },  "password": {    "enabled": true  },  "setup_token_required": true,  "terms_of_service_url": "string"}