feat: add user update
Some checks are pending
Publish / Publish npm package action (push) Has started running
Some checks are pending
Publish / Publish npm package action (push) Has started running
This commit is contained in:
parent
d59357f6c9
commit
f54e1456b4
@ -48,6 +48,7 @@ yarn add @teacinema/contracts
|
|||||||
|---|---|---|---|
|
|---|---|---|---|
|
||||||
| `GetMe` | `GetMeRequest` | `GetMeResponse` | Получить профиль пользователя по ID |
|
| `GetMe` | `GetMeRequest` | `GetMeResponse` | Получить профиль пользователя по ID |
|
||||||
| `CreateUser` | `CreateUserRequest` | `CreateUserResponse` | Создать нового пользователя |
|
| `CreateUser` | `CreateUserRequest` | `CreateUserResponse` | Создать нового пользователя |
|
||||||
|
| `PatchUser` | `PatchUserRequest` | `PatchUserResponse` | Обновить данные пользователя (частичное обновление) |
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
|
|||||||
@ -5,6 +5,7 @@ package users.v1;
|
|||||||
service UsersService {
|
service UsersService {
|
||||||
rpc GetMe (GetMeRequest) returns (GetMeResponse);
|
rpc GetMe (GetMeRequest) returns (GetMeResponse);
|
||||||
rpc CreateUser (CreateUserRequest) returns (CreateUserResponse);
|
rpc CreateUser (CreateUserRequest) returns (CreateUserResponse);
|
||||||
|
rpc PatchUser (PatchUserRequest) returns (PatchUserResponse);
|
||||||
}
|
}
|
||||||
|
|
||||||
message GetMeRequest {
|
message GetMeRequest {
|
||||||
@ -30,3 +31,11 @@ message User {
|
|||||||
optional string email = 4;
|
optional string email = 4;
|
||||||
optional string avatar = 5;
|
optional string avatar = 5;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
message PatchUserRequest {
|
||||||
|
string user_id = 1;
|
||||||
|
optional string name = 2;
|
||||||
|
}
|
||||||
|
message PatchUserResponse {
|
||||||
|
bool ok = 1;
|
||||||
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user