---
title: "Get hourly usage for audit logs"
method: GET
path: "/api/v1/usage/audit_logs"
tags: ["Usage Metering"]
deprecated: true
---

# Get hourly usage for audit logs

`GET /api/v1/usage/audit_logs`

## Request

- Base URL: `https://api.datadoghq.com`
- URL: `https://api.datadoghq.com/api/v1/usage/audit_logs`
- Auth: one of:
  - API key in header `DD-API-KEY` and API key in header `DD-APPLICATION-KEY`
  - OAuth 2
    - Authorization code: `/oauth2/v1/authorize`
    - Token URL: `/oauth2/v1/token` scopes: `usage_read`

> **Deprecated.**

Get hourly usage for audit logs.
**Note:** This endpoint has been deprecated.

## Query parameters

- `start_hr` string, date-time, required
- `end_hr` string, date-time

## Response `200`

OK

- UsageAuditLogsResponse: Response containing the audit logs usage for each hour for a given organization.
  - `usage` UsageAuditLogsHour[]: Get hourly usage for audit logs.
    - `hour` string, date-time: The hour for the usage.
    - `lines_indexed` integer, nullable: The total number of audit logs lines indexed during a given hour.
    - `org_name` string: The organization name.
    - `public_id` string: The organization public ID.

## Other responses

- `400`: Bad Request
- `403`: Forbidden - User is not authorized
- `429`: Too many requests

---

[API](https://skmtc.dev/datadog/apis/datadog-api-v1-collection.md) - [All operations](https://skmtc.dev/datadog/apis/datadog-api-v1-collection/llms.txt) - [OpenAPI document](https://skmtc.dev/datadog/apis/datadog-api-v1-collection/revisions/ca5871004d26?raw)
