# The events' counts

Source: https://amanucci.com/fr/docs/developers/api/events/getEventTotals

## GET /v1/entities/{entityId}/event-totals

The events' counts

The Events strip: the events whose decision date falls in the days asked, counted by the server over every one by the list's own `status`, so no page bound caps them. The status is computed before the client paint, as the row's chip is. `period` or `from`/`to` as `listEvents` takes them.

Operation ID: `getEventTotals`

### Parameters

```json
[
  {
    "schema": {
      "type": "string",
      "format": "uuid"
    },
    "required": true,
    "name": "entityId",
    "in": "path"
  },
  {
    "schema": {
      "type": "string",
      "format": "date",
      "description": "The first decision date to count, inclusive."
    },
    "required": false,
    "description": "The first decision date to count, inclusive.",
    "name": "from",
    "in": "query"
  },
  {
    "schema": {
      "type": "string",
      "description": "The days to list, resolved by the server against today in the books' own day (Europe/Brussels): `7d` and `30d` (the last 7 or 30 days, today included), `month`, `last-month`, `quarter`, `last-quarter` and `year` (the whole calendar unit holding today, or the one before it), a year `2026`, a quarter `2026-q3`, a month `2026-03`, `all` (no bound), or a day range `2026-01-05..2026-02-10` (inclusive, its ends in order). Not with `from` or `to`.",
      "example": "quarter"
    },
    "required": false,
    "description": "The days to list, resolved by the server against today in the books' own day (Europe/Brussels): `7d` and `30d` (the last 7 or 30 days, today included), `month`, `last-month`, `quarter`, `last-quarter` and `year` (the whole calendar unit holding today, or the one before it), a year `2026`, a quarter `2026-q3`, a month `2026-03`, `all` (no bound), or a day range `2026-01-05..2026-02-10` (inclusive, its ends in order). Not with `from` or `to`.",
    "name": "period",
    "in": "query"
  },
  {
    "schema": {
      "type": "string",
      "format": "date",
      "description": "The last decision date to count, inclusive."
    },
    "required": false,
    "description": "The last decision date to count, inclusive.",
    "name": "to",
    "in": "query"
  }
]
```

### Responses

#### 200 The strip's counts.

```json
{
  "application/json": {
    "schema": {
      "$ref": "#/components/schemas/EventTotals"
    }
  }
}
```

#### 401 Dead or absent credential (`unauthenticated`).

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```

#### 403 Authenticated, present, and refused: a missing grant, a missing seat, or a missing step-up.

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```

#### 404 Absent, or hidden from this asker — the two are indistinguishable (`not-found`).

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```

#### 422 The request did not satisfy the schema (`invalid-input`).

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```

#### 429 Too many requests on this door's bucket (`rate-limited`); refused before any handler ran, `Retry-After` says when to come back.

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```

#### 503 Temporarily unavailable; `Retry-After` says when to come back.

```json
{
  "application/problem+json": {
    "schema": {
      "$ref": "#/components/schemas/Problem"
    }
  }
}
```
