> For the complete documentation index, see [llms.txt](https://dynamicpixels.gitbook.io/dynamicpixels-docs/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://dynamicpixels.gitbook.io/dynamicpixels-docs/more/trusted-server/users.md).

# Users

## GET /server/services/user/{userId}

> Finds a user by their unique identifier.

```json
{"openapi":"3.0.4","info":{"title":"DynamicPixels GameService V2","version":"v2"},"paths":{"/server/services/user/{userId}":{"get":{"tags":["User"],"summary":"Finds a user by their unique identifier.","operationId":"TrustedServer.GetUserById","parameters":[{"name":"userId","in":"path","required":true,"schema":{"type":"integer","format":"int32"}}],"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/UserDtoRowResponse"}},"application/json":{"schema":{"$ref":"#/components/schemas/UserDtoRowResponse"}},"text/json":{"schema":{"$ref":"#/components/schemas/UserDtoRowResponse"}}}}}}}},"components":{"schemas":{"UserDtoRowResponse":{"type":"object","properties":{"row":{"$ref":"#/components/schemas/UserDto"}},"additionalProperties":false},"UserDto":{"type":"object","properties":{"id":{"type":"integer","format":"int32"},"name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phoneNumber":{"type":"string","nullable":true},"image":{"type":"string","nullable":true},"username":{"type":"string","nullable":true},"steamId":{"type":"string","nullable":true},"steamAppId":{"type":"string","nullable":true},"label":{"type":"string","nullable":true},"tags":{"type":"string","nullable":true},"isBan":{"type":"boolean"},"isTester":{"type":"boolean"},"isGuest":{"type":"boolean"},"googleToken":{"type":"string","nullable":true},"fcmId":{"type":"string","nullable":true},"firstLogin":{"type":"string","format":"date-time","nullable":true},"lastLogin":{"type":"string","format":"date-time","nullable":true}},"additionalProperties":false}}}}
```

## PUT /server/services/user/{userId}

> Updates the details of a user by their unique identifier.

```json
{"openapi":"3.0.4","info":{"title":"DynamicPixels GameService V2","version":"v2"},"paths":{"/server/services/user/{userId}":{"put":{"tags":["User"],"summary":"Updates the details of a user by their unique identifier.","operationId":"TrustedServer.EditUserById","parameters":[{"name":"userId","in":"path","required":true,"schema":{"type":"integer","format":"int32"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EditUserParams"}},"text/json":{"schema":{"$ref":"#/components/schemas/EditUserParams"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/EditUserParams"}}}},"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/UserDtoRowsResponse"}},"application/json":{"schema":{"$ref":"#/components/schemas/UserDtoRowsResponse"}},"text/json":{"schema":{"$ref":"#/components/schemas/UserDtoRowsResponse"}}}}}}}},"components":{"schemas":{"EditUserParams":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/EditUserFields"}},"additionalProperties":false},"EditUserFields":{"type":"object","properties":{"name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phone_number":{"type":"string","nullable":true},"image":{"type":"string","nullable":true},"username":{"type":"string","nullable":true},"label":{"type":"string","nullable":true},"tags":{"type":"string","nullable":true}},"additionalProperties":false},"UserDtoRowsResponse":{"type":"object","properties":{"list":{"type":"array","items":{"$ref":"#/components/schemas/UserDto"},"nullable":true},"totalCount":{"type":"integer","format":"int32"}},"additionalProperties":false},"UserDto":{"type":"object","properties":{"id":{"type":"integer","format":"int32"},"name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phoneNumber":{"type":"string","nullable":true},"image":{"type":"string","nullable":true},"username":{"type":"string","nullable":true},"steamId":{"type":"string","nullable":true},"steamAppId":{"type":"string","nullable":true},"label":{"type":"string","nullable":true},"tags":{"type":"string","nullable":true},"isBan":{"type":"boolean"},"isTester":{"type":"boolean"},"isGuest":{"type":"boolean"},"googleToken":{"type":"string","nullable":true},"fcmId":{"type":"string","nullable":true},"firstLogin":{"type":"string","format":"date-time","nullable":true},"lastLogin":{"type":"string","format":"date-time","nullable":true}},"additionalProperties":false}}}}
```

## GET /server/services/user/steam/{steamId}

> Finds a user by their Steam unique identifier.

```json
{"openapi":"3.0.4","info":{"title":"DynamicPixels GameService V2","version":"v2"},"paths":{"/server/services/user/steam/{steamId}":{"get":{"tags":["User"],"summary":"Finds a user by their Steam unique identifier.","operationId":"TrustedServer.GetUserBySteamId","parameters":[{"name":"steamId","in":"path","required":true,"schema":{"type":"integer","format":"int32"}}],"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/UserDtoRowResponse"}},"application/json":{"schema":{"$ref":"#/components/schemas/UserDtoRowResponse"}},"text/json":{"schema":{"$ref":"#/components/schemas/UserDtoRowResponse"}}}}}}}},"components":{"schemas":{"UserDtoRowResponse":{"type":"object","properties":{"row":{"$ref":"#/components/schemas/UserDto"}},"additionalProperties":false},"UserDto":{"type":"object","properties":{"id":{"type":"integer","format":"int32"},"name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phoneNumber":{"type":"string","nullable":true},"image":{"type":"string","nullable":true},"username":{"type":"string","nullable":true},"steamId":{"type":"string","nullable":true},"steamAppId":{"type":"string","nullable":true},"label":{"type":"string","nullable":true},"tags":{"type":"string","nullable":true},"isBan":{"type":"boolean"},"isTester":{"type":"boolean"},"isGuest":{"type":"boolean"},"googleToken":{"type":"string","nullable":true},"fcmId":{"type":"string","nullable":true},"firstLogin":{"type":"string","format":"date-time","nullable":true},"lastLogin":{"type":"string","format":"date-time","nullable":true}},"additionalProperties":false}}}}
```

## POST /server/services/user/find

> Find users based on the provided parameters.

```json
{"openapi":"3.0.4","info":{"title":"DynamicPixels GameService V2","version":"v2"},"paths":{"/server/services/user/find":{"post":{"tags":["User"],"summary":"Find users based on the provided parameters.","operationId":"TrustedServer.Find","parameters":[{"name":"skip","in":"query","schema":{"type":"integer","format":"int32","default":0}},{"name":"limit","in":"query","schema":{"type":"integer","format":"int32","default":25}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FindUserParams"}},"text/json":{"schema":{"$ref":"#/components/schemas/FindUserParams"}},"application/*+json":{"schema":{"$ref":"#/components/schemas/FindUserParams"}}}},"responses":{"200":{"description":"OK","content":{"text/plain":{"schema":{"$ref":"#/components/schemas/UserDtoRowsResponse"}},"application/json":{"schema":{"$ref":"#/components/schemas/UserDtoRowsResponse"}},"text/json":{"schema":{"$ref":"#/components/schemas/UserDtoRowsResponse"}}}}}}}},"components":{"schemas":{"FindUserParams":{"type":"object","properties":{"query":{"type":"object","additionalProperties":{"type":"string"},"nullable":true}},"additionalProperties":false},"UserDtoRowsResponse":{"type":"object","properties":{"list":{"type":"array","items":{"$ref":"#/components/schemas/UserDto"},"nullable":true},"totalCount":{"type":"integer","format":"int32"}},"additionalProperties":false},"UserDto":{"type":"object","properties":{"id":{"type":"integer","format":"int32"},"name":{"type":"string","nullable":true},"email":{"type":"string","nullable":true},"phoneNumber":{"type":"string","nullable":true},"image":{"type":"string","nullable":true},"username":{"type":"string","nullable":true},"steamId":{"type":"string","nullable":true},"steamAppId":{"type":"string","nullable":true},"label":{"type":"string","nullable":true},"tags":{"type":"string","nullable":true},"isBan":{"type":"boolean"},"isTester":{"type":"boolean"},"isGuest":{"type":"boolean"},"googleToken":{"type":"string","nullable":true},"fcmId":{"type":"string","nullable":true},"firstLogin":{"type":"string","format":"date-time","nullable":true},"lastLogin":{"type":"string","format":"date-time","nullable":true}},"additionalProperties":false}}}}
```
