From 879687fc36f1cc1e6e5d3ae1fd6108c247ef8b6c Mon Sep 17 00:00:00 2001 From: wimo7083 Date: Wed, 27 Dec 2017 15:55:42 -0700 Subject: [PATCH 1/7] added api/v1/users documentation --- apiary.apib | 144 +++++++++++++++++++++++++++++++++++++++++++++++++++- 1 file changed, 143 insertions(+), 1 deletion(-) diff --git a/apiary.apib b/apiary.apib index 5fed815a..77063ef9 100644 --- a/apiary.apib +++ b/apiary.apib @@ -5,6 +5,148 @@ HOST: https://operationcode.org/ API endpoints that Operation Code's Rails backend makes available to its React frontend. +## Users | Create [/api/v1/users{?first_name,last_name,email,zip,password,mentor}] + ++ Parameters + + + first_name (string, required) - First Name of the user in the form of an string + + last_name (string, required) - Last Name of the user in the form of an string + + email (string, required) - Email of the User in the form of a string + + zip (string, required) - Zipcode of the User in the form of a string + + password (string, required) - Password of the User in the form on a string + + mentor (boolean, required) - Is User requesting mentor in the form of a boolean + +### Create new user record [POST] + ++ Request (application/json) + + + Body + + { + first_name: "Mike", + last_name: "Johnson", + email: "dreams@operationcode.org" , + zip: "80020" , + password: "hunter2", + mentor: "true", + } + + ++ Response 201 (application/json) + + { + token: Bearer Access-Token + } + ++ Response 422 (application/json) + + { + errors: "Some error message" + } + +## Users | Update [/api/v1/users{?education_level,mentor,scholarship_info,employment_status,company_name,company_role,volunteer,branch_of_service,interests}] + ++ Parameters + + + education_level (string, required) - Users highest level of education in the form of a string + + mentor (boolean, required) - Is User requesting mentor in the form of a boolean + + scholarship_info (boolean, required) - Is User interested in scholarship info in the form of a boolean + + employment_status (string, required) - Users employment status in the form of a string + + company_name (string, required) - Users name of employer in the form on a string + + company_role (string, required) - Users role at company in the form of a string + + volunteer (boolean, required) - Is User wanting to volunteer in the form of a boolean + + branch_of_service (string) - Users branch of service in the form of a string + + interests (string) - User interests in the form of a string. + +### Update user record [PATCH] + ++ Request (application/json) + + + Headers + + Authorization: Bearer Access-Token + + + Body + + { + education_level: "College Graduate" , + mentor: "true", + scholarship_info: "true", + employment_status: "Employed", + company_name: "Comcast", + company_role: "Developer", + volunteer: "false", + branch_of_service: "Air Force", + interests: "Python, Python, Python, Python" + } + ++ Response 200 (application/json) + + + Body + + { + first_name: "Mike", + last_name: "Johnson", + email: "dreams@operationcode.org", + zip: "80020", + password: "hunter2", + mentor: "true", + education_level: "College Graduate", + scholarship_info: "true", + employment_status: "Employed", + company_name: "Comcast", + company_role: "Developer", + volunteer: "false", + branch_of_service: "Air Force", + interests: "Python, Python, Python, Python" + } + ++ Response 422 (application/json) + + + Body + + { + errors: "Some error message" + } + +## Users | Verify [/api/v1/users/profile/verify{?verified}] + ++ Parameters + + + verified (boolean, required) - Users verified veteran status in the form of a boolean + +### Modify User record verified status [POST] + ++ Request (application/json) + + + Headers + + Authorization: Bearer Access-Token, + verified: true + + + Body + + { + verified: true + } + ++ Response 200 (application/json) + + + Body + + { + status: "ok", + verified: "verified" + } + ++ Response 422 (application/json) + + + Body + + { + errors: "Some error message" + } + ## CodeSchool | Collection [/api/v1/code_schools] ### List All CodeSchool Members [GET] @@ -1112,4 +1254,4 @@ API endpoints that Operation Code's Rails backend makes available to its React f { errors: "Some error message" - } + } \ No newline at end of file From b6a6283bc1c9c1131b987f1c0a02b94d9b6585d1 Mon Sep 17 00:00:00 2001 From: wimo7083 Date: Thu, 28 Dec 2017 15:46:39 -0700 Subject: [PATCH 2/7] updated alphabetical ordering removed trailing whitespace. --- apiary.apib | 348 ++++++++++++++++++++++++++-------------------------- 1 file changed, 177 insertions(+), 171 deletions(-) diff --git a/apiary.apib b/apiary.apib index 77063ef9..c6de2f39 100644 --- a/apiary.apib +++ b/apiary.apib @@ -5,148 +5,8 @@ HOST: https://operationcode.org/ API endpoints that Operation Code's Rails backend makes available to its React frontend. -## Users | Create [/api/v1/users{?first_name,last_name,email,zip,password,mentor}] -+ Parameters - - + first_name (string, required) - First Name of the user in the form of an string - + last_name (string, required) - Last Name of the user in the form of an string - + email (string, required) - Email of the User in the form of a string - + zip (string, required) - Zipcode of the User in the form of a string - + password (string, required) - Password of the User in the form on a string - + mentor (boolean, required) - Is User requesting mentor in the form of a boolean - -### Create new user record [POST] - -+ Request (application/json) - - + Body - - { - first_name: "Mike", - last_name: "Johnson", - email: "dreams@operationcode.org" , - zip: "80020" , - password: "hunter2", - mentor: "true", - } - - -+ Response 201 (application/json) - - { - token: Bearer Access-Token - } - -+ Response 422 (application/json) - - { - errors: "Some error message" - } - -## Users | Update [/api/v1/users{?education_level,mentor,scholarship_info,employment_status,company_name,company_role,volunteer,branch_of_service,interests}] - -+ Parameters - - + education_level (string, required) - Users highest level of education in the form of a string - + mentor (boolean, required) - Is User requesting mentor in the form of a boolean - + scholarship_info (boolean, required) - Is User interested in scholarship info in the form of a boolean - + employment_status (string, required) - Users employment status in the form of a string - + company_name (string, required) - Users name of employer in the form on a string - + company_role (string, required) - Users role at company in the form of a string - + volunteer (boolean, required) - Is User wanting to volunteer in the form of a boolean - + branch_of_service (string) - Users branch of service in the form of a string - + interests (string) - User interests in the form of a string. - -### Update user record [PATCH] - -+ Request (application/json) - - + Headers - - Authorization: Bearer Access-Token - - + Body - - { - education_level: "College Graduate" , - mentor: "true", - scholarship_info: "true", - employment_status: "Employed", - company_name: "Comcast", - company_role: "Developer", - volunteer: "false", - branch_of_service: "Air Force", - interests: "Python, Python, Python, Python" - } - -+ Response 200 (application/json) - - + Body - - { - first_name: "Mike", - last_name: "Johnson", - email: "dreams@operationcode.org", - zip: "80020", - password: "hunter2", - mentor: "true", - education_level: "College Graduate", - scholarship_info: "true", - employment_status: "Employed", - company_name: "Comcast", - company_role: "Developer", - volunteer: "false", - branch_of_service: "Air Force", - interests: "Python, Python, Python, Python" - } - -+ Response 422 (application/json) - - + Body - { - errors: "Some error message" - } - -## Users | Verify [/api/v1/users/profile/verify{?verified}] - -+ Parameters - - + verified (boolean, required) - Users verified veteran status in the form of a boolean - -### Modify User record verified status [POST] - -+ Request (application/json) - - + Headers - - Authorization: Bearer Access-Token, - verified: true - - + Body - - { - verified: true - } - -+ Response 200 (application/json) - - + Body - - { - status: "ok", - verified: "verified" - } - -+ Response 422 (application/json) - - + Body - - { - errors: "Some error message" - } - ## CodeSchool | Collection [/api/v1/code_schools] ### List All CodeSchool Members [GET] @@ -603,6 +463,39 @@ API endpoints that Operation Code's Rails backend makes available to its React f { errors: "Some error message" } + +## Location | Delete [/api/v1/code_schools/:code_school_id/locations/:id] + +### Delete an Existing Location [DELETE] + + + Request (application/json) + + + Headers + + Authorization: Bearer Access-Token + + + Body + + { + "id": 1 + } + + + Response 200 (application/json) + + + Body + + { + status: "ok" + } + + + Response 422 (application/json) + + + Body + + { + errors: "Some error message" + } + ## Location | Update [/api/v1/code_schools/:code_school_id/locations/:id?{?code_school_id,va_accepted,address1,address2,city,state,zip}] + Parameters @@ -651,37 +544,7 @@ API endpoints that Operation Code's Rails backend makes available to its React f errors: "Some error message" } -## Location | Delete [/api/v1/code_schools/:code_school_id/locations/:id] -### Delete an Existing Location [DELETE] - - + Request (application/json) - - + Headers - - Authorization: Bearer Access-Token - - + Body - - { - "id": 1 - } - - + Response 200 (application/json) - - + Body - - { - status: "ok" - } - - + Response 422 (application/json) - - + Body - - { - errors: "Some error message" - } ## Resource [/api/v1/resources/{resource_id}] @@ -1071,6 +934,8 @@ API endpoints that Operation Code's Rails backend makes available to its React f errors: "Some error message" } + + ## User | Count By Location [/api/v1/users/by_location{?state,zip,city,lat_long,radius}] ### By Location [GET] @@ -1134,6 +999,44 @@ API endpoints that Operation Code's Rails backend makes available to its React f { errors: "Some error message" } +## User | Create [/api/v1/users{?first_name,last_name,email,zip,password,mentor}] + ++ Parameters + + + first_name (string, required) - First Name of the user in the form of an string + + last_name (string, required) - Last Name of the user in the form of an string + + email (string, required) - Email of the User in the form of a string + + zip (string, required) - Zipcode of the User in the form of a string + + password (string, required) - Password of the User in the form on a string + + mentor (boolean, required) - Is User requesting mentor in the form of a boolean + +### Create new user record [POST] + ++ Request (application/json) + + + Body + + { + first_name: "Mike", + last_name: "Johnson", + email: "dreams@operationcode.org" , + zip: "80020" , + password: "hunter2", + mentor: "true", + } + + ++ Response 201 (application/json) + + { + token: Bearer Access-Token + } + ++ Response 422 (application/json) + + { + errors: "Some error message" + } ## User | Reset Password [/api/v1/users/passwords/reset{?email}] @@ -1182,6 +1085,109 @@ API endpoints that Operation Code's Rails backend makes available to its React f { errors: "Some error message" } +## User | Update [/api/v1/users{?education_level,mentor,scholarship_info,employment_status,company_name,company_role,volunteer,branch_of_service,interests}] + ++ Parameters + + + education_level (string, required) - Users highest level of education in the form of a string + + mentor (boolean, required) - Is User requesting mentor in the form of a boolean + + scholarship_info (boolean, required) - Is User interested in scholarship info in the form of a boolean + + employment_status (string, required) - Users employment status in the form of a string + + company_name (string, required) - Users name of employer in the form on a string + + company_role (string, required) - Users role at company in the form of a string + + volunteer (boolean, required) - Is User wanting to volunteer in the form of a boolean + + branch_of_service (string) - Users branch of service in the form of a string + + interests (string) - User interests in the form of a string. + +### Update user record [PATCH] + ++ Request (application/json) + + + Headers + + Authorization: Bearer Access-Token + + + Body + + { + education_level: "College Graduate" , + mentor: "true", + scholarship_info: "true", + employment_status: "Employed", + company_name: "Comcast", + company_role: "Developer", + volunteer: "false", + branch_of_service: "Air Force", + interests: "Python, Python, Python, Python" + } + ++ Response 200 (application/json) + + + Body + + { + first_name: "Mike", + last_name: "Johnson", + email: "dreams@operationcode.org", + zip: "80020", + password: "hunter2", + mentor: "true", + education_level: "College Graduate", + scholarship_info: "true", + employment_status: "Employed", + company_name: "Comcast", + company_role: "Developer", + volunteer: "false", + branch_of_service: "Air Force", + interests: "Python, Python, Python, Python" + } + ++ Response 422 (application/json) + + + Body + + { + errors: "Some error message" + } + +## User | Verify [/api/v1/users/profile/verify{?verified}] + ++ Parameters + + + verified (boolean, required) - Users verified veteran status in the form of a boolean + +### Modify User record verified status [POST] + ++ Request (application/json) + + + Headers + + Authorization: Bearer Access-Token, + verified: true + + + Body + + { + verified: true + } + ++ Response 200 (application/json) + + + Body + + { + status: "ok", + verified: "verified" + } + ++ Response 422 (application/json) + + + Body + + { + errors: "Some error message" + } + ## Vote | Create [/api/v1/resources/{resource_id}/votes{?user_id}] @@ -1254,4 +1260,4 @@ API endpoints that Operation Code's Rails backend makes available to its React f { errors: "Some error message" - } \ No newline at end of file + } From 0d27001598987d62585d539e62d19c170d5dac2d Mon Sep 17 00:00:00 2001 From: wimo7083 Date: Thu, 28 Dec 2017 15:53:39 -0700 Subject: [PATCH 3/7] removed leading space and changed mentor to be optional --- apiary.apib | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/apiary.apib b/apiary.apib index c6de2f39..118b2bb0 100644 --- a/apiary.apib +++ b/apiary.apib @@ -5,8 +5,6 @@ HOST: https://operationcode.org/ API endpoints that Operation Code's Rails backend makes available to its React frontend. - - ## CodeSchool | Collection [/api/v1/code_schools] ### List All CodeSchool Members [GET] @@ -1008,7 +1006,7 @@ API endpoints that Operation Code's Rails backend makes available to its React f + email (string, required) - Email of the User in the form of a string + zip (string, required) - Zipcode of the User in the form of a string + password (string, required) - Password of the User in the form on a string - + mentor (boolean, required) - Is User requesting mentor in the form of a boolean + + mentor (boolean, optional) - Is User requesting mentor in the form of a boolean ### Create new user record [POST] From 0c9e07f01f119cc786e02f723144a96991fb61cb Mon Sep 17 00:00:00 2001 From: wimo7083 Date: Thu, 28 Dec 2017 16:03:44 -0700 Subject: [PATCH 4/7] more whitespace fixes, indentation fix, updated verified descriptor, removed verified in header. --- apiary.apib | 67 +++++++++++++++++++++++++---------------------------- 1 file changed, 32 insertions(+), 35 deletions(-) diff --git a/apiary.apib b/apiary.apib index 118b2bb0..3096e3b1 100644 --- a/apiary.apib +++ b/apiary.apib @@ -932,8 +932,6 @@ API endpoints that Operation Code's Rails backend makes available to its React f errors: "Some error message" } - - ## User | Count By Location [/api/v1/users/by_location{?state,zip,city,lat_long,radius}] ### By Location [GET] @@ -1027,13 +1025,13 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Response 201 (application/json) { - token: Bearer Access-Token + token: Bearer Access-Token } + Response 422 (application/json) { - errors: "Some error message" + errors: "Some error message" } ## User | Reset Password [/api/v1/users/passwords/reset{?email}] @@ -1108,15 +1106,15 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Body { - education_level: "College Graduate" , - mentor: "true", - scholarship_info: "true", - employment_status: "Employed", - company_name: "Comcast", - company_role: "Developer", - volunteer: "false", - branch_of_service: "Air Force", - interests: "Python, Python, Python, Python" + education_level: "College Graduate" , + mentor: "true", + scholarship_info: "true", + employment_status: "Employed", + company_name: "Comcast", + company_role: "Developer", + volunteer: "false", + branch_of_service: "Air Force", + interests: "Python, Python, Python, Python" } + Response 200 (application/json) @@ -1124,20 +1122,20 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Body { - first_name: "Mike", - last_name: "Johnson", - email: "dreams@operationcode.org", - zip: "80020", - password: "hunter2", - mentor: "true", - education_level: "College Graduate", - scholarship_info: "true", - employment_status: "Employed", - company_name: "Comcast", - company_role: "Developer", - volunteer: "false", - branch_of_service: "Air Force", - interests: "Python, Python, Python, Python" + first_name: "Mike", + last_name: "Johnson", + email: "dreams@operationcode.org", + zip: "80020", + password: "hunter2", + mentor: "true", + education_level: "College Graduate", + scholarship_info: "true", + employment_status: "Employed", + company_name: "Comcast", + company_role: "Developer", + volunteer: "false", + branch_of_service: "Air Force", + interests: "Python, Python, Python, Python" } + Response 422 (application/json) @@ -1145,14 +1143,14 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Body { - errors: "Some error message" + errors: "Some error message" } ## User | Verify [/api/v1/users/profile/verify{?verified}] + Parameters - + verified (boolean, required) - Users verified veteran status in the form of a boolean + + verified (boolean, required) - User has verified military affiliation status through ID.me ### Modify User record verified status [POST] @@ -1160,13 +1158,12 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Headers - Authorization: Bearer Access-Token, - verified: true + Authorization: Bearer Access-Token + Body { - verified: true + verified: true } + Response 200 (application/json) @@ -1174,8 +1171,8 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Body { - status: "ok", - verified: "verified" + status: "ok", + verified: "verified" } + Response 422 (application/json) @@ -1183,7 +1180,7 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Body { - errors: "Some error message" + errors: "Some error message" } From 700ca3fd097ddacc3b680063220360fbfc6c3afe Mon Sep 17 00:00:00 2001 From: wimo7083 Date: Thu, 28 Dec 2017 16:08:04 -0700 Subject: [PATCH 5/7] changed update to all optional --- apiary.apib | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/apiary.apib b/apiary.apib index 3096e3b1..a298215e 100644 --- a/apiary.apib +++ b/apiary.apib @@ -1085,15 +1085,15 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Parameters - + education_level (string, required) - Users highest level of education in the form of a string - + mentor (boolean, required) - Is User requesting mentor in the form of a boolean - + scholarship_info (boolean, required) - Is User interested in scholarship info in the form of a boolean - + employment_status (string, required) - Users employment status in the form of a string - + company_name (string, required) - Users name of employer in the form on a string - + company_role (string, required) - Users role at company in the form of a string - + volunteer (boolean, required) - Is User wanting to volunteer in the form of a boolean - + branch_of_service (string) - Users branch of service in the form of a string - + interests (string) - User interests in the form of a string. + + education_level (string, optional) - Users highest level of education in the form of a string + + mentor (boolean, optional) - Is User requesting mentor in the form of a boolean + + scholarship_info (boolean, optional) - Is User interested in scholarship info in the form of a boolean + + employment_status (string, optional) - Users employment status in the form of a string + + company_name (string, optional) - Users name of employer in the form on a string + + company_role (string, optional) - Users role at company in the form of a string + + volunteer (boolean, optional) - Is User wanting to volunteer in the form of a boolean + + branch_of_service (string, optional) - Users branch of service in the form of a string + + interests (string, optional) - User interests in the form of a string. ### Update user record [PATCH] From 5054b6498abd79a4a8c212b5e191809ab3c65670 Mon Sep 17 00:00:00 2001 From: wimo7083 Date: Thu, 28 Dec 2017 16:11:37 -0700 Subject: [PATCH 6/7] removed hunter2 from create response --- apiary.apib | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/apiary.apib b/apiary.apib index a298215e..4d1348ed 100644 --- a/apiary.apib +++ b/apiary.apib @@ -1015,9 +1015,8 @@ API endpoints that Operation Code's Rails backend makes available to its React f { first_name: "Mike", last_name: "Johnson", - email: "dreams@operationcode.org" , - zip: "80020" , - password: "hunter2", + email: "dreams@operationcode.org", + zip: "80020", mentor: "true", } From 0725d47829f4f37f6e514d37554dd1958a4e314f Mon Sep 17 00:00:00 2001 From: wimo7 Date: Sun, 31 Dec 2017 12:01:48 -0700 Subject: [PATCH 7/7] fixed indentation, changed params to access_token for verify --- apiary.apib | 70 +++++++++++++++++++++++++---------------------------- 1 file changed, 33 insertions(+), 37 deletions(-) diff --git a/apiary.apib b/apiary.apib index 4d1348ed..bb85d945 100644 --- a/apiary.apib +++ b/apiary.apib @@ -42,14 +42,14 @@ API endpoints that Operation Code's Rails backend makes available to its React f ## CodeSchool | Create [/api/v1/code_schools{?name,url,logo,full_time,hardware_included,has_online,online_only,notes}] + Parameters - + name (string, required) - The CodeSchool's name - + url (string, required) - The CodeSchool's url for homepage - + logo (string, required) - The CodeSchool's logo url - + full_time (boolean, required) - Are the CodeSchool's courses full time - + hardware_included (boolean, required) - Is Hardware included with the CodeSchool - + has_online (boolean, required) - Does the CodeSchool have an online component - + online_only (boolean, required) - Is the CodeSchool online only? - + notes (text, optional) - Any additional information about the CodeSchool + + name (string, required) - The CodeSchool's name + + url (string, required) - The CodeSchool's url for homepage + + logo (string, required) - The CodeSchool's logo url + + full_time (boolean, required) - Are the CodeSchool's courses full time + + hardware_included (boolean, required) - Is Hardware included with the CodeSchool + + has_online (boolean, required) - Does the CodeSchool have an online component + + online_only (boolean, required) - Is the CodeSchool online only? + + notes (text, optional) - Any additional information about the CodeSchool ### Create a CodeSchool Member [POST] @@ -193,7 +193,7 @@ API endpoints that Operation Code's Rails backend makes available to its React f ## Email List Recipients | Create [/api/v1/email_list_recipients{?email}] + Parameters - + email (string, required) - The email address of the OC guest to be added to the OC's email list + + email (string, required) - The email address of the OC guest to be added to the OC's email list ### Add a guest (non-user) to the OC's email list [POST] @@ -999,12 +999,12 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Parameters - + first_name (string, required) - First Name of the user in the form of an string - + last_name (string, required) - Last Name of the user in the form of an string - + email (string, required) - Email of the User in the form of a string - + zip (string, required) - Zipcode of the User in the form of a string - + password (string, required) - Password of the User in the form on a string - + mentor (boolean, optional) - Is User requesting mentor in the form of a boolean + + first_name (string, required) - First Name of the user in the form of an string + + last_name (string, required) - Last Name of the user in the form of an string + + email (string, required) - Email of the User in the form of a string + + zip (string, required) - Zipcode of the User in the form of a string + + password (string, required) - Password of the User in the form on a string + + mentor (boolean, optional) - Is User requesting mentor in the form of a boolean ### Create new user record [POST] @@ -1013,11 +1013,11 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Body { - first_name: "Mike", - last_name: "Johnson", - email: "dreams@operationcode.org", - zip: "80020", - mentor: "true", + first_name: "Mike", + last_name: "Johnson", + email: "dreams@operationcode.org", + zip: "80020", + mentor: "true" } @@ -1084,15 +1084,15 @@ API endpoints that Operation Code's Rails backend makes available to its React f + Parameters - + education_level (string, optional) - Users highest level of education in the form of a string - + mentor (boolean, optional) - Is User requesting mentor in the form of a boolean - + scholarship_info (boolean, optional) - Is User interested in scholarship info in the form of a boolean - + employment_status (string, optional) - Users employment status in the form of a string - + company_name (string, optional) - Users name of employer in the form on a string - + company_role (string, optional) - Users role at company in the form of a string - + volunteer (boolean, optional) - Is User wanting to volunteer in the form of a boolean - + branch_of_service (string, optional) - Users branch of service in the form of a string - + interests (string, optional) - User interests in the form of a string. + + education_level (string, optional) - Users highest level of education in the form of a string + + mentor (boolean, optional) - Is User requesting mentor in the form of a boolean + + scholarship_info (boolean, optional) - Is User interested in scholarship info in the form of a boolean + + employment_status (string, optional) - Users employment status in the form of a string + + company_name (string, optional) - Users name of employer in the form on a string + + company_role (string, optional) - Users role at company in the form of a string + + volunteer (boolean, optional) - Is User wanting to volunteer in the form of a boolean + + branch_of_service (string, optional) - Users branch of service in the form of a string + + interests (string, optional) - User interests in the form of a string. ### Update user record [PATCH] @@ -1145,24 +1145,20 @@ API endpoints that Operation Code's Rails backend makes available to its React f errors: "Some error message" } -## User | Verify [/api/v1/users/profile/verify{?verified}] +## User | Verify [/api/v1/users/profile/verify{?access_token}] + Parameters - + verified (boolean, required) - User has verified military affiliation status through ID.me + + access_token (string, required) - User verified access token through Id.me in the form of a string -### Modify User record verified status [POST] +### Verifies a user's military affiliation status through ID.me [POST] + Request (application/json) - + Headers - - Authorization: Bearer Access-Token - + Body { - verified: true + access_token: "access token" } + Response 200 (application/json)