---
title: "OAuth/OpenID userinfo endpoint"
method: GET
path: "/oauth/userinfo"
tags: ["OAuth"]
---

# OAuth/OpenID userinfo 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`)

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.

## Response `200`

Identity claims for the resource owner

- OauthUserinfo
  - `sub` string, required: Stringified user id of the resource owner.
  - `tenant_id` integer, required: Tenant the access token is scoped to.
  - `email` string, email, required: Email address of the resource owner.
  - `name` string, required: `firstName lastName`, trimmed. Empty string when both names are missing — never null.
  - `role` string, required: The user's tenant role at the moment the request was authenticated.
  - `scopes` string[], required: The scopes carried by the presented access token.

## Other responses

- `401`: Authentication missing, invalid, expired, or membership revoked

---

[API](https://skmtc.dev/buildworkpro/apis/buildworkpro-api.md) · [All operations](https://skmtc.dev/buildworkpro/apis/buildworkpro-api/llms.txt) · [OpenAPI document](https://skmtc.dev/buildworkpro/apis/buildworkpro-api/revisions/441cf40012f7?raw)
