# <a id="bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest"></a>SessionAdvancedSearchRequest

**Source definition:** [`src/bitdrift/public/unary/timeline/v1/search.proto#L12-L140`](<https://github.com/bitdriftlabs/api/blob/main/src/bitdrift/public/unary/timeline/v1/search.proto#L12-L140>)

Advanced search request for logs within a session.

<section class="proto-fields-table" markdown>
| Field | Type | Description |
|---|---|---|
| session_id | <span class="proto-type proto-type-primitive">string</span><br><em class="proto-field-annotation">between 1 and 100 chars</em> | The session ID to search within. |
| start_time | <span class="proto-type proto-type-well-known">[google.protobuf.Timestamp](https://protobuf.dev/reference/protobuf/google.protobuf/#timestamp "google.protobuf.Timestamp")</span> | The start time of the query. If not specified, the query will start from the beginning of the session. |
| end_time | <span class="proto-type proto-type-well-known">[google.protobuf.Timestamp](https://protobuf.dev/reference/protobuf/google.protobuf/#timestamp "google.protobuf.Timestamp")</span> | The end time of the query. If not specified, the query will end at the end of the session. |
| limit | <span class="proto-type proto-type-primitive">optional uint32</span><br><em class="proto-field-annotation">between 1 and 5000</em> | The maximum number of results to return. |
| offset | <span class="proto-type proto-type-primitive">optional uint32</span> | The result offset for pagination. |
| include_internal_logs | <span class="proto-type proto-type-primitive">bool</span> | Whether to include internal logs in the search results.   Internal logs include screen capture, resource, and internal SDK logs that do not appear in the default timeline view. |
| or_query | <span class="proto-type proto-type-message">array of [<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">timeline</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">SessionAdvancedSearchRequest</i><i class="proto-type-dot">.</i><i class="proto-type-part">AndQuery</i>](#bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.AndQuery "bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.AndQuery")</span><br><em class="proto-field-annotation">between 1 and 20 items</em> | All AndQuery groups are combined with logical OR.   (or_query[0].conditions[0] AND or_query[0].conditions[1] AND or_query[0].conditions[2])                             OR  (or_query[1].conditions[0] AND or_query[1].conditions[1]) |

</section>
<p class="h4">Example</p>
```json
{
  "end_time": "2024-01-15T09:30:00Z",
  "include_internal_logs": true,
  "limit": 25,
  "offset": 0,
  "or_query": [
    {
      "conditions": [
        {
          "field_match": {
            "json_path": "$.fields.os_version",
            "operator": "EQUAL",
            "value": "14.0"
          }
        }
      ]
    }
  ],
  "session_id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
  "start_time": "2024-01-15T09:30:00Z"
}
```

# <a id="bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.FieldMatch"></a>SessionAdvancedSearchRequest.FieldMatch

**Source definition:** [`src/bitdrift/public/unary/timeline/v1/search.proto#L40-L56`](<https://github.com/bitdriftlabs/api/blob/main/src/bitdrift/public/unary/timeline/v1/search.proto#L40-L56>)

Matches against a specific field value.

<section class="proto-fields-table" markdown>
| Field | Type | Description |
|---|---|---|
| json_path | <span class="proto-type proto-type-primitive">string</span><br><em class="proto-field-annotation">between 1 and 500 chars</em> | The JSONPath expression identifying the field to match against.  For a known field type like `os_version`, this would be `$.fields.os_version`. |
| operator | <span class="proto-type proto-type-enum">[<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">common</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">Operator</i>](bitdrift_public_unary_common_v1_Operator.md "bitdrift.public.unary.common.v1.Operator")</span><br><em class="proto-field-annotation">must be a defined enum value</em> | The operator to use for comparison. |
| value | <span class="proto-type proto-type-primitive">string</span><br><em class="proto-field-annotation">between 1 and 1000 chars</em> | The value to compare against. |

</section>
<p class="h4">Example</p>
```json
{
  "json_path": "$.fields.os_version",
  "operator": "EQUAL",
  "value": "14.0"
}
```

# <a id="bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.LogTypeMatch"></a>SessionAdvancedSearchRequest.LogTypeMatch

**Source definition:** [`src/bitdrift/public/unary/timeline/v1/search.proto#L59-L65`](<https://github.com/bitdriftlabs/api/blob/main/src/bitdrift/public/unary/timeline/v1/search.proto#L59-L65>)

Matches against the log type.

<section class="proto-fields-table" markdown>
| Field | Type | Description |
|---|---|---|
| operator | <span class="proto-type proto-type-enum">[<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">common</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">Operator</i>](bitdrift_public_unary_common_v1_Operator.md "bitdrift.public.unary.common.v1.Operator")</span><br><em class="proto-field-annotation">must be a defined enum value</em> | The operator to use for comparison. |
| log_type | <span class="proto-type proto-type-enum">[<i class="proto-type-part">bitdrift_public</i><i class="proto-type-dot">.</i><i class="proto-type-part">protobuf</i><i class="proto-type-dot">.</i><i class="proto-type-part">logging</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">LogType</i>](bitdrift_public_protobuf_logging_v1_LogType.md "bitdrift_public.protobuf.logging.v1.LogType")</span><br><em class="proto-field-annotation">must be a defined enum value</em> | The log type to match. |

</section>
<p class="h4">Example</p>
```json
{
  "log_type": "REPLAY",
  "operator": "EQUAL"
}
```

# <a id="bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.LogLevelMatch"></a>SessionAdvancedSearchRequest.LogLevelMatch

**Source definition:** [`src/bitdrift/public/unary/timeline/v1/search.proto#L68-L74`](<https://github.com/bitdriftlabs/api/blob/main/src/bitdrift/public/unary/timeline/v1/search.proto#L68-L74>)

Matches against the log level.

<section class="proto-fields-table" markdown>
| Field | Type | Description |
|---|---|---|
| operator | <span class="proto-type proto-type-enum">[<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">common</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">Operator</i>](bitdrift_public_unary_common_v1_Operator.md "bitdrift.public.unary.common.v1.Operator")</span><br><em class="proto-field-annotation">must be a defined enum value</em> | The operator to use for comparison. |
| log_level | <span class="proto-type proto-type-enum">[<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">timeline</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">Log</i><i class="proto-type-dot">.</i><i class="proto-type-part">LogLevel</i>](bitdrift_public_unary_timeline_v1_Log.md "bitdrift.public.unary.timeline.v1.Log.LogLevel")</span><br><em class="proto-field-annotation">must be a defined enum value</em> | The log level to match. |

</section>
<p class="h4">Example</p>
```json
{
  "log_level": "DEBUG",
  "operator": "EQUAL"
}
```

# <a id="bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.RawMatch"></a>SessionAdvancedSearchRequest.RawMatch

**Source definition:** [`src/bitdrift/public/unary/timeline/v1/search.proto#L95-L104`](<https://github.com/bitdriftlabs/api/blob/main/src/bitdrift/public/unary/timeline/v1/search.proto#L95-L104>)

A full-text search condition.

 Searches across top-level log properties and nested values within the
 `fields` object.

 For example, the search term "1234" against a log like:
 {
   "message": "This is a test log",
   "fields": {
     "foo_bar": {
       "baz": {
         "qux": "1234"
       }
     }
   }
 }

 matches on $.fields.foo_bar because the query runs against each
 top-level field's value.

<section class="proto-fields-table" markdown>
| Field | Type | Description |
|---|---|---|
| query | <span class="proto-type proto-type-primitive">string</span><br><em class="proto-field-annotation">between 1 and 1000 chars</em> | The raw search query. |
| operator | <span class="proto-type proto-type-enum">[<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">common</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">Operator</i>](bitdrift_public_unary_common_v1_Operator.md "bitdrift.public.unary.common.v1.Operator")</span><br><em class="proto-field-annotation">must be a defined enum value</em> | The operator to use for comparison. |

</section>
<p class="h4">Example</p>
```json
{
  "operator": "WILDCARD",
  "query": "error"
}
```

# <a id="bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.Condition"></a>SessionAdvancedSearchRequest.Condition

**Source definition:** [`src/bitdrift/public/unary/timeline/v1/search.proto#L106-L121`](<https://github.com/bitdriftlabs/api/blob/main/src/bitdrift/public/unary/timeline/v1/search.proto#L106-L121>)

<section class="proto-fields-table" markdown>
| Field | Type | Description |
|---|---|---|
| field_match | <span class="proto-type proto-type-message">[<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">timeline</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">SessionAdvancedSearchRequest</i><i class="proto-type-dot">.</i><i class="proto-type-part">FieldMatch</i>](#bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.FieldMatch "bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.FieldMatch")</span><span class="proto-field-annotation">only one of <em>field_match</em>, or <em>raw_match</em>, <em>log_type_match</em>, <em>log_level_match</em> can be set</span> | Matches against a specific field value. |
| raw_match | <span class="proto-type proto-type-message">[<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">timeline</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">SessionAdvancedSearchRequest</i><i class="proto-type-dot">.</i><i class="proto-type-part">RawMatch</i>](#bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.RawMatch "bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.RawMatch")</span><span class="proto-field-annotation">only one of <em>raw_match</em>, or <em>field_match</em>, <em>log_type_match</em>, <em>log_level_match</em> can be set</span> | Matches against the full-text content of the log. |
| log_type_match | <span class="proto-type proto-type-message">[<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">timeline</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">SessionAdvancedSearchRequest</i><i class="proto-type-dot">.</i><i class="proto-type-part">LogTypeMatch</i>](#bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.LogTypeMatch "bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.LogTypeMatch")</span><span class="proto-field-annotation">only one of <em>log_type_match</em>, or <em>field_match</em>, <em>raw_match</em>, <em>log_level_match</em> can be set</span> | Matches against the log type. |
| log_level_match | <span class="proto-type proto-type-message">[<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">timeline</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">SessionAdvancedSearchRequest</i><i class="proto-type-dot">.</i><i class="proto-type-part">LogLevelMatch</i>](#bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.LogLevelMatch "bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.LogLevelMatch")</span><span class="proto-field-annotation">only one of <em>log_level_match</em>, or <em>field_match</em>, <em>raw_match</em>, <em>log_type_match</em> can be set</span> | Matches against the log level. |

</section>
<p class="h4">Example</p>
```json
{
  "field_match": {
    "json_path": "$.fields.os_version",
    "operator": "EQUAL",
    "value": "14.0"
  }
}
```

# <a id="bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.AndQuery"></a>SessionAdvancedSearchRequest.AndQuery

**Source definition:** [`src/bitdrift/public/unary/timeline/v1/search.proto#L123-L129`](<https://github.com/bitdriftlabs/api/blob/main/src/bitdrift/public/unary/timeline/v1/search.proto#L123-L129>)

<section class="proto-fields-table" markdown>
| Field | Type | Description |
|---|---|---|
| conditions | <span class="proto-type proto-type-message">array of [<i class="proto-type-part">bitdrift</i><i class="proto-type-dot">.</i><i class="proto-type-part">public</i><i class="proto-type-dot">.</i><i class="proto-type-part">unary</i><i class="proto-type-dot">.</i><i class="proto-type-part">timeline</i><i class="proto-type-dot">.</i><i class="proto-type-part">v1</i><i class="proto-type-dot">.</i><i class="proto-type-part">SessionAdvancedSearchRequest</i><i class="proto-type-dot">.</i><i class="proto-type-part">Condition</i>](#bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.Condition "bitdrift.public.unary.timeline.v1.SessionAdvancedSearchRequest.Condition")</span><br><em class="proto-field-annotation">between 1 and 20 items</em> | The conditions to combine with logical AND. |

</section>
<p class="h4">Example</p>
```json
{
  "conditions": [
    {
      "field_match": {
        "json_path": "$.fields.os_version",
        "operator": "EQUAL",
        "value": "14.0"
      }
    }
  ]
}
```

