Get the signed-in user's own per-turn µ spend (D5 per-user visibility)
curl --request GET \
--url https://api.mnemom.ai/v1/billing/usage/per-turn \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.mnemom.ai/v1/billing/usage/per-turn"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.mnemom.ai/v1/billing/usage/per-turn', 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.mnemom.ai/v1/billing/usage/per-turn",
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.mnemom.ai/v1/billing/usage/per-turn"
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.mnemom.ai/v1/billing/usage/per-turn")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mnemom.ai/v1/billing/usage/per-turn")
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{
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"basis": "rate_card_estimate",
"data": [
{
"id": "<string>",
"occurred_at": "2023-11-07T05:31:56Z",
"provider": "<string>",
"model": "<string>",
"tokens_in": "<string>",
"tokens_out": "<string>",
"estimated_cost_usd": 123,
"estimated_mmu": "<string>",
"estimated_mu": "<string>"
}
],
"totals": {
"tokens_in": "<string>",
"tokens_out": "<string>",
"turn_count": "<string>",
"estimated_cost_usd": 123,
"estimated_mmu": "<string>",
"estimated_mu": "<string>",
"totals_unavailable": true
},
"next_cursor": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}
}Billing
Get the signed-in user's own per-turn µ spend (D5 per-user visibility)
Returns the CURRENT user’s own per-turn spend, self-scoped by session sub only — there is no person_id parameter and a user can never read another person’s t…
GET
/
billing
/
usage
/
per-turn
Get the signed-in user's own per-turn µ spend (D5 per-user visibility)
curl --request GET \
--url https://api.mnemom.ai/v1/billing/usage/per-turn \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.mnemom.ai/v1/billing/usage/per-turn"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.mnemom.ai/v1/billing/usage/per-turn', 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.mnemom.ai/v1/billing/usage/per-turn",
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.mnemom.ai/v1/billing/usage/per-turn"
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.mnemom.ai/v1/billing/usage/per-turn")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mnemom.ai/v1/billing/usage/per-turn")
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{
"from": "2023-11-07T05:31:56Z",
"to": "2023-11-07T05:31:56Z",
"basis": "rate_card_estimate",
"data": [
{
"id": "<string>",
"occurred_at": "2023-11-07T05:31:56Z",
"provider": "<string>",
"model": "<string>",
"tokens_in": "<string>",
"tokens_out": "<string>",
"estimated_cost_usd": 123,
"estimated_mmu": "<string>",
"estimated_mu": "<string>"
}
],
"totals": {
"tokens_in": "<string>",
"tokens_out": "<string>",
"turn_count": "<string>",
"estimated_cost_usd": 123,
"estimated_mmu": "<string>",
"estimated_mu": "<string>",
"totals_unavailable": true
},
"next_cursor": "<string>"
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}
}{
"error": {
"code": "<string>",
"message": "<string>",
"details": "<unknown>"
}
}Authorizations
BearerAuthCookieAuth
Supabase JWT token in Authorization: Bearer header
Query Parameters
Lookback window in days. One of 7, 30, 90.
Available options:
7, 30, 90 Max turns per page (clamped to 200).
Required range:
1 <= x <= 200Opaque keyset cursor from a prior response's next_cursor.
Response
The user's own per-turn spend (estimated) for the window.
Always rate_card_estimate — the µ figures are derived from token counts, not the settled ledger burn.
Available options:
rate_card_estimate Show child attributes
Show child attributes
Show child attributes
Show child attributes