Skip to content

Get OCPP Logs

GET
/tenant/{tenantId}/logs/ocpp
curl --request GET \
--url https://api.exolink.cloud/tenant/example/logs/ocpp \
--header 'Authorization: Bearer <token>' \
--header 'x-exo-actions: BootNotification,Heartbeat' \
--header 'x-exo-direction: charger' \
--header 'x-exo-logs-format: csv' \
--header 'x-exo-msg-types: CALL,CALLERROR'

Get OCPP communication logs, in one of three modes:

  • With x-exo-logs-format, the logs are stored as a file and the response carries a download link.
  • Otherwise, with x-exo-size, one page of the logs, newest first. Pass the returned nextCursor as x-exo-cursor for the next page. Only this mode applies the x-exo-actions, x-exo-msg-types, x-exo-direction, x-exo-msg-id and x-exo-search filters.
  • Otherwise, the JSON list of all log rows in the range.
tenantId
required
string

Tenant domain prefix

x-exo-from
string format: date-time

Start of the log range. Defaults to the start of the current UTC day.

x-exo-to
string format: date-time

End of the log range. Defaults to the end of the current UTC day.

x-exo-logs-format
string

Return a download link instead of the logs. csv stores a CSV file, any other value a JSON file.

Example

csv
x-exo-charger-ids
string

Comma-separated charger identities

x-exo-size
integer
>= 1 <= 1000

Page size; selects the paged list

x-exo-cursor
string

The nextCursor of the previous page

x-exo-actions
string

Comma-separated OCPP actions

Example

BootNotification,Heartbeat
x-exo-msg-types
string

Comma-separated message types out of CALL, CALLRESULT, CALLERROR

Example

CALL,CALLERROR
x-exo-direction
string
Allowed values: charger cpms

Sender of the message

x-exo-msg-id
string
<= 200 characters

OCPP message ID

x-exo-search
string
<= 200 characters

Text to search for in the message

OCPP logs, a page of them, or the download link

Media typeapplication/json
One of:
Array<object>
object

Example

{
"expiresIn": 3600
}

Malformed request

Media typeapplication/json

Error response. Some rejections carry only message.

object
message
required

Error message

string
errorCode

Error code

string
Allowed values: ERR_API_BAD_REQUEST ERR_API_NOT_AUTHORIZED ERR_API_PAYMENT_REQUIRED ERR_API_FORBIDDEN ERR_API_RESOURCE_NOT_FOUND ERR_API_RESOURCE_IN_USE ERR_API_RESOURCE_ALREADY_EXISTS ERR_API_UNEXPECTED_STATE ERR_API_CONTENT_TOO_LARGE ERR_API_VALIDATION_FAILED ERR_API_VERIFICATION_FAILED ERR_API_NO_TENANT ERR_API_INVALID_INVITATION ERR_API_USER_DISABLED ERR_API_FAILED_DEPENDENCY ERR_EXOLINK_GENERIC
details

Failed validations, for requests checked against a schema

Array<object>
object
path

Path of the invalid field

string
message
string
code
string

Example

{
"message": "Bad Request",
"errorCode": "ERR_API_BAD_REQUEST"
}

Missing, invalid or expired credentials

Media typeapplication/json

Error response. Some rejections carry only message.

object
message
required

Error message

string
errorCode

Error code

string
Allowed values: ERR_API_BAD_REQUEST ERR_API_NOT_AUTHORIZED ERR_API_PAYMENT_REQUIRED ERR_API_FORBIDDEN ERR_API_RESOURCE_NOT_FOUND ERR_API_RESOURCE_IN_USE ERR_API_RESOURCE_ALREADY_EXISTS ERR_API_UNEXPECTED_STATE ERR_API_CONTENT_TOO_LARGE ERR_API_VALIDATION_FAILED ERR_API_VERIFICATION_FAILED ERR_API_NO_TENANT ERR_API_INVALID_INVITATION ERR_API_USER_DISABLED ERR_API_FAILED_DEPENDENCY ERR_EXOLINK_GENERIC
details

Failed validations, for requests checked against a schema

Array<object>
object
path

Path of the invalid field

string
message
string
code
string

Example

{
"message": "Not authorized",
"errorCode": "ERR_API_NOT_AUTHORIZED"
}

The caller may not perform this action

Media typeapplication/json

Error response. Some rejections carry only message.

object
message
required

Error message

string
errorCode

Error code

string
Allowed values: ERR_API_BAD_REQUEST ERR_API_NOT_AUTHORIZED ERR_API_PAYMENT_REQUIRED ERR_API_FORBIDDEN ERR_API_RESOURCE_NOT_FOUND ERR_API_RESOURCE_IN_USE ERR_API_RESOURCE_ALREADY_EXISTS ERR_API_UNEXPECTED_STATE ERR_API_CONTENT_TOO_LARGE ERR_API_VALIDATION_FAILED ERR_API_VERIFICATION_FAILED ERR_API_NO_TENANT ERR_API_INVALID_INVITATION ERR_API_USER_DISABLED ERR_API_FAILED_DEPENDENCY ERR_EXOLINK_GENERIC
details

Failed validations, for requests checked against a schema

Array<object>
object
path

Path of the invalid field

string
message
string
code
string

Example

{
"message": "Forbidden",
"errorCode": "ERR_API_FORBIDDEN"
}

Result too large to return

Media typeapplication/json

Error response. Some rejections carry only message.

object
message
required

Error message

string
errorCode

Error code

string
Allowed values: ERR_API_BAD_REQUEST ERR_API_NOT_AUTHORIZED ERR_API_PAYMENT_REQUIRED ERR_API_FORBIDDEN ERR_API_RESOURCE_NOT_FOUND ERR_API_RESOURCE_IN_USE ERR_API_RESOURCE_ALREADY_EXISTS ERR_API_UNEXPECTED_STATE ERR_API_CONTENT_TOO_LARGE ERR_API_VALIDATION_FAILED ERR_API_VERIFICATION_FAILED ERR_API_NO_TENANT ERR_API_INVALID_INVITATION ERR_API_USER_DISABLED ERR_API_FAILED_DEPENDENCY ERR_EXOLINK_GENERIC
details

Failed validations, for requests checked against a schema

Array<object>
object
path

Path of the invalid field

string
message
string
code
string

Example

{
"message": "Content too large",
"errorCode": "ERR_API_CONTENT_TOO_LARGE"
}