Get All Persons
curl --request GET \
--url 'http://{{baseurl}}/api/v1/management/people' \
--header 'x-api-key: <x-api-key>'import requests
url = "http://{{baseurl}}/api/v1/management/people"
headers = {"x-api-key": "<x-api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<x-api-key>'}};
fetch('http://{{baseurl}}/api/v1/management/people', 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 => "http://{{baseurl}}/api/v1/management/people",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <x-api-key>"
],
]);
$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 := "http://{{baseurl}}/api/v1/management/people"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<x-api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("http://{{baseurl}}/api/v1/management/people")
.header("x-api-key", "<x-api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("http://{{baseurl}}/api/v1/management/people")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"attributes": {
"Init Attribute 1": "eight",
"language": "gu"
},
"createdAt": "2024-04-22T08:59:26.959Z",
"environmentId": "clurwouax000azffxt7n5unn3",
"id": "clvaq77u70002mhqfih5bnk0i",
"updatedAt": "2024-04-22T08:59:26.959Z",
"userId": "THIS-IS-A-VERY-LONG-USER-ID-FOR-TESTING"
},
{
"attributes": {},
"createdAt": "2024-04-23T07:12:44.928Z",
"environmentId": "clurwouax000azffxt7n5unn3",
"id": "clvc1tuo00003494jnz64wd0t",
"updatedAt": "2024-04-23T07:12:44.928Z",
"userId": "1"
},
{
"attributes": {
"Init Attribute 1": "eight",
"language": "gu"
},
"createdAt": "2024-04-23T07:30:42.730Z",
"environmentId": "clurwouax000azffxt7n5unn3",
"id": "clvc2gyay0009494jbanqhr79",
"updatedAt": "2024-04-23T07:30:42.730Z",
"userId": "SECOND-USER-ID"
},
{
"attributes": {},
"createdAt": "2024-04-23T07:35:47.091Z",
"environmentId": "clurwouax000azffxt7n5unn3",
"id": "clvc2nh5g000h494jkr6qcxhz",
"updatedAt": "2024-04-23T07:35:47.091Z",
"userId": "Shubham"
},
{
"attributes": {
"Created From": "API",
"created_from": "API"
},
"createdAt": "2024-04-23T07:39:22.696Z",
"environmentId": "clurwouax000azffxt7n5unn3",
"id": "clvc2s3ig000k494jltkqkm2u",
"updatedAt": "2024-04-23T07:39:22.696Z",
"userId": "THIS-IS-A-VVERY-LONG-USER-ID-FOR-TESTING"
}
]
}Management API > People
Get All Persons
Get all the identified people from Formbricks
GET
/
api
/
v1
/
management
/
people
Get All Persons
curl --request GET \
--url 'http://{{baseurl}}/api/v1/management/people' \
--header 'x-api-key: <x-api-key>'import requests
url = "http://{{baseurl}}/api/v1/management/people"
headers = {"x-api-key": "<x-api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-api-key': '<x-api-key>'}};
fetch('http://{{baseurl}}/api/v1/management/people', 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 => "http://{{baseurl}}/api/v1/management/people",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-api-key: <x-api-key>"
],
]);
$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 := "http://{{baseurl}}/api/v1/management/people"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-api-key", "<x-api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("http://{{baseurl}}/api/v1/management/people")
.header("x-api-key", "<x-api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("http://{{baseurl}}/api/v1/management/people")
http = Net::HTTP.new(url.host, url.port)
request = Net::HTTP::Get.new(url)
request["x-api-key"] = '<x-api-key>'
response = http.request(request)
puts response.read_body{
"data": [
{
"attributes": {
"Init Attribute 1": "eight",
"language": "gu"
},
"createdAt": "2024-04-22T08:59:26.959Z",
"environmentId": "clurwouax000azffxt7n5unn3",
"id": "clvaq77u70002mhqfih5bnk0i",
"updatedAt": "2024-04-22T08:59:26.959Z",
"userId": "THIS-IS-A-VERY-LONG-USER-ID-FOR-TESTING"
},
{
"attributes": {},
"createdAt": "2024-04-23T07:12:44.928Z",
"environmentId": "clurwouax000azffxt7n5unn3",
"id": "clvc1tuo00003494jnz64wd0t",
"updatedAt": "2024-04-23T07:12:44.928Z",
"userId": "1"
},
{
"attributes": {
"Init Attribute 1": "eight",
"language": "gu"
},
"createdAt": "2024-04-23T07:30:42.730Z",
"environmentId": "clurwouax000azffxt7n5unn3",
"id": "clvc2gyay0009494jbanqhr79",
"updatedAt": "2024-04-23T07:30:42.730Z",
"userId": "SECOND-USER-ID"
},
{
"attributes": {},
"createdAt": "2024-04-23T07:35:47.091Z",
"environmentId": "clurwouax000azffxt7n5unn3",
"id": "clvc2nh5g000h494jkr6qcxhz",
"updatedAt": "2024-04-23T07:35:47.091Z",
"userId": "Shubham"
},
{
"attributes": {
"Created From": "API",
"created_from": "API"
},
"createdAt": "2024-04-23T07:39:22.696Z",
"environmentId": "clurwouax000azffxt7n5unn3",
"id": "clvc2s3ig000k494jltkqkm2u",
"updatedAt": "2024-04-23T07:39:22.696Z",
"userId": "THIS-IS-A-VVERY-LONG-USER-ID-FOR-TESTING"
}
]
}Headers
Response
200 - application/json
OK
The response is of type object.
Was this page helpful?
⌘I