logs

Retrieve App Services logs

get/groups/{groupId}/apps/{appId}/logs

Query parameters

co_idstring

Return only log messages associated with the given request Correlation ID.

errors_onlyboolean

The value of this field does not matter. If included in the request, this endpoint only returns error logs (even if the value is set to false). If this field is excluded from the request, this endpoint only returns non-error logs.

user_idstring

Return only log messages associated with the given user_id.

start_datestring

The date and time in ISO 8601 at which to begin returning results, exclusive.

end_datestring

The date and time in ISO 8601 at which to cease returning results, inclusive.

skipinteger

The offset number of matching log entries to skip before including them in the response.

limitinteger

The maximum number of log entries to include in the response. If the query matches more than this many logs, it returns documents in ascending order by date until the limit is reached.

type'TRIGGER_FAILURE' | 'TRIGGER_ERROR_HANDLER' | 'DB_TRIGGER' | 'AUTH_TRIGGER' | 'SCHEDULED_TRIGGER' | 'FUNCTION' | 'SERVICE_FUNCTION' | 'STREAM_FUNCTION' | 'SERVICE_STREAM_FUNCTION' | 'AUTH' | 'WEBHOOK' | 'ENDPOINT' | 'PUSH' | 'API' | 'API_KEY' | 'GRAPHQL' | 'SYNC_CONNECTION_START' | 'SYNC_CONNECTION_END' | 'SYNC_SESSION_START' | 'SYNC_SESSION_END' | 'SYNC_CLIENT_WRITE' | 'SYNC_ERROR' | 'SYNC_OTHER' | 'SCHEMA_ADDITIVE_CHANGE' | 'SCHEMA_GENERATION' | 'SCHEMA_VALIDATION' | 'LOG_FORWARDER'

The kind of log you would like to retrieve.

Response

Successfully retrieved.

nextEndDatestring required

The end date and time of the next page of log entries in ISO 8601 format. App Services paginates the result sets of queries that match more than 100 log entries and includes this field in paginated responses. To get the next page of up to 100 entries, pass this value as the end_date parameter in a subsequent request.

nextSkipinteger required

The offset into the next page of log entries in ISO 8601 format. MongoDB App Services paginates the result sets of queries that match more than 100 log entries and includes this field in paginated responses where the first entry on the next page has the same timestamp as the last entry on this page. To get the next page of up to 100 entries, pass this value, if it is present, as the skip parameter in a subsequent request.

Changes

Changed in 2 of the 50 revisions of this API.3121

  • v32ac2149ab3ee11See the full diff
    • added TriggerErrorHandler to the logs/items/ response property oneOf list for the response status 200

      response-property-one-of-added

    • added the new enum value TRIGGER_ERROR_HANDLER to the query request parameter type

      request-parameter-enum-value-added

  • v367a4425e31b4212See the full diff
    • added API APIKey TriggerFailure DBEventTrigger AuthEventTrigger ScheduledEventTrigger Function ServiceFunction StreamFunction ServiceStreamFunction Auth IncomingWebhook Endpoint Push GraphQL SyncConnectionStart SyncConnectionEnd SyncSessionStart SyncSessionEnd SyncClientWrite SyncError SyncOther SchemaAdditiveChange SchemaGeneration SchemaValidation LogForwarder to the logs/items/ response property oneOf list for the response status 200

      response-property-one-of-added

    • the logs/items/ response's property type/format changed from object/ to / for status 200

      response-property-type-changed

    • removed the optional property logs/items/_id from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/app_id from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/co_id from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/completed from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/domain_id from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/error from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/error_code from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/group_id from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/request_method from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/request_url from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/started from the response with the 200 status

      response-optional-property-removed

    • removed the optional property logs/items/status from the response with the 200 status

      response-optional-property-removed