Skip to the page

Retrieve log

One request: what was asked, what was answered and how long it took.

opensend.logs.get(id)
Needs the scopelogs:readFrom a terminalopensend logs get

Input

id goes first, on its own, and the rest in one object. One object that holds id works too.

  • idstringRequired

    The id of the item. Up to 64 characters.

Returns

The call resolves to the answer, already parsed. A call the API refuses throws OpenSendError with the code and the message of the answer. SDK lists the errors of the client itself.

  • object"log"

    Always log.

  • idstring

    The id of the log entry.

  • methodstring

    The HTTP verb of the request.

    One ofGETPOSTPATCHDELETE

  • pathstring

    The path that was asked for.

  • statusinteger

    The HTTP status of the answer.

  • outcomestring

    success for a 2xx answer, client_error for 4xx, server_error for 5xx.

    One ofsuccessclient_errorserver_error

  • durationMsnumber

    How long the request took, in milliseconds.

  • keyIdstring | null

    The id of the API key that made it, or null.

  • userAgentstring

    What the client called itself.

  • requestIdstring

    The id the answer carried in its request id header. Empty on an older entry.

  • errorobject | null

    Why the request failed, or null when it did not.

  • error.typestring

    The kind of error, as in the answer.

  • error.codestring

    The code of the error, as in the answer.

  • error.messagestring

    What the answer said was wrong.

  • resourceobject | null

    What a request that changed something made or changed, or null.

  • resource.objectstring

    The kind of thing, such as email or domain.

  • resource.idstring

    Its id.

  • toolstring | null

    The tool an MCP request called, such as emails_send, or null.

  • createdAtstring

    When the request was made.