> For the complete documentation index, see [llms.txt](https://docs.abtasty.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.abtasty.com/server-side/remote-control-api/users.md).

# Users

Manage users

## Get users of the account environment

> Return the list of the user of the account environment

```json
{"openapi":"3.0.0","info":{"title":"Flagship - Remote Control API","version":"1.0"},"tags":[{"name":"Users","description":"Manage users"}],"servers":[{"url":"https://api.flagship.io/v1"}],"security":[{"token":[]}],"components":{"securitySchemes":{"token":{"type":"apiKey","description":"Prefix the token with 'Bearer ' to indicate it is a bearer token","name":"Authorization","in":"header"}},"parameters":{"account_id":{"name":"account_id","in":"path","description":"The ID of the account","required":true,"schema":{"type":"string"}},"account_environment_id":{"name":"account_environment_id","in":"path","description":"The ID of the environment","required":true,"schema":{"type":"string"}},"_page":{"name":"_page","in":"query","description":"Index of the page","schema":{"type":"integer"}},"_max_per_page":{"name":"_max_per_page","in":"query","description":"Number of items per page","schema":{"type":"integer"}}},"schemas":{"ItemCollection":{"properties":{"current_item_count":{"description":"Returns the number of items in the current page","type":"integer","format":"int"},"current_page":{"description":"Returns the number of the current page","type":"integer","format":"int","default":0},"total_count":{"description":"Returns the number of total items","type":"integer","format":"int"},"items_per_page":{"title":"Items per page","description":"Returns the number of items per page","type":"integer","format":"int","default":10},"last_page":{"title":"Last page","description":"Returns the index of the page","type":"integer","format":"int"}},"type":"object"},"UserList":{"required":["data"],"properties":{"data":{"description":"List of users","type":"array","items":{"$ref":"#/components/schemas/User"}}},"type":"object"},"User":{"required":["email","role"],"properties":{"email":{"description":"Email of the user","type":"string"},"role":{"description":"Role of the user","type":"string","enum":["ACCOUNT_OWNER","SUPER_ADMIN","PROJECT_MANAGER","MEMBER","GUEST"]}},"type":"object"}}},"paths":{"/accounts/{account_id}/account_environments/{account_environment_id}/users":{"get":{"tags":["Users"],"summary":"Get users of the account environment","description":"Return the list of the user of the account environment","operationId":"0aeb678fc30329a5b3f1c04d1d29520b","parameters":[{"$ref":"#/components/parameters/account_id"},{"$ref":"#/components/parameters/account_environment_id"},{"$ref":"#/components/parameters/_page"},{"$ref":"#/components/parameters/_max_per_page"}],"responses":{"200":{"description":"Success","content":{"application/json":{"schema":{"allOf":[{"$ref":"#/components/schemas/ItemCollection"},{"properties":{"items":{"type":"array","items":{"$ref":"#/components/schemas/UserList"}}},"type":"object"}]}}}},"404":{"description":"Not Found"}}}}}}
```

## Update the users of the account environment

> Update the users of the account environment. It will create automatically the users which does not exist.

```json
{"openapi":"3.0.0","info":{"title":"Flagship - Remote Control API","version":"1.0"},"tags":[{"name":"Users","description":"Manage users"}],"servers":[{"url":"https://api.flagship.io/v1"}],"security":[{"token":[]}],"components":{"securitySchemes":{"token":{"type":"apiKey","description":"Prefix the token with 'Bearer ' to indicate it is a bearer token","name":"Authorization","in":"header"}},"parameters":{"account_id":{"name":"account_id","in":"path","description":"The ID of the account","required":true,"schema":{"type":"string"}},"account_environment_id":{"name":"account_environment_id","in":"path","description":"The ID of the environment","required":true,"schema":{"type":"string"}}},"schemas":{"User":{"required":["email","role"],"properties":{"email":{"description":"Email of the user","type":"string"},"role":{"description":"Role of the user","type":"string","enum":["ACCOUNT_OWNER","SUPER_ADMIN","PROJECT_MANAGER","MEMBER","GUEST"]}},"type":"object"}}},"paths":{"/accounts/{account_id}/account_environments/{account_environment_id}/users":{"put":{"tags":["Users"],"summary":"Update the users of the account environment","description":"Update the users of the account environment. It will create automatically the users which does not exist.","operationId":"2dcfe3b154f38137fc43551187695136","parameters":[{"$ref":"#/components/parameters/account_id"},{"$ref":"#/components/parameters/account_environment_id"}],"requestBody":{"description":"Informations of the users","required":true,"content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/User"}}}}},"responses":{"204":{"description":"Updated"},"404":{"description":"Not Found"}}}}}}
```

## Delete the users of the account environment

> Delete the users of the account environment. You can delete multuple users in the same time.

```json
{"openapi":"3.0.0","info":{"title":"Flagship - Remote Control API","version":"1.0"},"tags":[{"name":"Users","description":"Manage users"}],"servers":[{"url":"https://api.flagship.io/v1"}],"security":[{"token":[]}],"components":{"securitySchemes":{"token":{"type":"apiKey","description":"Prefix the token with 'Bearer ' to indicate it is a bearer token","name":"Authorization","in":"header"}},"parameters":{"account_id":{"name":"account_id","in":"path","description":"The ID of the account","required":true,"schema":{"type":"string"}},"account_environment_id":{"name":"account_environment_id","in":"path","description":"The ID of the environment","required":true,"schema":{"type":"string"}}}},"paths":{"/accounts/{account_id}/account_environments/{account_environment_id}/users":{"delete":{"tags":["Users"],"summary":"Delete the users of the account environment","description":"Delete the users of the account environment. You can delete multuple users in the same time.","operationId":"6b288f6a9df1e400b1aaa4ada1cd4487","parameters":[{"$ref":"#/components/parameters/account_id"},{"$ref":"#/components/parameters/account_environment_id"},{"name":"email[]","in":"query","description":"Email of the user to delete","schema":{"type":"array","items":{"type":"string"}}}],"responses":{"204":{"description":"Deleted"},"404":{"description":"Not Found"}}}}}}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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, and the optional `goal` query parameter:

```
GET https://docs.abtasty.com/server-side/remote-control-api/users.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
