Users
Search users
Search Alvys user accounts with paginated POST filters — name, email, role, subsidiary access, and enabled or disabled account status.
POST
/
api
/
p
/
v
{version}
/
users
/
search
Search users
curl --request POST \
--url https://integrations.alvys.com/api/p/v{version}/users/search \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json-patch+json' \
--data '
{
"Page": 123,
"PageSize": 123,
"Keyword": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json-patch+json'},
body: JSON.stringify({Page: 123, PageSize: 123, Keyword: '<string>'})
};
fetch('https://integrations.alvys.com/api/p/v{version}/users/search', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://integrations.alvys.com/api/p/v{version}/users/search"
payload = {
"Page": 123,
"PageSize": 123,
"Keyword": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json-patch+json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://integrations.alvys.com/api/p/v{version}/users/search",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'Page' => 123,
'PageSize' => 123,
'Keyword' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json-patch+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 := "https://integrations.alvys.com/api/p/v{version}/users/search"
payload := strings.NewReader("{\n \"Page\": 123,\n \"PageSize\": 123,\n \"Keyword\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json-patch+json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://integrations.alvys.com/api/p/v{version}/users/search")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json-patch+json")
.body("{\n \"Page\": 123,\n \"PageSize\": 123,\n \"Keyword\": \"<string>\"\n}")
.asString();{
"Page": 123,
"PageSize": 123,
"Total": 123,
"Items": [
{
"Id": "<string>",
"UserName": "<string>",
"Name": "<string>",
"UserType": "<string>",
"Role": "Admin",
"CompanyCode": "<string>",
"Status": "Active",
"Permissions": [
"<string>"
],
"Email": "<string>",
"Phone": "<string>",
"CreatedAt": "2023-11-07T05:31:56Z",
"ModifiedAt": "2023-11-07T05:31:56Z"
}
],
"Facets": {}
}{
"Errors": {},
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}The Search Users API endpoint allows users to search for specific user accounts within the Alvys system based on a keyword. This endpoint helps administrators efficiently find and manage user data by providing detailed information about users matching the search criteria.
Parameter Type Required Description
Page Number Yes The page number for pagination. PageSize Number Yes The number of results per page.
PageSize must be greater than 0. Keyword String No The keyword to search for in user data.

Request Parameters
The following parameter is required in the URL path:| Parameter | Type | Required | Description |
|---|---|---|---|
| version | String | Yes | The version of the API being requested. |
Request Body
The request body must include the following parameters:<Table>
PageSize must be greater than 0.
</Table>
Example CURL request
Use the Current API version number and make sure to replace the Authorization header value with your actual Bearer token for the request:curl --location 'https://integrations.alvys.com/api/p/v1/users/search' \
--header 'Authorization: Bearer eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ....' \
--header 'Content-Type: application/json' \
--data-raw '{
"Page": 0,
"PageSize": 100,
"Keyword": ""
}'
Response Parameters
The response contains a list of users matching the search criteria, each represented by the following parameters:| Parameter | Type | Description |
|---|---|---|
| Page | Number | The current page number. |
| PageSize | Number | The number of items per page. |
| Total | Number | The total number of matching items. |
| Items | Array | The list of users matching the search criteria. |
| Items.Id | String | The unique identifier of the user. |
| Items.UserName | String | The username of the user. |
| Items.Name | String | The full name of the user. |
| Items.Email | String | The email address of the user. |
| Items.UserType | String | The type of user (e.g., Internal, External). |
| Items.Role | String | The role assigned to the user (e.g., Admin, Dispatcher, Driver, Biller, SalesAgent, DataEntry, Safety, OperationManager). |
| Items.Phone | String | The phone number of the user. |
| Items.CompanyCode | String | The code of the company the user is associated with. |
| Items.Status | String | The current status of the user (e.g., Active, Disabled, Deleted). |
| Items.Permissions | Array of Strings | A list of permissions assigned to the user. |
| Items.CreatedAt | String (Date-Time) | The date and time when the user was created. |
| Items.ModifiedAt | String (Date-Time) | The date and time when the user’s details were last modified. |
Example Response
On the right side, you can see examples of different error codes by clicking “Example” and selecting the response code.
Rate Limits
All endpoints are subject to rate limits to protect the API from traffic spikes. For detailed information on rate limits, please refer to the Rate Limits section. This page is interactive, allowing you to try a request by completing the fields for the parameters below. As you fill out the parameters, the Curl command on the right side of the page will be automatically updated. Alternatively, you can directly edit the Curl command. Make sure to authorize yourself before trying a request.Authorizations
OAuth 2.0 client-credentials access token. Obtain one from https://auth.alvys.com/oauth/token (grant_type=client_credentials, audience=https://api.alvys.com/public/), then paste it here. The playground sends it as Authorization: Bearer <token>.
Path Parameters
API version (e.g., 1.0)
Example:
"1.0"
Body
application/json-patch+jsonapplication/jsontext/jsonapplication/*+json
⌘I
Search users
curl --request POST \
--url https://integrations.alvys.com/api/p/v{version}/users/search \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json-patch+json' \
--data '
{
"Page": 123,
"PageSize": 123,
"Keyword": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json-patch+json'},
body: JSON.stringify({Page: 123, PageSize: 123, Keyword: '<string>'})
};
fetch('https://integrations.alvys.com/api/p/v{version}/users/search', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "https://integrations.alvys.com/api/p/v{version}/users/search"
payload = {
"Page": 123,
"PageSize": 123,
"Keyword": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json-patch+json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://integrations.alvys.com/api/p/v{version}/users/search",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'Page' => 123,
'PageSize' => 123,
'Keyword' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json-patch+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 := "https://integrations.alvys.com/api/p/v{version}/users/search"
payload := strings.NewReader("{\n \"Page\": 123,\n \"PageSize\": 123,\n \"Keyword\": \"<string>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json-patch+json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://integrations.alvys.com/api/p/v{version}/users/search")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json-patch+json")
.body("{\n \"Page\": 123,\n \"PageSize\": 123,\n \"Keyword\": \"<string>\"\n}")
.asString();{
"Page": 123,
"PageSize": 123,
"Total": 123,
"Items": [
{
"Id": "<string>",
"UserName": "<string>",
"Name": "<string>",
"UserType": "<string>",
"Role": "Admin",
"CompanyCode": "<string>",
"Status": "Active",
"Permissions": [
"<string>"
],
"Email": "<string>",
"Phone": "<string>",
"CreatedAt": "2023-11-07T05:31:56Z",
"ModifiedAt": "2023-11-07T05:31:56Z"
}
],
"Facets": {}
}{
"Errors": {},
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}{
"Type": "<string>",
"Title": "<string>",
"Status": 123,
"Detail": "<string>",
"Instance": "<string>"
}