Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.
Authentication
HTTP Authentication, scheme: bearer
Invitation
Invites a new user to a specific project
Code samples
URL obj = new URL("/account-service/invitations");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
POST /account-service/invitations
This operation invites a new user to a specific project. The platform sends an invitation email with an invitation link to the provided email address.
A new account has been created with the provided email.
None
default
Default
An unexpected error has occurred.
Inline
Response Schema
Status Code default
Name
Type
Required
Restrictions
Description
» code
string
true
none
none
» message
string
true
none
none
ResearchAssistant
Verifies the provided email and sends a reset password email
Code samples
URL obj = new URL("/account-service/user/password/forgot");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
POST /account-service/user/password/forgot
This operation accepts an email address. If the provided email address is registered, the server sends a password reset email. If not, it returns a 404 response.
URL obj = new URL("/account-service/user/password/reset");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
POST /account-service/user/password/reset
This operation resets the user's password. The "profile" field is optional. If no value is set for this field, the server doesn't change the user's profile.
Signed Json Web Token payload is as below. { "email": "cubist@samsung.com", "roles": ["study_1:study-creator", "study_2:research-assistant"], "iss": "https://research-hub.io/", "exp": 1660377937, "iat": 1660291536 }
» refreshToken
string
true
none
none
» roles
[string]
true
none
none
» profile
object
true
none
Account information in JSON without pre-defined fields.
Status Code default
Name
Type
Required
Restrictions
Description
» code
string
true
none
none
» message
string
true
none
none
Signs in a user with an email and password
Code samples
URL obj = new URL("/account-service/signin");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
Signed Json Web Token payload is as below. { "email": "cubist@samsung.com", "roles": ["study_1:study-creator", "study_2:research-assistant"], "iss": "https://research-hub.io/", "exp": 1660377937, "iat": 1660291536 }
» refreshToken
string
true
none
none
» roles
[string]
true
none
none
» profile
object
true
none
Account information in JSON without pre-defined fields.
Status Code default
Name
Type
Required
Restrictions
Description
» code
string
true
none
none
» message
string
true
none
none
Signs up a new user
Code samples
URL obj = new URL("/account-service/signup");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
POST /account-service/signup
This operation signs up a new user. Afterwards, the server sends a verification link to the provided email address.
URL obj = new URL("/account-service/token/refresh");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
POST /account-service/token/refresh
This operation requests a new token by sending a pair of JWT (accessToken) and refreshToken.
Signed Json Web Token payload is as below. { "email": "cubist@samsung.com", "roles": ["study_1:study-creator", "study_2:research-assistant"], "iss": "https://research-hub.io/", "exp": 1660377937, "iat": 1660291536 }
» refreshToken
string
true
none
none
Status Code default
Name
Type
Required
Restrictions
Description
» code
string
true
none
none
» message
string
true
none
none
Role
Assigns roles to a user
Code samples
URL obj = new URL("/account-service/user/roles");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
URL obj = new URL("/account-service/user/roles/remove");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
URL obj = new URL("/account-service/users?projectId=100");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
GET /account-service/users
Parameters
Name
In
Type
Required
Description
projectId
query
string
true
The ID of the specific project for which to retrieve users
Account information in JSON without pre-defined fields.
Status Code default
Name
Type
Required
Restrictions
Description
» code
string
true
none
none
» message
string
true
none
none
Email Verification
Verifies the email with a token
Code samples
URL obj = new URL("/account-service/user/email/verify");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
Signed Json Web Token payload is as below. { "email": "cubist@samsung.com", "roles": ["study_1:study-creator", "study_2:research-assistant"], "iss": "https://research-hub.io/", "exp": 1660377937, "iat": 1660291536 }
» refreshToken
string
true
none
none
» roles
[string]
true
none
none
» profile
object
true
none
Account information in JSON without pre-defined fields.
Status Code default
Name
Type
Required
Restrictions
Description
» code
string
true
none
none
» message
string
true
none
none
Resends a verification email
Code samples
URL obj = new URL("/account-service/verification");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
POST /account-service/verification
This operation resends a verification link to the provided email address.
A role is either system role or project role.
Researchers must have project roles to access specific project.
The format of project role is as follow: $project_id:$role_name
Properties
Name
Type
Required
Restrictions
Description
anonymous
string
false
none
A role is either system role or project role. Researchers must have project roles to access specific project. - The format of project role is as follow: $project_id:$role_name
Account information in JSON without pre-defined fields.
Profile
{
"name": "david.lee",
"status": "active"
}
Account information in JSON without pre-defined fields.
Properties
None
Token
"eyJhbGc...ssw5c"
Signed Json Web Token payload is as below.
{
"email": "cubist@samsung.com",
"roles": ["study_1:study-creator", "study_2:research-assistant"],
"iss": "https://research-hub.io/",
"exp": 1660377937,
"iat": 1660291536
}
Properties
Name
Type
Required
Restrictions
Description
anonymous
string
false
none
Signed Json Web Token payload is as below. { "email": "cubist@samsung.com", "roles": ["study_1:study-creator", "study_2:research-assistant"], "iss": "https://research-hub.io/", "exp": 1660377937, "iat": 1660291536 }
Email
"cubist@samsung.com"
Properties
Name
Type
Required
Restrictions
Description
anonymous
string(email)
false
none
none
AccountId
"7d08351b-85b6-488e-a8a2-b8653defb865"
Properties
Name
Type
Required
Restrictions
Description
anonymous
string
false
none
none
ProjectId
100
Properties
Name
Type
Required
Restrictions
Description
anonymous
string
false
none
none
ResetToken
"aadfad...badfdfad"
Properties
Name
Type
Required
Restrictions
Description
anonymous
string
false
none
none
RefreshToken
"aadfad...badfdfad"
Properties
Name
Type
Required
Restrictions
Description
anonymous
string
false
none
none
VerifyEmailToken
"aadfad...badfdfad"
Properties
Name
Type
Required
Restrictions
Description
anonymous
string
false
none
none
Error
{
"code": "string",
"message": "string"
}
Properties
Name
Type
Required
Restrictions
Description
code
string
true
none
none
message
string
true
none
none
Manage Your Cookies
We use cookies to improve your experience on our website and to show you relevant
advertising. Manage you settings for our cookies below.
Essential Cookies
These cookies are essential as they enable you to move around the website. This
category cannot be disabled.
Company
Domain
Samsung Electronics
.samsungdeveloperconference.com
Analytical/Performance Cookies
These cookies collect information about how you use our website. for example which
pages you visit most often. All information these cookies collect is used to improve
how the website works.
Company
Domain
LinkedIn
.linkedin.com
Meta (formerly Facebook)
.samsungdeveloperconference.com
Google Inc.
.samsungdeveloperconference.com
Functionality Cookies
These cookies allow our website to remember choices you make (such as your user name, language or the region your are in) and
tailor the website to provide enhanced features and content for you.
Company
Domain
LinkedIn
.ads.linkedin.com, .linkedin.com
Advertising Cookies
These cookies gather information about your browser habits. They remember that
you've visited our website and share this information with other organizations such
as advertisers.
Company
Domain
LinkedIn
.linkedin.com
Meta (formerly Facebook)
.samsungdeveloperconference.com
Google Inc.
.samsungdeveloperconference.com
Preferences Submitted
You have successfully updated your cookie preferences.