Get stock levels with per-lot breakdown
curl --request GET \
--url https://api.maxcare.ai/v4/inventory/stock-levels/detail \
--header 'Authorization: Bearer <token>' \
--header 'X-Organization-Id: <x-organization-id>'import requests
url = "https://api.maxcare.ai/v4/inventory/stock-levels/detail"
headers = {
"X-Organization-Id": "<x-organization-id>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-Organization-Id': '<x-organization-id>', Authorization: 'Bearer <token>'}
};
fetch('https://api.maxcare.ai/v4/inventory/stock-levels/detail', 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.maxcare.ai/v4/inventory/stock-levels/detail",
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-Organization-Id: <x-organization-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.maxcare.ai/v4/inventory/stock-levels/detail"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Organization-Id", "<x-organization-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.maxcare.ai/v4/inventory/stock-levels/detail")
.header("X-Organization-Id", "<x-organization-id>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.maxcare.ai/v4/inventory/stock-levels/detail")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Organization-Id"] = '<x-organization-id>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"code": "success",
"data": {
"stockLevels": [
{
"quantity": 24,
"updatedAt": "2025-01-20T17:00:00.000Z",
"items": [
{
"lotNumber": "C4231A1",
"expirationDate": "2027-03-31",
"serialNumber": null,
"quantity": 6
}
],
"product": {
"id": "prd_b4c5d6e7f8a94b0c1d2e3f4a5b6c7d8e",
"gtin": "00814260991517",
"additionalGtins": [
"00814260991524"
],
"customBarcode": null,
"ndc": "0002-1365-01",
"name": "Botox 100 Units",
"manufacturer": "Allergan",
"type": "drug",
"description": "OnabotulinumtoxinA for injection, 100 units per vial",
"unitOfMeasure": "each",
"quantityPerUnit": 1,
"metadata": null,
"archivedAt": null,
"createdAt": "2025-01-10T12:00:00.000Z",
"updatedAt": "2025-01-15T08:30:00.000Z"
}
}
],
"stats": {
"totalProducts": 14,
"totalQuantity": 213,
"expiredCount": 1,
"expiringIn30DaysCount": 2,
"lastInventoryDate": "<string>"
}
}
}{
"code": "unauthorized",
"message": "Invalid or missing API key",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "forbidden",
"message": "Insufficient scope",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "rate_limit_exceeded",
"message": "Rate limit exceeded. Maximum 1000 requests per 60 seconds.",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}Inventory
Get stock levels with per-lot breakdown
Returns current stock levels for a facility with a per-lot breakdown (lot number, expiration date, serial number, quantity) plus expiry stats. Requires read:inventory scope.
GET
/
inventory
/
stock-levels
/
detail
Get stock levels with per-lot breakdown
curl --request GET \
--url https://api.maxcare.ai/v4/inventory/stock-levels/detail \
--header 'Authorization: Bearer <token>' \
--header 'X-Organization-Id: <x-organization-id>'import requests
url = "https://api.maxcare.ai/v4/inventory/stock-levels/detail"
headers = {
"X-Organization-Id": "<x-organization-id>",
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {'X-Organization-Id': '<x-organization-id>', Authorization: 'Bearer <token>'}
};
fetch('https://api.maxcare.ai/v4/inventory/stock-levels/detail', 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.maxcare.ai/v4/inventory/stock-levels/detail",
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-Organization-Id: <x-organization-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.maxcare.ai/v4/inventory/stock-levels/detail"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-Organization-Id", "<x-organization-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.maxcare.ai/v4/inventory/stock-levels/detail")
.header("X-Organization-Id", "<x-organization-id>")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.maxcare.ai/v4/inventory/stock-levels/detail")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-Organization-Id"] = '<x-organization-id>'
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"code": "success",
"data": {
"stockLevels": [
{
"quantity": 24,
"updatedAt": "2025-01-20T17:00:00.000Z",
"items": [
{
"lotNumber": "C4231A1",
"expirationDate": "2027-03-31",
"serialNumber": null,
"quantity": 6
}
],
"product": {
"id": "prd_b4c5d6e7f8a94b0c1d2e3f4a5b6c7d8e",
"gtin": "00814260991517",
"additionalGtins": [
"00814260991524"
],
"customBarcode": null,
"ndc": "0002-1365-01",
"name": "Botox 100 Units",
"manufacturer": "Allergan",
"type": "drug",
"description": "OnabotulinumtoxinA for injection, 100 units per vial",
"unitOfMeasure": "each",
"quantityPerUnit": 1,
"metadata": null,
"archivedAt": null,
"createdAt": "2025-01-10T12:00:00.000Z",
"updatedAt": "2025-01-15T08:30:00.000Z"
}
}
],
"stats": {
"totalProducts": 14,
"totalQuantity": 213,
"expiredCount": 1,
"expiringIn30DaysCount": 2,
"lastInventoryDate": "<string>"
}
}
}{
"code": "unauthorized",
"message": "Invalid or missing API key",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "forbidden",
"message": "Insufficient scope",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}{
"code": "rate_limit_exceeded",
"message": "Rate limit exceeded. Maximum 1000 requests per 60 seconds.",
"trace_id": "550e8400-e29b-41d4-a716-446655440000"
}Authorizations
Marketplace API key
Headers
Target clinic organization ID
Query Parameters
Facility ID to get stock levels for
