---
title: "Get service log entries"
method: POST
path: "/project/{project}/service/{service_name}/logs"
tags: ["Service"]
---

# Get service log entries

`POST /project/{project}/service/{service_name}/logs`

## Path parameters

- `project` string, required
- `service_name` string, required

## Request body

- ProjectGetServiceLogsRequestBody — ProjectGetServiceLogsRequestBody
  - `limit` integer — How many log entries to receive at most
  - `log_type` 'application-build' | 'application-run' — Filter to entries of a specific application log type. Only supported for application services. When omitted on application services, runtime logs (application-run) are returned.
  - `offset` string — Opaque offset identifier
  - `severity` 'emerg' | 'alert' | 'crit' | 'err' | 'warning' | 'notice' | 'info' | 'debug' — Filter to entries with severity at least as severe as this value
  - `sort_order` 'desc' | 'asc' — Sort order for log messages

## Response `200`

Response

- ProjectGetServiceLogsResponse — ProjectGetServiceLogsResponse
  - `errors` object[] — List of errors occurred during request processing
    - `message` string, required — Printable error message
    - `more_info` string — URL to the documentation of the error
    - `status` integer, required — HTTP error status code
  - `first_log_offset` string, required — Opaque offset identifier of the first received log message. A null value is returned when there are no logs at all.
  - `logs` object[], required — List of log entries
    - `msg` string, required — Log message
    - `severity` string — Log severity level
    - `time` string — Timestamp in ISO 8601 format, always in UTC
    - `unit` string — SystemD unit name
  - `message` string — Printable result of the request
  - `offset` string, required — Opaque offset identifier. A null value is returned when there are no logs at all.

---

[API](https://skmtc.net/aiven/apis/aiven-api-documentation.md) · [All operations](https://skmtc.net/aiven/apis/aiven-api-documentation/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/aiven/aiven-api-documentation/revisions/ecaeabf1da31/schema)
