From 50807e52c0fd718ebc72be2d56beb9ddf9beefd8 Mon Sep 17 00:00:00 2001 From: ChronosX88 Date: Mon, 16 Dec 2019 17:53:37 +0400 Subject: [PATCH] Lint Account Registration --- protocol-spec/account-registration.md | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/protocol-spec/account-registration.md b/protocol-spec/account-registration.md index 7daf529..9f1cce5 100644 --- a/protocol-spec/account-registration.md +++ b/protocol-spec/account-registration.md @@ -1,17 +1,23 @@ # Account registration + ## Introduction + This extension is intended for creating user accounts on a server ## Message type identifiers -- `profile:register` + +- `profile:register` ## Error codes + - 0: limit exceed - 1: username/third party ID already taken - 2: registration isn't allowed on a server ## Use cases + - Request: + ```json { "id": "abcd", @@ -29,6 +35,7 @@ This extension is intended for creating user accounts on a server ``` - Response: + ```json { "id": "abcd", @@ -56,12 +63,15 @@ This extension is intended for creating user accounts on a server ``` ## Business Rules + None. ## JSON Schema -**Payload** + +### Payload - Request: + ```typescript interface RegistrationRequestPayload { /** @@ -92,7 +102,9 @@ interface ThirdPartyID { value: string } ``` + - Response: + ```typescript interface RegistrationResponsePayload { /** @@ -100,4 +112,4 @@ interface RegistrationResponsePayload { */ userID: EntityID } -``` \ No newline at end of file +```