List profiles
curl --request GET \
--url https://api.hi-doctor.ai/v1/users/profile/ \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.hi-doctor.ai/v1/users/profile/"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.hi-doctor.ai/v1/users/profile/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.hi-doctor.ai/v1/users/profile/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.hi-doctor.ai/v1/users/profile/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.hi-doctor.ai/v1/users/profile/")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hi-doctor.ai/v1/users/profile/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "0a1b2c3d-4e5f-4a6b-8c9d-000000000001",
"email": "patient@example.com",
"first_name": "Alex",
"last_name": "Moreno",
"date_of_birth": "1985-04-12",
"gender": "1",
"country_of_residence": "ESP",
"timezone": "Europe/Madrid",
"locale": "en",
"city": null,
"postal_code": null,
"issuing_state": "ESP",
"document_number": "X0000000X",
"document_type": "ID_CARD",
"addresses": [],
"is_doctor": false,
"is_backoffice_admin": false,
"is_marketer": false,
"is_referrer": false,
"forms_completed": {
"hair_growth": true,
"weight_loss": true,
"sexual_health": false,
"premature_ejaculation": false,
"chlamydia": false,
"urinary_tract_infection": false,
"emergency_contraception": false,
"hiv_prep": false
},
"orders": []
}{
"detail": "Given token not valid for any token type",
"code": "token_not_valid",
"messages": [
{
"token_class": "AccessToken",
"token_type": "access",
"message": "Token is invalid"
}
]
}Account
List profiles
Self-scoped.
GET
/
v1
/
users
/
profile
/
List profiles
curl --request GET \
--url https://api.hi-doctor.ai/v1/users/profile/ \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.hi-doctor.ai/v1/users/profile/"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.hi-doctor.ai/v1/users/profile/', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.hi-doctor.ai/v1/users/profile/",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.hi-doctor.ai/v1/users/profile/"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.hi-doctor.ai/v1/users/profile/")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.hi-doctor.ai/v1/users/profile/")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"id": "0a1b2c3d-4e5f-4a6b-8c9d-000000000001",
"email": "patient@example.com",
"first_name": "Alex",
"last_name": "Moreno",
"date_of_birth": "1985-04-12",
"gender": "1",
"country_of_residence": "ESP",
"timezone": "Europe/Madrid",
"locale": "en",
"city": null,
"postal_code": null,
"issuing_state": "ESP",
"document_number": "X0000000X",
"document_type": "ID_CARD",
"addresses": [],
"is_doctor": false,
"is_backoffice_admin": false,
"is_marketer": false,
"is_referrer": false,
"forms_completed": {
"hair_growth": true,
"weight_loss": true,
"sexual_health": false,
"premature_ejaculation": false,
"chlamydia": false,
"urinary_tract_infection": false,
"emergency_contraception": false,
"hiv_prep": false
},
"orders": []
}{
"detail": "Given token not valid for any token type",
"code": "token_not_valid",
"messages": [
{
"token_class": "AccessToken",
"token_type": "access",
"message": "Token is invalid"
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Response
Patient gender is required
Available options:
0, 1, 2, 3 Show child attributes
Show child attributes
Show child attributes
Show child attributes
Can manage configuration surfaces such as questionnaires, templates, automations, and audiences.
Can access aggregated revenue and funnel analytics without patient or doctor PII.
Show child attributes
Show child attributes
Show child attributes
Show child attributes
Maximum string length:
150Maximum string length:
150Maximum string length:
64Available options:
de, en, es, fr, it, nl, pt Patient city used to recommend nearby pharmacies.
Maximum string length:
120Patient postal code used to recommend nearby pharmacies.
Maximum string length:
20Maximum string length:
200Maximum string length:
50Available options:
PASSPORT, ID_CARD