# Activity per service in a ticket's replay

`GET /v1/tickets/{ticket_id}/replay/timeline`

Requires role member or higher.

Lines, warnings and errors per service, in at most 200 columns. `from` and `to` must be inside the ticket's window (`422 replay-window`).

## Authentication

A session token: `Authorization: Bearer <session token>`, or the session cookie in the browser. Requires role `member` or higher.

## Parameters

| Name | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `from` | query | string | yes |  |
| `to` | query | string | yes |  |
| `environment` | query | string | no |  |
| `ticket_id` | path | string | yes |  |

## Responses

### 200

Lines, warnings and errors per service over a part of a ticket's replay window.

`application/json`

```json
{
  "additionalProperties": false,
  "description": "Lines, warnings and errors per service over a part of a ticket's replay window.",
  "properties": {
    "bucket_seconds": {
      "description": "Column width: the smallest multiple of 15 seconds that gives at most 200 columns.",
      "minimum": 15,
      "type": "integer"
    },
    "from": {
      "format": "date-time",
      "type": "string"
    },
    "gaps": {
      "description": "Stretches whose lines could not be stored. A known loss is not silence.",
      "items": {
        "additionalProperties": false,
        "properties": {
          "from": {
            "format": "date-time",
            "type": "string"
          },
          "lines": {
            "minimum": 1,
            "type": "integer"
          },
          "to": {
            "format": "date-time",
            "type": "string"
          }
        },
        "required": [
          "from",
          "to",
          "lines"
        ],
        "type": "object"
      },
      "type": "array"
    },
    "history_off": {
      "description": "Stretches when the project's log history was turned off: nothing was stored, which is not silence.",
      "items": {
        "additionalProperties": false,
        "properties": {
          "from": {
            "format": "date-time",
            "type": "string"
          },
          "to": {
            "format": "date-time",
            "type": "string"
          }
        },
        "required": [
          "from",
          "to"
        ],
        "type": "object"
      },
      "type": "array"
    },
    "other_services": {
      "description": "Services beyond the 100 returned.",
      "minimum": 0,
      "type": "integer"
    },
    "pending_until": {
      "anyOf": [
        {
          "format": "date-time",
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "description": "Lines after this time may still be being written; null when no archiver has reported."
    },
    "services": {
      "description": "At most 100, ordered by errors, warnings and lines.",
      "items": {
        "additionalProperties": false,
        "properties": {
          "errors": {
            "description": "One number per column, oldest first. Fatal counts as an error.",
            "items": {
              "minimum": 0,
              "type": "integer"
            },
            "type": "array"
          },
          "lines": {
            "description": "One number per column, oldest first.",
            "items": {
              "minimum": 0,
              "type": "integer"
            },
            "type": "array"
          },
          "service": {
            "type": "string"
          },
          "warnings": {
            "description": "One number per column, oldest first.",
            "items": {
              "minimum": 0,
              "type": "integer"
            },
            "type": "array"
          }
        },
        "required": [
          "service",
          "lines",
          "warnings",
          "errors"
        ],
        "type": "object"
      },
      "type": "array"
    },
    "to": {
      "format": "date-time",
      "type": "string"
    }
  },
  "required": [
    "from",
    "to",
    "bucket_seconds",
    "services",
    "other_services",
    "gaps",
    "history_off",
    "pending_until"
  ],
  "type": "object"
}
```

### 401

unauthorized: no valid session, or the email is not verified.

Problem type: [unauthorized](https://docs.dlogify.com/errors/unauthorized.md).

### 404

not-found: the resource does not exist, or the caller is not a member of its organization.

Problem type: [not-found](https://docs.dlogify.com/errors/not-found.md).

### 422

validation-failed: the request does not match the schema.

Problem type: [validation-failed](https://docs.dlogify.com/errors/validation-failed.md).

### 429

rate-limited: per-user management request limit.

Problem type: [rate-limited](https://docs.dlogify.com/errors/rate-limited.md).

## Example

```bash
curl -X GET "https://api.dlogify.com/v1/tickets/{ticket_id}/replay/timeline" \
  -H "Authorization: Bearer $DLOGIFY_SESSION"
```

Source: https://docs.dlogify.com/api/replay/getTicketReplayTimeline
