List a bot's logs
GET https://rest.haasapi.com/v1/partner/users/{user_id}/bots/{bot_id}/logs
Returns a bot’s most recent log entries, parsed into structured entries (timestamp, severity, message). The most recent page only.
Requires the partner scope.
Example request
Section titled “Example request”curl "https://rest.haasapi.com/v1/partner/users/{user_id}/bots/{bot_id}/logs" \ -H "Authorization: Bearer hk_live_YOUR_KEY"Response
Section titled “Response”200 OK. Returns a PartnerBotLogs.
{ "data": [ { "timestamp": "2026-08-28T19:04:11Z", "severity": "trade", "message": "Placed buy order at 25000." }, { "timestamp": "2026-08-28T19:05:00Z", "severity": "info", "message": "Grid rebalanced." } ]}Fields
Section titled “Fields”PartnerBotLogs
Section titled “PartnerBotLogs”| Field | Type | Description |
|---|---|---|
data |
array of PartnerBotLogEntry | The bot’s most recent log entries, newest first. |
PartnerBotLogEntry
Section titled “PartnerBotLogEntry”| Field | Type | Description |
|---|---|---|
timestamp |
string, nullable | When the line was logged. RFC 3339 UTC. |
severity |
string | info, trade, warning, error, or custom. |
message |
string |
Errors
Section titled “Errors”All errors are RFC 9457 problem documents.
| Status | Description |
|---|---|
400 |
The request is malformed (invalid limit, unusable cursor, …). (code: invalid_request) |
401 |
Missing, malformed, disabled, or revoked API key. (code: invalid_api_key) |
404 |
No accessible bot with that id for this end-user. (code: bot_not_found) |
500 |
An unexpected error inside the API. Nothing about the request caused it; retry, and quote the instance value if it persists. (code: internal_error) |
502 |
An internal service answered in a way the API could not serve. Retry. (code: upstream_error) |
503 |
The request could not be served right now. Retry with the same key - do not discard it. (code: temporarily_unavailable) |
504 |
An internal service did not answer within the deadline. Retry with backoff. (code: upstream_timeout) |
{ "type": "https://docs.haasapi.com/errors/invalid_request", "title": "Invalid request", "status": 400, "detail": "The request is malformed (invalid limit, unusable cursor, …).", "code": "invalid_request"}