OAuth

OAuth/OpenID userinfo endpoint

Returns identity information about the resource owner authenticated by the presented access token. Authentication is the standard Authorization: Bearer header — both API keys (bwp_live_/bwp_test_) and OAuth access tokens (bwp_at_) are accepted. No scope is required to call this endpoint.

get/oauth/userinfo

Request

  • Base URL: https://app.buildworkpro.com/api/v1
  • URL: https://app.buildworkpro.com/api/v1/oauth/userinfo
  • Auth: one of:
    • HTTP bearer
    • OAuth 2 (authorization code, authorization URL https://app.buildworkpro.com/api/v1/oauth/authorize, token URL https://app.buildworkpro.com/api/v1/oauth/token)

Response

Identity claims for the resource owner

substring required

Stringified user id of the resource owner.

tenant_idinteger required

Tenant the access token is scoped to.

emailstring email required

Email address of the resource owner.

namestring required

firstName lastName, trimmed. Empty string when both names are missing — never null.

rolestring required

The user's tenant role at the moment the request was authenticated.

scopesstring[] required

The scopes carried by the presented access token.

Example response

{
  "sub": "42",
  "tenant_id": 7,
  "email": "jane@example.com",
  "name": "Jane Doe",
  "role": "company_admin",
  "scopes": [
    "contacts:read",
    "leads:read"
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.