# Get multiple accounts' information

## &#x20;Get multiple accounts' information

<mark style="color:blue;">`GET`</mark> `https://abc.hoola.vn/manage/api/users/get-multi-user`

&#x20;Maximum 100 accounts for every query.

#### Query Parameters

| Name  | Type    | Description                                                       |
| ----- | ------- | ----------------------------------------------------------------- |
| token | string  | Account Authentication Token                                      |
| start | integer | Ignore the number of accounts in query results (minimum 0)        |
| limit | integer | Limit the accounts to get information (minimum 1 and maximum 100) |

{% tabs %}
{% tab title="200 Get information successfully" %}

```javascript
// Response Code "00". Query successfully. 
// Return data:
{
    "respCode": "00",
    "users": [
        {
            "_id": "73chhLtPnxpPoekrx",
            "createdAt": "2021-05-27T08:38:15.067Z",
            "username": "vuvanhoang",
            "emails": [
                {
                    "address": "hoangvuvan@abc.com",
                    "verified": false
                }
            ],
            "profile": {
                "name": "Vu Van Hoang"
            },
            "myCourses": [
                {
                    "courseId": "wSZpqbtWowmpLC68L",
                    "activatedDate": "2021-05-29T06:19:24.107Z",
                    "expiredAt": "2121-05-05T06:19:24.107Z"
                }
            ],
            "myCart": [
                {
                    "courseId": "vivPteJNNC2P94Es8",
                    "status": "DELETED"
                }
            ],
            "myTransactions": [
                "nTv5XgDMNcMLBuRM5"
            ]
        },
        {
            "_id": "sWMDTaKwgdAqnLtYd",
            "createdAt": "2021-05-27T08:35:38.162Z",
            "username": "userAPI48",
            "emails": [
                {
                    "address": "userapi48@api.com",
                    "verified": true
                }
            ],
            "profile": {
                "name": "Tai khoan API 48",
                "affUserType": "L1",
                "tUid": ""
            },
            "myCourses": [],
            "myCart": [
                {
                    "courseId": "vivPteJNNC2P94Es8",
                    "status": "DELETED"
                }
            ]
        },
        {
            "_id": "jSYigdZhMMLY9yava",
            "createdAt": "2021-05-27T07:15:01.150Z",
            "username": "userAPI44",
            "emails": [
                {
                    "address": "userapi44@api.com",
                    "verified": false
                }
            ],
            "profile": {
                "name": "Tai khoan API 44"
            },
            "myCart": [
                {
                    "courseId": "wSZpqbtWowmpLC68L",
                    "status": "DELETED"
                }
            ]
        }
    ],
    "msg": "Success"
}
```

{% endtab %}

{% tab title="400 Query is missing request parameters or having malformed parameters" %}

```javascript
// Response Code "02". No token provided. 
// Return data:
{
    "respCode": "02",
    "users": null,
    "msg": "No token"
}


// Response Code "03". No start parameter. 
// Return data:
{
    "respCode": "03",
    "users": null,
    "msg": "No start parameter"
}


// Response Code "04". Invalid start parameter. 
// Return data:
{
    "respCode": "04",
    "users": null,
    "msg": "Invalid start parameter, start should be greater than or equal 0"
}


// Resposne Code "05". No limit parameter. 
// Return data:
{
    "respCode": "05",
    "users": null,
    "msg": "No limit parameter"
}


// Response Code "06". Invalid parameter. 
// Return data:
{
    "respCode": "06",
    "users": null,
    "msg": "Invalid limit parameter, limit should be greater than 0 and less than 100"
}
```

{% endtab %}

{% tab title="401 Fail to verify your account" %}

```javascript
// Response Code "08". Token is invalid or has expired. 
// Return data:
{
    "respCode": "08",
    "users": null,
    "msg": "Invalid token || Token has expired"
}
```

{% endtab %}

{% tab title="403 Your account is not authorized to execute this query" %}

```javascript
// Response Code "09". Your account is not authorized to execute this query. 
// Return data:
{
    "respCode": "09",
    "users": null,
    "msg": "Your account does not have permission"
}
```

{% endtab %}

{% tab title="405 Wrong request method" %}

```javascript
// Response Code "01". Wrong request method. 
// Return data:
{
    "respCode": "01",
    "users": null,
    "msg": "Request method should be GET"
}
```

{% endtab %}

{% tab title="500 Server error" %}

```javascript
// Response Code "07". Server not able to authenticate your account.
// Return data:
{
    "respCode": "07",
    "users": null,
    "msg": "Server not able to authenticate your account"
}
```

{% endtab %}
{% endtabs %}

<mark style="color:blue;">`GET`</mark> `https://abc.hoola.vn/manage/api/user/get-single-user/:id`

#### Path Parameters

| Name | Type   | Description |
| ---- | ------ | ----------- |
|      | string |             |

{% tabs %}
{% tab title="403 Your account is not authorized to execute this query" %}

```
Your account is not authorized to execute this query
```

{% endtab %}
{% endtabs %}

Example:

```javascript
// GET: 
https://abc.hoola.vn/manage/api/users/get-multi-user?token=kshfk295xkjvbk0929375knxcbvk9895792&start=0&limit=50
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.hoola.vn/english/api/get-multi-user.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
