Users
This operation registers a new user in hosted API. After a new user is registered, a scan for this user can be registered with /scans.
A unique token for the user provided by the partner
unique-user-token
The user's weight
{"value":80,"unit":"kg"}
The user's height
{"value":1.8,"unit":"m"}
The user's sex
male
Possible values: The user's region
north_america
Possible values: The user's state of residence
California
The user's birth date
1990-01-01
Whether the user has consented to their data being used for research
true
The terms of service
{"accepted":true,"version":"1"}
POST /users HTTP/1.1
Host: api.hosted.prismlabs.tech
Content-Type: application/json
Accept: */*
Content-Length: 282
{
"email": "[email protected]",
"token": "unique-user-token",
"weight": {
"value": 80,
"unit": "kg"
},
"height": {
"value": 1.8,
"unit": "m"
},
"sex": "male",
"region": "north_america",
"usaResidence": "California",
"birthDate": "1990-01-01",
"researchConsent": true,
"termsOfService": {
"accepted": true,
"version": "1"
}
}
{
"id": "unique-user-id",
"sex": "male",
"region": "north_america",
"usaResidence": "California",
"birthDate": "1990-01-01",
"weight": {
"value": 80,
"unit": "kg"
},
"height": {
"value": 1.8,
"unit": "m"
},
"token": "unique-user-token",
"email": "[email protected]",
"researchConsent": true
}
This operation provides the meta data for a specific user.
A unique token for the user provided by the partner
unique-user-token
GET /users/{token} HTTP/1.1
Host: api.hosted.prismlabs.tech
Accept: */*
{
"id": "unique-user-id",
"sex": "male",
"region": "north_america",
"usaResidence": "California",
"birthDate": "1990-01-01",
"weight": {
"value": 80,
"unit": "kg"
},
"height": {
"value": 1.8,
"unit": "m"
},
"token": "unique-user-token",
"email": "[email protected]",
"researchConsent": true
}
This operation deletes a specific user.
A unique token for the user provided by the partner
unique-user-token
DELETE /users/{token} HTTP/1.1
Host: api.hosted.prismlabs.tech
Accept: */*
{
"id": "unique-user-id",
"sex": "male",
"region": "north_america",
"usaResidence": "California",
"birthDate": "1990-01-01",
"weight": {
"value": 80,
"unit": "kg"
},
"height": {
"value": 1.8,
"unit": "m"
},
"token": "unique-user-token",
"email": "[email protected]",
"researchConsent": true
}
This operation updates the meta data for a specific user.
A unique token for the user provided by the partner
unique-user-token
A unique token for the user provided by the partner
unique-user-token
The user's weight
{"value":80,"unit":"kg"}
The user's height
{"value":1.8,"unit":"m"}
The user's sex
male
Possible values: The user's region
north_america
Possible values: The user's state of residence
California
The user's birth date
1990-01-01
Whether the user has consented to their data being used for research
true
PATCH /users/{token} HTTP/1.1
Host: api.hosted.prismlabs.tech
Content-Type: application/json
Accept: */*
Content-Length: 233
{
"email": "[email protected]",
"token": "unique-user-token",
"weight": {
"value": 80,
"unit": "kg"
},
"height": {
"value": 1.8,
"unit": "m"
},
"sex": "male",
"region": "north_america",
"usaResidence": "California",
"birthDate": "1990-01-01",
"researchConsent": true
}
{
"id": "unique-user-id",
"sex": "male",
"region": "north_america",
"usaResidence": "California",
"birthDate": "1990-01-01",
"weight": {
"value": 80,
"unit": "kg"
},
"height": {
"value": 1.8,
"unit": "m"
},
"token": "unique-user-token",
"email": "[email protected]",
"researchConsent": true
}