Get Asset Counts
curl --request GET \
--url https://api.us.lexful.app/v1/assets/counts \
--header 'Authorization: Bearer <token>' \
--header 'X-Account-ID: <x-account-id>'import requests
url = "https://api.us.lexful.app/v1/assets/counts"
headers = {
"X-Account-ID": "<x-account-id>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-Account-ID': '<x-account-id>', Authorization: 'Bearer <token>'}
};
fetch('https://api.us.lexful.app/v1/assets/counts', 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.us.lexful.app/v1/assets/counts",
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>",
"X-Account-ID: <x-account-id>"
],
]);
$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.us.lexful.app/v1/assets/counts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Account-ID", "<x-account-id>")
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.us.lexful.app/v1/assets/counts")
.header("X-Account-ID", "<x-account-id>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.us.lexful.app/v1/assets/counts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Account-ID"] = '<x-account-id>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"system.configuration": {
"display_name": "Configurations",
"is_system": true,
"counts": {
"019983a9-c4bf-77da-a35b-5eb177b7b859": 606,
"019983a9-c4c0-73af-aec9-463feeadc2e7": 66
}
},
"system.contact": {
"display_name": "Contacts",
"is_system": true,
"counts": {
"019983a9-c4bf-77da-a35b-5eb177b7b859": 300,
"019983a9-c4c0-73af-aec9-463feeadc2e7": 40
}
},
"custom_type": {
"display_name": "Custom Type",
"is_system": false,
"counts": {
"019983a9-c4bf-77da-a35b-5eb177b7b859": 50
}
}
}{
"status": 123,
"message": "<string>",
"error_id": "<string>",
"error_code": "<string>",
"developer_message": "<string>"
}{
"status": 123,
"message": "<string>",
"error_id": "<string>",
"error_code": "<string>",
"developer_message": "<string>"
}{
"status": 123,
"message": "<string>",
"error_id": "<string>",
"error_code": "<string>",
"developer_message": "<string>"
}Assets
Get Asset Counts
Get asset counts grouped by type and organization
GET
/
v1
/
assets
/
counts
Get Asset Counts
curl --request GET \
--url https://api.us.lexful.app/v1/assets/counts \
--header 'Authorization: Bearer <token>' \
--header 'X-Account-ID: <x-account-id>'import requests
url = "https://api.us.lexful.app/v1/assets/counts"
headers = {
"X-Account-ID": "<x-account-id>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-Account-ID': '<x-account-id>', Authorization: 'Bearer <token>'}
};
fetch('https://api.us.lexful.app/v1/assets/counts', 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.us.lexful.app/v1/assets/counts",
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>",
"X-Account-ID: <x-account-id>"
],
]);
$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.us.lexful.app/v1/assets/counts"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Account-ID", "<x-account-id>")
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.us.lexful.app/v1/assets/counts")
.header("X-Account-ID", "<x-account-id>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.us.lexful.app/v1/assets/counts")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Account-ID"] = '<x-account-id>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"system.configuration": {
"display_name": "Configurations",
"is_system": true,
"counts": {
"019983a9-c4bf-77da-a35b-5eb177b7b859": 606,
"019983a9-c4c0-73af-aec9-463feeadc2e7": 66
}
},
"system.contact": {
"display_name": "Contacts",
"is_system": true,
"counts": {
"019983a9-c4bf-77da-a35b-5eb177b7b859": 300,
"019983a9-c4c0-73af-aec9-463feeadc2e7": 40
}
},
"custom_type": {
"display_name": "Custom Type",
"is_system": false,
"counts": {
"019983a9-c4bf-77da-a35b-5eb177b7b859": 50
}
}
}{
"status": 123,
"message": "<string>",
"error_id": "<string>",
"error_code": "<string>",
"developer_message": "<string>"
}{
"status": 123,
"message": "<string>",
"error_id": "<string>",
"error_code": "<string>",
"developer_message": "<string>"
}{
"status": 123,
"message": "<string>",
"error_id": "<string>",
"error_code": "<string>",
"developer_message": "<string>"
}Query Parameters
Response
Asset counts grouped by type and organization. Keys are asset type names, values are objects containing display name, system flag, and organization counts.
Was this page helpful?