User Management – Fetch Users
Fetch organization users with optional role filtering.
Authentication
Authorization: Bearer <YOUR_AUTH_TOKEN>
Endpoint
POSThttps://api.samvyo.com/api/user/fetchOrgUsers
Required Headers
Content-Type: application/json
Authorization: Bearer <YOUR_AUTH_TOKEN>
Request Body
{
"role": "moderator"
}
Example Requests
JavaScript (fetch)
const res = await fetch('https://api.samvyo.com/api/user/fetchOrgUsers', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
'Authorization': `Bearer ${authToken}`
},
body: JSON.stringify({ role: 'moderator' })
});
const data = await res.json();
cURL
curl -X POST \
'https://api.samvyo.com/api/user/fetchOrgUsers' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer <YOUR_AUTH_TOKEN>' \
-d '{"role":"moderator"}'
Success Response
{
"success": true,
"users": [
{
"id": "<USER_ID_1>",
"email": "user1@example.com",
"name": "John Doe",
"createdAt": "2025-08-06T02:16:24.398Z",
"location": "New York",
"username": "john_doe_123",
"role": "moderator",
"accountSuspended": false,
"profileId": "1234567890",
"meetNowEnabled": true,
"displayRating": false,
"tags": ["sales"],
"admin": true
},
{
"id": "<USER_ID_2>",
"email": "user2@example.com",
"name": "Jane Smith",
"createdAt": "2025-08-07T02:12:39.474Z",
"location": "San Francisco",
"username": "jane_smith_456",
"role": "moderator",
"accountSuspended": false,
"profileId": "0987654321",
"meetNowEnabled": true,
"displayRating": true,
"tags": ["customer success"],
"admin": false
}
]
}