curl --request PATCH \
--url http://localhost:3000/v2/users/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"firstName": "John",
"lastName": "Doe",
"email": "user@example.com",
"preferences": {
"libraryFavorites": [
{
"orgId": "<string>",
"document": "<string>",
"name": "<string>",
"retrievedAt": "2023-11-07T05:31:56Z"
}
],
"notifications": {
"monitoring_weekly_email": true,
"topics": {
"mentions": {
"in_app": true
},
"watchlists": {
"in_app": true
},
"opportunities": {
"in_app": true
}
}
}
},
"onboarding": {
"completedAt": "2023-11-07T05:31:56Z",
"role": "<string>"
}
}
'import requests
url = "http://localhost:3000/v2/users/{id}"
payload = {
"firstName": "John",
"lastName": "Doe",
"email": "user@example.com",
"preferences": {
"libraryFavorites": [
{
"orgId": "<string>",
"document": "<string>",
"name": "<string>",
"retrievedAt": "2023-11-07T05:31:56Z"
}
],
"notifications": {
"monitoring_weekly_email": True,
"topics": {
"mentions": { "in_app": True },
"watchlists": { "in_app": True },
"opportunities": { "in_app": True }
}
}
},
"onboarding": {
"completedAt": "2023-11-07T05:31:56Z",
"role": "<string>"
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
firstName: 'John',
lastName: 'Doe',
email: 'user@example.com',
preferences: {
libraryFavorites: [
{
orgId: '<string>',
document: '<string>',
name: '<string>',
retrievedAt: '2023-11-07T05:31:56Z'
}
],
notifications: {
monitoring_weekly_email: true,
topics: {
mentions: {in_app: true},
watchlists: {in_app: true},
opportunities: {in_app: true}
}
}
},
onboarding: {completedAt: '2023-11-07T05:31:56Z', role: '<string>'}
})
};
fetch('http://localhost:3000/v2/users/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "3000",
CURLOPT_URL => "http://localhost:3000/v2/users/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'firstName' => 'John',
'lastName' => 'Doe',
'email' => 'user@example.com',
'preferences' => [
'libraryFavorites' => [
[
'orgId' => '<string>',
'document' => '<string>',
'name' => '<string>',
'retrievedAt' => '2023-11-07T05:31:56Z'
]
],
'notifications' => [
'monitoring_weekly_email' => true,
'topics' => [
'mentions' => [
'in_app' => true
],
'watchlists' => [
'in_app' => true
],
'opportunities' => [
'in_app' => true
]
]
]
],
'onboarding' => [
'completedAt' => '2023-11-07T05:31:56Z',
'role' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "http://localhost:3000/v2/users/{id}"
payload := strings.NewReader("{\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"email\": \"user@example.com\",\n \"preferences\": {\n \"libraryFavorites\": [\n {\n \"orgId\": \"<string>\",\n \"document\": \"<string>\",\n \"name\": \"<string>\",\n \"retrievedAt\": \"2023-11-07T05:31:56Z\"\n }\n ],\n \"notifications\": {\n \"monitoring_weekly_email\": true,\n \"topics\": {\n \"mentions\": {\n \"in_app\": true\n },\n \"watchlists\": {\n \"in_app\": true\n },\n \"opportunities\": {\n \"in_app\": true\n }\n }\n }\n },\n \"onboarding\": {\n \"completedAt\": \"2023-11-07T05:31:56Z\",\n \"role\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("http://localhost:3000/v2/users/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"email\": \"user@example.com\",\n \"preferences\": {\n \"libraryFavorites\": [\n {\n \"orgId\": \"<string>\",\n \"document\": \"<string>\",\n \"name\": \"<string>\",\n \"retrievedAt\": \"2023-11-07T05:31:56Z\"\n }\n ],\n \"notifications\": {\n \"monitoring_weekly_email\": true,\n \"topics\": {\n \"mentions\": {\n \"in_app\": true\n },\n \"watchlists\": {\n \"in_app\": true\n },\n \"opportunities\": {\n \"in_app\": true\n }\n }\n }\n },\n \"onboarding\": {\n \"completedAt\": \"2023-11-07T05:31:56Z\",\n \"role\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:3000/v2/users/{id}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"email\": \"user@example.com\",\n \"preferences\": {\n \"libraryFavorites\": [\n {\n \"orgId\": \"<string>\",\n \"document\": \"<string>\",\n \"name\": \"<string>\",\n \"retrievedAt\": \"2023-11-07T05:31:56Z\"\n }\n ],\n \"notifications\": {\n \"monitoring_weekly_email\": true,\n \"topics\": {\n \"mentions\": {\n \"in_app\": true\n },\n \"watchlists\": {\n \"in_app\": true\n },\n \"opportunities\": {\n \"in_app\": true\n }\n }\n }\n },\n \"onboarding\": {\n \"completedAt\": \"2023-11-07T05:31:56Z\",\n \"role\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"object": "page",
"id": "p_abc123",
"createdAt": "2024-01-15T10:30:00.000Z",
"updatedAt": "2024-01-15T14:45:00.000Z",
"email": "user@example.com",
"firstName": "John",
"lastName": "Doe",
"name": "John Doe",
"picture": "https://lh3.googleusercontent.com/a/photo.jpg",
"membershipStatus": "active",
"last_login_at": "2025-11-21T19:00:00.000Z",
"last_activity_at": "2025-11-21T19:00:00.000Z",
"preferences": {
"currency_format": "kmb"
},
"onboarding": {
"completedAt": "2026-04-09T23:10:00.000Z"
},
"orgId": "o_abc123",
"createdBy": {
"object": "user",
"id": "u_abc123",
"apiKeyId": "bsk_abc123"
},
"updatedBy": {
"object": "user",
"id": "u_abc123",
"apiKeyId": "bsk_abc123"
},
"role": "admin"
}Update user
Updates user details. Role changes sync with Cognito groups.
curl --request PATCH \
--url http://localhost:3000/v2/users/{id} \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"firstName": "John",
"lastName": "Doe",
"email": "user@example.com",
"preferences": {
"libraryFavorites": [
{
"orgId": "<string>",
"document": "<string>",
"name": "<string>",
"retrievedAt": "2023-11-07T05:31:56Z"
}
],
"notifications": {
"monitoring_weekly_email": true,
"topics": {
"mentions": {
"in_app": true
},
"watchlists": {
"in_app": true
},
"opportunities": {
"in_app": true
}
}
}
},
"onboarding": {
"completedAt": "2023-11-07T05:31:56Z",
"role": "<string>"
}
}
'import requests
url = "http://localhost:3000/v2/users/{id}"
payload = {
"firstName": "John",
"lastName": "Doe",
"email": "user@example.com",
"preferences": {
"libraryFavorites": [
{
"orgId": "<string>",
"document": "<string>",
"name": "<string>",
"retrievedAt": "2023-11-07T05:31:56Z"
}
],
"notifications": {
"monitoring_weekly_email": True,
"topics": {
"mentions": { "in_app": True },
"watchlists": { "in_app": True },
"opportunities": { "in_app": True }
}
}
},
"onboarding": {
"completedAt": "2023-11-07T05:31:56Z",
"role": "<string>"
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.patch(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
firstName: 'John',
lastName: 'Doe',
email: 'user@example.com',
preferences: {
libraryFavorites: [
{
orgId: '<string>',
document: '<string>',
name: '<string>',
retrievedAt: '2023-11-07T05:31:56Z'
}
],
notifications: {
monitoring_weekly_email: true,
topics: {
mentions: {in_app: true},
watchlists: {in_app: true},
opportunities: {in_app: true}
}
}
},
onboarding: {completedAt: '2023-11-07T05:31:56Z', role: '<string>'}
})
};
fetch('http://localhost:3000/v2/users/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_PORT => "3000",
CURLOPT_URL => "http://localhost:3000/v2/users/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'firstName' => 'John',
'lastName' => 'Doe',
'email' => 'user@example.com',
'preferences' => [
'libraryFavorites' => [
[
'orgId' => '<string>',
'document' => '<string>',
'name' => '<string>',
'retrievedAt' => '2023-11-07T05:31:56Z'
]
],
'notifications' => [
'monitoring_weekly_email' => true,
'topics' => [
'mentions' => [
'in_app' => true
],
'watchlists' => [
'in_app' => true
],
'opportunities' => [
'in_app' => true
]
]
]
],
'onboarding' => [
'completedAt' => '2023-11-07T05:31:56Z',
'role' => '<string>'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "http://localhost:3000/v2/users/{id}"
payload := strings.NewReader("{\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"email\": \"user@example.com\",\n \"preferences\": {\n \"libraryFavorites\": [\n {\n \"orgId\": \"<string>\",\n \"document\": \"<string>\",\n \"name\": \"<string>\",\n \"retrievedAt\": \"2023-11-07T05:31:56Z\"\n }\n ],\n \"notifications\": {\n \"monitoring_weekly_email\": true,\n \"topics\": {\n \"mentions\": {\n \"in_app\": true\n },\n \"watchlists\": {\n \"in_app\": true\n },\n \"opportunities\": {\n \"in_app\": true\n }\n }\n }\n },\n \"onboarding\": {\n \"completedAt\": \"2023-11-07T05:31:56Z\",\n \"role\": \"<string>\"\n }\n}")
req, _ := http.NewRequest("PATCH", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.patch("http://localhost:3000/v2/users/{id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"email\": \"user@example.com\",\n \"preferences\": {\n \"libraryFavorites\": [\n {\n \"orgId\": \"<string>\",\n \"document\": \"<string>\",\n \"name\": \"<string>\",\n \"retrievedAt\": \"2023-11-07T05:31:56Z\"\n }\n ],\n \"notifications\": {\n \"monitoring_weekly_email\": true,\n \"topics\": {\n \"mentions\": {\n \"in_app\": true\n },\n \"watchlists\": {\n \"in_app\": true\n },\n \"opportunities\": {\n \"in_app\": true\n }\n }\n }\n },\n \"onboarding\": {\n \"completedAt\": \"2023-11-07T05:31:56Z\",\n \"role\": \"<string>\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("http://localhost:3000/v2/users/{id}")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"firstName\": \"John\",\n \"lastName\": \"Doe\",\n \"email\": \"user@example.com\",\n \"preferences\": {\n \"libraryFavorites\": [\n {\n \"orgId\": \"<string>\",\n \"document\": \"<string>\",\n \"name\": \"<string>\",\n \"retrievedAt\": \"2023-11-07T05:31:56Z\"\n }\n ],\n \"notifications\": {\n \"monitoring_weekly_email\": true,\n \"topics\": {\n \"mentions\": {\n \"in_app\": true\n },\n \"watchlists\": {\n \"in_app\": true\n },\n \"opportunities\": {\n \"in_app\": true\n }\n }\n }\n },\n \"onboarding\": {\n \"completedAt\": \"2023-11-07T05:31:56Z\",\n \"role\": \"<string>\"\n }\n}"
response = http.request(request)
puts response.read_body{
"object": "page",
"id": "p_abc123",
"createdAt": "2024-01-15T10:30:00.000Z",
"updatedAt": "2024-01-15T14:45:00.000Z",
"email": "user@example.com",
"firstName": "John",
"lastName": "Doe",
"name": "John Doe",
"picture": "https://lh3.googleusercontent.com/a/photo.jpg",
"membershipStatus": "active",
"last_login_at": "2025-11-21T19:00:00.000Z",
"last_activity_at": "2025-11-21T19:00:00.000Z",
"preferences": {
"currency_format": "kmb"
},
"onboarding": {
"completedAt": "2026-04-09T23:10:00.000Z"
},
"orgId": "o_abc123",
"createdBy": {
"object": "user",
"id": "u_abc123",
"apiKeyId": "bsk_abc123"
},
"updatedBy": {
"object": "user",
"id": "u_abc123",
"apiKeyId": "bsk_abc123"
},
"role": "admin"
}Authorizations
OAuth2 Authorization Code flow
Path Parameters
User ID
Body
User first name
"John"
User last name
"Doe"
User email address
"user@example.com"
User membership status in the organization
active, disabled User role in the organization
admin, editor, viewer, operator Show child attributes
Show child attributes
Show child attributes
Show child attributes
Response
User updated successfully
Object type
"page"
Unique identifier
"p_abc123"
Creation timestamp
"2024-01-15T10:30:00.000Z"
Last update timestamp
"2024-01-15T14:45:00.000Z"
User email address
"user@example.com"
User first name
"John"
User last name
"Doe"
User full name (virtual, concatenation of firstName + lastName)
"John Doe"
User profile picture URL
"https://lh3.googleusercontent.com/a/photo.jpg"
User membership status in the organization
active, waiting_approval, disabled "active"
Last login timestamp (null if user has not logged in yet)
"2025-11-21T19:00:00.000Z"
Last activity timestamp for this organization membership
"2025-11-21T19:00:00.000Z"
User preferences
{ "currency_format": "kmb" }
User onboarding state
{ "completedAt": "2026-04-09T23:10:00.000Z" }
Organization ID the user belongs to
"o_abc123"
Principal who created this object
Show child attributes
Show child attributes
{
"object": "user",
"id": "u_abc123",
"apiKeyId": "bsk_abc123"
}
Principal who last updated this object
Show child attributes
Show child attributes
{
"object": "user",
"id": "u_abc123",
"apiKeyId": "bsk_abc123"
}
User role in the organization
"admin"