From 12f89444f216683e83a58a1124eeabd430b8efd7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sat, 20 Jul 2024 16:09:07 +0900 Subject: [PATCH 01/13] Add ChangePassword, DeleteAccount APIs for admin --- api/docs/yorkie/v1/admin.openapi.yaml | 652 ++++++++------ api/docs/yorkie/v1/resources.openapi.yaml | 409 +++++---- api/docs/yorkie/v1/yorkie.openapi.yaml | 453 +++++----- api/yorkie/v1/admin.pb.go | 970 +++++++++++++-------- api/yorkie/v1/admin.proto | 19 + api/yorkie/v1/v1connect/admin.connect.go | 54 ++ server/backend/database/database.go | 6 + server/backend/database/memory/database.go | 44 + server/backend/database/mongo/client.go | 29 + server/rpc/admin_server.go | 51 ++ server/rpc/interceptors/admin.go | 4 +- server/users/users.go | 32 + 12 files changed, 1671 insertions(+), 1052 deletions(-) diff --git a/api/docs/yorkie/v1/admin.openapi.yaml b/api/docs/yorkie/v1/admin.openapi.yaml index 5b41c9ae1..409277c81 100644 --- a/api/docs/yorkie/v1/admin.openapi.yaml +++ b/api/docs/yorkie/v1/admin.openapi.yaml @@ -1,442 +1,501 @@ openapi: 3.1.0 info: - description: - Yorkie is an open source document store for building collaborative + description: Yorkie is an open source document store for building collaborative editing applications. title: Yorkie version: v0.4.28 servers: - - description: Production server - url: https://api.yorkie.dev - - description: Local server - url: http://localhost:8080 +- description: Production server + url: https://api.yorkie.dev +- description: Local server + url: http://localhost:8080 paths: + /yorkie.v1.AdminService/ChangePassword: + post: + description: "" + requestBody: + $ref: '#/components/requestBodies/yorkie.v1.AdminService.ChangePassword.yorkie.v1.ChangePasswordRequest' + responses: + "200": + $ref: '#/components/responses/yorkie.v1.AdminService.ChangePassword.yorkie.v1.ChangePasswordResponse' + default: + $ref: '#/components/responses/connect.error' + tags: + - yorkie.v1.AdminService /yorkie.v1.AdminService/CreateProject: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.CreateProject.yorkie.v1.CreateProjectRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.CreateProject.yorkie.v1.CreateProjectRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.CreateProject.yorkie.v1.CreateProjectResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.CreateProject.yorkie.v1.CreateProjectResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService + /yorkie.v1.AdminService/DeleteAccount: + post: + description: "" + requestBody: + $ref: '#/components/requestBodies/yorkie.v1.AdminService.DeleteAccount.yorkie.v1.DeleteAccountRequest' + responses: + "200": + $ref: '#/components/responses/yorkie.v1.AdminService.DeleteAccount.yorkie.v1.DeleteAccountResponse' + default: + $ref: '#/components/responses/connect.error' + tags: + - yorkie.v1.AdminService /yorkie.v1.AdminService/GetDocument: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.GetDocument.yorkie.v1.GetDocumentRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.GetDocument.yorkie.v1.GetDocumentRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.GetDocument.yorkie.v1.GetDocumentResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.GetDocument.yorkie.v1.GetDocumentResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/GetDocuments: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.GetDocuments.yorkie.v1.GetDocumentsRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.GetDocuments.yorkie.v1.GetDocumentsRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.GetDocuments.yorkie.v1.GetDocumentsResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.GetDocuments.yorkie.v1.GetDocumentsResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/GetProject: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.GetProject.yorkie.v1.GetProjectRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.GetProject.yorkie.v1.GetProjectRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.GetProject.yorkie.v1.GetProjectResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.GetProject.yorkie.v1.GetProjectResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/GetSnapshotMeta: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.GetSnapshotMeta.yorkie.v1.GetSnapshotMetaRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.GetSnapshotMeta.yorkie.v1.GetSnapshotMetaRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.GetSnapshotMeta.yorkie.v1.GetSnapshotMetaResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.GetSnapshotMeta.yorkie.v1.GetSnapshotMetaResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/ListChanges: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.ListChanges.yorkie.v1.ListChangesRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.ListChanges.yorkie.v1.ListChangesRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.ListChanges.yorkie.v1.ListChangesResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.ListChanges.yorkie.v1.ListChangesResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/ListDocuments: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.ListDocuments.yorkie.v1.ListDocumentsRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.ListDocuments.yorkie.v1.ListDocumentsRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.ListDocuments.yorkie.v1.ListDocumentsResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.ListDocuments.yorkie.v1.ListDocumentsResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/ListProjects: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.ListProjects.yorkie.v1.ListProjectsRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.ListProjects.yorkie.v1.ListProjectsRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.ListProjects.yorkie.v1.ListProjectsResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.ListProjects.yorkie.v1.ListProjectsResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/LogIn: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.LogIn.yorkie.v1.LogInRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.LogIn.yorkie.v1.LogInRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.LogIn.yorkie.v1.LogInResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.LogIn.yorkie.v1.LogInResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/RemoveDocumentByAdmin: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.RemoveDocumentByAdmin.yorkie.v1.RemoveDocumentByAdminRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.RemoveDocumentByAdmin.yorkie.v1.RemoveDocumentByAdminRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.RemoveDocumentByAdmin.yorkie.v1.RemoveDocumentByAdminResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.RemoveDocumentByAdmin.yorkie.v1.RemoveDocumentByAdminResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/SearchDocuments: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.SearchDocuments.yorkie.v1.SearchDocumentsRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.SearchDocuments.yorkie.v1.SearchDocumentsRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.SearchDocuments.yorkie.v1.SearchDocumentsResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.SearchDocuments.yorkie.v1.SearchDocumentsResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/SignUp: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.SignUp.yorkie.v1.SignUpRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.SignUp.yorkie.v1.SignUpRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.SignUp.yorkie.v1.SignUpResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.SignUp.yorkie.v1.SignUpResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService /yorkie.v1.AdminService/UpdateProject: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.AdminService.UpdateProject.yorkie.v1.UpdateProjectRequest" + $ref: '#/components/requestBodies/yorkie.v1.AdminService.UpdateProject.yorkie.v1.UpdateProjectRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.AdminService.UpdateProject.yorkie.v1.UpdateProjectResponse" + $ref: '#/components/responses/yorkie.v1.AdminService.UpdateProject.yorkie.v1.UpdateProjectResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.AdminService + - yorkie.v1.AdminService components: requestBodies: + yorkie.v1.AdminService.ChangePassword.yorkie.v1.ChangePasswordRequest: + content: + application/json: + schema: + $ref: '#/components/schemas/yorkie.v1.ChangePasswordRequest' + application/proto: + schema: + $ref: '#/components/schemas/yorkie.v1.ChangePasswordRequest' + required: true yorkie.v1.AdminService.CreateProject.yorkie.v1.CreateProjectRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.CreateProjectRequest" + $ref: '#/components/schemas/yorkie.v1.CreateProjectRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.CreateProjectRequest" + $ref: '#/components/schemas/yorkie.v1.CreateProjectRequest' + required: true + yorkie.v1.AdminService.DeleteAccount.yorkie.v1.DeleteAccountRequest: + content: + application/json: + schema: + $ref: '#/components/schemas/yorkie.v1.DeleteAccountRequest' + application/proto: + schema: + $ref: '#/components/schemas/yorkie.v1.DeleteAccountRequest' required: true yorkie.v1.AdminService.GetDocument.yorkie.v1.GetDocumentRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.GetDocumentRequest" + $ref: '#/components/schemas/yorkie.v1.GetDocumentRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.GetDocumentRequest" + $ref: '#/components/schemas/yorkie.v1.GetDocumentRequest' required: true yorkie.v1.AdminService.GetDocuments.yorkie.v1.GetDocumentsRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.GetDocumentsRequest" + $ref: '#/components/schemas/yorkie.v1.GetDocumentsRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.GetDocumentsRequest" + $ref: '#/components/schemas/yorkie.v1.GetDocumentsRequest' required: true yorkie.v1.AdminService.GetProject.yorkie.v1.GetProjectRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.GetProjectRequest" + $ref: '#/components/schemas/yorkie.v1.GetProjectRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.GetProjectRequest" + $ref: '#/components/schemas/yorkie.v1.GetProjectRequest' required: true yorkie.v1.AdminService.GetSnapshotMeta.yorkie.v1.GetSnapshotMetaRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.GetSnapshotMetaRequest" + $ref: '#/components/schemas/yorkie.v1.GetSnapshotMetaRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.GetSnapshotMetaRequest" + $ref: '#/components/schemas/yorkie.v1.GetSnapshotMetaRequest' required: true yorkie.v1.AdminService.ListChanges.yorkie.v1.ListChangesRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.ListChangesRequest" + $ref: '#/components/schemas/yorkie.v1.ListChangesRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.ListChangesRequest" + $ref: '#/components/schemas/yorkie.v1.ListChangesRequest' required: true yorkie.v1.AdminService.ListDocuments.yorkie.v1.ListDocumentsRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.ListDocumentsRequest" + $ref: '#/components/schemas/yorkie.v1.ListDocumentsRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.ListDocumentsRequest" + $ref: '#/components/schemas/yorkie.v1.ListDocumentsRequest' required: true yorkie.v1.AdminService.ListProjects.yorkie.v1.ListProjectsRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.ListProjectsRequest" + $ref: '#/components/schemas/yorkie.v1.ListProjectsRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.ListProjectsRequest" + $ref: '#/components/schemas/yorkie.v1.ListProjectsRequest' required: true yorkie.v1.AdminService.LogIn.yorkie.v1.LogInRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.LogInRequest" + $ref: '#/components/schemas/yorkie.v1.LogInRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.LogInRequest" + $ref: '#/components/schemas/yorkie.v1.LogInRequest' required: true yorkie.v1.AdminService.RemoveDocumentByAdmin.yorkie.v1.RemoveDocumentByAdminRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.RemoveDocumentByAdminRequest" + $ref: '#/components/schemas/yorkie.v1.RemoveDocumentByAdminRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.RemoveDocumentByAdminRequest" + $ref: '#/components/schemas/yorkie.v1.RemoveDocumentByAdminRequest' required: true yorkie.v1.AdminService.SearchDocuments.yorkie.v1.SearchDocumentsRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.SearchDocumentsRequest" + $ref: '#/components/schemas/yorkie.v1.SearchDocumentsRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.SearchDocumentsRequest" + $ref: '#/components/schemas/yorkie.v1.SearchDocumentsRequest' required: true yorkie.v1.AdminService.SignUp.yorkie.v1.SignUpRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.SignUpRequest" + $ref: '#/components/schemas/yorkie.v1.SignUpRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.SignUpRequest" + $ref: '#/components/schemas/yorkie.v1.SignUpRequest' required: true yorkie.v1.AdminService.UpdateProject.yorkie.v1.UpdateProjectRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.UpdateProjectRequest" + $ref: '#/components/schemas/yorkie.v1.UpdateProjectRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.UpdateProjectRequest" + $ref: '#/components/schemas/yorkie.v1.UpdateProjectRequest' required: true responses: connect.error: content: application/json: schema: - $ref: "#/components/schemas/connect.error" + $ref: '#/components/schemas/connect.error' + application/proto: + schema: + $ref: '#/components/schemas/connect.error' + description: "" + yorkie.v1.AdminService.ChangePassword.yorkie.v1.ChangePasswordResponse: + content: + application/json: + schema: + $ref: '#/components/schemas/yorkie.v1.ChangePasswordResponse' application/proto: schema: - $ref: "#/components/schemas/connect.error" + $ref: '#/components/schemas/yorkie.v1.ChangePasswordResponse' description: "" yorkie.v1.AdminService.CreateProject.yorkie.v1.CreateProjectResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.CreateProjectResponse" + $ref: '#/components/schemas/yorkie.v1.CreateProjectResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.CreateProjectResponse" + $ref: '#/components/schemas/yorkie.v1.CreateProjectResponse' + description: "" + yorkie.v1.AdminService.DeleteAccount.yorkie.v1.DeleteAccountResponse: + content: + application/json: + schema: + $ref: '#/components/schemas/yorkie.v1.DeleteAccountResponse' + application/proto: + schema: + $ref: '#/components/schemas/yorkie.v1.DeleteAccountResponse' description: "" yorkie.v1.AdminService.GetDocument.yorkie.v1.GetDocumentResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.GetDocumentResponse" + $ref: '#/components/schemas/yorkie.v1.GetDocumentResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.GetDocumentResponse" + $ref: '#/components/schemas/yorkie.v1.GetDocumentResponse' description: "" yorkie.v1.AdminService.GetDocuments.yorkie.v1.GetDocumentsResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.GetDocumentsResponse" + $ref: '#/components/schemas/yorkie.v1.GetDocumentsResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.GetDocumentsResponse" + $ref: '#/components/schemas/yorkie.v1.GetDocumentsResponse' description: "" yorkie.v1.AdminService.GetProject.yorkie.v1.GetProjectResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.GetProjectResponse" + $ref: '#/components/schemas/yorkie.v1.GetProjectResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.GetProjectResponse" + $ref: '#/components/schemas/yorkie.v1.GetProjectResponse' description: "" yorkie.v1.AdminService.GetSnapshotMeta.yorkie.v1.GetSnapshotMetaResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.GetSnapshotMetaResponse" + $ref: '#/components/schemas/yorkie.v1.GetSnapshotMetaResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.GetSnapshotMetaResponse" + $ref: '#/components/schemas/yorkie.v1.GetSnapshotMetaResponse' description: "" yorkie.v1.AdminService.ListChanges.yorkie.v1.ListChangesResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.ListChangesResponse" + $ref: '#/components/schemas/yorkie.v1.ListChangesResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.ListChangesResponse" + $ref: '#/components/schemas/yorkie.v1.ListChangesResponse' description: "" yorkie.v1.AdminService.ListDocuments.yorkie.v1.ListDocumentsResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.ListDocumentsResponse" + $ref: '#/components/schemas/yorkie.v1.ListDocumentsResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.ListDocumentsResponse" + $ref: '#/components/schemas/yorkie.v1.ListDocumentsResponse' description: "" yorkie.v1.AdminService.ListProjects.yorkie.v1.ListProjectsResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.ListProjectsResponse" + $ref: '#/components/schemas/yorkie.v1.ListProjectsResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.ListProjectsResponse" + $ref: '#/components/schemas/yorkie.v1.ListProjectsResponse' description: "" yorkie.v1.AdminService.LogIn.yorkie.v1.LogInResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.LogInResponse" + $ref: '#/components/schemas/yorkie.v1.LogInResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.LogInResponse" + $ref: '#/components/schemas/yorkie.v1.LogInResponse' description: "" yorkie.v1.AdminService.RemoveDocumentByAdmin.yorkie.v1.RemoveDocumentByAdminResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.RemoveDocumentByAdminResponse" + $ref: '#/components/schemas/yorkie.v1.RemoveDocumentByAdminResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.RemoveDocumentByAdminResponse" + $ref: '#/components/schemas/yorkie.v1.RemoveDocumentByAdminResponse' description: "" yorkie.v1.AdminService.SearchDocuments.yorkie.v1.SearchDocumentsResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.SearchDocumentsResponse" + $ref: '#/components/schemas/yorkie.v1.SearchDocumentsResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.SearchDocumentsResponse" + $ref: '#/components/schemas/yorkie.v1.SearchDocumentsResponse' description: "" yorkie.v1.AdminService.SignUp.yorkie.v1.SignUpResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.SignUpResponse" + $ref: '#/components/schemas/yorkie.v1.SignUpResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.SignUpResponse" + $ref: '#/components/schemas/yorkie.v1.SignUpResponse' description: "" yorkie.v1.AdminService.UpdateProject.yorkie.v1.UpdateProjectResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.UpdateProjectResponse" + $ref: '#/components/schemas/yorkie.v1.UpdateProjectResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.UpdateProjectResponse" + $ref: '#/components/schemas/yorkie.v1.UpdateProjectResponse' description: "" schemas: connect.error: additionalProperties: false - description: "Error type returned by Connect: https://connectrpc.com/docs/go/errors/#http-representation" + description: 'Error type returned by Connect: https://connectrpc.com/docs/go/errors/#http-representation' properties: code: enum: - - CodeCanceled - - CodeUnknown - - CodeInvalidArgument - - CodeDeadlineExceeded - - CodeNotFound - - CodeAlreadyExists - - CodePermissionDenied - - CodeResourceExhausted - - CodeFailedPrecondition - - CodeAborted - - CodeOutOfRange - - CodeInternal - - CodeUnavailable - - CodeDataLoss - - CodeUnauthenticated + - CodeCanceled + - CodeUnknown + - CodeInvalidArgument + - CodeDeadlineExceeded + - CodeNotFound + - CodeAlreadyExists + - CodePermissionDenied + - CodeResourceExhausted + - CodeFailedPrecondition + - CodeAborted + - CodeOutOfRange + - CodeInternal + - CodeUnavailable + - CodeDataLoss + - CodeUnauthenticated examples: - - CodeNotFound + - CodeNotFound type: string message: type: string @@ -555,7 +614,7 @@ components: description: "" properties: id: - $ref: "#/components/schemas/yorkie.v1.ChangeID" + $ref: '#/components/schemas/yorkie.v1.ChangeID' additionalProperties: false description: "" title: id @@ -569,12 +628,12 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.Operation" + $ref: '#/components/schemas/yorkie.v1.Operation' type: object title: operations type: array presenceChange: - $ref: "#/components/schemas/yorkie.v1.PresenceChange" + $ref: '#/components/schemas/yorkie.v1.PresenceChange' additionalProperties: false description: "" title: presence_change @@ -600,18 +659,44 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: lamport serverSeq: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: server_seq title: ChangeID type: object + yorkie.v1.ChangePasswordRequest: + additionalProperties: false + description: "" + properties: + currentPassword: + additionalProperties: false + description: "" + title: current_password + type: string + newPassword: + additionalProperties: false + description: "" + title: new_password + type: string + username: + additionalProperties: false + description: "" + title: username + type: string + title: ChangePasswordRequest + type: object + yorkie.v1.ChangePasswordResponse: + additionalProperties: false + description: "" + title: ChangePasswordResponse + type: object yorkie.v1.CreateProjectRequest: additionalProperties: false description: "" @@ -628,25 +713,46 @@ components: description: "" properties: project: - $ref: "#/components/schemas/yorkie.v1.Project" + $ref: '#/components/schemas/yorkie.v1.Project' additionalProperties: false description: "" title: project type: object title: CreateProjectResponse type: object + yorkie.v1.DeleteAccountRequest: + additionalProperties: false + description: "" + properties: + password: + additionalProperties: false + description: "" + title: password + type: string + username: + additionalProperties: false + description: "" + title: username + type: string + title: DeleteAccountRequest + type: object + yorkie.v1.DeleteAccountResponse: + additionalProperties: false + description: "" + title: DeleteAccountResponse + type: object yorkie.v1.DocumentSummary: additionalProperties: false description: "" properties: accessedAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: accessed_at type: object createdAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: created_at @@ -667,7 +773,7 @@ components: title: snapshot type: string updatedAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: updated_at @@ -695,7 +801,7 @@ components: description: "" properties: document: - $ref: "#/components/schemas/yorkie.v1.DocumentSummary" + $ref: '#/components/schemas/yorkie.v1.DocumentSummary' additionalProperties: false description: "" title: document @@ -733,7 +839,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.DocumentSummary" + $ref: '#/components/schemas/yorkie.v1.DocumentSummary' type: object title: documents type: array @@ -755,7 +861,7 @@ components: description: "" properties: project: - $ref: "#/components/schemas/yorkie.v1.Project" + $ref: '#/components/schemas/yorkie.v1.Project' additionalProperties: false description: "" title: project @@ -780,8 +886,8 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: server_seq title: GetSnapshotMetaRequest type: object @@ -793,8 +899,8 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: lamport snapshot: additionalProperties: false @@ -809,25 +915,25 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object movedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: moved_at type: object removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at type: object type: - $ref: "#/components/schemas/yorkie.v1.ValueType" + $ref: '#/components/schemas/yorkie.v1.ValueType' additionalProperties: false description: "" title: type @@ -862,8 +968,8 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: previous_seq projectName: additionalProperties: false @@ -880,7 +986,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.Change" + $ref: '#/components/schemas/yorkie.v1.Change' type: object title: changes type: array @@ -925,7 +1031,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.DocumentSummary" + $ref: '#/components/schemas/yorkie.v1.DocumentSummary' type: object title: documents type: array @@ -944,7 +1050,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.Project" + $ref: '#/components/schemas/yorkie.v1.Project' type: object title: projects type: array @@ -987,7 +1093,7 @@ components: title: is_removed type: boolean updatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: updated_at @@ -1004,61 +1110,61 @@ components: description: "" properties: add: - $ref: "#/components/schemas/yorkie.v1.Operation.Add" + $ref: '#/components/schemas/yorkie.v1.Operation.Add' additionalProperties: false description: "" title: add type: object edit: - $ref: "#/components/schemas/yorkie.v1.Operation.Edit" + $ref: '#/components/schemas/yorkie.v1.Operation.Edit' additionalProperties: false description: "" title: edit type: object increase: - $ref: "#/components/schemas/yorkie.v1.Operation.Increase" + $ref: '#/components/schemas/yorkie.v1.Operation.Increase' additionalProperties: false description: "" title: increase type: object move: - $ref: "#/components/schemas/yorkie.v1.Operation.Move" + $ref: '#/components/schemas/yorkie.v1.Operation.Move' additionalProperties: false description: "" title: move type: object remove: - $ref: "#/components/schemas/yorkie.v1.Operation.Remove" + $ref: '#/components/schemas/yorkie.v1.Operation.Remove' additionalProperties: false description: "" title: remove type: object select: - $ref: "#/components/schemas/yorkie.v1.Operation.Select" + $ref: '#/components/schemas/yorkie.v1.Operation.Select' additionalProperties: false description: "" title: select type: object set: - $ref: "#/components/schemas/yorkie.v1.Operation.Set" + $ref: '#/components/schemas/yorkie.v1.Operation.Set' additionalProperties: false description: "" title: set type: object style: - $ref: "#/components/schemas/yorkie.v1.Operation.Style" + $ref: '#/components/schemas/yorkie.v1.Operation.Style' additionalProperties: false description: "" title: style type: object treeEdit: - $ref: "#/components/schemas/yorkie.v1.Operation.TreeEdit" + $ref: '#/components/schemas/yorkie.v1.Operation.TreeEdit' additionalProperties: false description: "" title: tree_edit type: object treeStyle: - $ref: "#/components/schemas/yorkie.v1.Operation.TreeStyle" + $ref: '#/components/schemas/yorkie.v1.Operation.TreeStyle' additionalProperties: false description: "" title: tree_style @@ -1070,25 +1176,25 @@ components: description: "" properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object prevCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: prev_created_at type: object value: - $ref: "#/components/schemas/yorkie.v1.JSONElementSimple" + $ref: '#/components/schemas/yorkie.v1.JSONElementSimple' additionalProperties: false description: "" title: value @@ -1115,25 +1221,25 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: to @@ -1166,7 +1272,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -1178,19 +1284,19 @@ components: description: "" properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object value: - $ref: "#/components/schemas/yorkie.v1.JSONElementSimple" + $ref: '#/components/schemas/yorkie.v1.JSONElementSimple' additionalProperties: false description: "" title: value @@ -1202,25 +1308,25 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object prevCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: prev_created_at @@ -1232,19 +1338,19 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at @@ -1260,25 +1366,25 @@ components: compatibility purposes. properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: to @@ -1290,7 +1396,7 @@ components: description: "" properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at @@ -1301,13 +1407,13 @@ components: title: key type: string parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object value: - $ref: "#/components/schemas/yorkie.v1.JSONElementSimple" + $ref: '#/components/schemas/yorkie.v1.JSONElementSimple' additionalProperties: false description: "" title: value @@ -1329,25 +1435,25 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: to @@ -1380,7 +1486,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -1395,7 +1501,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.TreeNodes" + $ref: '#/components/schemas/yorkie.v1.TreeNodes' type: object title: contents type: array @@ -1405,19 +1511,19 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at @@ -1428,7 +1534,7 @@ components: title: split_level type: integer to: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: to @@ -1445,7 +1551,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -1474,25 +1580,25 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: to @@ -1525,7 +1631,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -1564,13 +1670,13 @@ components: description: "" properties: presence: - $ref: "#/components/schemas/yorkie.v1.Presence" + $ref: '#/components/schemas/yorkie.v1.Presence' additionalProperties: false description: "" title: presence type: object type: - $ref: "#/components/schemas/yorkie.v1.PresenceChange.ChangeType" + $ref: '#/components/schemas/yorkie.v1.PresenceChange.ChangeType' additionalProperties: false description: "" title: type @@ -1579,14 +1685,14 @@ components: yorkie.v1.PresenceChange.ChangeType: description: "" enum: - - - CHANGE_TYPE_UNSPECIFIED - - 0 - - CHANGE_TYPE_PUT - - 1 - - CHANGE_TYPE_DELETE - - 2 - - CHANGE_TYPE_CLEAR - - 3 + - - CHANGE_TYPE_UNSPECIFIED + - 0 + - CHANGE_TYPE_PUT + - 1 + - CHANGE_TYPE_DELETE + - 2 + - CHANGE_TYPE_CLEAR + - 3 title: ChangeType type: string yorkie.v1.Project: @@ -1611,7 +1717,7 @@ components: title: client_deactivate_threshold type: string createdAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: created_at @@ -1637,7 +1743,7 @@ components: title: secret_key type: string updatedAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: updated_at @@ -1699,7 +1805,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.DocumentSummary" + $ref: '#/components/schemas/yorkie.v1.DocumentSummary' type: object title: documents type: array @@ -1731,7 +1837,7 @@ components: description: "" properties: user: - $ref: "#/components/schemas/yorkie.v1.User" + $ref: '#/components/schemas/yorkie.v1.User' additionalProperties: false description: "" title: user @@ -1743,7 +1849,7 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at @@ -1779,8 +1885,8 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: lamport title: TimeTicket type: object @@ -1799,25 +1905,25 @@ components: title: depth type: integer id: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: id type: object insNextId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: ins_next_id type: object insPrevId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: ins_prev_id type: object removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at @@ -1844,7 +1950,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.NodeAttr" + $ref: '#/components/schemas/yorkie.v1.NodeAttr' additionalProperties: false description: "" title: value @@ -1856,7 +1962,7 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at @@ -1876,7 +1982,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.TreeNode" + $ref: '#/components/schemas/yorkie.v1.TreeNode' type: object title: content type: array @@ -1887,13 +1993,13 @@ components: description: "" properties: leftSiblingId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: left_sibling_id type: object parentId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: parent_id @@ -1905,25 +2011,25 @@ components: description: "" properties: authWebhookMethods: - $ref: "#/components/schemas/yorkie.v1.UpdatableProjectFields.AuthWebhookMethods" + $ref: '#/components/schemas/yorkie.v1.UpdatableProjectFields.AuthWebhookMethods' additionalProperties: false description: "" title: auth_webhook_methods type: object authWebhookUrl: - $ref: "#/components/schemas/google.protobuf.StringValue" + $ref: '#/components/schemas/google.protobuf.StringValue' additionalProperties: false description: "" title: auth_webhook_url type: object clientDeactivateThreshold: - $ref: "#/components/schemas/google.protobuf.StringValue" + $ref: '#/components/schemas/google.protobuf.StringValue' additionalProperties: false description: "" title: client_deactivate_threshold type: object name: - $ref: "#/components/schemas/google.protobuf.StringValue" + $ref: '#/components/schemas/google.protobuf.StringValue' additionalProperties: false description: "" title: name @@ -1948,7 +2054,7 @@ components: description: "" properties: fields: - $ref: "#/components/schemas/yorkie.v1.UpdatableProjectFields" + $ref: '#/components/schemas/yorkie.v1.UpdatableProjectFields' additionalProperties: false description: "" title: fields @@ -1965,7 +2071,7 @@ components: description: "" properties: project: - $ref: "#/components/schemas/yorkie.v1.Project" + $ref: '#/components/schemas/yorkie.v1.Project' additionalProperties: false description: "" title: project @@ -1977,7 +2083,7 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: created_at @@ -1997,34 +2103,34 @@ components: yorkie.v1.ValueType: description: "" enum: - - - VALUE_TYPE_NULL - - 0 - - VALUE_TYPE_BOOLEAN - - 1 - - VALUE_TYPE_INTEGER - - 2 - - VALUE_TYPE_LONG - - 3 - - VALUE_TYPE_DOUBLE - - 4 - - VALUE_TYPE_STRING - - 5 - - VALUE_TYPE_BYTES - - 6 - - VALUE_TYPE_DATE - - 7 - - VALUE_TYPE_JSON_OBJECT - - 8 - - VALUE_TYPE_JSON_ARRAY - - 9 - - VALUE_TYPE_TEXT - - 10 - - VALUE_TYPE_INTEGER_CNT - - 11 - - VALUE_TYPE_LONG_CNT - - 12 - - VALUE_TYPE_TREE - - 13 + - - VALUE_TYPE_NULL + - 0 + - VALUE_TYPE_BOOLEAN + - 1 + - VALUE_TYPE_INTEGER + - 2 + - VALUE_TYPE_LONG + - 3 + - VALUE_TYPE_DOUBLE + - 4 + - VALUE_TYPE_STRING + - 5 + - VALUE_TYPE_BYTES + - 6 + - VALUE_TYPE_DATE + - 7 + - VALUE_TYPE_JSON_OBJECT + - 8 + - VALUE_TYPE_JSON_ARRAY + - 9 + - VALUE_TYPE_TEXT + - 10 + - VALUE_TYPE_INTEGER_CNT + - 11 + - VALUE_TYPE_LONG_CNT + - 12 + - VALUE_TYPE_TREE + - 13 title: ValueType type: string securitySchemes: @@ -2033,7 +2139,7 @@ components: name: Authorization type: apiKey security: - - ApiKeyAuth: [] +- ApiKeyAuth: [] tags: - - description: Admin is a service that provides a API for Admin. - name: yorkie.v1.AdminService +- description: Admin is a service that provides a API for Admin. + name: yorkie.v1.AdminService diff --git a/api/docs/yorkie/v1/resources.openapi.yaml b/api/docs/yorkie/v1/resources.openapi.yaml index 1671ee2c1..b8c892b66 100644 --- a/api/docs/yorkie/v1/resources.openapi.yaml +++ b/api/docs/yorkie/v1/resources.openapi.yaml @@ -1,15 +1,14 @@ openapi: 3.1.0 info: - description: - Yorkie is an open source document store for building collaborative + description: Yorkie is an open source document store for building collaborative editing applications. title: Yorkie version: v0.4.28 servers: - - description: Production server - url: https://api.yorkie.dev - - description: Local server - url: http://localhost:8080 +- description: Production server + url: https://api.yorkie.dev +- description: Local server + url: http://localhost:8080 paths: {} components: responses: @@ -17,35 +16,35 @@ components: content: application/json: schema: - $ref: "#/components/schemas/connect.error" + $ref: '#/components/schemas/connect.error' application/proto: schema: - $ref: "#/components/schemas/connect.error" + $ref: '#/components/schemas/connect.error' description: "" schemas: connect.error: additionalProperties: false - description: "Error type returned by Connect: https://connectrpc.com/docs/go/errors/#http-representation" + description: 'Error type returned by Connect: https://connectrpc.com/docs/go/errors/#http-representation' properties: code: enum: - - CodeCanceled - - CodeUnknown - - CodeInvalidArgument - - CodeDeadlineExceeded - - CodeNotFound - - CodeAlreadyExists - - CodePermissionDenied - - CodeResourceExhausted - - CodeFailedPrecondition - - CodeAborted - - CodeOutOfRange - - CodeInternal - - CodeUnavailable - - CodeDataLoss - - CodeUnauthenticated + - CodeCanceled + - CodeUnknown + - CodeInvalidArgument + - CodeDeadlineExceeded + - CodeNotFound + - CodeAlreadyExists + - CodePermissionDenied + - CodeResourceExhausted + - CodeFailedPrecondition + - CodeAborted + - CodeOutOfRange + - CodeInternal + - CodeUnavailable + - CodeDataLoss + - CodeUnauthenticated examples: - - CodeNotFound + - CodeNotFound type: string message: type: string @@ -164,7 +163,7 @@ components: description: "" properties: id: - $ref: "#/components/schemas/yorkie.v1.ChangeID" + $ref: '#/components/schemas/yorkie.v1.ChangeID' additionalProperties: false description: "" title: id @@ -178,12 +177,12 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.Operation" + $ref: '#/components/schemas/yorkie.v1.Operation' type: object title: operations type: array presenceChange: - $ref: "#/components/schemas/yorkie.v1.PresenceChange" + $ref: '#/components/schemas/yorkie.v1.PresenceChange' additionalProperties: false description: "" title: presence_change @@ -209,15 +208,15 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: lamport serverSeq: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: server_seq title: ChangeID type: object @@ -231,12 +230,12 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.Change" + $ref: '#/components/schemas/yorkie.v1.Change' type: object title: changes type: array checkpoint: - $ref: "#/components/schemas/yorkie.v1.Checkpoint" + $ref: '#/components/schemas/yorkie.v1.Checkpoint' additionalProperties: false description: "" title: checkpoint @@ -252,7 +251,7 @@ components: title: is_removed type: boolean minSyncedTicket: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: min_synced_ticket @@ -278,8 +277,8 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: server_seq title: Checkpoint type: object @@ -288,7 +287,7 @@ components: description: "" properties: body: - $ref: "#/components/schemas/yorkie.v1.DocEventBody" + $ref: '#/components/schemas/yorkie.v1.DocEventBody' additionalProperties: false description: "" title: body @@ -299,7 +298,7 @@ components: title: publisher type: string type: - $ref: "#/components/schemas/yorkie.v1.DocEventType" + $ref: '#/components/schemas/yorkie.v1.DocEventType' additionalProperties: false description: "" title: type @@ -325,14 +324,14 @@ components: yorkie.v1.DocEventType: description: "" enum: - - - DOC_EVENT_TYPE_DOCUMENT_CHANGED - - 0 - - DOC_EVENT_TYPE_DOCUMENT_WATCHED - - 1 - - DOC_EVENT_TYPE_DOCUMENT_UNWATCHED - - 2 - - DOC_EVENT_TYPE_DOCUMENT_BROADCAST - - 3 + - - DOC_EVENT_TYPE_DOCUMENT_CHANGED + - 0 + - DOC_EVENT_TYPE_DOCUMENT_WATCHED + - 1 + - DOC_EVENT_TYPE_DOCUMENT_UNWATCHED + - 2 + - DOC_EVENT_TYPE_DOCUMENT_BROADCAST + - 3 title: DocEventType type: string yorkie.v1.DocumentSummary: @@ -340,13 +339,13 @@ components: description: "" properties: accessedAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: accessed_at type: object createdAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: created_at @@ -367,7 +366,7 @@ components: title: snapshot type: string updatedAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: updated_at @@ -379,37 +378,37 @@ components: description: "" properties: counter: - $ref: "#/components/schemas/yorkie.v1.JSONElement.Counter" + $ref: '#/components/schemas/yorkie.v1.JSONElement.Counter' additionalProperties: false description: "" title: counter type: object jsonArray: - $ref: "#/components/schemas/yorkie.v1.JSONElement.JSONArray" + $ref: '#/components/schemas/yorkie.v1.JSONElement.JSONArray' additionalProperties: false description: "" title: json_array type: object jsonObject: - $ref: "#/components/schemas/yorkie.v1.JSONElement.JSONObject" + $ref: '#/components/schemas/yorkie.v1.JSONElement.JSONObject' additionalProperties: false description: "" title: json_object type: object primitive: - $ref: "#/components/schemas/yorkie.v1.JSONElement.Primitive" + $ref: '#/components/schemas/yorkie.v1.JSONElement.Primitive' additionalProperties: false description: "" title: primitive type: object text: - $ref: "#/components/schemas/yorkie.v1.JSONElement.Text" + $ref: '#/components/schemas/yorkie.v1.JSONElement.Text' additionalProperties: false description: "" title: text type: object tree: - $ref: "#/components/schemas/yorkie.v1.JSONElement.Tree" + $ref: '#/components/schemas/yorkie.v1.JSONElement.Tree' additionalProperties: false description: "" title: tree @@ -421,25 +420,25 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object movedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: moved_at type: object removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at type: object type: - $ref: "#/components/schemas/yorkie.v1.ValueType" + $ref: '#/components/schemas/yorkie.v1.ValueType' additionalProperties: false description: "" title: type @@ -456,13 +455,13 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object movedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: moved_at @@ -471,12 +470,12 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.RGANode" + $ref: '#/components/schemas/yorkie.v1.RGANode' type: object title: nodes type: array removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at @@ -488,13 +487,13 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object movedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: moved_at @@ -503,12 +502,12 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.RHTNode" + $ref: '#/components/schemas/yorkie.v1.RHTNode' type: object title: nodes type: array removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at @@ -520,25 +519,25 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object movedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: moved_at type: object removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at type: object type: - $ref: "#/components/schemas/yorkie.v1.ValueType" + $ref: '#/components/schemas/yorkie.v1.ValueType' additionalProperties: false description: "" title: type @@ -555,13 +554,13 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object movedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: moved_at @@ -570,12 +569,12 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.TextNode" + $ref: '#/components/schemas/yorkie.v1.TextNode' type: object title: nodes type: array removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at @@ -587,13 +586,13 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object movedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: moved_at @@ -602,12 +601,12 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.TreeNode" + $ref: '#/components/schemas/yorkie.v1.TreeNode' type: object title: nodes type: array removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at @@ -619,25 +618,25 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object movedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: moved_at type: object removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at type: object type: - $ref: "#/components/schemas/yorkie.v1.ValueType" + $ref: '#/components/schemas/yorkie.v1.ValueType' additionalProperties: false description: "" title: type @@ -659,7 +658,7 @@ components: title: is_removed type: boolean updatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: updated_at @@ -676,61 +675,61 @@ components: description: "" properties: add: - $ref: "#/components/schemas/yorkie.v1.Operation.Add" + $ref: '#/components/schemas/yorkie.v1.Operation.Add' additionalProperties: false description: "" title: add type: object edit: - $ref: "#/components/schemas/yorkie.v1.Operation.Edit" + $ref: '#/components/schemas/yorkie.v1.Operation.Edit' additionalProperties: false description: "" title: edit type: object increase: - $ref: "#/components/schemas/yorkie.v1.Operation.Increase" + $ref: '#/components/schemas/yorkie.v1.Operation.Increase' additionalProperties: false description: "" title: increase type: object move: - $ref: "#/components/schemas/yorkie.v1.Operation.Move" + $ref: '#/components/schemas/yorkie.v1.Operation.Move' additionalProperties: false description: "" title: move type: object remove: - $ref: "#/components/schemas/yorkie.v1.Operation.Remove" + $ref: '#/components/schemas/yorkie.v1.Operation.Remove' additionalProperties: false description: "" title: remove type: object select: - $ref: "#/components/schemas/yorkie.v1.Operation.Select" + $ref: '#/components/schemas/yorkie.v1.Operation.Select' additionalProperties: false description: "" title: select type: object set: - $ref: "#/components/schemas/yorkie.v1.Operation.Set" + $ref: '#/components/schemas/yorkie.v1.Operation.Set' additionalProperties: false description: "" title: set type: object style: - $ref: "#/components/schemas/yorkie.v1.Operation.Style" + $ref: '#/components/schemas/yorkie.v1.Operation.Style' additionalProperties: false description: "" title: style type: object treeEdit: - $ref: "#/components/schemas/yorkie.v1.Operation.TreeEdit" + $ref: '#/components/schemas/yorkie.v1.Operation.TreeEdit' additionalProperties: false description: "" title: tree_edit type: object treeStyle: - $ref: "#/components/schemas/yorkie.v1.Operation.TreeStyle" + $ref: '#/components/schemas/yorkie.v1.Operation.TreeStyle' additionalProperties: false description: "" title: tree_style @@ -742,25 +741,25 @@ components: description: "" properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object prevCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: prev_created_at type: object value: - $ref: "#/components/schemas/yorkie.v1.JSONElementSimple" + $ref: '#/components/schemas/yorkie.v1.JSONElementSimple' additionalProperties: false description: "" title: value @@ -787,25 +786,25 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: to @@ -838,7 +837,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -850,19 +849,19 @@ components: description: "" properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object value: - $ref: "#/components/schemas/yorkie.v1.JSONElementSimple" + $ref: '#/components/schemas/yorkie.v1.JSONElementSimple' additionalProperties: false description: "" title: value @@ -874,25 +873,25 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object prevCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: prev_created_at @@ -904,19 +903,19 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at @@ -932,25 +931,25 @@ components: compatibility purposes. properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: to @@ -962,7 +961,7 @@ components: description: "" properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at @@ -973,13 +972,13 @@ components: title: key type: string parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object value: - $ref: "#/components/schemas/yorkie.v1.JSONElementSimple" + $ref: '#/components/schemas/yorkie.v1.JSONElementSimple' additionalProperties: false description: "" title: value @@ -1001,25 +1000,25 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: to @@ -1052,7 +1051,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -1067,7 +1066,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.TreeNodes" + $ref: '#/components/schemas/yorkie.v1.TreeNodes' type: object title: contents type: array @@ -1077,19 +1076,19 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at @@ -1100,7 +1099,7 @@ components: title: split_level type: integer to: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: to @@ -1117,7 +1116,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -1146,25 +1145,25 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: to @@ -1197,7 +1196,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -1236,13 +1235,13 @@ components: description: "" properties: presence: - $ref: "#/components/schemas/yorkie.v1.Presence" + $ref: '#/components/schemas/yorkie.v1.Presence' additionalProperties: false description: "" title: presence type: object type: - $ref: "#/components/schemas/yorkie.v1.PresenceChange.ChangeType" + $ref: '#/components/schemas/yorkie.v1.PresenceChange.ChangeType' additionalProperties: false description: "" title: type @@ -1251,14 +1250,14 @@ components: yorkie.v1.PresenceChange.ChangeType: description: "" enum: - - - CHANGE_TYPE_UNSPECIFIED - - 0 - - CHANGE_TYPE_PUT - - 1 - - CHANGE_TYPE_DELETE - - 2 - - CHANGE_TYPE_CLEAR - - 3 + - - CHANGE_TYPE_UNSPECIFIED + - 0 + - CHANGE_TYPE_PUT + - 1 + - CHANGE_TYPE_DELETE + - 2 + - CHANGE_TYPE_CLEAR + - 3 title: ChangeType type: string yorkie.v1.Project: @@ -1283,7 +1282,7 @@ components: title: client_deactivate_threshold type: string createdAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: created_at @@ -1309,7 +1308,7 @@ components: title: secret_key type: string updatedAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: updated_at @@ -1321,13 +1320,13 @@ components: description: "" properties: element: - $ref: "#/components/schemas/yorkie.v1.JSONElement" + $ref: '#/components/schemas/yorkie.v1.JSONElement' additionalProperties: false description: "" title: element type: object next: - $ref: "#/components/schemas/yorkie.v1.RGANode" + $ref: '#/components/schemas/yorkie.v1.RGANode' additionalProperties: false description: "" title: next @@ -1339,7 +1338,7 @@ components: description: "" properties: element: - $ref: "#/components/schemas/yorkie.v1.JSONElement" + $ref: '#/components/schemas/yorkie.v1.JSONElement' additionalProperties: false description: "" title: element @@ -1364,7 +1363,7 @@ components: title: presences type: object root: - $ref: "#/components/schemas/yorkie.v1.JSONElement" + $ref: '#/components/schemas/yorkie.v1.JSONElement' additionalProperties: false description: "" title: root @@ -1381,7 +1380,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.Presence" + $ref: '#/components/schemas/yorkie.v1.Presence' additionalProperties: false description: "" title: value @@ -1398,19 +1397,19 @@ components: title: attributes type: object id: - $ref: "#/components/schemas/yorkie.v1.TextNodeID" + $ref: '#/components/schemas/yorkie.v1.TextNodeID' additionalProperties: false description: "" title: id type: object insPrevId: - $ref: "#/components/schemas/yorkie.v1.TextNodeID" + $ref: '#/components/schemas/yorkie.v1.TextNodeID' additionalProperties: false description: "" title: ins_prev_id type: object removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at @@ -1432,7 +1431,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.NodeAttr" + $ref: '#/components/schemas/yorkie.v1.NodeAttr' additionalProperties: false description: "" title: value @@ -1444,7 +1443,7 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at @@ -1461,7 +1460,7 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at @@ -1497,8 +1496,8 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: lamport title: TimeTicket type: object @@ -1517,25 +1516,25 @@ components: title: depth type: integer id: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: id type: object insNextId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: ins_next_id type: object insPrevId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: ins_prev_id type: object removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at @@ -1562,7 +1561,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.NodeAttr" + $ref: '#/components/schemas/yorkie.v1.NodeAttr' additionalProperties: false description: "" title: value @@ -1574,7 +1573,7 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at @@ -1594,7 +1593,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.TreeNode" + $ref: '#/components/schemas/yorkie.v1.TreeNode' type: object title: content type: array @@ -1605,13 +1604,13 @@ components: description: "" properties: leftSiblingId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: left_sibling_id type: object parentId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: parent_id @@ -1623,25 +1622,25 @@ components: description: "" properties: authWebhookMethods: - $ref: "#/components/schemas/yorkie.v1.UpdatableProjectFields.AuthWebhookMethods" + $ref: '#/components/schemas/yorkie.v1.UpdatableProjectFields.AuthWebhookMethods' additionalProperties: false description: "" title: auth_webhook_methods type: object authWebhookUrl: - $ref: "#/components/schemas/google.protobuf.StringValue" + $ref: '#/components/schemas/google.protobuf.StringValue' additionalProperties: false description: "" title: auth_webhook_url type: object clientDeactivateThreshold: - $ref: "#/components/schemas/google.protobuf.StringValue" + $ref: '#/components/schemas/google.protobuf.StringValue' additionalProperties: false description: "" title: client_deactivate_threshold type: object name: - $ref: "#/components/schemas/google.protobuf.StringValue" + $ref: '#/components/schemas/google.protobuf.StringValue' additionalProperties: false description: "" title: name @@ -1666,7 +1665,7 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/google.protobuf.Timestamp" + $ref: '#/components/schemas/google.protobuf.Timestamp' additionalProperties: false description: "" title: created_at @@ -1686,34 +1685,34 @@ components: yorkie.v1.ValueType: description: "" enum: - - - VALUE_TYPE_NULL - - 0 - - VALUE_TYPE_BOOLEAN - - 1 - - VALUE_TYPE_INTEGER - - 2 - - VALUE_TYPE_LONG - - 3 - - VALUE_TYPE_DOUBLE - - 4 - - VALUE_TYPE_STRING - - 5 - - VALUE_TYPE_BYTES - - 6 - - VALUE_TYPE_DATE - - 7 - - VALUE_TYPE_JSON_OBJECT - - 8 - - VALUE_TYPE_JSON_ARRAY - - 9 - - VALUE_TYPE_TEXT - - 10 - - VALUE_TYPE_INTEGER_CNT - - 11 - - VALUE_TYPE_LONG_CNT - - 12 - - VALUE_TYPE_TREE - - 13 + - - VALUE_TYPE_NULL + - 0 + - VALUE_TYPE_BOOLEAN + - 1 + - VALUE_TYPE_INTEGER + - 2 + - VALUE_TYPE_LONG + - 3 + - VALUE_TYPE_DOUBLE + - 4 + - VALUE_TYPE_STRING + - 5 + - VALUE_TYPE_BYTES + - 6 + - VALUE_TYPE_DATE + - 7 + - VALUE_TYPE_JSON_OBJECT + - 8 + - VALUE_TYPE_JSON_ARRAY + - 9 + - VALUE_TYPE_TEXT + - 10 + - VALUE_TYPE_INTEGER_CNT + - 11 + - VALUE_TYPE_LONG_CNT + - 12 + - VALUE_TYPE_TREE + - 13 title: ValueType type: string securitySchemes: @@ -1722,4 +1721,4 @@ components: name: Authorization type: apiKey security: - - ApiKeyAuth: [] +- ApiKeyAuth: [] diff --git a/api/docs/yorkie/v1/yorkie.openapi.yaml b/api/docs/yorkie/v1/yorkie.openapi.yaml index aed705196..1c8a7cd1c 100644 --- a/api/docs/yorkie/v1/yorkie.openapi.yaml +++ b/api/docs/yorkie/v1/yorkie.openapi.yaml @@ -1,176 +1,175 @@ openapi: 3.1.0 info: - description: - Yorkie is an open source document store for building collaborative + description: Yorkie is an open source document store for building collaborative editing applications. title: Yorkie version: v0.4.28 servers: - - description: Production server - url: https://api.yorkie.dev - - description: Local server - url: http://localhost:8080 +- description: Production server + url: https://api.yorkie.dev +- description: Local server + url: http://localhost:8080 paths: /yorkie.v1.YorkieService/ActivateClient: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.YorkieService.ActivateClient.yorkie.v1.ActivateClientRequest" + $ref: '#/components/requestBodies/yorkie.v1.YorkieService.ActivateClient.yorkie.v1.ActivateClientRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.YorkieService.ActivateClient.yorkie.v1.ActivateClientResponse" + $ref: '#/components/responses/yorkie.v1.YorkieService.ActivateClient.yorkie.v1.ActivateClientResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.YorkieService + - yorkie.v1.YorkieService /yorkie.v1.YorkieService/AttachDocument: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.YorkieService.AttachDocument.yorkie.v1.AttachDocumentRequest" + $ref: '#/components/requestBodies/yorkie.v1.YorkieService.AttachDocument.yorkie.v1.AttachDocumentRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.YorkieService.AttachDocument.yorkie.v1.AttachDocumentResponse" + $ref: '#/components/responses/yorkie.v1.YorkieService.AttachDocument.yorkie.v1.AttachDocumentResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.YorkieService + - yorkie.v1.YorkieService /yorkie.v1.YorkieService/Broadcast: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.YorkieService.Broadcast.yorkie.v1.BroadcastRequest" + $ref: '#/components/requestBodies/yorkie.v1.YorkieService.Broadcast.yorkie.v1.BroadcastRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.YorkieService.Broadcast.yorkie.v1.BroadcastResponse" + $ref: '#/components/responses/yorkie.v1.YorkieService.Broadcast.yorkie.v1.BroadcastResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.YorkieService + - yorkie.v1.YorkieService /yorkie.v1.YorkieService/DeactivateClient: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.YorkieService.DeactivateClient.yorkie.v1.DeactivateClientRequest" + $ref: '#/components/requestBodies/yorkie.v1.YorkieService.DeactivateClient.yorkie.v1.DeactivateClientRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.YorkieService.DeactivateClient.yorkie.v1.DeactivateClientResponse" + $ref: '#/components/responses/yorkie.v1.YorkieService.DeactivateClient.yorkie.v1.DeactivateClientResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.YorkieService + - yorkie.v1.YorkieService /yorkie.v1.YorkieService/DetachDocument: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.YorkieService.DetachDocument.yorkie.v1.DetachDocumentRequest" + $ref: '#/components/requestBodies/yorkie.v1.YorkieService.DetachDocument.yorkie.v1.DetachDocumentRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.YorkieService.DetachDocument.yorkie.v1.DetachDocumentResponse" + $ref: '#/components/responses/yorkie.v1.YorkieService.DetachDocument.yorkie.v1.DetachDocumentResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.YorkieService + - yorkie.v1.YorkieService /yorkie.v1.YorkieService/PushPullChanges: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.YorkieService.PushPullChanges.yorkie.v1.PushPullChangesRequest" + $ref: '#/components/requestBodies/yorkie.v1.YorkieService.PushPullChanges.yorkie.v1.PushPullChangesRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.YorkieService.PushPullChanges.yorkie.v1.PushPullChangesResponse" + $ref: '#/components/responses/yorkie.v1.YorkieService.PushPullChanges.yorkie.v1.PushPullChangesResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.YorkieService + - yorkie.v1.YorkieService /yorkie.v1.YorkieService/RemoveDocument: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.YorkieService.RemoveDocument.yorkie.v1.RemoveDocumentRequest" + $ref: '#/components/requestBodies/yorkie.v1.YorkieService.RemoveDocument.yorkie.v1.RemoveDocumentRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.YorkieService.RemoveDocument.yorkie.v1.RemoveDocumentResponse" + $ref: '#/components/responses/yorkie.v1.YorkieService.RemoveDocument.yorkie.v1.RemoveDocumentResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.YorkieService + - yorkie.v1.YorkieService /yorkie.v1.YorkieService/WatchDocument: post: description: "" requestBody: - $ref: "#/components/requestBodies/yorkie.v1.YorkieService.WatchDocument.yorkie.v1.WatchDocumentRequest" + $ref: '#/components/requestBodies/yorkie.v1.YorkieService.WatchDocument.yorkie.v1.WatchDocumentRequest' responses: "200": - $ref: "#/components/responses/yorkie.v1.YorkieService.WatchDocument.yorkie.v1.WatchDocumentResponse" + $ref: '#/components/responses/yorkie.v1.YorkieService.WatchDocument.yorkie.v1.WatchDocumentResponse' default: - $ref: "#/components/responses/connect.error" + $ref: '#/components/responses/connect.error' tags: - - yorkie.v1.YorkieService + - yorkie.v1.YorkieService components: requestBodies: yorkie.v1.YorkieService.ActivateClient.yorkie.v1.ActivateClientRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.ActivateClientRequest" + $ref: '#/components/schemas/yorkie.v1.ActivateClientRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.ActivateClientRequest" + $ref: '#/components/schemas/yorkie.v1.ActivateClientRequest' required: true yorkie.v1.YorkieService.AttachDocument.yorkie.v1.AttachDocumentRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.AttachDocumentRequest" + $ref: '#/components/schemas/yorkie.v1.AttachDocumentRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.AttachDocumentRequest" + $ref: '#/components/schemas/yorkie.v1.AttachDocumentRequest' required: true yorkie.v1.YorkieService.Broadcast.yorkie.v1.BroadcastRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.BroadcastRequest" + $ref: '#/components/schemas/yorkie.v1.BroadcastRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.BroadcastRequest" + $ref: '#/components/schemas/yorkie.v1.BroadcastRequest' required: true yorkie.v1.YorkieService.DeactivateClient.yorkie.v1.DeactivateClientRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.DeactivateClientRequest" + $ref: '#/components/schemas/yorkie.v1.DeactivateClientRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.DeactivateClientRequest" + $ref: '#/components/schemas/yorkie.v1.DeactivateClientRequest' required: true yorkie.v1.YorkieService.DetachDocument.yorkie.v1.DetachDocumentRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.DetachDocumentRequest" + $ref: '#/components/schemas/yorkie.v1.DetachDocumentRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.DetachDocumentRequest" + $ref: '#/components/schemas/yorkie.v1.DetachDocumentRequest' required: true yorkie.v1.YorkieService.PushPullChanges.yorkie.v1.PushPullChangesRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.PushPullChangesRequest" + $ref: '#/components/schemas/yorkie.v1.PushPullChangesRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.PushPullChangesRequest" + $ref: '#/components/schemas/yorkie.v1.PushPullChangesRequest' required: true yorkie.v1.YorkieService.RemoveDocument.yorkie.v1.RemoveDocumentRequest: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.RemoveDocumentRequest" + $ref: '#/components/schemas/yorkie.v1.RemoveDocumentRequest' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.RemoveDocumentRequest" + $ref: '#/components/schemas/yorkie.v1.RemoveDocumentRequest' required: true yorkie.v1.YorkieService.WatchDocument.yorkie.v1.WatchDocumentRequest: content: {} @@ -180,100 +179,100 @@ components: content: application/json: schema: - $ref: "#/components/schemas/connect.error" + $ref: '#/components/schemas/connect.error' application/proto: schema: - $ref: "#/components/schemas/connect.error" + $ref: '#/components/schemas/connect.error' description: "" yorkie.v1.YorkieService.ActivateClient.yorkie.v1.ActivateClientResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.ActivateClientResponse" + $ref: '#/components/schemas/yorkie.v1.ActivateClientResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.ActivateClientResponse" + $ref: '#/components/schemas/yorkie.v1.ActivateClientResponse' description: "" yorkie.v1.YorkieService.AttachDocument.yorkie.v1.AttachDocumentResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.AttachDocumentResponse" + $ref: '#/components/schemas/yorkie.v1.AttachDocumentResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.AttachDocumentResponse" + $ref: '#/components/schemas/yorkie.v1.AttachDocumentResponse' description: "" yorkie.v1.YorkieService.Broadcast.yorkie.v1.BroadcastResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.BroadcastResponse" + $ref: '#/components/schemas/yorkie.v1.BroadcastResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.BroadcastResponse" + $ref: '#/components/schemas/yorkie.v1.BroadcastResponse' description: "" yorkie.v1.YorkieService.DeactivateClient.yorkie.v1.DeactivateClientResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.DeactivateClientResponse" + $ref: '#/components/schemas/yorkie.v1.DeactivateClientResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.DeactivateClientResponse" + $ref: '#/components/schemas/yorkie.v1.DeactivateClientResponse' description: "" yorkie.v1.YorkieService.DetachDocument.yorkie.v1.DetachDocumentResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.DetachDocumentResponse" + $ref: '#/components/schemas/yorkie.v1.DetachDocumentResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.DetachDocumentResponse" + $ref: '#/components/schemas/yorkie.v1.DetachDocumentResponse' description: "" yorkie.v1.YorkieService.PushPullChanges.yorkie.v1.PushPullChangesResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.PushPullChangesResponse" + $ref: '#/components/schemas/yorkie.v1.PushPullChangesResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.PushPullChangesResponse" + $ref: '#/components/schemas/yorkie.v1.PushPullChangesResponse' description: "" yorkie.v1.YorkieService.RemoveDocument.yorkie.v1.RemoveDocumentResponse: content: application/json: schema: - $ref: "#/components/schemas/yorkie.v1.RemoveDocumentResponse" + $ref: '#/components/schemas/yorkie.v1.RemoveDocumentResponse' application/proto: schema: - $ref: "#/components/schemas/yorkie.v1.RemoveDocumentResponse" + $ref: '#/components/schemas/yorkie.v1.RemoveDocumentResponse' description: "" yorkie.v1.YorkieService.WatchDocument.yorkie.v1.WatchDocumentResponse: description: "" schemas: connect.error: additionalProperties: false - description: "Error type returned by Connect: https://connectrpc.com/docs/go/errors/#http-representation" + description: 'Error type returned by Connect: https://connectrpc.com/docs/go/errors/#http-representation' properties: code: enum: - - CodeCanceled - - CodeUnknown - - CodeInvalidArgument - - CodeDeadlineExceeded - - CodeNotFound - - CodeAlreadyExists - - CodePermissionDenied - - CodeResourceExhausted - - CodeFailedPrecondition - - CodeAborted - - CodeOutOfRange - - CodeInternal - - CodeUnavailable - - CodeDataLoss - - CodeUnauthenticated + - CodeCanceled + - CodeUnknown + - CodeInvalidArgument + - CodeDeadlineExceeded + - CodeNotFound + - CodeAlreadyExists + - CodePermissionDenied + - CodeResourceExhausted + - CodeFailedPrecondition + - CodeAborted + - CodeOutOfRange + - CodeInternal + - CodeUnavailable + - CodeDataLoss + - CodeUnauthenticated examples: - - CodeNotFound + - CodeNotFound type: string message: type: string @@ -306,7 +305,7 @@ components: description: "" properties: changePack: - $ref: "#/components/schemas/yorkie.v1.ChangePack" + $ref: '#/components/schemas/yorkie.v1.ChangePack' additionalProperties: false description: "" title: change_pack @@ -323,7 +322,7 @@ components: description: "" properties: changePack: - $ref: "#/components/schemas/yorkie.v1.ChangePack" + $ref: '#/components/schemas/yorkie.v1.ChangePack' additionalProperties: false description: "" title: change_pack @@ -372,7 +371,7 @@ components: description: "" properties: id: - $ref: "#/components/schemas/yorkie.v1.ChangeID" + $ref: '#/components/schemas/yorkie.v1.ChangeID' additionalProperties: false description: "" title: id @@ -386,12 +385,12 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.Operation" + $ref: '#/components/schemas/yorkie.v1.Operation' type: object title: operations type: array presenceChange: - $ref: "#/components/schemas/yorkie.v1.PresenceChange" + $ref: '#/components/schemas/yorkie.v1.PresenceChange' additionalProperties: false description: "" title: presence_change @@ -417,15 +416,15 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: lamport serverSeq: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: server_seq title: ChangeID type: object @@ -439,12 +438,12 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.Change" + $ref: '#/components/schemas/yorkie.v1.Change' type: object title: changes type: array checkpoint: - $ref: "#/components/schemas/yorkie.v1.Checkpoint" + $ref: '#/components/schemas/yorkie.v1.Checkpoint' additionalProperties: false description: "" title: checkpoint @@ -460,7 +459,7 @@ components: title: is_removed type: boolean minSyncedTicket: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: min_synced_ticket @@ -486,8 +485,8 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: server_seq title: Checkpoint type: object @@ -512,7 +511,7 @@ components: description: "" properties: changePack: - $ref: "#/components/schemas/yorkie.v1.ChangePack" + $ref: '#/components/schemas/yorkie.v1.ChangePack' additionalProperties: false description: "" title: change_pack @@ -539,7 +538,7 @@ components: description: "" properties: changePack: - $ref: "#/components/schemas/yorkie.v1.ChangePack" + $ref: '#/components/schemas/yorkie.v1.ChangePack' additionalProperties: false description: "" title: change_pack @@ -551,7 +550,7 @@ components: description: "" properties: body: - $ref: "#/components/schemas/yorkie.v1.DocEventBody" + $ref: '#/components/schemas/yorkie.v1.DocEventBody' additionalProperties: false description: "" title: body @@ -562,7 +561,7 @@ components: title: publisher type: string type: - $ref: "#/components/schemas/yorkie.v1.DocEventType" + $ref: '#/components/schemas/yorkie.v1.DocEventType' additionalProperties: false description: "" title: type @@ -588,14 +587,14 @@ components: yorkie.v1.DocEventType: description: "" enum: - - - DOC_EVENT_TYPE_DOCUMENT_CHANGED - - 0 - - DOC_EVENT_TYPE_DOCUMENT_WATCHED - - 1 - - DOC_EVENT_TYPE_DOCUMENT_UNWATCHED - - 2 - - DOC_EVENT_TYPE_DOCUMENT_BROADCAST - - 3 + - - DOC_EVENT_TYPE_DOCUMENT_CHANGED + - 0 + - DOC_EVENT_TYPE_DOCUMENT_WATCHED + - 1 + - DOC_EVENT_TYPE_DOCUMENT_UNWATCHED + - 2 + - DOC_EVENT_TYPE_DOCUMENT_BROADCAST + - 3 title: DocEventType type: string yorkie.v1.JSONElementSimple: @@ -603,25 +602,25 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object movedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: moved_at type: object removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at type: object type: - $ref: "#/components/schemas/yorkie.v1.ValueType" + $ref: '#/components/schemas/yorkie.v1.ValueType' additionalProperties: false description: "" title: type @@ -643,7 +642,7 @@ components: title: is_removed type: boolean updatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: updated_at @@ -660,61 +659,61 @@ components: description: "" properties: add: - $ref: "#/components/schemas/yorkie.v1.Operation.Add" + $ref: '#/components/schemas/yorkie.v1.Operation.Add' additionalProperties: false description: "" title: add type: object edit: - $ref: "#/components/schemas/yorkie.v1.Operation.Edit" + $ref: '#/components/schemas/yorkie.v1.Operation.Edit' additionalProperties: false description: "" title: edit type: object increase: - $ref: "#/components/schemas/yorkie.v1.Operation.Increase" + $ref: '#/components/schemas/yorkie.v1.Operation.Increase' additionalProperties: false description: "" title: increase type: object move: - $ref: "#/components/schemas/yorkie.v1.Operation.Move" + $ref: '#/components/schemas/yorkie.v1.Operation.Move' additionalProperties: false description: "" title: move type: object remove: - $ref: "#/components/schemas/yorkie.v1.Operation.Remove" + $ref: '#/components/schemas/yorkie.v1.Operation.Remove' additionalProperties: false description: "" title: remove type: object select: - $ref: "#/components/schemas/yorkie.v1.Operation.Select" + $ref: '#/components/schemas/yorkie.v1.Operation.Select' additionalProperties: false description: "" title: select type: object set: - $ref: "#/components/schemas/yorkie.v1.Operation.Set" + $ref: '#/components/schemas/yorkie.v1.Operation.Set' additionalProperties: false description: "" title: set type: object style: - $ref: "#/components/schemas/yorkie.v1.Operation.Style" + $ref: '#/components/schemas/yorkie.v1.Operation.Style' additionalProperties: false description: "" title: style type: object treeEdit: - $ref: "#/components/schemas/yorkie.v1.Operation.TreeEdit" + $ref: '#/components/schemas/yorkie.v1.Operation.TreeEdit' additionalProperties: false description: "" title: tree_edit type: object treeStyle: - $ref: "#/components/schemas/yorkie.v1.Operation.TreeStyle" + $ref: '#/components/schemas/yorkie.v1.Operation.TreeStyle' additionalProperties: false description: "" title: tree_style @@ -726,25 +725,25 @@ components: description: "" properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object prevCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: prev_created_at type: object value: - $ref: "#/components/schemas/yorkie.v1.JSONElementSimple" + $ref: '#/components/schemas/yorkie.v1.JSONElementSimple' additionalProperties: false description: "" title: value @@ -771,25 +770,25 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: to @@ -822,7 +821,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -834,19 +833,19 @@ components: description: "" properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object value: - $ref: "#/components/schemas/yorkie.v1.JSONElementSimple" + $ref: '#/components/schemas/yorkie.v1.JSONElementSimple' additionalProperties: false description: "" title: value @@ -858,25 +857,25 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object prevCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: prev_created_at @@ -888,19 +887,19 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at @@ -916,25 +915,25 @@ components: compatibility purposes. properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: to @@ -946,7 +945,7 @@ components: description: "" properties: executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at @@ -957,13 +956,13 @@ components: title: key type: string parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object value: - $ref: "#/components/schemas/yorkie.v1.JSONElementSimple" + $ref: '#/components/schemas/yorkie.v1.JSONElementSimple' additionalProperties: false description: "" title: value @@ -985,25 +984,25 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TextNodePos" + $ref: '#/components/schemas/yorkie.v1.TextNodePos' additionalProperties: false description: "" title: to @@ -1036,7 +1035,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -1051,7 +1050,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.TreeNodes" + $ref: '#/components/schemas/yorkie.v1.TreeNodes' type: object title: contents type: array @@ -1061,19 +1060,19 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at @@ -1084,7 +1083,7 @@ components: title: split_level type: integer to: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: to @@ -1101,7 +1100,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -1130,25 +1129,25 @@ components: title: created_at_map_by_actor type: object executedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: executed_at type: object from: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: from type: object parentCreatedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: parent_created_at type: object to: - $ref: "#/components/schemas/yorkie.v1.TreePos" + $ref: '#/components/schemas/yorkie.v1.TreePos' additionalProperties: false description: "" title: to @@ -1181,7 +1180,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: value @@ -1220,13 +1219,13 @@ components: description: "" properties: presence: - $ref: "#/components/schemas/yorkie.v1.Presence" + $ref: '#/components/schemas/yorkie.v1.Presence' additionalProperties: false description: "" title: presence type: object type: - $ref: "#/components/schemas/yorkie.v1.PresenceChange.ChangeType" + $ref: '#/components/schemas/yorkie.v1.PresenceChange.ChangeType' additionalProperties: false description: "" title: type @@ -1235,14 +1234,14 @@ components: yorkie.v1.PresenceChange.ChangeType: description: "" enum: - - - CHANGE_TYPE_UNSPECIFIED - - 0 - - CHANGE_TYPE_PUT - - 1 - - CHANGE_TYPE_DELETE - - 2 - - CHANGE_TYPE_CLEAR - - 3 + - - CHANGE_TYPE_UNSPECIFIED + - 0 + - CHANGE_TYPE_PUT + - 1 + - CHANGE_TYPE_DELETE + - 2 + - CHANGE_TYPE_CLEAR + - 3 title: ChangeType type: string yorkie.v1.PushPullChangesRequest: @@ -1250,7 +1249,7 @@ components: description: "" properties: changePack: - $ref: "#/components/schemas/yorkie.v1.ChangePack" + $ref: '#/components/schemas/yorkie.v1.ChangePack' additionalProperties: false description: "" title: change_pack @@ -1277,7 +1276,7 @@ components: description: "" properties: changePack: - $ref: "#/components/schemas/yorkie.v1.ChangePack" + $ref: '#/components/schemas/yorkie.v1.ChangePack' additionalProperties: false description: "" title: change_pack @@ -1289,7 +1288,7 @@ components: description: "" properties: changePack: - $ref: "#/components/schemas/yorkie.v1.ChangePack" + $ref: '#/components/schemas/yorkie.v1.ChangePack' additionalProperties: false description: "" title: change_pack @@ -1311,7 +1310,7 @@ components: description: "" properties: changePack: - $ref: "#/components/schemas/yorkie.v1.ChangePack" + $ref: '#/components/schemas/yorkie.v1.ChangePack' additionalProperties: false description: "" title: change_pack @@ -1323,7 +1322,7 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at @@ -1359,8 +1358,8 @@ components: additionalProperties: false description: "" oneOf: - - type: string - - type: number + - type: string + - type: number title: lamport title: TimeTicket type: object @@ -1379,25 +1378,25 @@ components: title: depth type: integer id: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: id type: object insNextId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: ins_next_id type: object insPrevId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: ins_prev_id type: object removedAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: removed_at @@ -1424,7 +1423,7 @@ components: title: key type: string value: - $ref: "#/components/schemas/yorkie.v1.NodeAttr" + $ref: '#/components/schemas/yorkie.v1.NodeAttr' additionalProperties: false description: "" title: value @@ -1436,7 +1435,7 @@ components: description: "" properties: createdAt: - $ref: "#/components/schemas/yorkie.v1.TimeTicket" + $ref: '#/components/schemas/yorkie.v1.TimeTicket' additionalProperties: false description: "" title: created_at @@ -1456,7 +1455,7 @@ components: additionalProperties: false description: "" items: - $ref: "#/components/schemas/yorkie.v1.TreeNode" + $ref: '#/components/schemas/yorkie.v1.TreeNode' type: object title: content type: array @@ -1467,13 +1466,13 @@ components: description: "" properties: leftSiblingId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: left_sibling_id type: object parentId: - $ref: "#/components/schemas/yorkie.v1.TreeNodeID" + $ref: '#/components/schemas/yorkie.v1.TreeNodeID' additionalProperties: false description: "" title: parent_id @@ -1483,34 +1482,34 @@ components: yorkie.v1.ValueType: description: "" enum: - - - VALUE_TYPE_NULL - - 0 - - VALUE_TYPE_BOOLEAN - - 1 - - VALUE_TYPE_INTEGER - - 2 - - VALUE_TYPE_LONG - - 3 - - VALUE_TYPE_DOUBLE - - 4 - - VALUE_TYPE_STRING - - 5 - - VALUE_TYPE_BYTES - - 6 - - VALUE_TYPE_DATE - - 7 - - VALUE_TYPE_JSON_OBJECT - - 8 - - VALUE_TYPE_JSON_ARRAY - - 9 - - VALUE_TYPE_TEXT - - 10 - - VALUE_TYPE_INTEGER_CNT - - 11 - - VALUE_TYPE_LONG_CNT - - 12 - - VALUE_TYPE_TREE - - 13 + - - VALUE_TYPE_NULL + - 0 + - VALUE_TYPE_BOOLEAN + - 1 + - VALUE_TYPE_INTEGER + - 2 + - VALUE_TYPE_LONG + - 3 + - VALUE_TYPE_DOUBLE + - 4 + - VALUE_TYPE_STRING + - 5 + - VALUE_TYPE_BYTES + - 6 + - VALUE_TYPE_DATE + - 7 + - VALUE_TYPE_JSON_OBJECT + - 8 + - VALUE_TYPE_JSON_ARRAY + - 9 + - VALUE_TYPE_TEXT + - 10 + - VALUE_TYPE_INTEGER_CNT + - 11 + - VALUE_TYPE_LONG_CNT + - 12 + - VALUE_TYPE_TREE + - 13 title: ValueType type: string yorkie.v1.WatchDocumentRequest: @@ -1534,13 +1533,13 @@ components: description: "" properties: event: - $ref: "#/components/schemas/yorkie.v1.DocEvent" + $ref: '#/components/schemas/yorkie.v1.DocEvent' additionalProperties: false description: "" title: event type: object initialization: - $ref: "#/components/schemas/yorkie.v1.WatchDocumentResponse.Initialization" + $ref: '#/components/schemas/yorkie.v1.WatchDocumentResponse.Initialization' additionalProperties: false description: "" title: initialization @@ -1566,7 +1565,7 @@ components: name: Authorization type: apiKey security: - - ApiKeyAuth: [] +- ApiKeyAuth: [] tags: - - description: Yorkie is a service that provides a API for SDKs. - name: yorkie.v1.YorkieService +- description: Yorkie is a service that provides a API for SDKs. + name: yorkie.v1.YorkieService diff --git a/api/yorkie/v1/admin.pb.go b/api/yorkie/v1/admin.pb.go index ace02635d..02c79116a 100644 --- a/api/yorkie/v1/admin.pb.go +++ b/api/yorkie/v1/admin.pb.go @@ -239,6 +239,200 @@ func (x *LogInResponse) GetToken() string { return "" } +type DeleteAccountRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"` + Password string `protobuf:"bytes,2,opt,name=password,proto3" json:"password,omitempty"` +} + +func (x *DeleteAccountRequest) Reset() { + *x = DeleteAccountRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_yorkie_v1_admin_proto_msgTypes[4] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *DeleteAccountRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*DeleteAccountRequest) ProtoMessage() {} + +func (x *DeleteAccountRequest) ProtoReflect() protoreflect.Message { + mi := &file_yorkie_v1_admin_proto_msgTypes[4] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use DeleteAccountRequest.ProtoReflect.Descriptor instead. +func (*DeleteAccountRequest) Descriptor() ([]byte, []int) { + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{4} +} + +func (x *DeleteAccountRequest) GetUsername() string { + if x != nil { + return x.Username + } + return "" +} + +func (x *DeleteAccountRequest) GetPassword() string { + if x != nil { + return x.Password + } + return "" +} + +type DeleteAccountResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *DeleteAccountResponse) Reset() { + *x = DeleteAccountResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_yorkie_v1_admin_proto_msgTypes[5] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *DeleteAccountResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*DeleteAccountResponse) ProtoMessage() {} + +func (x *DeleteAccountResponse) ProtoReflect() protoreflect.Message { + mi := &file_yorkie_v1_admin_proto_msgTypes[5] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use DeleteAccountResponse.ProtoReflect.Descriptor instead. +func (*DeleteAccountResponse) Descriptor() ([]byte, []int) { + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{5} +} + +type ChangePasswordRequest struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields + + Username string `protobuf:"bytes,1,opt,name=username,proto3" json:"username,omitempty"` + CurrentPassword string `protobuf:"bytes,2,opt,name=current_password,json=currentPassword,proto3" json:"current_password,omitempty"` + NewPassword string `protobuf:"bytes,3,opt,name=new_password,json=newPassword,proto3" json:"new_password,omitempty"` +} + +func (x *ChangePasswordRequest) Reset() { + *x = ChangePasswordRequest{} + if protoimpl.UnsafeEnabled { + mi := &file_yorkie_v1_admin_proto_msgTypes[6] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangePasswordRequest) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangePasswordRequest) ProtoMessage() {} + +func (x *ChangePasswordRequest) ProtoReflect() protoreflect.Message { + mi := &file_yorkie_v1_admin_proto_msgTypes[6] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangePasswordRequest.ProtoReflect.Descriptor instead. +func (*ChangePasswordRequest) Descriptor() ([]byte, []int) { + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{6} +} + +func (x *ChangePasswordRequest) GetUsername() string { + if x != nil { + return x.Username + } + return "" +} + +func (x *ChangePasswordRequest) GetCurrentPassword() string { + if x != nil { + return x.CurrentPassword + } + return "" +} + +func (x *ChangePasswordRequest) GetNewPassword() string { + if x != nil { + return x.NewPassword + } + return "" +} + +type ChangePasswordResponse struct { + state protoimpl.MessageState + sizeCache protoimpl.SizeCache + unknownFields protoimpl.UnknownFields +} + +func (x *ChangePasswordResponse) Reset() { + *x = ChangePasswordResponse{} + if protoimpl.UnsafeEnabled { + mi := &file_yorkie_v1_admin_proto_msgTypes[7] + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + ms.StoreMessageInfo(mi) + } +} + +func (x *ChangePasswordResponse) String() string { + return protoimpl.X.MessageStringOf(x) +} + +func (*ChangePasswordResponse) ProtoMessage() {} + +func (x *ChangePasswordResponse) ProtoReflect() protoreflect.Message { + mi := &file_yorkie_v1_admin_proto_msgTypes[7] + if protoimpl.UnsafeEnabled && x != nil { + ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) + if ms.LoadMessageInfo() == nil { + ms.StoreMessageInfo(mi) + } + return ms + } + return mi.MessageOf(x) +} + +// Deprecated: Use ChangePasswordResponse.ProtoReflect.Descriptor instead. +func (*ChangePasswordResponse) Descriptor() ([]byte, []int) { + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{7} +} + type CreateProjectRequest struct { state protoimpl.MessageState sizeCache protoimpl.SizeCache @@ -250,7 +444,7 @@ type CreateProjectRequest struct { func (x *CreateProjectRequest) Reset() { *x = CreateProjectRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[4] + mi := &file_yorkie_v1_admin_proto_msgTypes[8] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -263,7 +457,7 @@ func (x *CreateProjectRequest) String() string { func (*CreateProjectRequest) ProtoMessage() {} func (x *CreateProjectRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[4] + mi := &file_yorkie_v1_admin_proto_msgTypes[8] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -276,7 +470,7 @@ func (x *CreateProjectRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use CreateProjectRequest.ProtoReflect.Descriptor instead. func (*CreateProjectRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{4} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{8} } func (x *CreateProjectRequest) GetName() string { @@ -297,7 +491,7 @@ type CreateProjectResponse struct { func (x *CreateProjectResponse) Reset() { *x = CreateProjectResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[5] + mi := &file_yorkie_v1_admin_proto_msgTypes[9] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -310,7 +504,7 @@ func (x *CreateProjectResponse) String() string { func (*CreateProjectResponse) ProtoMessage() {} func (x *CreateProjectResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[5] + mi := &file_yorkie_v1_admin_proto_msgTypes[9] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -323,7 +517,7 @@ func (x *CreateProjectResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use CreateProjectResponse.ProtoReflect.Descriptor instead. func (*CreateProjectResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{5} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{9} } func (x *CreateProjectResponse) GetProject() *Project { @@ -344,7 +538,7 @@ type GetProjectRequest struct { func (x *GetProjectRequest) Reset() { *x = GetProjectRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[6] + mi := &file_yorkie_v1_admin_proto_msgTypes[10] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -357,7 +551,7 @@ func (x *GetProjectRequest) String() string { func (*GetProjectRequest) ProtoMessage() {} func (x *GetProjectRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[6] + mi := &file_yorkie_v1_admin_proto_msgTypes[10] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -370,7 +564,7 @@ func (x *GetProjectRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetProjectRequest.ProtoReflect.Descriptor instead. func (*GetProjectRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{6} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{10} } func (x *GetProjectRequest) GetName() string { @@ -391,7 +585,7 @@ type GetProjectResponse struct { func (x *GetProjectResponse) Reset() { *x = GetProjectResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[7] + mi := &file_yorkie_v1_admin_proto_msgTypes[11] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -404,7 +598,7 @@ func (x *GetProjectResponse) String() string { func (*GetProjectResponse) ProtoMessage() {} func (x *GetProjectResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[7] + mi := &file_yorkie_v1_admin_proto_msgTypes[11] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -417,7 +611,7 @@ func (x *GetProjectResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetProjectResponse.ProtoReflect.Descriptor instead. func (*GetProjectResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{7} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{11} } func (x *GetProjectResponse) GetProject() *Project { @@ -436,7 +630,7 @@ type ListProjectsRequest struct { func (x *ListProjectsRequest) Reset() { *x = ListProjectsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[8] + mi := &file_yorkie_v1_admin_proto_msgTypes[12] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -449,7 +643,7 @@ func (x *ListProjectsRequest) String() string { func (*ListProjectsRequest) ProtoMessage() {} func (x *ListProjectsRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[8] + mi := &file_yorkie_v1_admin_proto_msgTypes[12] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -462,7 +656,7 @@ func (x *ListProjectsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListProjectsRequest.ProtoReflect.Descriptor instead. func (*ListProjectsRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{8} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{12} } type ListProjectsResponse struct { @@ -476,7 +670,7 @@ type ListProjectsResponse struct { func (x *ListProjectsResponse) Reset() { *x = ListProjectsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[9] + mi := &file_yorkie_v1_admin_proto_msgTypes[13] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -489,7 +683,7 @@ func (x *ListProjectsResponse) String() string { func (*ListProjectsResponse) ProtoMessage() {} func (x *ListProjectsResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[9] + mi := &file_yorkie_v1_admin_proto_msgTypes[13] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -502,7 +696,7 @@ func (x *ListProjectsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListProjectsResponse.ProtoReflect.Descriptor instead. func (*ListProjectsResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{9} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{13} } func (x *ListProjectsResponse) GetProjects() []*Project { @@ -524,7 +718,7 @@ type UpdateProjectRequest struct { func (x *UpdateProjectRequest) Reset() { *x = UpdateProjectRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[10] + mi := &file_yorkie_v1_admin_proto_msgTypes[14] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -537,7 +731,7 @@ func (x *UpdateProjectRequest) String() string { func (*UpdateProjectRequest) ProtoMessage() {} func (x *UpdateProjectRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[10] + mi := &file_yorkie_v1_admin_proto_msgTypes[14] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -550,7 +744,7 @@ func (x *UpdateProjectRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateProjectRequest.ProtoReflect.Descriptor instead. func (*UpdateProjectRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{10} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{14} } func (x *UpdateProjectRequest) GetId() string { @@ -578,7 +772,7 @@ type UpdateProjectResponse struct { func (x *UpdateProjectResponse) Reset() { *x = UpdateProjectResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[11] + mi := &file_yorkie_v1_admin_proto_msgTypes[15] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -591,7 +785,7 @@ func (x *UpdateProjectResponse) String() string { func (*UpdateProjectResponse) ProtoMessage() {} func (x *UpdateProjectResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[11] + mi := &file_yorkie_v1_admin_proto_msgTypes[15] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -604,7 +798,7 @@ func (x *UpdateProjectResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use UpdateProjectResponse.ProtoReflect.Descriptor instead. func (*UpdateProjectResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{11} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{15} } func (x *UpdateProjectResponse) GetProject() *Project { @@ -629,7 +823,7 @@ type ListDocumentsRequest struct { func (x *ListDocumentsRequest) Reset() { *x = ListDocumentsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[12] + mi := &file_yorkie_v1_admin_proto_msgTypes[16] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -642,7 +836,7 @@ func (x *ListDocumentsRequest) String() string { func (*ListDocumentsRequest) ProtoMessage() {} func (x *ListDocumentsRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[12] + mi := &file_yorkie_v1_admin_proto_msgTypes[16] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -655,7 +849,7 @@ func (x *ListDocumentsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListDocumentsRequest.ProtoReflect.Descriptor instead. func (*ListDocumentsRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{12} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{16} } func (x *ListDocumentsRequest) GetProjectName() string { @@ -704,7 +898,7 @@ type ListDocumentsResponse struct { func (x *ListDocumentsResponse) Reset() { *x = ListDocumentsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[13] + mi := &file_yorkie_v1_admin_proto_msgTypes[17] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -717,7 +911,7 @@ func (x *ListDocumentsResponse) String() string { func (*ListDocumentsResponse) ProtoMessage() {} func (x *ListDocumentsResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[13] + mi := &file_yorkie_v1_admin_proto_msgTypes[17] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -730,7 +924,7 @@ func (x *ListDocumentsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListDocumentsResponse.ProtoReflect.Descriptor instead. func (*ListDocumentsResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{13} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{17} } func (x *ListDocumentsResponse) GetDocuments() []*DocumentSummary { @@ -752,7 +946,7 @@ type GetDocumentRequest struct { func (x *GetDocumentRequest) Reset() { *x = GetDocumentRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[14] + mi := &file_yorkie_v1_admin_proto_msgTypes[18] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -765,7 +959,7 @@ func (x *GetDocumentRequest) String() string { func (*GetDocumentRequest) ProtoMessage() {} func (x *GetDocumentRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[14] + mi := &file_yorkie_v1_admin_proto_msgTypes[18] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -778,7 +972,7 @@ func (x *GetDocumentRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetDocumentRequest.ProtoReflect.Descriptor instead. func (*GetDocumentRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{14} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{18} } func (x *GetDocumentRequest) GetProjectName() string { @@ -806,7 +1000,7 @@ type GetDocumentResponse struct { func (x *GetDocumentResponse) Reset() { *x = GetDocumentResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[15] + mi := &file_yorkie_v1_admin_proto_msgTypes[19] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -819,7 +1013,7 @@ func (x *GetDocumentResponse) String() string { func (*GetDocumentResponse) ProtoMessage() {} func (x *GetDocumentResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[15] + mi := &file_yorkie_v1_admin_proto_msgTypes[19] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -832,7 +1026,7 @@ func (x *GetDocumentResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetDocumentResponse.ProtoReflect.Descriptor instead. func (*GetDocumentResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{15} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{19} } func (x *GetDocumentResponse) GetDocument() *DocumentSummary { @@ -855,7 +1049,7 @@ type GetDocumentsRequest struct { func (x *GetDocumentsRequest) Reset() { *x = GetDocumentsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[16] + mi := &file_yorkie_v1_admin_proto_msgTypes[20] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -868,7 +1062,7 @@ func (x *GetDocumentsRequest) String() string { func (*GetDocumentsRequest) ProtoMessage() {} func (x *GetDocumentsRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[16] + mi := &file_yorkie_v1_admin_proto_msgTypes[20] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -881,7 +1075,7 @@ func (x *GetDocumentsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetDocumentsRequest.ProtoReflect.Descriptor instead. func (*GetDocumentsRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{16} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{20} } func (x *GetDocumentsRequest) GetProjectName() string { @@ -916,7 +1110,7 @@ type GetDocumentsResponse struct { func (x *GetDocumentsResponse) Reset() { *x = GetDocumentsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[17] + mi := &file_yorkie_v1_admin_proto_msgTypes[21] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -929,7 +1123,7 @@ func (x *GetDocumentsResponse) String() string { func (*GetDocumentsResponse) ProtoMessage() {} func (x *GetDocumentsResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[17] + mi := &file_yorkie_v1_admin_proto_msgTypes[21] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -942,7 +1136,7 @@ func (x *GetDocumentsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetDocumentsResponse.ProtoReflect.Descriptor instead. func (*GetDocumentsResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{17} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{21} } func (x *GetDocumentsResponse) GetDocuments() []*DocumentSummary { @@ -965,7 +1159,7 @@ type RemoveDocumentByAdminRequest struct { func (x *RemoveDocumentByAdminRequest) Reset() { *x = RemoveDocumentByAdminRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[18] + mi := &file_yorkie_v1_admin_proto_msgTypes[22] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -978,7 +1172,7 @@ func (x *RemoveDocumentByAdminRequest) String() string { func (*RemoveDocumentByAdminRequest) ProtoMessage() {} func (x *RemoveDocumentByAdminRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[18] + mi := &file_yorkie_v1_admin_proto_msgTypes[22] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -991,7 +1185,7 @@ func (x *RemoveDocumentByAdminRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use RemoveDocumentByAdminRequest.ProtoReflect.Descriptor instead. func (*RemoveDocumentByAdminRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{18} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{22} } func (x *RemoveDocumentByAdminRequest) GetProjectName() string { @@ -1024,7 +1218,7 @@ type RemoveDocumentByAdminResponse struct { func (x *RemoveDocumentByAdminResponse) Reset() { *x = RemoveDocumentByAdminResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[19] + mi := &file_yorkie_v1_admin_proto_msgTypes[23] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1037,7 +1231,7 @@ func (x *RemoveDocumentByAdminResponse) String() string { func (*RemoveDocumentByAdminResponse) ProtoMessage() {} func (x *RemoveDocumentByAdminResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[19] + mi := &file_yorkie_v1_admin_proto_msgTypes[23] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1050,7 +1244,7 @@ func (x *RemoveDocumentByAdminResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use RemoveDocumentByAdminResponse.ProtoReflect.Descriptor instead. func (*RemoveDocumentByAdminResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{19} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{23} } type GetSnapshotMetaRequest struct { @@ -1066,7 +1260,7 @@ type GetSnapshotMetaRequest struct { func (x *GetSnapshotMetaRequest) Reset() { *x = GetSnapshotMetaRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[20] + mi := &file_yorkie_v1_admin_proto_msgTypes[24] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1079,7 +1273,7 @@ func (x *GetSnapshotMetaRequest) String() string { func (*GetSnapshotMetaRequest) ProtoMessage() {} func (x *GetSnapshotMetaRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[20] + mi := &file_yorkie_v1_admin_proto_msgTypes[24] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1092,7 +1286,7 @@ func (x *GetSnapshotMetaRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use GetSnapshotMetaRequest.ProtoReflect.Descriptor instead. func (*GetSnapshotMetaRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{20} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{24} } func (x *GetSnapshotMetaRequest) GetProjectName() string { @@ -1128,7 +1322,7 @@ type GetSnapshotMetaResponse struct { func (x *GetSnapshotMetaResponse) Reset() { *x = GetSnapshotMetaResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[21] + mi := &file_yorkie_v1_admin_proto_msgTypes[25] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1141,7 +1335,7 @@ func (x *GetSnapshotMetaResponse) String() string { func (*GetSnapshotMetaResponse) ProtoMessage() {} func (x *GetSnapshotMetaResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[21] + mi := &file_yorkie_v1_admin_proto_msgTypes[25] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1154,7 +1348,7 @@ func (x *GetSnapshotMetaResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use GetSnapshotMetaResponse.ProtoReflect.Descriptor instead. func (*GetSnapshotMetaResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{21} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{25} } func (x *GetSnapshotMetaResponse) GetSnapshot() []byte { @@ -1184,7 +1378,7 @@ type SearchDocumentsRequest struct { func (x *SearchDocumentsRequest) Reset() { *x = SearchDocumentsRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[22] + mi := &file_yorkie_v1_admin_proto_msgTypes[26] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1197,7 +1391,7 @@ func (x *SearchDocumentsRequest) String() string { func (*SearchDocumentsRequest) ProtoMessage() {} func (x *SearchDocumentsRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[22] + mi := &file_yorkie_v1_admin_proto_msgTypes[26] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1210,7 +1404,7 @@ func (x *SearchDocumentsRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use SearchDocumentsRequest.ProtoReflect.Descriptor instead. func (*SearchDocumentsRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{22} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{26} } func (x *SearchDocumentsRequest) GetProjectName() string { @@ -1246,7 +1440,7 @@ type SearchDocumentsResponse struct { func (x *SearchDocumentsResponse) Reset() { *x = SearchDocumentsResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[23] + mi := &file_yorkie_v1_admin_proto_msgTypes[27] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1259,7 +1453,7 @@ func (x *SearchDocumentsResponse) String() string { func (*SearchDocumentsResponse) ProtoMessage() {} func (x *SearchDocumentsResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[23] + mi := &file_yorkie_v1_admin_proto_msgTypes[27] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1272,7 +1466,7 @@ func (x *SearchDocumentsResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use SearchDocumentsResponse.ProtoReflect.Descriptor instead. func (*SearchDocumentsResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{23} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{27} } func (x *SearchDocumentsResponse) GetTotalCount() int32 { @@ -1304,7 +1498,7 @@ type ListChangesRequest struct { func (x *ListChangesRequest) Reset() { *x = ListChangesRequest{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[24] + mi := &file_yorkie_v1_admin_proto_msgTypes[28] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1317,7 +1511,7 @@ func (x *ListChangesRequest) String() string { func (*ListChangesRequest) ProtoMessage() {} func (x *ListChangesRequest) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[24] + mi := &file_yorkie_v1_admin_proto_msgTypes[28] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1330,7 +1524,7 @@ func (x *ListChangesRequest) ProtoReflect() protoreflect.Message { // Deprecated: Use ListChangesRequest.ProtoReflect.Descriptor instead. func (*ListChangesRequest) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{24} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{28} } func (x *ListChangesRequest) GetProjectName() string { @@ -1379,7 +1573,7 @@ type ListChangesResponse struct { func (x *ListChangesResponse) Reset() { *x = ListChangesResponse{} if protoimpl.UnsafeEnabled { - mi := &file_yorkie_v1_admin_proto_msgTypes[25] + mi := &file_yorkie_v1_admin_proto_msgTypes[29] ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) ms.StoreMessageInfo(mi) } @@ -1392,7 +1586,7 @@ func (x *ListChangesResponse) String() string { func (*ListChangesResponse) ProtoMessage() {} func (x *ListChangesResponse) ProtoReflect() protoreflect.Message { - mi := &file_yorkie_v1_admin_proto_msgTypes[25] + mi := &file_yorkie_v1_admin_proto_msgTypes[29] if protoimpl.UnsafeEnabled && x != nil { ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x)) if ms.LoadMessageInfo() == nil { @@ -1405,7 +1599,7 @@ func (x *ListChangesResponse) ProtoReflect() protoreflect.Message { // Deprecated: Use ListChangesResponse.ProtoReflect.Descriptor instead. func (*ListChangesResponse) Descriptor() ([]byte, []int) { - return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{25} + return file_yorkie_v1_admin_proto_rawDescGZIP(), []int{29} } func (x *ListChangesResponse) GetChanges() []*Change { @@ -1436,207 +1630,235 @@ var file_yorkie_v1_admin_proto_rawDesc = []byte{ 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x22, 0x25, 0x0a, 0x0d, 0x4c, 0x6f, 0x67, 0x49, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x2a, 0x0a, 0x14, - 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x45, 0x0a, 0x15, 0x43, 0x72, 0x65, 0x61, - 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x12, 0x2c, 0x0a, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x50, - 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x22, - 0x27, 0x0a, 0x11, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, 0x42, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x50, + 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x6f, 0x6b, 0x65, 0x6e, 0x22, 0x4e, 0x0a, 0x14, + 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, + 0x75, 0x65, 0x73, 0x74, 0x12, 0x1a, 0x0a, 0x08, 0x75, 0x73, 0x65, 0x72, 0x6e, 0x61, 0x6d, 0x65, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x75, 0x73, 0x65, 0x72, 0x6e, 0x61, 0x6d, 0x65, + 0x12, 0x1a, 0x0a, 0x08, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x08, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x22, 0x17, 0x0a, 0x15, + 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x81, 0x01, 0x0a, 0x15, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, + 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, + 0x1a, 0x0a, 0x08, 0x75, 0x73, 0x65, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x08, 0x75, 0x73, 0x65, 0x72, 0x6e, 0x61, 0x6d, 0x65, 0x12, 0x29, 0x0a, 0x10, 0x63, + 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x5f, 0x70, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, + 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0f, 0x63, 0x75, 0x72, 0x72, 0x65, 0x6e, 0x74, 0x50, 0x61, + 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x12, 0x21, 0x0a, 0x0c, 0x6e, 0x65, 0x77, 0x5f, 0x70, 0x61, + 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x18, 0x03, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x6e, 0x65, + 0x77, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x22, 0x18, 0x0a, 0x16, 0x43, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x2a, 0x0a, 0x14, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, + 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, + 0x45, 0x0a, 0x15, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2c, 0x0a, 0x07, 0x70, 0x72, 0x6f, 0x6a, + 0x65, 0x63, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x79, 0x6f, 0x72, 0x6b, + 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x07, 0x70, + 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x22, 0x27, 0x0a, 0x11, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, + 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x12, 0x0a, 0x04, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x04, 0x6e, 0x61, 0x6d, 0x65, 0x22, + 0x42, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, + 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2c, 0x0a, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x07, 0x70, 0x72, 0x6f, 0x6a, + 0x65, 0x63, 0x74, 0x22, 0x15, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, + 0x63, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x22, 0x46, 0x0a, 0x14, 0x4c, 0x69, + 0x73, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, + 0x73, 0x65, 0x12, 0x2e, 0x0a, 0x08, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x18, 0x01, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, + 0x74, 0x73, 0x22, 0x61, 0x0a, 0x14, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, + 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, + 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x39, 0x0a, 0x06, 0x66, 0x69, + 0x65, 0x6c, 0x64, 0x73, 0x18, 0x02, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x79, 0x6f, 0x72, + 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, + 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x46, 0x69, 0x65, 0x6c, 0x64, 0x73, 0x52, 0x06, 0x66, + 0x69, 0x65, 0x6c, 0x64, 0x73, 0x22, 0x45, 0x0a, 0x15, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2c, 0x0a, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x6a, - 0x65, 0x63, 0x74, 0x52, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x22, 0x15, 0x0a, 0x13, - 0x4c, 0x69, 0x73, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x22, 0x46, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, - 0x63, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2e, 0x0a, 0x08, 0x70, - 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x12, 0x2e, - 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, - 0x74, 0x52, 0x08, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x22, 0x61, 0x0a, 0x14, 0x55, - 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, - 0x65, 0x73, 0x74, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, - 0x02, 0x69, 0x64, 0x12, 0x39, 0x0a, 0x06, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x73, 0x18, 0x02, 0x20, - 0x01, 0x28, 0x0b, 0x32, 0x21, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, - 0x55, 0x70, 0x64, 0x61, 0x74, 0x61, 0x62, 0x6c, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, - 0x46, 0x69, 0x65, 0x6c, 0x64, 0x73, 0x52, 0x06, 0x66, 0x69, 0x65, 0x6c, 0x64, 0x73, 0x22, 0x45, - 0x0a, 0x15, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2c, 0x0a, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, - 0x63, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x12, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x07, 0x70, 0x72, - 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x22, 0xc1, 0x01, 0x0a, 0x14, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x6f, - 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, + 0x65, 0x63, 0x74, 0x52, 0x07, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x22, 0xc1, 0x01, 0x0a, + 0x14, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, + 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, + 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x72, 0x65, 0x76, + 0x69, 0x6f, 0x75, 0x73, 0x5f, 0x69, 0x64, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, + 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x49, 0x64, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x67, + 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x61, + 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x66, 0x6f, 0x72, + 0x77, 0x61, 0x72, 0x64, 0x18, 0x04, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x46, 0x6f, + 0x72, 0x77, 0x61, 0x72, 0x64, 0x12, 0x29, 0x0a, 0x10, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x65, + 0x5f, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, + 0x0f, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, + 0x22, 0x51, 0x0a, 0x15, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, + 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x38, 0x0a, 0x09, 0x64, 0x6f, 0x63, + 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x79, + 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, + 0x74, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x52, 0x09, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, + 0x6e, 0x74, 0x73, 0x22, 0x5a, 0x0a, 0x12, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, + 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, + 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, + 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x21, 0x0a, 0x0c, + 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, + 0x28, 0x09, 0x52, 0x0b, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x22, + 0x4d, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x65, + 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x36, 0x0a, 0x08, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, + 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x53, 0x75, 0x6d, + 0x6d, 0x61, 0x72, 0x79, 0x52, 0x08, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x88, + 0x01, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, + 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, + 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, + 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x6f, 0x63, + 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, + 0x52, 0x0c, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x73, 0x12, 0x29, + 0x0a, 0x10, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x5f, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, + 0x6f, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0f, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, + 0x65, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x22, 0x50, 0x0a, 0x14, 0x47, 0x65, 0x74, + 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x12, 0x38, 0x0a, 0x09, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x01, + 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, + 0x52, 0x09, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x22, 0x7a, 0x0a, 0x1c, 0x52, + 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x42, 0x79, 0x41, + 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, + 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x21, + 0x0a, 0x0c, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x4b, 0x65, + 0x79, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x6f, 0x72, 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, + 0x52, 0x05, 0x66, 0x6f, 0x72, 0x63, 0x65, 0x22, 0x1f, 0x0a, 0x1d, 0x52, 0x65, 0x6d, 0x6f, 0x76, + 0x65, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x42, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x81, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, + 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x6e, + 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, + 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, + 0x6e, 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x6f, + 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x12, 0x21, 0x0a, 0x0a, 0x73, 0x65, 0x72, + 0x76, 0x65, 0x72, 0x5f, 0x73, 0x65, 0x71, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x42, 0x02, 0x30, + 0x01, 0x52, 0x09, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x53, 0x65, 0x71, 0x22, 0x53, 0x0a, 0x17, + 0x47, 0x65, 0x74, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x6e, 0x61, 0x70, 0x73, + 0x68, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x08, 0x73, 0x6e, 0x61, 0x70, 0x73, + 0x68, 0x6f, 0x74, 0x12, 0x1c, 0x0a, 0x07, 0x6c, 0x61, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x02, + 0x20, 0x01, 0x28, 0x03, 0x42, 0x02, 0x30, 0x01, 0x52, 0x07, 0x6c, 0x61, 0x6d, 0x70, 0x6f, 0x72, + 0x74, 0x22, 0x6e, 0x0a, 0x16, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x44, 0x6f, 0x63, 0x75, 0x6d, + 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, + 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x14, + 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x71, + 0x75, 0x65, 0x72, 0x79, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, + 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, + 0x65, 0x22, 0x74, 0x0a, 0x17, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x44, 0x6f, 0x63, 0x75, 0x6d, + 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1f, 0x0a, 0x0b, + 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, + 0x05, 0x52, 0x0a, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x38, 0x0a, + 0x09, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, + 0x32, 0x1a, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x63, + 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x52, 0x09, 0x64, 0x6f, + 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x22, 0xbd, 0x01, 0x0a, 0x12, 0x4c, 0x69, 0x73, 0x74, + 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, - 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x5f, 0x69, 0x64, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0a, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, - 0x49, 0x64, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, - 0x03, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, - 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x66, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x18, 0x04, 0x20, - 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x12, 0x29, - 0x0a, 0x10, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x5f, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, - 0x6f, 0x74, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x0f, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, - 0x65, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x22, 0x51, 0x0a, 0x15, 0x4c, 0x69, 0x73, - 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x12, 0x38, 0x0a, 0x09, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, - 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, - 0x79, 0x52, 0x09, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x22, 0x5a, 0x0a, 0x12, - 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x6e, 0x61, - 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, - 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, - 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x6f, 0x63, - 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x22, 0x4d, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x44, - 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, - 0x36, 0x0a, 0x08, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, - 0x0b, 0x32, 0x1a, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, - 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x52, 0x08, 0x64, - 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x22, 0x88, 0x01, 0x0a, 0x13, 0x47, 0x65, 0x74, 0x44, - 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, - 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, - 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, - 0x6d, 0x65, 0x12, 0x23, 0x0a, 0x0d, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x6b, - 0x65, 0x79, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x09, 0x52, 0x0c, 0x64, 0x6f, 0x63, 0x75, 0x6d, - 0x65, 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x73, 0x12, 0x29, 0x0a, 0x10, 0x69, 0x6e, 0x63, 0x6c, 0x75, - 0x64, 0x65, 0x5f, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x18, 0x03, 0x20, 0x01, 0x28, - 0x08, 0x52, 0x0f, 0x69, 0x6e, 0x63, 0x6c, 0x75, 0x64, 0x65, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, - 0x6f, 0x74, 0x22, 0x50, 0x0a, 0x14, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x38, 0x0a, 0x09, 0x64, 0x6f, - 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, - 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, - 0x6e, 0x74, 0x53, 0x75, 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x52, 0x09, 0x64, 0x6f, 0x63, 0x75, 0x6d, - 0x65, 0x6e, 0x74, 0x73, 0x22, 0x7a, 0x0a, 0x1c, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x6f, - 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x42, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x5f, - 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, - 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x64, 0x6f, 0x63, 0x75, 0x6d, - 0x65, 0x6e, 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, - 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x12, 0x14, 0x0a, 0x05, 0x66, 0x6f, - 0x72, 0x63, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x08, 0x52, 0x05, 0x66, 0x6f, 0x72, 0x63, 0x65, - 0x22, 0x1f, 0x0a, 0x1d, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, - 0x6e, 0x74, 0x42, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x81, 0x01, 0x0a, 0x16, 0x47, 0x65, 0x74, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, - 0x74, 0x4d, 0x65, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, - 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, - 0x21, 0x0a, 0x0c, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x18, - 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x4b, - 0x65, 0x79, 0x12, 0x21, 0x0a, 0x0a, 0x73, 0x65, 0x72, 0x76, 0x65, 0x72, 0x5f, 0x73, 0x65, 0x71, - 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x42, 0x02, 0x30, 0x01, 0x52, 0x09, 0x73, 0x65, 0x72, 0x76, - 0x65, 0x72, 0x53, 0x65, 0x71, 0x22, 0x53, 0x0a, 0x17, 0x47, 0x65, 0x74, 0x53, 0x6e, 0x61, 0x70, - 0x73, 0x68, 0x6f, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, - 0x12, 0x1a, 0x0a, 0x08, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x18, 0x01, 0x20, 0x01, - 0x28, 0x0c, 0x52, 0x08, 0x73, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x12, 0x1c, 0x0a, 0x07, - 0x6c, 0x61, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x18, 0x02, 0x20, 0x01, 0x28, 0x03, 0x42, 0x02, 0x30, - 0x01, 0x52, 0x07, 0x6c, 0x61, 0x6d, 0x70, 0x6f, 0x72, 0x74, 0x22, 0x6e, 0x0a, 0x16, 0x53, 0x65, - 0x61, 0x72, 0x63, 0x68, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x5f, - 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, 0x72, 0x6f, 0x6a, - 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, - 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x71, 0x75, 0x65, 0x72, 0x79, 0x12, 0x1b, 0x0a, - 0x09, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x03, 0x20, 0x01, 0x28, 0x05, - 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x22, 0x74, 0x0a, 0x17, 0x53, 0x65, - 0x61, 0x72, 0x63, 0x68, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x1f, 0x0a, 0x0b, 0x74, 0x6f, 0x74, 0x61, 0x6c, 0x5f, 0x63, - 0x6f, 0x75, 0x6e, 0x74, 0x18, 0x01, 0x20, 0x01, 0x28, 0x05, 0x52, 0x0a, 0x74, 0x6f, 0x74, 0x61, - 0x6c, 0x43, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x38, 0x0a, 0x09, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, - 0x6e, 0x74, 0x73, 0x18, 0x02, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x1a, 0x2e, 0x79, 0x6f, 0x72, 0x6b, - 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x53, 0x75, - 0x6d, 0x6d, 0x61, 0x72, 0x79, 0x52, 0x09, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, - 0x22, 0xbd, 0x01, 0x0a, 0x12, 0x4c, 0x69, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, - 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x12, 0x21, 0x0a, 0x0c, 0x70, 0x72, 0x6f, 0x6a, 0x65, - 0x63, 0x74, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x70, - 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x64, 0x6f, - 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x6b, 0x65, 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, - 0x52, 0x0b, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x4b, 0x65, 0x79, 0x12, 0x25, 0x0a, - 0x0c, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x5f, 0x73, 0x65, 0x71, 0x18, 0x03, 0x20, - 0x01, 0x28, 0x03, 0x42, 0x02, 0x30, 0x01, 0x52, 0x0b, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, - 0x73, 0x53, 0x65, 0x71, 0x12, 0x1b, 0x0a, 0x09, 0x70, 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, - 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, - 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x66, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x18, - 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, - 0x22, 0x42, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2b, 0x0a, 0x07, 0x63, 0x68, 0x61, 0x6e, 0x67, - 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, 0x11, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x52, 0x07, 0x63, 0x68, 0x61, - 0x6e, 0x67, 0x65, 0x73, 0x32, 0xc8, 0x08, 0x0a, 0x0c, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x53, 0x65, - 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x3f, 0x0a, 0x06, 0x53, 0x69, 0x67, 0x6e, 0x55, 0x70, 0x12, - 0x18, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x69, 0x67, 0x6e, - 0x55, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x19, 0x2e, 0x79, 0x6f, 0x72, 0x6b, - 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x55, 0x70, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3c, 0x0a, 0x05, 0x4c, 0x6f, 0x67, 0x49, 0x6e, 0x12, - 0x17, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x6f, 0x67, 0x49, - 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x18, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, - 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x6f, 0x67, 0x49, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, - 0x73, 0x65, 0x22, 0x00, 0x12, 0x54, 0x0a, 0x0d, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, - 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x1f, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x51, 0x0a, 0x0c, 0x4c, 0x69, - 0x73, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x12, 0x1e, 0x2e, 0x79, 0x6f, 0x72, - 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, - 0x63, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x79, 0x6f, 0x72, - 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, - 0x63, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4b, 0x0a, - 0x0a, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x1c, 0x2e, 0x79, 0x6f, - 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, - 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1d, 0x2e, 0x79, 0x6f, 0x72, 0x6b, - 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, - 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x54, 0x0a, 0x0d, 0x55, 0x70, - 0x64, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x1f, 0x2e, 0x79, 0x6f, - 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x72, + 0x65, 0x12, 0x21, 0x0a, 0x0c, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x5f, 0x6b, 0x65, + 0x79, 0x18, 0x02, 0x20, 0x01, 0x28, 0x09, 0x52, 0x0b, 0x64, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, + 0x74, 0x4b, 0x65, 0x79, 0x12, 0x25, 0x0a, 0x0c, 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, + 0x5f, 0x73, 0x65, 0x71, 0x18, 0x03, 0x20, 0x01, 0x28, 0x03, 0x42, 0x02, 0x30, 0x01, 0x52, 0x0b, + 0x70, 0x72, 0x65, 0x76, 0x69, 0x6f, 0x75, 0x73, 0x53, 0x65, 0x71, 0x12, 0x1b, 0x0a, 0x09, 0x70, + 0x61, 0x67, 0x65, 0x5f, 0x73, 0x69, 0x7a, 0x65, 0x18, 0x04, 0x20, 0x01, 0x28, 0x05, 0x52, 0x08, + 0x70, 0x61, 0x67, 0x65, 0x53, 0x69, 0x7a, 0x65, 0x12, 0x1d, 0x0a, 0x0a, 0x69, 0x73, 0x5f, 0x66, + 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x18, 0x05, 0x20, 0x01, 0x28, 0x08, 0x52, 0x09, 0x69, 0x73, + 0x46, 0x6f, 0x72, 0x77, 0x61, 0x72, 0x64, 0x22, 0x42, 0x0a, 0x13, 0x4c, 0x69, 0x73, 0x74, 0x43, + 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x12, 0x2b, + 0x0a, 0x07, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x18, 0x01, 0x20, 0x03, 0x28, 0x0b, 0x32, + 0x11, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x68, 0x61, 0x6e, + 0x67, 0x65, 0x52, 0x07, 0x63, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x32, 0xf7, 0x09, 0x0a, 0x0c, + 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x53, 0x65, 0x72, 0x76, 0x69, 0x63, 0x65, 0x12, 0x3f, 0x0a, 0x06, + 0x53, 0x69, 0x67, 0x6e, 0x55, 0x70, 0x12, 0x18, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x53, 0x69, 0x67, 0x6e, 0x55, 0x70, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x19, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x69, 0x67, + 0x6e, 0x55, 0x70, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x3c, 0x0a, + 0x05, 0x4c, 0x6f, 0x67, 0x49, 0x6e, 0x12, 0x17, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, + 0x76, 0x31, 0x2e, 0x4c, 0x6f, 0x67, 0x49, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x18, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x6f, 0x67, 0x49, + 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x54, 0x0a, 0x0d, 0x44, + 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x12, 0x1f, 0x2e, 0x79, + 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, 0x41, + 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, + 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x44, 0x65, 0x6c, 0x65, 0x74, 0x65, + 0x41, 0x63, 0x63, 0x6f, 0x75, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, + 0x00, 0x12, 0x57, 0x0a, 0x0e, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x61, 0x73, 0x73, 0x77, + 0x6f, 0x72, 0x64, 0x12, 0x20, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, 0x52, 0x65, + 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x21, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, + 0x31, 0x2e, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x50, 0x61, 0x73, 0x73, 0x77, 0x6f, 0x72, 0x64, + 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x54, 0x0a, 0x0d, 0x43, 0x72, + 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x12, 0x1f, 0x2e, 0x79, 0x6f, + 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x79, - 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, + 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x43, 0x72, 0x65, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, - 0x12, 0x54, 0x0a, 0x0d, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, - 0x73, 0x12, 0x1f, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, - 0x73, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, - 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, - 0x69, 0x73, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4e, 0x0a, 0x0b, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, - 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x1d, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, - 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, - 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, - 0x2e, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, - 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x51, 0x0a, 0x0c, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, - 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x1e, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, - 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, - 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x6c, 0x0a, 0x15, 0x52, 0x65, 0x6d, - 0x6f, 0x76, 0x65, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x42, 0x79, 0x41, 0x64, 0x6d, - 0x69, 0x6e, 0x12, 0x27, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, - 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x42, 0x79, 0x41, - 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x28, 0x2e, 0x79, 0x6f, - 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x6f, - 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x42, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x73, - 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x5a, 0x0a, 0x0f, 0x47, 0x65, 0x74, 0x53, 0x6e, - 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x12, 0x21, 0x2e, 0x79, 0x6f, 0x72, - 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, - 0x6f, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, - 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x53, 0x6e, 0x61, - 0x70, 0x73, 0x68, 0x6f, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, - 0x65, 0x22, 0x00, 0x12, 0x5a, 0x0a, 0x0f, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x44, 0x6f, 0x63, - 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x21, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, - 0x76, 0x31, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, - 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x79, 0x6f, 0x72, 0x6b, - 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x44, 0x6f, 0x63, 0x75, + 0x12, 0x51, 0x0a, 0x0c, 0x4c, 0x69, 0x73, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, + 0x12, 0x1e, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, + 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, + 0x1a, 0x1f, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, + 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, + 0x65, 0x22, 0x00, 0x12, 0x4b, 0x0a, 0x0a, 0x47, 0x65, 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, + 0x74, 0x12, 0x1c, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, + 0x74, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x1d, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x50, + 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, + 0x12, 0x54, 0x0a, 0x0d, 0x55, 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, + 0x74, 0x12, 0x1f, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, 0x70, + 0x64, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, + 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x55, + 0x70, 0x64, 0x61, 0x74, 0x65, 0x50, 0x72, 0x6f, 0x6a, 0x65, 0x63, 0x74, 0x52, 0x65, 0x73, 0x70, + 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x54, 0x0a, 0x0d, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x6f, + 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x1f, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, + 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, + 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x20, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, + 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4e, 0x0a, 0x0b, + 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x12, 0x1d, 0x2e, 0x79, 0x6f, + 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, + 0x65, 0x6e, 0x74, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x79, 0x6f, 0x72, + 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, + 0x6e, 0x74, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x51, 0x0a, 0x0c, + 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x1e, 0x2e, 0x79, + 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, + 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1f, 0x2e, 0x79, + 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, - 0x4e, 0x0a, 0x0b, 0x4c, 0x69, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x12, 0x1d, - 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x43, - 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, - 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x43, 0x68, - 0x61, 0x6e, 0x67, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, - 0x45, 0x0a, 0x11, 0x64, 0x65, 0x76, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x61, 0x70, - 0x69, 0x2e, 0x76, 0x31, 0x50, 0x01, 0x5a, 0x2e, 0x67, 0x69, 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, - 0x6f, 0x6d, 0x2f, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2d, 0x74, 0x65, 0x61, 0x6d, 0x2f, 0x79, - 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, - 0x2f, 0x76, 0x31, 0x3b, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x6c, 0x0a, 0x15, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, + 0x74, 0x42, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x12, 0x27, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, + 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x6f, 0x63, 0x75, 0x6d, + 0x65, 0x6e, 0x74, 0x42, 0x79, 0x41, 0x64, 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, + 0x74, 0x1a, 0x28, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x52, 0x65, + 0x6d, 0x6f, 0x76, 0x65, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x42, 0x79, 0x41, 0x64, + 0x6d, 0x69, 0x6e, 0x52, 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x5a, 0x0a, + 0x0f, 0x47, 0x65, 0x74, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x4d, 0x65, 0x74, 0x61, + 0x12, 0x21, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x47, 0x65, 0x74, + 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x22, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x47, 0x65, 0x74, 0x53, 0x6e, 0x61, 0x70, 0x73, 0x68, 0x6f, 0x74, 0x4d, 0x65, 0x74, 0x61, 0x52, + 0x65, 0x73, 0x70, 0x6f, 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x5a, 0x0a, 0x0f, 0x53, 0x65, 0x61, + 0x72, 0x63, 0x68, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x21, 0x2e, 0x79, + 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x65, 0x61, 0x72, 0x63, 0x68, 0x44, + 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x71, 0x75, 0x65, 0x73, 0x74, 0x1a, + 0x22, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, 0x53, 0x65, 0x61, 0x72, + 0x63, 0x68, 0x44, 0x6f, 0x63, 0x75, 0x6d, 0x65, 0x6e, 0x74, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x00, 0x12, 0x4e, 0x0a, 0x0b, 0x4c, 0x69, 0x73, 0x74, 0x43, 0x68, 0x61, + 0x6e, 0x67, 0x65, 0x73, 0x12, 0x1d, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, + 0x2e, 0x4c, 0x69, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x52, 0x65, 0x71, 0x75, + 0x65, 0x73, 0x74, 0x1a, 0x1e, 0x2e, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2e, 0x76, 0x31, 0x2e, + 0x4c, 0x69, 0x73, 0x74, 0x43, 0x68, 0x61, 0x6e, 0x67, 0x65, 0x73, 0x52, 0x65, 0x73, 0x70, 0x6f, + 0x6e, 0x73, 0x65, 0x22, 0x00, 0x42, 0x45, 0x0a, 0x11, 0x64, 0x65, 0x76, 0x2e, 0x79, 0x6f, 0x72, + 0x6b, 0x69, 0x65, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x76, 0x31, 0x50, 0x01, 0x5a, 0x2e, 0x67, 0x69, + 0x74, 0x68, 0x75, 0x62, 0x2e, 0x63, 0x6f, 0x6d, 0x2f, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2d, + 0x74, 0x65, 0x61, 0x6d, 0x2f, 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2f, 0x61, 0x70, 0x69, 0x2f, + 0x79, 0x6f, 0x72, 0x6b, 0x69, 0x65, 0x2f, 0x76, 0x31, 0x3b, 0x76, 0x31, 0x62, 0x06, 0x70, 0x72, + 0x6f, 0x74, 0x6f, 0x33, } var ( @@ -1651,80 +1873,88 @@ func file_yorkie_v1_admin_proto_rawDescGZIP() []byte { return file_yorkie_v1_admin_proto_rawDescData } -var file_yorkie_v1_admin_proto_msgTypes = make([]protoimpl.MessageInfo, 26) +var file_yorkie_v1_admin_proto_msgTypes = make([]protoimpl.MessageInfo, 30) var file_yorkie_v1_admin_proto_goTypes = []interface{}{ (*SignUpRequest)(nil), // 0: yorkie.v1.SignUpRequest (*SignUpResponse)(nil), // 1: yorkie.v1.SignUpResponse (*LogInRequest)(nil), // 2: yorkie.v1.LogInRequest (*LogInResponse)(nil), // 3: yorkie.v1.LogInResponse - (*CreateProjectRequest)(nil), // 4: yorkie.v1.CreateProjectRequest - (*CreateProjectResponse)(nil), // 5: yorkie.v1.CreateProjectResponse - (*GetProjectRequest)(nil), // 6: yorkie.v1.GetProjectRequest - (*GetProjectResponse)(nil), // 7: yorkie.v1.GetProjectResponse - (*ListProjectsRequest)(nil), // 8: yorkie.v1.ListProjectsRequest - (*ListProjectsResponse)(nil), // 9: yorkie.v1.ListProjectsResponse - (*UpdateProjectRequest)(nil), // 10: yorkie.v1.UpdateProjectRequest - (*UpdateProjectResponse)(nil), // 11: yorkie.v1.UpdateProjectResponse - (*ListDocumentsRequest)(nil), // 12: yorkie.v1.ListDocumentsRequest - (*ListDocumentsResponse)(nil), // 13: yorkie.v1.ListDocumentsResponse - (*GetDocumentRequest)(nil), // 14: yorkie.v1.GetDocumentRequest - (*GetDocumentResponse)(nil), // 15: yorkie.v1.GetDocumentResponse - (*GetDocumentsRequest)(nil), // 16: yorkie.v1.GetDocumentsRequest - (*GetDocumentsResponse)(nil), // 17: yorkie.v1.GetDocumentsResponse - (*RemoveDocumentByAdminRequest)(nil), // 18: yorkie.v1.RemoveDocumentByAdminRequest - (*RemoveDocumentByAdminResponse)(nil), // 19: yorkie.v1.RemoveDocumentByAdminResponse - (*GetSnapshotMetaRequest)(nil), // 20: yorkie.v1.GetSnapshotMetaRequest - (*GetSnapshotMetaResponse)(nil), // 21: yorkie.v1.GetSnapshotMetaResponse - (*SearchDocumentsRequest)(nil), // 22: yorkie.v1.SearchDocumentsRequest - (*SearchDocumentsResponse)(nil), // 23: yorkie.v1.SearchDocumentsResponse - (*ListChangesRequest)(nil), // 24: yorkie.v1.ListChangesRequest - (*ListChangesResponse)(nil), // 25: yorkie.v1.ListChangesResponse - (*User)(nil), // 26: yorkie.v1.User - (*Project)(nil), // 27: yorkie.v1.Project - (*UpdatableProjectFields)(nil), // 28: yorkie.v1.UpdatableProjectFields - (*DocumentSummary)(nil), // 29: yorkie.v1.DocumentSummary - (*Change)(nil), // 30: yorkie.v1.Change + (*DeleteAccountRequest)(nil), // 4: yorkie.v1.DeleteAccountRequest + (*DeleteAccountResponse)(nil), // 5: yorkie.v1.DeleteAccountResponse + (*ChangePasswordRequest)(nil), // 6: yorkie.v1.ChangePasswordRequest + (*ChangePasswordResponse)(nil), // 7: yorkie.v1.ChangePasswordResponse + (*CreateProjectRequest)(nil), // 8: yorkie.v1.CreateProjectRequest + (*CreateProjectResponse)(nil), // 9: yorkie.v1.CreateProjectResponse + (*GetProjectRequest)(nil), // 10: yorkie.v1.GetProjectRequest + (*GetProjectResponse)(nil), // 11: yorkie.v1.GetProjectResponse + (*ListProjectsRequest)(nil), // 12: yorkie.v1.ListProjectsRequest + (*ListProjectsResponse)(nil), // 13: yorkie.v1.ListProjectsResponse + (*UpdateProjectRequest)(nil), // 14: yorkie.v1.UpdateProjectRequest + (*UpdateProjectResponse)(nil), // 15: yorkie.v1.UpdateProjectResponse + (*ListDocumentsRequest)(nil), // 16: yorkie.v1.ListDocumentsRequest + (*ListDocumentsResponse)(nil), // 17: yorkie.v1.ListDocumentsResponse + (*GetDocumentRequest)(nil), // 18: yorkie.v1.GetDocumentRequest + (*GetDocumentResponse)(nil), // 19: yorkie.v1.GetDocumentResponse + (*GetDocumentsRequest)(nil), // 20: yorkie.v1.GetDocumentsRequest + (*GetDocumentsResponse)(nil), // 21: yorkie.v1.GetDocumentsResponse + (*RemoveDocumentByAdminRequest)(nil), // 22: yorkie.v1.RemoveDocumentByAdminRequest + (*RemoveDocumentByAdminResponse)(nil), // 23: yorkie.v1.RemoveDocumentByAdminResponse + (*GetSnapshotMetaRequest)(nil), // 24: yorkie.v1.GetSnapshotMetaRequest + (*GetSnapshotMetaResponse)(nil), // 25: yorkie.v1.GetSnapshotMetaResponse + (*SearchDocumentsRequest)(nil), // 26: yorkie.v1.SearchDocumentsRequest + (*SearchDocumentsResponse)(nil), // 27: yorkie.v1.SearchDocumentsResponse + (*ListChangesRequest)(nil), // 28: yorkie.v1.ListChangesRequest + (*ListChangesResponse)(nil), // 29: yorkie.v1.ListChangesResponse + (*User)(nil), // 30: yorkie.v1.User + (*Project)(nil), // 31: yorkie.v1.Project + (*UpdatableProjectFields)(nil), // 32: yorkie.v1.UpdatableProjectFields + (*DocumentSummary)(nil), // 33: yorkie.v1.DocumentSummary + (*Change)(nil), // 34: yorkie.v1.Change } var file_yorkie_v1_admin_proto_depIdxs = []int32{ - 26, // 0: yorkie.v1.SignUpResponse.user:type_name -> yorkie.v1.User - 27, // 1: yorkie.v1.CreateProjectResponse.project:type_name -> yorkie.v1.Project - 27, // 2: yorkie.v1.GetProjectResponse.project:type_name -> yorkie.v1.Project - 27, // 3: yorkie.v1.ListProjectsResponse.projects:type_name -> yorkie.v1.Project - 28, // 4: yorkie.v1.UpdateProjectRequest.fields:type_name -> yorkie.v1.UpdatableProjectFields - 27, // 5: yorkie.v1.UpdateProjectResponse.project:type_name -> yorkie.v1.Project - 29, // 6: yorkie.v1.ListDocumentsResponse.documents:type_name -> yorkie.v1.DocumentSummary - 29, // 7: yorkie.v1.GetDocumentResponse.document:type_name -> yorkie.v1.DocumentSummary - 29, // 8: yorkie.v1.GetDocumentsResponse.documents:type_name -> yorkie.v1.DocumentSummary - 29, // 9: yorkie.v1.SearchDocumentsResponse.documents:type_name -> yorkie.v1.DocumentSummary - 30, // 10: yorkie.v1.ListChangesResponse.changes:type_name -> yorkie.v1.Change + 30, // 0: yorkie.v1.SignUpResponse.user:type_name -> yorkie.v1.User + 31, // 1: yorkie.v1.CreateProjectResponse.project:type_name -> yorkie.v1.Project + 31, // 2: yorkie.v1.GetProjectResponse.project:type_name -> yorkie.v1.Project + 31, // 3: yorkie.v1.ListProjectsResponse.projects:type_name -> yorkie.v1.Project + 32, // 4: yorkie.v1.UpdateProjectRequest.fields:type_name -> yorkie.v1.UpdatableProjectFields + 31, // 5: yorkie.v1.UpdateProjectResponse.project:type_name -> yorkie.v1.Project + 33, // 6: yorkie.v1.ListDocumentsResponse.documents:type_name -> yorkie.v1.DocumentSummary + 33, // 7: yorkie.v1.GetDocumentResponse.document:type_name -> yorkie.v1.DocumentSummary + 33, // 8: yorkie.v1.GetDocumentsResponse.documents:type_name -> yorkie.v1.DocumentSummary + 33, // 9: yorkie.v1.SearchDocumentsResponse.documents:type_name -> yorkie.v1.DocumentSummary + 34, // 10: yorkie.v1.ListChangesResponse.changes:type_name -> yorkie.v1.Change 0, // 11: yorkie.v1.AdminService.SignUp:input_type -> yorkie.v1.SignUpRequest 2, // 12: yorkie.v1.AdminService.LogIn:input_type -> yorkie.v1.LogInRequest - 4, // 13: yorkie.v1.AdminService.CreateProject:input_type -> yorkie.v1.CreateProjectRequest - 8, // 14: yorkie.v1.AdminService.ListProjects:input_type -> yorkie.v1.ListProjectsRequest - 6, // 15: yorkie.v1.AdminService.GetProject:input_type -> yorkie.v1.GetProjectRequest - 10, // 16: yorkie.v1.AdminService.UpdateProject:input_type -> yorkie.v1.UpdateProjectRequest - 12, // 17: yorkie.v1.AdminService.ListDocuments:input_type -> yorkie.v1.ListDocumentsRequest - 14, // 18: yorkie.v1.AdminService.GetDocument:input_type -> yorkie.v1.GetDocumentRequest - 16, // 19: yorkie.v1.AdminService.GetDocuments:input_type -> yorkie.v1.GetDocumentsRequest - 18, // 20: yorkie.v1.AdminService.RemoveDocumentByAdmin:input_type -> yorkie.v1.RemoveDocumentByAdminRequest - 20, // 21: yorkie.v1.AdminService.GetSnapshotMeta:input_type -> yorkie.v1.GetSnapshotMetaRequest - 22, // 22: yorkie.v1.AdminService.SearchDocuments:input_type -> yorkie.v1.SearchDocumentsRequest - 24, // 23: yorkie.v1.AdminService.ListChanges:input_type -> yorkie.v1.ListChangesRequest - 1, // 24: yorkie.v1.AdminService.SignUp:output_type -> yorkie.v1.SignUpResponse - 3, // 25: yorkie.v1.AdminService.LogIn:output_type -> yorkie.v1.LogInResponse - 5, // 26: yorkie.v1.AdminService.CreateProject:output_type -> yorkie.v1.CreateProjectResponse - 9, // 27: yorkie.v1.AdminService.ListProjects:output_type -> yorkie.v1.ListProjectsResponse - 7, // 28: yorkie.v1.AdminService.GetProject:output_type -> yorkie.v1.GetProjectResponse - 11, // 29: yorkie.v1.AdminService.UpdateProject:output_type -> yorkie.v1.UpdateProjectResponse - 13, // 30: yorkie.v1.AdminService.ListDocuments:output_type -> yorkie.v1.ListDocumentsResponse - 15, // 31: yorkie.v1.AdminService.GetDocument:output_type -> yorkie.v1.GetDocumentResponse - 17, // 32: yorkie.v1.AdminService.GetDocuments:output_type -> yorkie.v1.GetDocumentsResponse - 19, // 33: yorkie.v1.AdminService.RemoveDocumentByAdmin:output_type -> yorkie.v1.RemoveDocumentByAdminResponse - 21, // 34: yorkie.v1.AdminService.GetSnapshotMeta:output_type -> yorkie.v1.GetSnapshotMetaResponse - 23, // 35: yorkie.v1.AdminService.SearchDocuments:output_type -> yorkie.v1.SearchDocumentsResponse - 25, // 36: yorkie.v1.AdminService.ListChanges:output_type -> yorkie.v1.ListChangesResponse - 24, // [24:37] is the sub-list for method output_type - 11, // [11:24] is the sub-list for method input_type + 4, // 13: yorkie.v1.AdminService.DeleteAccount:input_type -> yorkie.v1.DeleteAccountRequest + 6, // 14: yorkie.v1.AdminService.ChangePassword:input_type -> yorkie.v1.ChangePasswordRequest + 8, // 15: yorkie.v1.AdminService.CreateProject:input_type -> yorkie.v1.CreateProjectRequest + 12, // 16: yorkie.v1.AdminService.ListProjects:input_type -> yorkie.v1.ListProjectsRequest + 10, // 17: yorkie.v1.AdminService.GetProject:input_type -> yorkie.v1.GetProjectRequest + 14, // 18: yorkie.v1.AdminService.UpdateProject:input_type -> yorkie.v1.UpdateProjectRequest + 16, // 19: yorkie.v1.AdminService.ListDocuments:input_type -> yorkie.v1.ListDocumentsRequest + 18, // 20: yorkie.v1.AdminService.GetDocument:input_type -> yorkie.v1.GetDocumentRequest + 20, // 21: yorkie.v1.AdminService.GetDocuments:input_type -> yorkie.v1.GetDocumentsRequest + 22, // 22: yorkie.v1.AdminService.RemoveDocumentByAdmin:input_type -> yorkie.v1.RemoveDocumentByAdminRequest + 24, // 23: yorkie.v1.AdminService.GetSnapshotMeta:input_type -> yorkie.v1.GetSnapshotMetaRequest + 26, // 24: yorkie.v1.AdminService.SearchDocuments:input_type -> yorkie.v1.SearchDocumentsRequest + 28, // 25: yorkie.v1.AdminService.ListChanges:input_type -> yorkie.v1.ListChangesRequest + 1, // 26: yorkie.v1.AdminService.SignUp:output_type -> yorkie.v1.SignUpResponse + 3, // 27: yorkie.v1.AdminService.LogIn:output_type -> yorkie.v1.LogInResponse + 5, // 28: yorkie.v1.AdminService.DeleteAccount:output_type -> yorkie.v1.DeleteAccountResponse + 7, // 29: yorkie.v1.AdminService.ChangePassword:output_type -> yorkie.v1.ChangePasswordResponse + 9, // 30: yorkie.v1.AdminService.CreateProject:output_type -> yorkie.v1.CreateProjectResponse + 13, // 31: yorkie.v1.AdminService.ListProjects:output_type -> yorkie.v1.ListProjectsResponse + 11, // 32: yorkie.v1.AdminService.GetProject:output_type -> yorkie.v1.GetProjectResponse + 15, // 33: yorkie.v1.AdminService.UpdateProject:output_type -> yorkie.v1.UpdateProjectResponse + 17, // 34: yorkie.v1.AdminService.ListDocuments:output_type -> yorkie.v1.ListDocumentsResponse + 19, // 35: yorkie.v1.AdminService.GetDocument:output_type -> yorkie.v1.GetDocumentResponse + 21, // 36: yorkie.v1.AdminService.GetDocuments:output_type -> yorkie.v1.GetDocumentsResponse + 23, // 37: yorkie.v1.AdminService.RemoveDocumentByAdmin:output_type -> yorkie.v1.RemoveDocumentByAdminResponse + 25, // 38: yorkie.v1.AdminService.GetSnapshotMeta:output_type -> yorkie.v1.GetSnapshotMetaResponse + 27, // 39: yorkie.v1.AdminService.SearchDocuments:output_type -> yorkie.v1.SearchDocumentsResponse + 29, // 40: yorkie.v1.AdminService.ListChanges:output_type -> yorkie.v1.ListChangesResponse + 26, // [26:41] is the sub-list for method output_type + 11, // [11:26] is the sub-list for method input_type 11, // [11:11] is the sub-list for extension type_name 11, // [11:11] is the sub-list for extension extendee 0, // [0:11] is the sub-list for field type_name @@ -1786,7 +2016,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[4].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CreateProjectRequest); i { + switch v := v.(*DeleteAccountRequest); i { case 0: return &v.state case 1: @@ -1798,7 +2028,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[5].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*CreateProjectResponse); i { + switch v := v.(*DeleteAccountResponse); i { case 0: return &v.state case 1: @@ -1810,7 +2040,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[6].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetProjectRequest); i { + switch v := v.(*ChangePasswordRequest); i { case 0: return &v.state case 1: @@ -1822,7 +2052,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[7].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetProjectResponse); i { + switch v := v.(*ChangePasswordResponse); i { case 0: return &v.state case 1: @@ -1834,7 +2064,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[8].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListProjectsRequest); i { + switch v := v.(*CreateProjectRequest); i { case 0: return &v.state case 1: @@ -1846,7 +2076,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[9].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListProjectsResponse); i { + switch v := v.(*CreateProjectResponse); i { case 0: return &v.state case 1: @@ -1858,7 +2088,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[10].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UpdateProjectRequest); i { + switch v := v.(*GetProjectRequest); i { case 0: return &v.state case 1: @@ -1870,7 +2100,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[11].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*UpdateProjectResponse); i { + switch v := v.(*GetProjectResponse); i { case 0: return &v.state case 1: @@ -1882,7 +2112,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[12].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListDocumentsRequest); i { + switch v := v.(*ListProjectsRequest); i { case 0: return &v.state case 1: @@ -1894,7 +2124,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[13].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListDocumentsResponse); i { + switch v := v.(*ListProjectsResponse); i { case 0: return &v.state case 1: @@ -1906,7 +2136,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[14].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetDocumentRequest); i { + switch v := v.(*UpdateProjectRequest); i { case 0: return &v.state case 1: @@ -1918,7 +2148,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[15].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetDocumentResponse); i { + switch v := v.(*UpdateProjectResponse); i { case 0: return &v.state case 1: @@ -1930,7 +2160,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[16].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetDocumentsRequest); i { + switch v := v.(*ListDocumentsRequest); i { case 0: return &v.state case 1: @@ -1942,7 +2172,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[17].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetDocumentsResponse); i { + switch v := v.(*ListDocumentsResponse); i { case 0: return &v.state case 1: @@ -1954,7 +2184,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[18].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RemoveDocumentByAdminRequest); i { + switch v := v.(*GetDocumentRequest); i { case 0: return &v.state case 1: @@ -1966,7 +2196,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[19].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*RemoveDocumentByAdminResponse); i { + switch v := v.(*GetDocumentResponse); i { case 0: return &v.state case 1: @@ -1978,7 +2208,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[20].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetSnapshotMetaRequest); i { + switch v := v.(*GetDocumentsRequest); i { case 0: return &v.state case 1: @@ -1990,7 +2220,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[21].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*GetSnapshotMetaResponse); i { + switch v := v.(*GetDocumentsResponse); i { case 0: return &v.state case 1: @@ -2002,7 +2232,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[22].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SearchDocumentsRequest); i { + switch v := v.(*RemoveDocumentByAdminRequest); i { case 0: return &v.state case 1: @@ -2014,7 +2244,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[23].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*SearchDocumentsResponse); i { + switch v := v.(*RemoveDocumentByAdminResponse); i { case 0: return &v.state case 1: @@ -2026,7 +2256,7 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[24].Exporter = func(v interface{}, i int) interface{} { - switch v := v.(*ListChangesRequest); i { + switch v := v.(*GetSnapshotMetaRequest); i { case 0: return &v.state case 1: @@ -2038,6 +2268,54 @@ func file_yorkie_v1_admin_proto_init() { } } file_yorkie_v1_admin_proto_msgTypes[25].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*GetSnapshotMetaResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_yorkie_v1_admin_proto_msgTypes[26].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*SearchDocumentsRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_yorkie_v1_admin_proto_msgTypes[27].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*SearchDocumentsResponse); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_yorkie_v1_admin_proto_msgTypes[28].Exporter = func(v interface{}, i int) interface{} { + switch v := v.(*ListChangesRequest); i { + case 0: + return &v.state + case 1: + return &v.sizeCache + case 2: + return &v.unknownFields + default: + return nil + } + } + file_yorkie_v1_admin_proto_msgTypes[29].Exporter = func(v interface{}, i int) interface{} { switch v := v.(*ListChangesResponse); i { case 0: return &v.state @@ -2056,7 +2334,7 @@ func file_yorkie_v1_admin_proto_init() { GoPackagePath: reflect.TypeOf(x{}).PkgPath(), RawDescriptor: file_yorkie_v1_admin_proto_rawDesc, NumEnums: 0, - NumMessages: 26, + NumMessages: 30, NumExtensions: 0, NumServices: 1, }, diff --git a/api/yorkie/v1/admin.proto b/api/yorkie/v1/admin.proto index a9956afdc..9162e787f 100644 --- a/api/yorkie/v1/admin.proto +++ b/api/yorkie/v1/admin.proto @@ -28,6 +28,8 @@ option java_package = "dev.yorkie.api.v1"; service AdminService { rpc SignUp(SignUpRequest) returns (SignUpResponse) {} rpc LogIn(LogInRequest) returns (LogInResponse) {} + rpc DeleteAccount(DeleteAccountRequest) returns (DeleteAccountResponse) {} + rpc ChangePassword(ChangePasswordRequest) returns (ChangePasswordResponse) {} rpc CreateProject(CreateProjectRequest) returns (CreateProjectResponse) {} rpc ListProjects(ListProjectsRequest) returns (ListProjectsResponse) {} @@ -62,6 +64,23 @@ message LogInResponse { string token = 1; } +message DeleteAccountRequest { + string username = 1; + string password = 2; +} + +message DeleteAccountResponse { +} + +message ChangePasswordRequest { + string username = 1; + string current_password = 2; + string new_password = 3; +} + +message ChangePasswordResponse { +} + message CreateProjectRequest { string name = 1; } diff --git a/api/yorkie/v1/v1connect/admin.connect.go b/api/yorkie/v1/v1connect/admin.connect.go index f3d5bb4d6..84f412d65 100644 --- a/api/yorkie/v1/v1connect/admin.connect.go +++ b/api/yorkie/v1/v1connect/admin.connect.go @@ -52,6 +52,12 @@ const ( AdminServiceSignUpProcedure = "/yorkie.v1.AdminService/SignUp" // AdminServiceLogInProcedure is the fully-qualified name of the AdminService's LogIn RPC. AdminServiceLogInProcedure = "/yorkie.v1.AdminService/LogIn" + // AdminServiceDeleteAccountProcedure is the fully-qualified name of the AdminService's + // DeleteAccount RPC. + AdminServiceDeleteAccountProcedure = "/yorkie.v1.AdminService/DeleteAccount" + // AdminServiceChangePasswordProcedure is the fully-qualified name of the AdminService's + // ChangePassword RPC. + AdminServiceChangePasswordProcedure = "/yorkie.v1.AdminService/ChangePassword" // AdminServiceCreateProjectProcedure is the fully-qualified name of the AdminService's // CreateProject RPC. AdminServiceCreateProjectProcedure = "/yorkie.v1.AdminService/CreateProject" @@ -90,6 +96,8 @@ const ( type AdminServiceClient interface { SignUp(context.Context, *connect.Request[v1.SignUpRequest]) (*connect.Response[v1.SignUpResponse], error) LogIn(context.Context, *connect.Request[v1.LogInRequest]) (*connect.Response[v1.LogInResponse], error) + DeleteAccount(context.Context, *connect.Request[v1.DeleteAccountRequest]) (*connect.Response[v1.DeleteAccountResponse], error) + ChangePassword(context.Context, *connect.Request[v1.ChangePasswordRequest]) (*connect.Response[v1.ChangePasswordResponse], error) CreateProject(context.Context, *connect.Request[v1.CreateProjectRequest]) (*connect.Response[v1.CreateProjectResponse], error) ListProjects(context.Context, *connect.Request[v1.ListProjectsRequest]) (*connect.Response[v1.ListProjectsResponse], error) GetProject(context.Context, *connect.Request[v1.GetProjectRequest]) (*connect.Response[v1.GetProjectResponse], error) @@ -123,6 +131,16 @@ func NewAdminServiceClient(httpClient connect.HTTPClient, baseURL string, opts . baseURL+AdminServiceLogInProcedure, opts..., ), + deleteAccount: connect.NewClient[v1.DeleteAccountRequest, v1.DeleteAccountResponse]( + httpClient, + baseURL+AdminServiceDeleteAccountProcedure, + opts..., + ), + changePassword: connect.NewClient[v1.ChangePasswordRequest, v1.ChangePasswordResponse]( + httpClient, + baseURL+AdminServiceChangePasswordProcedure, + opts..., + ), createProject: connect.NewClient[v1.CreateProjectRequest, v1.CreateProjectResponse]( httpClient, baseURL+AdminServiceCreateProjectProcedure, @@ -185,6 +203,8 @@ func NewAdminServiceClient(httpClient connect.HTTPClient, baseURL string, opts . type adminServiceClient struct { signUp *connect.Client[v1.SignUpRequest, v1.SignUpResponse] logIn *connect.Client[v1.LogInRequest, v1.LogInResponse] + deleteAccount *connect.Client[v1.DeleteAccountRequest, v1.DeleteAccountResponse] + changePassword *connect.Client[v1.ChangePasswordRequest, v1.ChangePasswordResponse] createProject *connect.Client[v1.CreateProjectRequest, v1.CreateProjectResponse] listProjects *connect.Client[v1.ListProjectsRequest, v1.ListProjectsResponse] getProject *connect.Client[v1.GetProjectRequest, v1.GetProjectResponse] @@ -208,6 +228,16 @@ func (c *adminServiceClient) LogIn(ctx context.Context, req *connect.Request[v1. return c.logIn.CallUnary(ctx, req) } +// DeleteAccount calls yorkie.v1.AdminService.DeleteAccount. +func (c *adminServiceClient) DeleteAccount(ctx context.Context, req *connect.Request[v1.DeleteAccountRequest]) (*connect.Response[v1.DeleteAccountResponse], error) { + return c.deleteAccount.CallUnary(ctx, req) +} + +// ChangePassword calls yorkie.v1.AdminService.ChangePassword. +func (c *adminServiceClient) ChangePassword(ctx context.Context, req *connect.Request[v1.ChangePasswordRequest]) (*connect.Response[v1.ChangePasswordResponse], error) { + return c.changePassword.CallUnary(ctx, req) +} + // CreateProject calls yorkie.v1.AdminService.CreateProject. func (c *adminServiceClient) CreateProject(ctx context.Context, req *connect.Request[v1.CreateProjectRequest]) (*connect.Response[v1.CreateProjectResponse], error) { return c.createProject.CallUnary(ctx, req) @@ -267,6 +297,8 @@ func (c *adminServiceClient) ListChanges(ctx context.Context, req *connect.Reque type AdminServiceHandler interface { SignUp(context.Context, *connect.Request[v1.SignUpRequest]) (*connect.Response[v1.SignUpResponse], error) LogIn(context.Context, *connect.Request[v1.LogInRequest]) (*connect.Response[v1.LogInResponse], error) + DeleteAccount(context.Context, *connect.Request[v1.DeleteAccountRequest]) (*connect.Response[v1.DeleteAccountResponse], error) + ChangePassword(context.Context, *connect.Request[v1.ChangePasswordRequest]) (*connect.Response[v1.ChangePasswordResponse], error) CreateProject(context.Context, *connect.Request[v1.CreateProjectRequest]) (*connect.Response[v1.CreateProjectResponse], error) ListProjects(context.Context, *connect.Request[v1.ListProjectsRequest]) (*connect.Response[v1.ListProjectsResponse], error) GetProject(context.Context, *connect.Request[v1.GetProjectRequest]) (*connect.Response[v1.GetProjectResponse], error) @@ -296,6 +328,16 @@ func NewAdminServiceHandler(svc AdminServiceHandler, opts ...connect.HandlerOpti svc.LogIn, opts..., ) + adminServiceDeleteAccountHandler := connect.NewUnaryHandler( + AdminServiceDeleteAccountProcedure, + svc.DeleteAccount, + opts..., + ) + adminServiceChangePasswordHandler := connect.NewUnaryHandler( + AdminServiceChangePasswordProcedure, + svc.ChangePassword, + opts..., + ) adminServiceCreateProjectHandler := connect.NewUnaryHandler( AdminServiceCreateProjectProcedure, svc.CreateProject, @@ -357,6 +399,10 @@ func NewAdminServiceHandler(svc AdminServiceHandler, opts ...connect.HandlerOpti adminServiceSignUpHandler.ServeHTTP(w, r) case AdminServiceLogInProcedure: adminServiceLogInHandler.ServeHTTP(w, r) + case AdminServiceDeleteAccountProcedure: + adminServiceDeleteAccountHandler.ServeHTTP(w, r) + case AdminServiceChangePasswordProcedure: + adminServiceChangePasswordHandler.ServeHTTP(w, r) case AdminServiceCreateProjectProcedure: adminServiceCreateProjectHandler.ServeHTTP(w, r) case AdminServiceListProjectsProcedure: @@ -396,6 +442,14 @@ func (UnimplementedAdminServiceHandler) LogIn(context.Context, *connect.Request[ return nil, connect.NewError(connect.CodeUnimplemented, errors.New("yorkie.v1.AdminService.LogIn is not implemented")) } +func (UnimplementedAdminServiceHandler) DeleteAccount(context.Context, *connect.Request[v1.DeleteAccountRequest]) (*connect.Response[v1.DeleteAccountResponse], error) { + return nil, connect.NewError(connect.CodeUnimplemented, errors.New("yorkie.v1.AdminService.DeleteAccount is not implemented")) +} + +func (UnimplementedAdminServiceHandler) ChangePassword(context.Context, *connect.Request[v1.ChangePasswordRequest]) (*connect.Response[v1.ChangePasswordResponse], error) { + return nil, connect.NewError(connect.CodeUnimplemented, errors.New("yorkie.v1.AdminService.ChangePassword is not implemented")) +} + func (UnimplementedAdminServiceHandler) CreateProject(context.Context, *connect.Request[v1.CreateProjectRequest]) (*connect.Response[v1.CreateProjectResponse], error) { return nil, connect.NewError(connect.CodeUnimplemented, errors.New("yorkie.v1.AdminService.CreateProject is not implemented")) } diff --git a/server/backend/database/database.go b/server/backend/database/database.go index b038d098e..a47fae723 100644 --- a/server/backend/database/database.go +++ b/server/backend/database/database.go @@ -143,6 +143,12 @@ type Database interface { // after handling PushPull. UpdateClientInfoAfterPushPull(ctx context.Context, clientInfo *ClientInfo, docInfo *DocInfo) error + // DeleteUserInfoByName deletes a user by name. + DeleteUserInfoByName(ctx context.Context, username string) error + + // ChangePassword changes to new password. + ChangePassword(ctx context.Context, username, hashedNewPassword string) error + // FindNextNCyclingProjectInfos finds the next N cycling projects from the given projectID. FindNextNCyclingProjectInfos( ctx context.Context, diff --git a/server/backend/database/memory/database.go b/server/backend/database/memory/database.go index 9d4e9f8ee..a9c373fd1 100644 --- a/server/backend/database/memory/database.go +++ b/server/backend/database/memory/database.go @@ -627,6 +627,50 @@ func (d *DB) UpdateClientInfoAfterPushPull( return nil } +// DeleteUserInfoByName deletes a user by name. +func (d *DB) DeleteUserInfoByName(_ context.Context, username string) error { + txn := d.db.Txn(true) + defer txn.Abort() + + raw, err := txn.First(tblUsers, "username", username) + if err != nil || raw == nil { + return fmt.Errorf("find user by username: %w", err) + } + + info := raw.(*database.UserInfo).DeepCopy() + if err = txn.Delete(tblUsers, info); err != nil { + return fmt.Errorf("delete account %s: %w", info.ID, err) + } + + txn.Commit() + return nil +} + +// ChangePassword changes to new password. +func (d *DB) ChangePassword(_ context.Context, username, newPassword string) error { + txn := d.db.Txn(true) + defer txn.Abort() + + raw, err := txn.First(tblUsers, "username", username) + if err != nil || raw == nil { + return fmt.Errorf("find user by username: %w", err) + } + + hashedPassword, err := database.HashedPassword(newPassword) + if err != nil { + return err + } + info := raw.(*database.UserInfo).DeepCopy() + info.HashedPassword = hashedPassword + if err := txn.Insert(tblUsers, info); err != nil { + return fmt.Errorf("change password user: %w", err) + } + + txn.Commit() + + return nil +} + // FindDeactivateCandidatesPerProject finds the clients that need housekeeping per project. func (d *DB) FindDeactivateCandidatesPerProject( _ context.Context, diff --git a/server/backend/database/mongo/client.go b/server/backend/database/mongo/client.go index e5b0db867..6cdec4963 100644 --- a/server/backend/database/mongo/client.go +++ b/server/backend/database/mongo/client.go @@ -643,6 +643,35 @@ func (c *Client) UpdateClientInfoAfterPushPull( return nil } +// DeleteUserInfoByName deletes a user by name. +func (c *Client) DeleteUserInfoByName(ctx context.Context, username string) error { + deleteResult, err := c.collection(ColUsers).DeleteOne(ctx, bson.M{ + "username": username, + }) + if err != nil { + return err + } + if deleteResult.DeletedCount == 0 { + return fmt.Errorf("nothing has been deleted") + } + return nil +} + +// ChangePassword changes to new password. +func (c *Client) ChangePassword(ctx context.Context, username, hashedNewPassword string) error { + updateResult, err := c.collection(ColUsers).UpdateOne(ctx, + bson.M{"username": username}, + bson.M{"$set": bson.M{"hashed_password": hashedNewPassword}}, + ) + if err != nil { + return err + } + if updateResult.ModifiedCount == 0 { + return fmt.Errorf("nothing has been updated") + } + return nil +} + // FindDeactivateCandidatesPerProject finds the clients that need housekeeping per project. func (c *Client) FindDeactivateCandidatesPerProject( ctx context.Context, diff --git a/server/rpc/admin_server.go b/server/rpc/admin_server.go index 9f44d6b6f..ce7894f4f 100644 --- a/server/rpc/admin_server.go +++ b/server/rpc/admin_server.go @@ -95,6 +95,57 @@ func (s *adminServer) LogIn( }), nil } +// DeleteAccount deletes a user. +func (s *adminServer) DeleteAccount( + ctx context.Context, + req *connect.Request[api.DeleteAccountRequest], +) (*connect.Response[api.DeleteAccountResponse], error) { + user, err := users.IsCorrectPassword( + ctx, + s.backend, + req.Msg.Username, + req.Msg.Password, + ) + if err != nil { + return nil, err + } + + err = users.DeleteAccountByName(ctx, s.backend, user.Username) + if err != nil { + return nil, err + } + + return connect.NewResponse(&api.DeleteAccountResponse{}), nil +} + +// ChangePassword changes to new password. +func (s *adminServer) ChangePassword( + ctx context.Context, + req *connect.Request[api.ChangePasswordRequest], +) (*connect.Response[api.ChangePasswordResponse], error) { + fields := &types.SignupFields{Username: &req.Msg.Username, Password: &req.Msg.NewPassword} + if err := fields.Validate(); err != nil { + return nil, err + } + + user, err := users.IsCorrectPassword( + ctx, + s.backend, + req.Msg.Username, + req.Msg.CurrentPassword, + ) + if err != nil { + return nil, err + } + + err = users.ChangePassword(ctx, s.backend, user.Username, req.Msg.NewPassword) + if err != nil { + return nil, err + } + + return connect.NewResponse(&api.ChangePasswordResponse{}), nil +} + // CreateProject creates a new project. func (s *adminServer) CreateProject( ctx context.Context, diff --git a/server/rpc/interceptors/admin.go b/server/rpc/interceptors/admin.go index 1f6ab5373..ee59f4734 100644 --- a/server/rpc/interceptors/admin.go +++ b/server/rpc/interceptors/admin.go @@ -42,7 +42,9 @@ func isAdminService(method string) bool { func isRequiredAuth(method string) bool { return method != "/yorkie.v1.AdminService/LogIn" && - method != "/yorkie.v1.AdminService/SignUp" + method != "/yorkie.v1.AdminService/SignUp" && + method != "/yorkie.v1.AdminService/ChangePassword" && + method != "/yorkie.v1.AdminService/DeleteAccount" } // AdminServiceInterceptor is an interceptor for building additional context diff --git a/server/users/users.go b/server/users/users.go index e4adc6a66..58f11ddc9 100644 --- a/server/users/users.go +++ b/server/users/users.go @@ -94,3 +94,35 @@ func GetUserByID( } return info.ToUser(), nil } + +// DeleteAccountByName deletes a user by name. +func DeleteAccountByName( + ctx context.Context, + be *backend.Backend, + username string, +) error { + if err := be.DB.DeleteUserInfoByName(ctx, username); err != nil { + return err + } + + return nil +} + +// ChangePassword deletes a user by name. +func ChangePassword( + ctx context.Context, + be *backend.Backend, + username, + newPassword string, +) error { + hashedNewPassword, err := database.HashedPassword(newPassword) + if err != nil { + return fmt.Errorf("cannot hash newPassword: %w", err) + } + + if err := be.DB.ChangePassword(ctx, username, hashedNewPassword); err != nil { + return err + } + + return nil +} From f7164d3c92f6bc315168a73733ec19ea7a097229 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sat, 20 Jul 2024 16:32:53 +0900 Subject: [PATCH 02/13] signup_fields-> user_fields & add ChangePasswordFields renamed the signup_fields file that does the validation to user_fields to equalize the validation for the user, and I added ChangePasswordFields, with a comment saying that it should have the same validation as signup. --- api/types/{signup_fields.go => user_fields.go} | 16 ++++++++++++++++ ...signup_fields_test.go => user_fields_test.go} | 0 server/rpc/admin_server.go | 2 +- 3 files changed, 17 insertions(+), 1 deletion(-) rename api/types/{signup_fields.go => user_fields.go} (66%) rename api/types/{signup_fields_test.go => user_fields_test.go} (100%) diff --git a/api/types/signup_fields.go b/api/types/user_fields.go similarity index 66% rename from api/types/signup_fields.go rename to api/types/user_fields.go index 7c2769680..8782d3f99 100644 --- a/api/types/signup_fields.go +++ b/api/types/user_fields.go @@ -22,6 +22,7 @@ import ( ) // SignupFields is a set of fields that use to sign up to yorkie server. +// // must be same with [ChangePasswordFields]. type SignupFields struct { // Username is the name of user. Username *string `bson:"username" validate:"required,min=2,max=30,slug"` @@ -34,3 +35,18 @@ type SignupFields struct { func (i *SignupFields) Validate() error { return validation.ValidateStruct(i) } + +// ChangePasswordFields is a set of fields that use to change password to yorkie server. +// must be same with [SignupFields]. +type ChangePasswordFields struct { + // Username is the name of user. + Username *string `bson:"username" validate:"required,min=2,max=30,slug"` + + // NewPassword is the new password of user + NewPassword *string `bson:"new_password" validate:"required,min=8,max=30,alpha_num_special"` +} + +// Validate validates the ChangePasswordFields. +func (i *ChangePasswordFields) Validate() error { + return validation.ValidateStruct(i) +} diff --git a/api/types/signup_fields_test.go b/api/types/user_fields_test.go similarity index 100% rename from api/types/signup_fields_test.go rename to api/types/user_fields_test.go diff --git a/server/rpc/admin_server.go b/server/rpc/admin_server.go index ce7894f4f..743992f94 100644 --- a/server/rpc/admin_server.go +++ b/server/rpc/admin_server.go @@ -123,7 +123,7 @@ func (s *adminServer) ChangePassword( ctx context.Context, req *connect.Request[api.ChangePasswordRequest], ) (*connect.Response[api.ChangePasswordResponse], error) { - fields := &types.SignupFields{Username: &req.Msg.Username, Password: &req.Msg.NewPassword} + fields := &types.ChangePasswordFields{Username: &req.Msg.Username, NewPassword: &req.Msg.NewPassword} if err := fields.Validate(); err != nil { return nil, err } From a956fbaf28398b1a2f31e8c4799d549f123dd199 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sat, 20 Jul 2024 16:41:19 +0900 Subject: [PATCH 03/13] bug fix to hash password one more time in memoryDB --- server/backend/database/memory/database.go | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/server/backend/database/memory/database.go b/server/backend/database/memory/database.go index a9c373fd1..b61010914 100644 --- a/server/backend/database/memory/database.go +++ b/server/backend/database/memory/database.go @@ -647,7 +647,7 @@ func (d *DB) DeleteUserInfoByName(_ context.Context, username string) error { } // ChangePassword changes to new password. -func (d *DB) ChangePassword(_ context.Context, username, newPassword string) error { +func (d *DB) ChangePassword(_ context.Context, username, hashedNewPassword string) error { txn := d.db.Txn(true) defer txn.Abort() @@ -656,12 +656,8 @@ func (d *DB) ChangePassword(_ context.Context, username, newPassword string) err return fmt.Errorf("find user by username: %w", err) } - hashedPassword, err := database.HashedPassword(newPassword) - if err != nil { - return err - } info := raw.(*database.UserInfo).DeepCopy() - info.HashedPassword = hashedPassword + info.HashedPassword = hashedNewPassword if err := txn.Insert(tblUsers, info); err != nil { return fmt.Errorf("change password user: %w", err) } From a83675647fd0df55d85f8ad38add7854261e00d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sun, 21 Jul 2024 08:57:10 +0900 Subject: [PATCH 04/13] Update coderabbitai's review --- server/backend/database/memory/database.go | 10 ++++++++-- server/users/users.go | 2 +- 2 files changed, 9 insertions(+), 3 deletions(-) diff --git a/server/backend/database/memory/database.go b/server/backend/database/memory/database.go index b61010914..687ae53dc 100644 --- a/server/backend/database/memory/database.go +++ b/server/backend/database/memory/database.go @@ -633,9 +633,12 @@ func (d *DB) DeleteUserInfoByName(_ context.Context, username string) error { defer txn.Abort() raw, err := txn.First(tblUsers, "username", username) - if err != nil || raw == nil { + if err != nil { return fmt.Errorf("find user by username: %w", err) } + if raw == nil { + return fmt.Errorf("%s: %w", username, database.ErrUserNotFound) + } info := raw.(*database.UserInfo).DeepCopy() if err = txn.Delete(tblUsers, info); err != nil { @@ -652,9 +655,12 @@ func (d *DB) ChangePassword(_ context.Context, username, hashedNewPassword strin defer txn.Abort() raw, err := txn.First(tblUsers, "username", username) - if err != nil || raw == nil { + if err != nil { return fmt.Errorf("find user by username: %w", err) } + if raw == nil { + return fmt.Errorf("%s: %w", username, database.ErrUserNotFound) + } info := raw.(*database.UserInfo).DeepCopy() info.HashedPassword = hashedNewPassword diff --git a/server/users/users.go b/server/users/users.go index 58f11ddc9..98f2661da 100644 --- a/server/users/users.go +++ b/server/users/users.go @@ -108,7 +108,7 @@ func DeleteAccountByName( return nil } -// ChangePassword deletes a user by name. +// ChangePassword changes the password for a user. func ChangePassword( ctx context.Context, be *backend.Backend, From 9fec94a75bfe9973bda2cf2f22b0ac69f06b93de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sun, 21 Jul 2024 08:58:06 +0900 Subject: [PATCH 05/13] Combine validation in SignUp and ChangePassword --- api/types/user_fields.go | 24 ++++-------------------- api/types/user_fields_test.go | 16 ++++++++-------- server/rpc/admin_server.go | 4 ++-- 3 files changed, 14 insertions(+), 30 deletions(-) diff --git a/api/types/user_fields.go b/api/types/user_fields.go index 8782d3f99..3175c224b 100644 --- a/api/types/user_fields.go +++ b/api/types/user_fields.go @@ -21,9 +21,8 @@ import ( "github.com/yorkie-team/yorkie/internal/validation" ) -// SignupFields is a set of fields that use to sign up to yorkie server. -// // must be same with [ChangePasswordFields]. -type SignupFields struct { +// UserFields is a set of fields that use to sign up or change password to yorkie server. +type UserFields struct { // Username is the name of user. Username *string `bson:"username" validate:"required,min=2,max=30,slug"` @@ -31,22 +30,7 @@ type SignupFields struct { Password *string `bson:"password" validate:"required,min=8,max=30,alpha_num_special"` } -// Validate validates the SignupFields. -func (i *SignupFields) Validate() error { - return validation.ValidateStruct(i) -} - -// ChangePasswordFields is a set of fields that use to change password to yorkie server. -// must be same with [SignupFields]. -type ChangePasswordFields struct { - // Username is the name of user. - Username *string `bson:"username" validate:"required,min=2,max=30,slug"` - - // NewPassword is the new password of user - NewPassword *string `bson:"new_password" validate:"required,min=8,max=30,alpha_num_special"` -} - -// Validate validates the ChangePasswordFields. -func (i *ChangePasswordFields) Validate() error { +// Validate validates the UserFields. +func (i *UserFields) Validate() error { return validation.ValidateStruct(i) } diff --git a/api/types/user_fields_test.go b/api/types/user_fields_test.go index 19c1862f6..15e30339a 100644 --- a/api/types/user_fields_test.go +++ b/api/types/user_fields_test.go @@ -31,56 +31,56 @@ func TestSignupFields(t *testing.T) { t.Run("password validation test", func(t *testing.T) { validUsername := "test" validPassword := "pass123!" - fields := &types.SignupFields{ + fields := &types.UserFields{ Username: &validUsername, Password: &validPassword, } assert.NoError(t, fields.Validate()) invalidPassword := "1234" - fields = &types.SignupFields{ + fields = &types.UserFields{ Username: &validUsername, Password: &invalidPassword, } assert.ErrorAs(t, fields.Validate(), &structError) invalidPassword = "abcd" - fields = &types.SignupFields{ + fields = &types.UserFields{ Username: &validUsername, Password: &invalidPassword, } assert.ErrorAs(t, fields.Validate(), &structError) invalidPassword = "!@#$" - fields = &types.SignupFields{ + fields = &types.UserFields{ Username: &validUsername, Password: &invalidPassword, } assert.ErrorAs(t, fields.Validate(), &structError) invalidPassword = "abcd1234" - fields = &types.SignupFields{ + fields = &types.UserFields{ Username: &validUsername, Password: &invalidPassword, } assert.ErrorAs(t, fields.Validate(), &structError) invalidPassword = "abcd!@#$" - fields = &types.SignupFields{ + fields = &types.UserFields{ Username: &validUsername, Password: &invalidPassword, } assert.ErrorAs(t, fields.Validate(), &structError) invalidPassword = "1234!@#$" - fields = &types.SignupFields{ + fields = &types.UserFields{ Username: &validUsername, Password: &invalidPassword, } assert.ErrorAs(t, fields.Validate(), &structError) invalidPassword = "abcd1234!@abcd1234!@abcd1234!@1" - fields = &types.SignupFields{ + fields = &types.UserFields{ Username: &validUsername, Password: &invalidPassword, } diff --git a/server/rpc/admin_server.go b/server/rpc/admin_server.go index 743992f94..9352eed63 100644 --- a/server/rpc/admin_server.go +++ b/server/rpc/admin_server.go @@ -55,7 +55,7 @@ func (s *adminServer) SignUp( ctx context.Context, req *connect.Request[api.SignUpRequest], ) (*connect.Response[api.SignUpResponse], error) { - fields := &types.SignupFields{Username: &req.Msg.Username, Password: &req.Msg.Password} + fields := &types.UserFields{Username: &req.Msg.Username, Password: &req.Msg.Password} if err := fields.Validate(); err != nil { return nil, err } @@ -123,7 +123,7 @@ func (s *adminServer) ChangePassword( ctx context.Context, req *connect.Request[api.ChangePasswordRequest], ) (*connect.Response[api.ChangePasswordResponse], error) { - fields := &types.ChangePasswordFields{Username: &req.Msg.Username, NewPassword: &req.Msg.NewPassword} + fields := &types.UserFields{Username: &req.Msg.Username, Password: &req.Msg.NewPassword} if err := fields.Validate(); err != nil { return nil, err } From a9b274a6c6139ae0970410caa95efb393e0c5e37 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sun, 21 Jul 2024 09:15:00 +0900 Subject: [PATCH 06/13] Move admin actions near User related functions --- server/backend/database/memory/database.go | 92 +++++++++++----------- 1 file changed, 46 insertions(+), 46 deletions(-) diff --git a/server/backend/database/memory/database.go b/server/backend/database/memory/database.go index 687ae53dc..13a10aea2 100644 --- a/server/backend/database/memory/database.go +++ b/server/backend/database/memory/database.go @@ -402,6 +402,52 @@ func (d *DB) CreateUserInfo( return info, nil } +// DeleteUserInfoByName deletes a user by name. +func (d *DB) DeleteUserInfoByName(_ context.Context, username string) error { + txn := d.db.Txn(true) + defer txn.Abort() + + raw, err := txn.First(tblUsers, "username", username) + if err != nil { + return fmt.Errorf("find user by username: %w", err) + } + if raw == nil { + return fmt.Errorf("%s: %w", username, database.ErrUserNotFound) + } + + info := raw.(*database.UserInfo).DeepCopy() + if err = txn.Delete(tblUsers, info); err != nil { + return fmt.Errorf("delete account %s: %w", info.ID, err) + } + + txn.Commit() + return nil +} + +// ChangePassword changes to new password. +func (d *DB) ChangePassword(_ context.Context, username, hashedNewPassword string) error { + txn := d.db.Txn(true) + defer txn.Abort() + + raw, err := txn.First(tblUsers, "username", username) + if err != nil { + return fmt.Errorf("find user by username: %w", err) + } + if raw == nil { + return fmt.Errorf("%s: %w", username, database.ErrUserNotFound) + } + + info := raw.(*database.UserInfo).DeepCopy() + info.HashedPassword = hashedNewPassword + if err := txn.Insert(tblUsers, info); err != nil { + return fmt.Errorf("change password user: %w", err) + } + + txn.Commit() + + return nil +} + // FindUserInfoByID finds a user by the given ID. func (d *DB) FindUserInfoByID(_ context.Context, clientID types.ID) (*database.UserInfo, error) { txn := d.db.Txn(false) @@ -627,52 +673,6 @@ func (d *DB) UpdateClientInfoAfterPushPull( return nil } -// DeleteUserInfoByName deletes a user by name. -func (d *DB) DeleteUserInfoByName(_ context.Context, username string) error { - txn := d.db.Txn(true) - defer txn.Abort() - - raw, err := txn.First(tblUsers, "username", username) - if err != nil { - return fmt.Errorf("find user by username: %w", err) - } - if raw == nil { - return fmt.Errorf("%s: %w", username, database.ErrUserNotFound) - } - - info := raw.(*database.UserInfo).DeepCopy() - if err = txn.Delete(tblUsers, info); err != nil { - return fmt.Errorf("delete account %s: %w", info.ID, err) - } - - txn.Commit() - return nil -} - -// ChangePassword changes to new password. -func (d *DB) ChangePassword(_ context.Context, username, hashedNewPassword string) error { - txn := d.db.Txn(true) - defer txn.Abort() - - raw, err := txn.First(tblUsers, "username", username) - if err != nil { - return fmt.Errorf("find user by username: %w", err) - } - if raw == nil { - return fmt.Errorf("%s: %w", username, database.ErrUserNotFound) - } - - info := raw.(*database.UserInfo).DeepCopy() - info.HashedPassword = hashedNewPassword - if err := txn.Insert(tblUsers, info); err != nil { - return fmt.Errorf("change password user: %w", err) - } - - txn.Commit() - - return nil -} - // FindDeactivateCandidatesPerProject finds the clients that need housekeeping per project. func (d *DB) FindDeactivateCandidatesPerProject( _ context.Context, From a91d852baa5749b39c003abd5747713dada8d497 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sun, 21 Jul 2024 16:12:33 +0900 Subject: [PATCH 07/13] Consistent error messages --- server/backend/database/mongo/client.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/server/backend/database/mongo/client.go b/server/backend/database/mongo/client.go index 6cdec4963..62522e472 100644 --- a/server/backend/database/mongo/client.go +++ b/server/backend/database/mongo/client.go @@ -652,7 +652,7 @@ func (c *Client) DeleteUserInfoByName(ctx context.Context, username string) erro return err } if deleteResult.DeletedCount == 0 { - return fmt.Errorf("nothing has been deleted") + return fmt.Errorf("no user found with username %s", username) } return nil } @@ -667,7 +667,7 @@ func (c *Client) ChangePassword(ctx context.Context, username, hashedNewPassword return err } if updateResult.ModifiedCount == 0 { - return fmt.Errorf("nothing has been updated") + return fmt.Errorf("no user found with username %s", username) } return nil } From 78d1dae6f5516988265d7af76ec9ebcfe51e1105 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sun, 21 Jul 2024 17:09:16 +0900 Subject: [PATCH 08/13] Add test cases for ChangeUserPassword, DeleteUser --- server/rpc/server_test.go | 8 +++ server/rpc/testcases/testcases.go | 107 ++++++++++++++++++++++++++++++ 2 files changed, 115 insertions(+) diff --git a/server/rpc/server_test.go b/server/rpc/server_test.go index 4d85aff93..a786af035 100644 --- a/server/rpc/server_test.go +++ b/server/rpc/server_test.go @@ -183,6 +183,14 @@ func TestAdminRPCServerBackend(t *testing.T) { testcases.RunAdminLoginTest(t, testAdminClient) }) + t.Run("admin delete user test", func(t *testing.T) { + testcases.RunAdminDeleteUserTest(t, testAdminClient) + }) + + t.Run("admin change password test", func(t *testing.T) { + testcases.RunAdminChangePasswordTest(t, testAdminClient) + }) + t.Run("admin create project test", func(t *testing.T) { testcases.RunAdminCreateProjectTest(t, testAdminClient, testAdminAuthInterceptor) }) diff --git a/server/rpc/testcases/testcases.go b/server/rpc/testcases/testcases.go index 3094ae7dd..cf39b605e 100644 --- a/server/rpc/testcases/testcases.go +++ b/server/rpc/testcases/testcases.go @@ -693,6 +693,113 @@ func RunAdminLoginTest( assert.Equal(t, connecthelper.CodeOf(database.ErrMismatchedPassword), converter.ErrorCodeOf(err)) } +// RunAdminDeleteUserTest runs the admin delete user test. +func RunAdminDeleteUserTest( + t *testing.T, + testAdminClient v1connect.AdminServiceClient, +) { + adminUser := helper.TestSlugName(t) + adminPassword := helper.AdminPassword + "123!" + + _, err := testAdminClient.CreateUser( + context.Background(), + connect.NewRequest(&api.CreateUserRequest{ + Username: adminUser, + Password: adminPassword, + }, + )) + assert.NoError(t, err) + + _, err = testAdminClient.DeleteUser( + context.Background(), + connect.NewRequest(&api.DeleteUserRequest{ + Username: adminUser, + Password: adminPassword, + }, + )) + assert.NoError(t, err) + + // try to delete user with not existing username + _, err = testAdminClient.DeleteUser( + context.Background(), + connect.NewRequest(&api.DeleteUserRequest{ + Username: adminUser, + Password: adminPassword, + }, + )) + assert.Equal(t, connect.CodeNotFound, connect.CodeOf(err)) + assert.Equal(t, connecthelper.CodeOf(database.ErrUserNotFound), converter.ErrorCodeOf(err)) +} + +// RunAdminChangePasswordTest runs the admin change password user test. +func RunAdminChangePasswordTest( + t *testing.T, + testAdminClient v1connect.AdminServiceClient, +) { + adminUser := helper.TestSlugName(t) + adminPassword := helper.AdminPassword + "123!" + + _, err := testAdminClient.CreateUser( + context.Background(), + connect.NewRequest(&api.CreateUserRequest{ + Username: adminUser, + Password: adminPassword, + }, + )) + assert.NoError(t, err) + + _, err = testAdminClient.LogIn( + context.Background(), + connect.NewRequest(&api.LogInRequest{ + Username: adminUser, + Password: adminPassword, + }, + )) + assert.NoError(t, err) + + newAdminPassword := helper.AdminPassword + "12345!" + _, err = testAdminClient.ChangeUserPassword( + context.Background(), + connect.NewRequest(&api.ChangeUserPasswordRequest{ + Username: adminUser, + CurrentPassword: adminPassword, + NewPassword: newAdminPassword, + }, + )) + assert.NoError(t, err) + + // log in fail when try to log in with old password + _, err = testAdminClient.LogIn( + context.Background(), + connect.NewRequest(&api.LogInRequest{ + Username: adminUser, + Password: adminPassword, + }, + )) + assert.Equal(t, connect.CodeUnauthenticated, connect.CodeOf(err)) + assert.Equal(t, connecthelper.CodeOf(database.ErrMismatchedPassword), converter.ErrorCodeOf(err)) + + _, err = testAdminClient.LogIn( + context.Background(), + connect.NewRequest(&api.LogInRequest{ + Username: adminUser, + Password: newAdminPassword, + }, + )) + assert.NoError(t, err) + + // try to change password with invalid password + _, err = testAdminClient.ChangeUserPassword( + context.Background(), + connect.NewRequest(&api.ChangeUserPasswordRequest{ + Username: adminUser, + CurrentPassword: adminPassword, + NewPassword: invalidSlugName, + }, + )) + assert.Equal(t, connect.CodeInvalidArgument, connect.CodeOf(err)) +} + // RunAdminCreateProjectTest runs the CreateProject test in admin. func RunAdminCreateProjectTest( t *testing.T, From ce0c91529d14c5a4067f0bf09ceb71ebcb8a51a6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sun, 21 Jul 2024 17:14:52 +0900 Subject: [PATCH 09/13] Constantizing duplicate values --- server/rpc/testcases/testcases.go | 6 +++--- test/helper/helper.go | 1 + 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/server/rpc/testcases/testcases.go b/server/rpc/testcases/testcases.go index cf39b605e..45a37f81d 100644 --- a/server/rpc/testcases/testcases.go +++ b/server/rpc/testcases/testcases.go @@ -644,7 +644,7 @@ func RunAdminSignUpTest( testAdminClient v1connect.AdminServiceClient, ) { adminUser := helper.TestSlugName(t) - adminPassword := helper.AdminPassword + "123!" + adminPassword := helper.AdminPasswordForCreateUser _, err := testAdminClient.SignUp( context.Background(), @@ -699,7 +699,7 @@ func RunAdminDeleteUserTest( testAdminClient v1connect.AdminServiceClient, ) { adminUser := helper.TestSlugName(t) - adminPassword := helper.AdminPassword + "123!" + adminPassword := helper.AdminPasswordForCreateUser _, err := testAdminClient.CreateUser( context.Background(), @@ -737,7 +737,7 @@ func RunAdminChangePasswordTest( testAdminClient v1connect.AdminServiceClient, ) { adminUser := helper.TestSlugName(t) - adminPassword := helper.AdminPassword + "123!" + adminPassword := helper.AdminPasswordForCreateUser _, err := testAdminClient.CreateUser( context.Background(), diff --git a/test/helper/helper.go b/test/helper/helper.go index 223d89718..9790f525e 100644 --- a/test/helper/helper.go +++ b/test/helper/helper.go @@ -64,6 +64,7 @@ var ( AdminUser = server.DefaultAdminUser AdminPassword = server.DefaultAdminPassword + AdminPasswordForCreateUser = AdminPassword + "123!" UseDefaultProject = true HousekeepingInterval = 10 * gotime.Second HousekeepingCandidatesLimitPerProject = 10 From a77400f1d8ea28e0af4f6a4f17660ad3305a7c5f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Tue, 23 Jul 2024 21:44:42 +0900 Subject: [PATCH 10/13] Move admin actions near User related functions # Conflicts: # server/backend/database/database.go # server/backend/database/mongo/client.go --- server/backend/database/database.go | 12 ++--- server/backend/database/mongo/client.go | 58 ++++++++++++------------- 2 files changed, 35 insertions(+), 35 deletions(-) diff --git a/server/backend/database/database.go b/server/backend/database/database.go index a47fae723..4c45b1378 100644 --- a/server/backend/database/database.go +++ b/server/backend/database/database.go @@ -121,6 +121,12 @@ type Database interface { hashedPassword string, ) (*UserInfo, error) + // DeleteUserInfoByName deletes a user by name. + DeleteUserInfoByName(ctx context.Context, username string) error + + // ChangeUserPassword changes to new password for user. + ChangeUserPassword(ctx context.Context, username, hashedNewPassword string) error + // FindUserInfoByID returns a user by the given ID. FindUserInfoByID(ctx context.Context, id types.ID) (*UserInfo, error) @@ -143,12 +149,6 @@ type Database interface { // after handling PushPull. UpdateClientInfoAfterPushPull(ctx context.Context, clientInfo *ClientInfo, docInfo *DocInfo) error - // DeleteUserInfoByName deletes a user by name. - DeleteUserInfoByName(ctx context.Context, username string) error - - // ChangePassword changes to new password. - ChangePassword(ctx context.Context, username, hashedNewPassword string) error - // FindNextNCyclingProjectInfos finds the next N cycling projects from the given projectID. FindNextNCyclingProjectInfos( ctx context.Context, diff --git a/server/backend/database/mongo/client.go b/server/backend/database/mongo/client.go index 62522e472..3d65ff029 100644 --- a/server/backend/database/mongo/client.go +++ b/server/backend/database/mongo/client.go @@ -428,6 +428,35 @@ func (c *Client) CreateUserInfo( return info, nil } +// DeleteUserInfoByName deletes a user by name. +func (c *Client) DeleteUserInfoByName(ctx context.Context, username string) error { + deleteResult, err := c.collection(ColUsers).DeleteOne(ctx, bson.M{ + "username": username, + }) + if err != nil { + return err + } + if deleteResult.DeletedCount == 0 { + return fmt.Errorf("no user found with username %s", username) + } + return nil +} + +// ChangeUserPassword changes to new password for user. +func (c *Client) ChangeUserPassword(ctx context.Context, username, hashedNewPassword string) error { + updateResult, err := c.collection(ColUsers).UpdateOne(ctx, + bson.M{"username": username}, + bson.M{"$set": bson.M{"hashed_password": hashedNewPassword}}, + ) + if err != nil { + return err + } + if updateResult.ModifiedCount == 0 { + return fmt.Errorf("no user found with username %s", username) + } + return nil +} + // FindUserInfoByID returns a user by ID. func (c *Client) FindUserInfoByID(ctx context.Context, clientID types.ID) (*database.UserInfo, error) { result := c.collection(ColUsers).FindOne(ctx, bson.M{ @@ -643,35 +672,6 @@ func (c *Client) UpdateClientInfoAfterPushPull( return nil } -// DeleteUserInfoByName deletes a user by name. -func (c *Client) DeleteUserInfoByName(ctx context.Context, username string) error { - deleteResult, err := c.collection(ColUsers).DeleteOne(ctx, bson.M{ - "username": username, - }) - if err != nil { - return err - } - if deleteResult.DeletedCount == 0 { - return fmt.Errorf("no user found with username %s", username) - } - return nil -} - -// ChangePassword changes to new password. -func (c *Client) ChangePassword(ctx context.Context, username, hashedNewPassword string) error { - updateResult, err := c.collection(ColUsers).UpdateOne(ctx, - bson.M{"username": username}, - bson.M{"$set": bson.M{"hashed_password": hashedNewPassword}}, - ) - if err != nil { - return err - } - if updateResult.ModifiedCount == 0 { - return fmt.Errorf("no user found with username %s", username) - } - return nil -} - // FindDeactivateCandidatesPerProject finds the clients that need housekeeping per project. func (c *Client) FindDeactivateCandidatesPerProject( ctx context.Context, From ddfdff5bdc32db512b3dfba72f97558aac08cca6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sat, 27 Jul 2024 13:46:34 +0900 Subject: [PATCH 11/13] Fix the problem that occurred during the cherry-pick process --- server/backend/database/database.go | 4 +-- server/backend/database/mongo/client.go | 4 +-- server/rpc/server_test.go | 4 +-- server/rpc/testcases/testcases.go | 34 ++++++++++++------------- test/helper/helper.go | 2 +- 5 files changed, 24 insertions(+), 24 deletions(-) diff --git a/server/backend/database/database.go b/server/backend/database/database.go index 4c45b1378..5f6354c0e 100644 --- a/server/backend/database/database.go +++ b/server/backend/database/database.go @@ -124,8 +124,8 @@ type Database interface { // DeleteUserInfoByName deletes a user by name. DeleteUserInfoByName(ctx context.Context, username string) error - // ChangeUserPassword changes to new password for user. - ChangeUserPassword(ctx context.Context, username, hashedNewPassword string) error + // ChangePassword changes to new password for user. + ChangePassword(ctx context.Context, username, hashedNewPassword string) error // FindUserInfoByID returns a user by the given ID. FindUserInfoByID(ctx context.Context, id types.ID) (*UserInfo, error) diff --git a/server/backend/database/mongo/client.go b/server/backend/database/mongo/client.go index 3d65ff029..293a2379c 100644 --- a/server/backend/database/mongo/client.go +++ b/server/backend/database/mongo/client.go @@ -442,8 +442,8 @@ func (c *Client) DeleteUserInfoByName(ctx context.Context, username string) erro return nil } -// ChangeUserPassword changes to new password for user. -func (c *Client) ChangeUserPassword(ctx context.Context, username, hashedNewPassword string) error { +// ChangePassword changes to new password for user. +func (c *Client) ChangePassword(ctx context.Context, username, hashedNewPassword string) error { updateResult, err := c.collection(ColUsers).UpdateOne(ctx, bson.M{"username": username}, bson.M{"$set": bson.M{"hashed_password": hashedNewPassword}}, diff --git a/server/rpc/server_test.go b/server/rpc/server_test.go index a786af035..1d0976882 100644 --- a/server/rpc/server_test.go +++ b/server/rpc/server_test.go @@ -183,8 +183,8 @@ func TestAdminRPCServerBackend(t *testing.T) { testcases.RunAdminLoginTest(t, testAdminClient) }) - t.Run("admin delete user test", func(t *testing.T) { - testcases.RunAdminDeleteUserTest(t, testAdminClient) + t.Run("admin delete account test", func(t *testing.T) { + testcases.RunAdminDeleteAccountTest(t, testAdminClient) }) t.Run("admin change password test", func(t *testing.T) { diff --git a/server/rpc/testcases/testcases.go b/server/rpc/testcases/testcases.go index 45a37f81d..004f42c58 100644 --- a/server/rpc/testcases/testcases.go +++ b/server/rpc/testcases/testcases.go @@ -644,7 +644,7 @@ func RunAdminSignUpTest( testAdminClient v1connect.AdminServiceClient, ) { adminUser := helper.TestSlugName(t) - adminPassword := helper.AdminPasswordForCreateUser + adminPassword := helper.AdminPasswordForSignUp _, err := testAdminClient.SignUp( context.Background(), @@ -693,26 +693,26 @@ func RunAdminLoginTest( assert.Equal(t, connecthelper.CodeOf(database.ErrMismatchedPassword), converter.ErrorCodeOf(err)) } -// RunAdminDeleteUserTest runs the admin delete user test. -func RunAdminDeleteUserTest( +// RunAdminDeleteAccountTest runs the admin delete user test. +func RunAdminDeleteAccountTest( t *testing.T, testAdminClient v1connect.AdminServiceClient, ) { adminUser := helper.TestSlugName(t) - adminPassword := helper.AdminPasswordForCreateUser + adminPassword := helper.AdminPasswordForSignUp - _, err := testAdminClient.CreateUser( + _, err := testAdminClient.SignUp( context.Background(), - connect.NewRequest(&api.CreateUserRequest{ + connect.NewRequest(&api.SignUpRequest{ Username: adminUser, Password: adminPassword, }, )) assert.NoError(t, err) - _, err = testAdminClient.DeleteUser( + _, err = testAdminClient.DeleteAccount( context.Background(), - connect.NewRequest(&api.DeleteUserRequest{ + connect.NewRequest(&api.DeleteAccountRequest{ Username: adminUser, Password: adminPassword, }, @@ -720,9 +720,9 @@ func RunAdminDeleteUserTest( assert.NoError(t, err) // try to delete user with not existing username - _, err = testAdminClient.DeleteUser( + _, err = testAdminClient.DeleteAccount( context.Background(), - connect.NewRequest(&api.DeleteUserRequest{ + connect.NewRequest(&api.DeleteAccountRequest{ Username: adminUser, Password: adminPassword, }, @@ -737,11 +737,11 @@ func RunAdminChangePasswordTest( testAdminClient v1connect.AdminServiceClient, ) { adminUser := helper.TestSlugName(t) - adminPassword := helper.AdminPasswordForCreateUser + adminPassword := helper.AdminPasswordForSignUp - _, err := testAdminClient.CreateUser( + _, err := testAdminClient.SignUp( context.Background(), - connect.NewRequest(&api.CreateUserRequest{ + connect.NewRequest(&api.SignUpRequest{ Username: adminUser, Password: adminPassword, }, @@ -758,9 +758,9 @@ func RunAdminChangePasswordTest( assert.NoError(t, err) newAdminPassword := helper.AdminPassword + "12345!" - _, err = testAdminClient.ChangeUserPassword( + _, err = testAdminClient.ChangePassword( context.Background(), - connect.NewRequest(&api.ChangeUserPasswordRequest{ + connect.NewRequest(&api.ChangePasswordRequest{ Username: adminUser, CurrentPassword: adminPassword, NewPassword: newAdminPassword, @@ -789,9 +789,9 @@ func RunAdminChangePasswordTest( assert.NoError(t, err) // try to change password with invalid password - _, err = testAdminClient.ChangeUserPassword( + _, err = testAdminClient.ChangePassword( context.Background(), - connect.NewRequest(&api.ChangeUserPasswordRequest{ + connect.NewRequest(&api.ChangePasswordRequest{ Username: adminUser, CurrentPassword: adminPassword, NewPassword: invalidSlugName, diff --git a/test/helper/helper.go b/test/helper/helper.go index 9790f525e..346074c52 100644 --- a/test/helper/helper.go +++ b/test/helper/helper.go @@ -64,7 +64,7 @@ var ( AdminUser = server.DefaultAdminUser AdminPassword = server.DefaultAdminPassword - AdminPasswordForCreateUser = AdminPassword + "123!" + AdminPasswordForSignUp = AdminPassword + "123!" UseDefaultProject = true HousekeepingInterval = 10 * gotime.Second HousekeepingCandidatesLimitPerProject = 10 From 7022723793c9fcbf06ae961820a898bd4a2ab19b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sat, 27 Jul 2024 13:58:04 +0900 Subject: [PATCH 12/13] Method name change ChangePassword -> ChangeUserPassword --- server/backend/database/database.go | 4 ++-- server/backend/database/memory/database.go | 4 ++-- server/backend/database/mongo/client.go | 4 ++-- server/users/users.go | 2 +- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/server/backend/database/database.go b/server/backend/database/database.go index 5f6354c0e..4c45b1378 100644 --- a/server/backend/database/database.go +++ b/server/backend/database/database.go @@ -124,8 +124,8 @@ type Database interface { // DeleteUserInfoByName deletes a user by name. DeleteUserInfoByName(ctx context.Context, username string) error - // ChangePassword changes to new password for user. - ChangePassword(ctx context.Context, username, hashedNewPassword string) error + // ChangeUserPassword changes to new password for user. + ChangeUserPassword(ctx context.Context, username, hashedNewPassword string) error // FindUserInfoByID returns a user by the given ID. FindUserInfoByID(ctx context.Context, id types.ID) (*UserInfo, error) diff --git a/server/backend/database/memory/database.go b/server/backend/database/memory/database.go index 13a10aea2..08b2b1364 100644 --- a/server/backend/database/memory/database.go +++ b/server/backend/database/memory/database.go @@ -424,8 +424,8 @@ func (d *DB) DeleteUserInfoByName(_ context.Context, username string) error { return nil } -// ChangePassword changes to new password. -func (d *DB) ChangePassword(_ context.Context, username, hashedNewPassword string) error { +// ChangeUserPassword changes to new password. +func (d *DB) ChangeUserPassword(_ context.Context, username, hashedNewPassword string) error { txn := d.db.Txn(true) defer txn.Abort() diff --git a/server/backend/database/mongo/client.go b/server/backend/database/mongo/client.go index 293a2379c..3d65ff029 100644 --- a/server/backend/database/mongo/client.go +++ b/server/backend/database/mongo/client.go @@ -442,8 +442,8 @@ func (c *Client) DeleteUserInfoByName(ctx context.Context, username string) erro return nil } -// ChangePassword changes to new password for user. -func (c *Client) ChangePassword(ctx context.Context, username, hashedNewPassword string) error { +// ChangeUserPassword changes to new password for user. +func (c *Client) ChangeUserPassword(ctx context.Context, username, hashedNewPassword string) error { updateResult, err := c.collection(ColUsers).UpdateOne(ctx, bson.M{"username": username}, bson.M{"$set": bson.M{"hashed_password": hashedNewPassword}}, diff --git a/server/users/users.go b/server/users/users.go index 98f2661da..66831fd8d 100644 --- a/server/users/users.go +++ b/server/users/users.go @@ -120,7 +120,7 @@ func ChangePassword( return fmt.Errorf("cannot hash newPassword: %w", err) } - if err := be.DB.ChangePassword(ctx, username, hashedNewPassword); err != nil { + if err := be.DB.ChangeUserPassword(ctx, username, hashedNewPassword); err != nil { return err } From 6982a770a3faf09b5d02e4a4ecc802b46003baae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EC=A0=95=ED=95=B8=EB=AA=A8?= Date: Sat, 27 Jul 2024 14:08:30 +0900 Subject: [PATCH 13/13] Add missing tests for sharding testcases --- test/sharding/server_test.go | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/test/sharding/server_test.go b/test/sharding/server_test.go index 64f10fc8a..cd42f0567 100644 --- a/test/sharding/server_test.go +++ b/test/sharding/server_test.go @@ -175,6 +175,14 @@ func TestAdminRPCServerBackendWithShardedDB(t *testing.T) { testcases.RunAdminLoginTest(t, testAdminClient) }) + t.Run("admin delete account test", func(t *testing.T) { + testcases.RunAdminDeleteAccountTest(t, testAdminClient) + }) + + t.Run("admin change password test", func(t *testing.T) { + testcases.RunAdminChangePasswordTest(t, testAdminClient) + }) + t.Run("admin create project test", func(t *testing.T) { testcases.RunAdminCreateProjectTest(t, testAdminClient, testAdminAuthInterceptor) })