Search payloads

post/v1/environments/{environmentId}/logs/search/payloads
Page View

Logs endpoints allow you to review log metadata, including relevant timestamps and statuses. Or, if you want to dig into a log for troubleshooting purposes, you can run log inspector.

You can retrieve a list of log metadata, search for specific data within log payloads, retrieve one log with its metadata, or run log inspector.

Search payloads

Query for relevant logs using a particular search term. This endpoint allows you to search content within log payloads.

The response contains a list of metadata for matching logs based on the criteria you specify with query parameters. Log payloads aren't included. To review payloads, take the log ID from the list in the response and review the corresponding log payload in the Redox dashboard. Learn how to search for logs.

Usually, the list is qualified by a specific time range, like if you want to see what kind of traffic has happened within the last 3 hours. If retrieving a large list of logs, we recommend setting a date range with updatedAfter and updatedBefore to improve query performance and ensure you retrieve an accurate dataset.

Only users assigned to support or engineer roles can search log payloads. Learn about roles.

Request parameters and payload

cURL request example

bash
1
curl 'https://api.redoxengine.com/platform/v1/environments/{environmentId}/logs/search/payloads' \
2
--request POST \
3
--header 'Authorization: Bearer $API_TOKEN' \
4
--header 'accept: application/json' \
5
--header 'content-type: application/json' \
6
--data '{
7
"searchTerms": [
8
{
9
"value": "Nila Jonkel",
10
"category": "patient"
11
}
12
],
13
"dataMode": "realtime",
14
"serviceRegion": "AWS_USA_EAST_1",
15
"dataModel": "PatientAdmin",
16
"eventType": "Transfer",
17
"createdAfter": "2023-01-01T00:00:00.000Z",
18
"createdBefore": "2023-01-31T23:59:59.999Z",
19
"updatedAfter": "2023-01-01T00:00:00.000Z",
20
"updatedBefore": "2023-01-31T23:59:59.999Z",
21
"sourceId": "797f5a94-3689-4ac8-82fd-d749511ea2b2",
22
"destinationId": "d0a0ebc7-d6b4-4f3c-a5af-5761a8148e3a",
23
"type": "receive",
24
"status": "succeeded"
25
}'

Path Parameters

  • environmentId
    required, string

    Identifies the specific environment that you're operating in or on behalf of.

Query Parameters

  • _count
    number

    Defines the number of results to return per page. The maximum value per page is 50.

  • _cursor
    string

    Identifies the next set of results for a given search.

Request Body Schema

    You must include a requestBody, even if it's empty.

  • searchTerms
    Array of object

    Contains any keywords you want to use to search log content by. You can include one term per search.

    • value
      string

      Contains the value that you're searching for in the log metadata or payload.

    • category
      string

      Specifies that the logs to search are those with the indicated category. By default, if you indicate null, it means that the logs to search are those explicitly with no category.

      Possible Values: metadata, patient, provider, record, visit, null
  • dataMode
    string

    Indicates the type of log traffic to search (e.g., backfill or realtime). Backfill traffic is typically historical data that populates your system prior to go-live with your connection. Real-time traffic is normal traffic that happens between you and your connection after go-live. By default, log searches only query your database for real-time traffic unless you set this parameter to backfill. Leaving this parameter blank maintains default behavior.

    Possible Values: realtime, backfill
  • serviceRegion
    string

    This field is required if your environment is configured with multiple regions.

    Possible Values: AWS_USA_EAST_1, AWS_CAN_CENTRAL, GCP_USA_CENTRAL_1
  • dataModel
    string

    Indicates the data model used to exchange data.\n\nThis is the equivalent of the Meta.DataModel field in our data models.

  • eventType
    string

    Indicates the particular event type of a data model that's used to exchange data.\n\nThis is the equivalent of the Meta.EventType field in our data models.

  • createdAfter
    string

    Used to set a date range for the logs to search, which we recommend if you plan to export large amounts of log metadata. This parameter designates that the creation date for the logs to search should be equal to or greater than the date and time in this format (YYYY-MM-DDThh:mm:ss.sssZ).

    Format: date-time
  • createdBefore
    string

    Used to set a date range for the logs to search, which we recommend if you plan to export large amounts of log metadata. This parameter designates that the creation date for the logs to search should be less than or equal to the date and time in this format (YYYY-MM-DDThh:mm:ss.sssZ).

    Format: date-time
  • updatedAfter
    string

    Used to set a date range for the logs to search, which we recommend if you plan to export large amounts of log metadata. This parameter designates that the last updated date for the logs to search should be equal to or creater than the date and time in this format (YYYY-MM-DDThh:mm:ss.sssZ).

    Format: date-time
  • updatedBefore
    string

    Used to set a date range for the logs to search, which we recommend if you plan to export large amounts of log metadata. This parameter designates that the last updated date for the logs to search should be less than or equal to the date and time in this format (YYYY-MM-DDThh:mm:ss.sssZ).

    Format: date-time
  • sourceId
    string

    Contains the unique identifier of the source.

    Format: uuid
  • destinationId
    string

    Contains the unique identifier of the destination.

    Format: uuid
  • type
    string

    Indicates the type of data exchange that initiated the log (e.g., send, receive, request, respond, unknown).

    Possible Values: receive, request, respond, send, unknown
  • status
    string

    Indicates the current status of the log [e.g., succeeded, failed, filtered, pending].

    Possible Values: failed, filtered, pending, succeeded

