GET
/
v3
/
analytics
/
usage
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('https://api.supermemory.ai/v3/analytics/usage', options)
  .then(response => response.json())
  .then(response => console.log(response))
  .catch(err => console.error(err));
{
  "totalMemories": 123,
  "usage": [
    {
      "type": "add",
      "count": 123,
      "avgDuration": 123,
      "lastUsed": "<string>"
    }
  ],
  "hourly": [
    {
      "hour": "<string>",
      "count": 123,
      "avgDuration": 123
    }
  ],
  "byKey": [
    {
      "keyId": "<string>",
      "keyName": "<string>",
      "count": 123,
      "lastUsed": "<string>",
      "avgDuration": 123
    }
  ],
  "pagination": {
    "currentPage": 1,
    "totalPages": 10,
    "limit": 10,
    "totalItems": 100
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Response

200
application/json

Usage stats

The response is of type object.