---
title: "Get stats"
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.sureshake.com/llms.txt
> Use this file to discover all available pages before exploring further.

Path: Sureshake API › entities

`GET /v2/entities/stats`

## Query parameters

- `not` (`entity-get-stats.query.not`; unknown, optional)
- `period` (`entity-get-stats.query.period`; string, optional)
  - one of `"week"`, `"month"`, `"quarter"`, `"year"`, `"all"`; default `"all"`
- `groupBy` (`entity-get-stats.query.groupBy`; string, optional)
  - one of `"entityType"`, `"collection"`, `"parent"`

## Code samples

### cURL

```bash
curl --request GET \
  --url https://api.sureshake.com/v2/entities/stats
```

### TypeScript

```typescript
const url = 'https://api.sureshake.com/v2/entities/stats';
const options = {method: 'GET'};

fetch(url, options)
  .then(res => res.json())
  .then(json => console.log(json))
  .catch(err => console.error(err));
```

### Python

```python
import requests

url = "https://api.sureshake.com/v2/entities/stats"

response = requests.get(url)

print(response.text)
```

## Responses

### 200

Default Response

#### Example

```json
{
  "data": {
    "total": 0,
    "owned": 0
  }
}
```

- `data` (`entity-get-stats.response.200.data`; object, required)
  - `total` (`entity-get-stats.response.200.data.total`; number, required)
  - `owned` (`entity-get-stats.response.200.data.owned`; number, required)

### 400

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`entity-get-stats.response.400.error`; object, required)
  - `code` (`entity-get-stats.response.400.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`entity-get-stats.response.400.error.message`; string, required) — Human-readable error message
  - `details` (`entity-get-stats.response.400.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`entity-get-stats.response.400.error.traceId`; string, optional) — Unique ID for log correlation

### 401

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`entity-get-stats.response.401.error`; object, required)
  - `code` (`entity-get-stats.response.401.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`entity-get-stats.response.401.error.message`; string, required) — Human-readable error message
  - `details` (`entity-get-stats.response.401.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`entity-get-stats.response.401.error.traceId`; string, optional) — Unique ID for log correlation

### 403

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`entity-get-stats.response.403.error`; object, required)
  - `code` (`entity-get-stats.response.403.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`entity-get-stats.response.403.error.message`; string, required) — Human-readable error message
  - `details` (`entity-get-stats.response.403.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`entity-get-stats.response.403.error.traceId`; string, optional) — Unique ID for log correlation

### 404

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`entity-get-stats.response.404.error`; object, required)
  - `code` (`entity-get-stats.response.404.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`entity-get-stats.response.404.error.message`; string, required) — Human-readable error message
  - `details` (`entity-get-stats.response.404.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`entity-get-stats.response.404.error.traceId`; string, optional) — Unique ID for log correlation

### 409

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`entity-get-stats.response.409.error`; object, required)
  - `code` (`entity-get-stats.response.409.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`entity-get-stats.response.409.error.message`; string, required) — Human-readable error message
  - `details` (`entity-get-stats.response.409.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`entity-get-stats.response.409.error.traceId`; string, optional) — Unique ID for log correlation

### 422

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`entity-get-stats.response.422.error`; object, required)
  - `code` (`entity-get-stats.response.422.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`entity-get-stats.response.422.error.message`; string, required) — Human-readable error message
  - `details` (`entity-get-stats.response.422.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`entity-get-stats.response.422.error.traceId`; string, optional) — Unique ID for log correlation

### 429

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`entity-get-stats.response.429.error`; object, required)
  - `code` (`entity-get-stats.response.429.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`entity-get-stats.response.429.error.message`; string, required) — Human-readable error message
  - `details` (`entity-get-stats.response.429.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`entity-get-stats.response.429.error.traceId`; string, optional) — Unique ID for log correlation

### 500

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`entity-get-stats.response.500.error`; object, required)
  - `code` (`entity-get-stats.response.500.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`entity-get-stats.response.500.error.message`; string, required) — Human-readable error message
  - `details` (`entity-get-stats.response.500.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`entity-get-stats.response.500.error.traceId`; string, optional) — Unique ID for log correlation

### 503

Default Response

#### Example

```json
{
  "error": {
    "code": "string",
    "message": "string",
    "details": null,
    "traceId": "string"
  }
}
```

- `error` (`entity-get-stats.response.503.error`; object, required)
  - `code` (`entity-get-stats.response.503.error.code`; string, required) — Machine-readable error code (e.g., NOT_FOUND)
  - `message` (`entity-get-stats.response.503.error.message`; string, required) — Human-readable error message
  - `details` (`entity-get-stats.response.503.error.details`; unknown, optional) — Optional structured error details
  - `traceId` (`entity-get-stats.response.503.error.traceId`; string, optional) — Unique ID for log correlation


Source: https://docs.sureshake.com/reference/entity-get-stats/index.md