Response fields and example

Example payload generated from schema
1
{
2
"meta": {
3
"version": "1.0.0",
4
"links": {
5
"self": "string",
6
"first": "string",
7
"next": "string"
8
},
9
"pageSize": 0,
10
"pageType": "cursor"
11
},
12
"payload": {
13
"results": [
14
{
15
"matchCategories": [
16
"record"
17
],
18
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
19
"createdAt": "2024-02-27T17:50:10.584Z",
20
"updatedAt": "2024-02-27T17:50:10.584Z",
21
"dataModel": "PatientAdmin",
22
"eventType": "Transfer",
23
"status": "succeeded",
24
"type": "receive",
25
"source": {
26
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
27
"name": "string",
28
"organization": {
29
"id": 122,
30
"name": "string"
31
}
32
},
33
"destination": {
34
"id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
35
"name": "string",
36
"organization": {
37
"id": 122,
38
"name": "string"
39
}
40
}
41
}
42
]
43
}
44
}
  • meta
    object

    Contains metadata about paginated results of returned data.

    • version
      string

      Lists the major and minor version number for the format of the returned payload. The payload format or shape may change between minor versions, like including additional or extended fields in later versions. We include the version data in each response so that you have the option to handle the signaled differences.

      • self
        string

        Links to the current page of results.

      • first
        string

        Links to the first page of results.

      • next
        string

        Links to the next page of results.

    • pageSize
      number

      Describes the number of records included in each page of the current result set.

    • pageType
      string

      Describes the pagination algorithm. This endpoint only supports cursor pagination.

      Value: cursor
  • payload
    object

    Contains the query results, which includes the match categories for each log entry.

    • results
      Array of object

        Contains a log and its related details.

      • matchCategories
        Array of string

        Identifies the category that the matched criteria belongs to (e.g., patient, provider, visit, record, metadata, null).

      • id
        string

        Contains the unique identifier of the log.

        Format: uuid
      • createdAt
        string

        Displays the date and time that the log was originally created in ISO 8601 format, which is associated with the date and time that the related data exchange took place.

        Format: date-time
      • updatedAt
        string

        Displays the date and time when the log was last updated in ISO 8601 format.

        Format: date-time
      • dataModel
        string

        Indicates the data model used to exchange data.\n\nThis is the equivalent of the Meta.DataModel field in our data models.

      • eventType
        string

        Indicates the particular event type of a data model that's used to exchange data.\n\nThis is the equivalent of the Meta.EventType field in our data models.

      • status
        string

        Indicates the current status of the log [e.g., succeeded, failed, filtered, pending].

        Possible Values: failed, filtered, pending, succeeded
      • type
        string

        Indicates the type of data exchange that initiated the log (e.g., send, receive, request, respond, unknown).

        Possible Values: receive, request, respond, send, unknown
      • source
        object

        Describes the system that initiated the log.

        • id
          string

          Contains the unique identifier of the source.

          Format: uuid
        • name
          nullable, string

          Displays the human-readable name of the source.

        • organization
          object

          Contains metadata about the Redox organization.

          • id
            number

            Contains the unique identifier of the Redox organization.

          • name
            nullable, string

            Contains the human-readable name of the Redox organization.

      • destination
        object

        Describes the intended destination of the log.

        • id
          string

          Contains the unique identifier of the destination.

          Format: uuid
        • name
          nullable, string

          Displays the human-readable name of the destination.

        • organization
          object

          Contains metadata about the Redox organization.

          • id
            number

            Contains the unique identifier of the Redox organization.

          • name
            nullable, string

            Contains the human-readable name of the Redox organization.