Device Connections
Get User Connections
User Management
Vital Mobile SDK Integration
Device Connections
Device Connections
Get User Connections
GET Users connected providers
GET
/
v2
/
user
/
providers
/
{user_id}
curl --request GET \
--url {{BASE_URL}}/v2/user/providers/{user_id} \
--header 'Accept: application/json' \
--header 'x-vital-api-key: API_KEY'
{
"providers": [
{
"name": "Fitbit",
"slug": "fitbit",
"logo": "https://example.com/fitbit.png",
"status": "connected",
"created_on": "2010-01-23T12:34:56+00:00",
"resource_availability": {
"body": {
"status": "available",
"scope_requirements": {
"user_granted": {
"required": [
"weight"
],
"optional": []
},
"user_denied": {
"required": [],
"optional": []
}
}
},
"sleep": {
"status": "unavailable",
"scope_requirements": {
"user_granted": {
"required": [],
"optional": []
},
"user_denied": {
"required": [
"sleep"
],
"optional": [
"heartrate",
"oxygen_saturation",
"respiratory_rate"
]
}
}
}
},
"error_details": null
}
]
}
curl --request GET \
--url {{BASE_URL}}/v2/user/providers/{user_id} \
--header 'Accept: application/json' \
--header 'x-vital-api-key: API_KEY'
{
"providers": [
{
"name": "Fitbit",
"slug": "fitbit",
"logo": "https://example.com/fitbit.png",
"status": "connected",
"created_on": "2010-01-23T12:34:56+00:00",
"resource_availability": {
"body": {
"status": "available",
"scope_requirements": {
"user_granted": {
"required": [
"weight"
],
"optional": []
},
"user_denied": {
"required": [],
"optional": []
}
}
},
"sleep": {
"status": "unavailable",
"scope_requirements": {
"user_granted": {
"required": [],
"optional": []
},
"user_denied": {
"required": [
"sleep"
],
"optional": [
"heartrate",
"oxygen_saturation",
"respiratory_rate"
]
}
}
}
},
"error_details": null
}
]
}
Authorizations
Vital Team API Key
Path Parameters
Response
200
application/json
Successful Response
Name of source of information
Slug for designated source
URL for source logo
Status of source, either error or connected
Available options:
available
, unavailable
Details of the terminal connection error — populated only when the status is error
.
Available options:
token_refresh_failed
, webhook_registration_failed
, user_not_found
, deregistered_per_provider
, required_scopes_not_granted
, provider_credential_error
, unknown
curl --request GET \
--url {{BASE_URL}}/v2/user/providers/{user_id} \
--header 'Accept: application/json' \
--header 'x-vital-api-key: API_KEY'
{
"providers": [
{
"name": "Fitbit",
"slug": "fitbit",
"logo": "https://example.com/fitbit.png",
"status": "connected",
"created_on": "2010-01-23T12:34:56+00:00",
"resource_availability": {
"body": {
"status": "available",
"scope_requirements": {
"user_granted": {
"required": [
"weight"
],
"optional": []
},
"user_denied": {
"required": [],
"optional": []
}
}
},
"sleep": {
"status": "unavailable",
"scope_requirements": {
"user_granted": {
"required": [],
"optional": []
},
"user_denied": {
"required": [
"sleep"
],
"optional": [
"heartrate",
"oxygen_saturation",
"respiratory_rate"
]
}
}
}
},
"error_details": null
}
]
}