Skip to main content
Glama

Datadog MCP Server

by brukhabtu
  • Apple
  • Linux

ListLogsGet

Search and retrieve logs matching specific criteria using query parameters like timestamp, storage tier, and indexes. Paginate results for efficient log management.

Instructions

List endpoint returns logs that match a log search query. Results are paginated.

Use this endpoint to search and filter your logs.

If you are considering archiving logs for your organization, consider use of the Datadog archive capabilities instead of the log list API. See Datadog Logs Archive documentation.

Query Parameters:

  • filter[query]: Search query following logs syntax.
  • filter[indexes]: For customers with multiple indexes, the indexes to search. Defaults to '*' which means all indexes
  • filter[from]: Minimum timestamp for requested logs.
  • filter[to]: Maximum timestamp for requested logs.
  • filter[storage_tier]: Specifies the storage type to be used
  • sort: Order of logs in results.
  • page[cursor]: List following results with a cursor provided in the previous query.
  • page[limit]: Maximum number of logs in the response.

Responses:

  • 200 (Success): OK
    • Content-Type: application/json
    • Response Properties:
      • data: Array of logs matching the request.
    • Example:
{ "data": [ "unknown_type" ], "links": "unknown_type", "meta": "unknown_type" }
  • 400: Bad Request
    • Content-Type: application/json
    • Response Properties:
      • errors: A list of errors.
    • Example:
{ "errors": [ "Bad Request" ] }
  • 403: Not Authorized
    • Content-Type: application/json
    • Response Properties:
      • errors: A list of errors.
    • Example:
{ "errors": [ "Bad Request" ] }
  • 429: Too many requests
    • Content-Type: application/json
    • Response Properties:
      • errors: A list of errors.
    • Example:
{ "errors": [ "Bad Request" ] }

Input Schema

NameRequiredDescriptionDefault
filter[from]NoMinimum timestamp for requested logs.
filter[indexes]NoFor customers with multiple indexes, the indexes to search. Defaults to '*' which means all indexes
filter[query]NoSearch query following logs syntax.
filter[storage_tier]NoSpecifies storage type as indexes, online-archives or flexindexes
filter[to]NoMaximum timestamp for requested logs.
page[cursor]NoList following results with a cursor provided in the previous query.
page[limit]NoMaximum number of logs in the response.
sortNoSort parameters when querying logs.

Input Schema (JSON Schema)

{ "properties": { "filter[from]": { "description": "Minimum timestamp for requested logs.", "format": "date-time", "type": "string" }, "filter[indexes]": { "description": "For customers with multiple indexes, the indexes to search.\nDefaults to '*' which means all indexes", "items": { "description": "The name of a log index.", "type": "string" }, "type": "array" }, "filter[query]": { "description": "Search query following logs syntax.", "type": "string" }, "filter[storage_tier]": { "default": "indexes", "description": "Specifies storage type as indexes, online-archives or flex", "enum": [ "indexes", "online-archives", "flex" ], "example": "indexes", "type": "string", "x-enum-varnames": [ "INDEXES", "ONLINE_ARCHIVES", "FLEX" ] }, "filter[to]": { "description": "Maximum timestamp for requested logs.", "format": "date-time", "type": "string" }, "page[cursor]": { "description": "List following results with a cursor provided in the previous query.", "type": "string" }, "page[limit]": { "default": 10, "description": "Maximum number of logs in the response.", "format": "int32", "maximum": 1000, "type": "integer" }, "sort": { "description": "Sort parameters when querying logs.", "enum": [ "timestamp", "-timestamp" ], "type": "string", "x-enum-varnames": [ "TIMESTAMP_ASCENDING", "TIMESTAMP_DESCENDING" ] } }, "required": [], "type": "object" }

You must be authenticated.

Other Tools from Datadog MCP Server

Related Tools

    MCP directory API

    We provide all the information about MCP servers via our MCP API.

    curl -X GET 'https://glama.ai/api/mcp/v1/servers/brukhabtu/datadog-mcp'

    If you have feedback or need assistance with the MCP directory API, please join our Discord server