GET /GetAllUsers

  • HTTP Status 200

    Function returns all active users

    • user_id Type: integer

      User ID


    • firstname Type: varchar

      User firstname


    • lastname Type: varchar

      User lastname


    • email Type: varchar

      User e-mail


    • rights Type: integer

      User rights


    • lang Type: varchar

      User selected language


    Query Response Example

    {
        "code": 200,
        "response": [
            {
                "user_id": 1,
                "firstname": "Elijah",
                "lastname": "Spencer",
                "email": "Spencer@crmango.com",
                "rights": 1,
                "lang": "sk"
            },
            {
                "user_id": 2,
                "firstname": "Erica",
                "lastname": "Dunn",
                "email": "Dunn@crmango.com",
                "rights": 1,
                "lang": "en"
            },
            {
                "user_id": 3,
                "firstname": "Emmett",
                "lastname": "Spencer",
                "email": "Spencer2@crmango.com",
                "rights": 1,
                "lang": "sk"
            },
            {
                "user_id": 4,
                "firstname": "Emmett",
                "lastname": "Dunn",
                "email": "Dunn2@crmango.com",
                "rights": 1,
                "lang": "cz"
            },
            {
                "user_id": 7,
                "firstname": "Ephemera",
                "lastname": "Bell",
                "email": "Bell@crmango.com",
                "rights": 1,
                "lang": "sk"
            },
            {
                "user_id": 8,
                "firstname": "Eric",
                "lastname": "Less",
                "email": "Less@crmango.com",
                "rights": 1,
                "lang": "sk"
            },
            {
                "user_id": 57,
                "firstname": "Elda",
                "lastname": "als",
                "email": "als@crmango.com",
                "rights": 1,
                "lang": "sk"
            }
        ]
    }

    Error Response Example

    {
        "code": "int",
        "message": "string"
    }
  • Parameters

    Parameters that need to be sent in the request

      Authorization

    • Bearer Type: varchar

      Auth token


    • Body data

      None

Example Request

Mac window icon
$curl = curl_init();

curl_setopt_array($curl, array(
CURLOPT_URL => 'https://rest.crmango.com/api/GetAllUsers',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => '',
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 0,
CURLOPT_FOLLOWLOCATION => true,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => 'GET',
CURLOPT_HTTPHEADER => array(
'Authorization: Bearer auth_token'
),
));

$response = curl_exec($curl);

curl_close($curl);

echo $response;
chat