Get Membership Analytics List
curl --request GET \
--url https://api.decodahealth.com/analytics/dashboards/memberships/list \
--header 'API-KEY: <api-key>' \
--header 'Content-Type: application/json' \
--header 'TENANT: <tenant>' \
--data '
{
"membership_ids": [],
"member_statuses": [],
"location_ids": [],
"sold_by_provider_ids": []
}
'import requests
url = "https://api.decodahealth.com/analytics/dashboards/memberships/list"
payload = {
"membership_ids": [],
"member_statuses": [],
"location_ids": [],
"sold_by_provider_ids": []
}
headers = {
"TENANT": "<tenant>",
"API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.get(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {TENANT: '<tenant>', 'API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
membership_ids: [],
member_statuses: [],
location_ids: [],
sold_by_provider_ids: []
})
};
fetch('https://api.decodahealth.com/analytics/dashboards/memberships/list', 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.decodahealth.com/analytics/dashboards/memberships/list",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_POSTFIELDS => json_encode([
'membership_ids' => [
],
'member_statuses' => [
],
'location_ids' => [
],
'sold_by_provider_ids' => [
]
]),
CURLOPT_HTTPHEADER => [
"API-KEY: <api-key>",
"Content-Type: application/json",
"TENANT: <tenant>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.decodahealth.com/analytics/dashboards/memberships/list"
payload := strings.NewReader("{\n \"membership_ids\": [],\n \"member_statuses\": [],\n \"location_ids\": [],\n \"sold_by_provider_ids\": []\n}")
req, _ := http.NewRequest("GET", url, payload)
req.Header.Add("TENANT", "<tenant>")
req.Header.Add("API-KEY", "<api-key>")
req.Header.Add("Content-Type", "application/json")
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.decodahealth.com/analytics/dashboards/memberships/list")
.header("TENANT", "<tenant>")
.header("API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"membership_ids\": [],\n \"member_statuses\": [],\n \"location_ids\": [],\n \"sold_by_provider_ids\": []\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.decodahealth.com/analytics/dashboards/memberships/list")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["TENANT"] = '<tenant>'
request["API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"membership_ids\": [],\n \"member_statuses\": [],\n \"location_ids\": [],\n \"sold_by_provider_ids\": []\n}"
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "<string>",
"patientId": "<string>",
"membershipId": "<string>",
"membership": {
"id": "<string>",
"name": "<string>",
"textColor": "<string>"
},
"startDate": "2023-11-07T05:31:56Z",
"autoRenew": true,
"patient": {
"id": "<string>",
"createdDate": "2023-11-07T05:31:56Z",
"firstName": "<string>",
"lastName": "<string>",
"phoneNumber": "<string>",
"email": "<string>",
"locationId": "<string>",
"externalId": "<string>",
"address": "<string>",
"addressLineTwo": "<string>",
"city": "<string>",
"state": "<string>",
"zipCode": "<string>",
"country": "<string>",
"addressValid": true,
"meta": {},
"isArchived": true,
"primaryLocationId": "<string>",
"gender": "<string>",
"dateOfBirth": "2023-12-25",
"patientMedications": [
"<string>"
],
"onSchedulingBlacklist": true,
"surchargeDisabled": true,
"tags": [
{
"id": "<string>",
"name": "<string>",
"isActive": true,
"createdDate": "2023-11-07T05:31:56Z",
"emoji": "<string>",
"color": "<string>",
"updatedDate": "2023-11-07T05:31:56Z"
}
],
"creditBalance": 123,
"preferredProviderId": "<string>",
"primaryLocation": {
"id": "<string>",
"name": "<string>",
"isVirtual": true
}
},
"charges": [
{
"id": "<string>",
"patientId": "<string>"
}
],
"soldByProviderId": "<string>",
"endDate": "2023-11-07T05:31:56Z",
"nextBillingDate": "2023-11-07T05:31:56Z",
"unfreezeDate": "2023-11-07T05:31:56Z",
"soldByProvider": {
"id": "<string>",
"firstName": "<string>",
"lastName": "<string>"
},
"createdDate": "2023-11-07T05:31:56Z",
"updatedDate": "2023-11-07T05:31:56Z",
"paymentMethod": {
"id": "<string>",
"patientId": "<string>",
"rainforestPaymentMethodId": "<string>",
"brand": "<string>",
"last4": "<string>",
"expMonth": 123,
"expYear": 123,
"accountHolderType": "<string>",
"accountNumberLast4": 123,
"bankName": "<string>",
"routingNumber": 123,
"description": "<string>",
"isDefault": false,
"isArchived": false
}
}
],
"total": 123
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Analytics
Get Membership Analytics List
Get member analytics with filters.
GET
/
analytics
/
dashboards
/
memberships
/
list
Get Membership Analytics List
curl --request GET \
--url https://api.decodahealth.com/analytics/dashboards/memberships/list \
--header 'API-KEY: <api-key>' \
--header 'Content-Type: application/json' \
--header 'TENANT: <tenant>' \
--data '
{
"membership_ids": [],
"member_statuses": [],
"location_ids": [],
"sold_by_provider_ids": []
}
'import requests
url = "https://api.decodahealth.com/analytics/dashboards/memberships/list"
payload = {
"membership_ids": [],
"member_statuses": [],
"location_ids": [],
"sold_by_provider_ids": []
}
headers = {
"TENANT": "<tenant>",
"API-KEY": "<api-key>",
"Content-Type": "application/json"
}
response = requests.get(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {TENANT: '<tenant>', 'API-KEY': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
membership_ids: [],
member_statuses: [],
location_ids: [],
sold_by_provider_ids: []
})
};
fetch('https://api.decodahealth.com/analytics/dashboards/memberships/list', 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.decodahealth.com/analytics/dashboards/memberships/list",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_POSTFIELDS => json_encode([
'membership_ids' => [
],
'member_statuses' => [
],
'location_ids' => [
],
'sold_by_provider_ids' => [
]
]),
CURLOPT_HTTPHEADER => [
"API-KEY: <api-key>",
"Content-Type: application/json",
"TENANT: <tenant>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.decodahealth.com/analytics/dashboards/memberships/list"
payload := strings.NewReader("{\n \"membership_ids\": [],\n \"member_statuses\": [],\n \"location_ids\": [],\n \"sold_by_provider_ids\": []\n}")
req, _ := http.NewRequest("GET", url, payload)
req.Header.Add("TENANT", "<tenant>")
req.Header.Add("API-KEY", "<api-key>")
req.Header.Add("Content-Type", "application/json")
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.decodahealth.com/analytics/dashboards/memberships/list")
.header("TENANT", "<tenant>")
.header("API-KEY", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"membership_ids\": [],\n \"member_statuses\": [],\n \"location_ids\": [],\n \"sold_by_provider_ids\": []\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.decodahealth.com/analytics/dashboards/memberships/list")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["TENANT"] = '<tenant>'
request["API-KEY"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"membership_ids\": [],\n \"member_statuses\": [],\n \"location_ids\": [],\n \"sold_by_provider_ids\": []\n}"
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "<string>",
"patientId": "<string>",
"membershipId": "<string>",
"membership": {
"id": "<string>",
"name": "<string>",
"textColor": "<string>"
},
"startDate": "2023-11-07T05:31:56Z",
"autoRenew": true,
"patient": {
"id": "<string>",
"createdDate": "2023-11-07T05:31:56Z",
"firstName": "<string>",
"lastName": "<string>",
"phoneNumber": "<string>",
"email": "<string>",
"locationId": "<string>",
"externalId": "<string>",
"address": "<string>",
"addressLineTwo": "<string>",
"city": "<string>",
"state": "<string>",
"zipCode": "<string>",
"country": "<string>",
"addressValid": true,
"meta": {},
"isArchived": true,
"primaryLocationId": "<string>",
"gender": "<string>",
"dateOfBirth": "2023-12-25",
"patientMedications": [
"<string>"
],
"onSchedulingBlacklist": true,
"surchargeDisabled": true,
"tags": [
{
"id": "<string>",
"name": "<string>",
"isActive": true,
"createdDate": "2023-11-07T05:31:56Z",
"emoji": "<string>",
"color": "<string>",
"updatedDate": "2023-11-07T05:31:56Z"
}
],
"creditBalance": 123,
"preferredProviderId": "<string>",
"primaryLocation": {
"id": "<string>",
"name": "<string>",
"isVirtual": true
}
},
"charges": [
{
"id": "<string>",
"patientId": "<string>"
}
],
"soldByProviderId": "<string>",
"endDate": "2023-11-07T05:31:56Z",
"nextBillingDate": "2023-11-07T05:31:56Z",
"unfreezeDate": "2023-11-07T05:31:56Z",
"soldByProvider": {
"id": "<string>",
"firstName": "<string>",
"lastName": "<string>"
},
"createdDate": "2023-11-07T05:31:56Z",
"updatedDate": "2023-11-07T05:31:56Z",
"paymentMethod": {
"id": "<string>",
"patientId": "<string>",
"rainforestPaymentMethodId": "<string>",
"brand": "<string>",
"last4": "<string>",
"expMonth": 123,
"expYear": 123,
"accountHolderType": "<string>",
"accountNumberLast4": 123,
"bankName": "<string>",
"routingNumber": 123,
"description": "<string>",
"isDefault": false,
"isArchived": false
}
}
],
"total": 123
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Headers
The tenant you are making this request on behalf of
Your api key
Query Parameters
Available options:
asc, desc Body
application/json
⌘I
