User Queries
The User API provides queries to retrieve user information.
Get User
Get a user by their SSO ID.
Query Structure
query GetUser($ssoId: String!) {
user(ssoId: $ssoId) {
bio
email
emailOnMention
image
isSsoUser
isAPIUser
name
ssoId
ssoType
}
}
Input Fields
| Field | Type | Description |
|---|---|---|
ssoId | String! | The SSO ID of the user to retrieve |
Return Type
| Field | Type | Description |
|---|---|---|
bio | String | User's biography |
email | String | User's email address |
emailOnMention | Boolean! | Whether the user receives email notifications when mentioned |
image | String | URL of the user's profile image |
isSsoUser | Boolean! | Whether the user is authenticated via SSO |
isAPIUser | Boolean! | Whether the user was created through the API |
name | String | User's name |
ssoId | String | User's SSO identifier |
ssoType | SSOTypes | Type of SSO authentication |
SSOTypes Enum
| Value | Description |
|---|---|
SSO | Generic SSO authentication |
SSO_SAML | SAML-based SSO authentication |
SSO_OIDC | OpenID Connect-based SSO authentication |
Get All Users
Get all users in the board.
Query Structure
query GetUsers {
users {
bio
email
emailOnMention
image
isSsoUser
isAPIUser
name
ssoId
ssoType
}
}
Return Type
Returns an array of User objects with the fields specified in the query.
Error Handling
The User API requires proper authentication and will return appropriate error messages if:
- The API key is invalid
- The SSO type header is missing
- The user does not exist
- The user does not have permission to access the data
Common error scenarios:
{
"errors": [
{
"message": "Invalid Api Key",
"extensions": {
"code": "UNAUTHENTICATED"
}
}
]
}
{
"errors": [
{
"message": "ssotype is required in headers",
"extensions": {
"code": "BAD_REQUEST"
}
}
]
}
{
"errors": [
{
"message": "User not found",
"extensions": {
"code": "NOT_FOUND"
}
}
]
}