api_logs
Retrieve an API log
Changed onThis endpoint retrieves an existing API log, which represents a request made to Lago's API. The API log is identified by its request id.
get/api_logs/{request_id}
Request
- Base URLhttps://api.getlago.com/api/v1
- AuthHTTP bearer
- TypeScriptA function with typed inputs. Its response is checked against the schema.
Response
API log
Example response
{
"api_log": {
"api_version": "v1",
"client": "Lago Ruby v1.26.0",
"http_method": "post",
"http_status": 200,
"logged_at": "2025-03-31T12:31:44Z",
"request_body": {
"billable_metric": "{\"name\":\"Storage\",\"code\":\"storage\"}"
},
"request_origin": "https://api.getlago.com",
"request_path": "/api/v1/billable_metrics",
"created_at": "2022-04-29T08:59:51Z",
"request_id": "1a901a90-1a90-1a90-1a90-1a901a901a90",
"request_response": {
"billable_metric": "{\"lago_id\":\"b9155544-e261-4e92-b54e-f65d7609294c\"}"
}
}
}Changes
- breaking
the response property
/became nullable for the status - breaking
the
/response's property type changed fromstringtoobject, and format fromobjectto no format for status - breaking
the
/response's property format changed fromuuidto no format for status - breaking
the
/response's property type changed fromstringtoobjectnull, and format fromobjectto no format for status - warning
added the new
patchenum value to the/response property for the response status - info
added the non-success response with the status
- info
the response property
/became required for the status
- breaking