/
/Nhost Authentication API
DocsSign in
Sign in
  • APIs
  • Generators
  • Stacks
  • Projects
  • Docs
  • History
  • Schema
Checked 1h ago · Updated 4w ago
authentication31
  • postSign in anonymously
  • postSign in with email and password
  • postSign in with an ID token
  • postVerify TOTP for MFA
  • postSign in with email OTP
  • postVerify email OTP
  • postSign in with magic link email
  • postSign in with SMS OTP
  • postVerify SMS OTP
  • postSign in with Personal Access Token (PAT)
  • getSign in with an OAuth2 provider
  • getOAuth2 provider callback endpoint
  • postOAuth2 provider callback endpoint (form_post)
  • getRetrieve OAuth2 provider tokens from callback
  • postSign in with Webauthn
  • postVerify Webauthn sign-in
  • postSign up with email and password
  • postSign up with Webauthn
  • postVerify Webauthn sign-up
  • postSign up with magic link email
  • postSign up with email OTP
  • postSign up with SMS OTP
  • postSign up with ID token
  • getSign up with OAuth provider
  • postRefresh OAuth2 provider tokens
  • postDeanonymize an anonymous user
  • getOAuth2 Authorization Endpoint
  • postOAuth2 Authorization Endpoint (POST)
  • postOAuth2 Token Endpoint
  • getGet authorization request details for consent screen
  • postComplete login/consent for an authorization request
security7
session6
system7
user8
verification1
    authentication

    OAuth2 Token Endpoint

    Exchange an authorization code for tokens, or refresh an existing token. Supports grant_type authorization_code and refresh_token.

    post/oauth2/token

    Response

    Token response

    access_tokenstring required
    token_typestring required
    expires_ininteger required
    refresh_tokenstring
    id_tokenstring
    scopestring

    Changes