## Search Agent Data

`AgentDataSearchPage beta().agentData().search(AgentDataSearchParamsparams, RequestOptionsrequestOptions = RequestOptions.none())`

**post** `/api/v1/beta/agent-data/:search`

Search agent data with filtering, sorting, and pagination.

### Parameters

- `AgentDataSearchParams params`

  - `Optional<String> organizationId`

  - `Optional<String> projectId`

  - `String deploymentName`

    The agent deployment's name to search within

  - `Optional<String> collection`

    The logical agent data collection to search within

  - `Optional<Filter> filter`

    A filter object or expression that filters resources listed in the response.

    - `Optional<Eq> eq`

      - `double`

      - `String`

      - `LocalDateTime`

    - `Optional<List<Exclude>> excludes`

      - `double`

      - `String`

      - `LocalDateTime`

    - `Optional<Gt> gt`

      - `double`

      - `String`

      - `LocalDateTime`

    - `Optional<Gte> gte`

      - `double`

      - `String`

      - `LocalDateTime`

    - `Optional<List<Include>> includes`

      - `double`

      - `String`

      - `LocalDateTime`

    - `Optional<Lt> lt`

      - `double`

      - `String`

      - `LocalDateTime`

    - `Optional<Lte> lte`

      - `double`

      - `String`

      - `LocalDateTime`

    - `Optional<Ne> ne`

      - `double`

      - `String`

      - `LocalDateTime`

  - `Optional<Boolean> includeTotal`

    Whether to include the total number of items in the response

  - `Optional<Long> offset`

    The offset to start from. If not provided, the first page is returned

  - `Optional<String> orderBy`

    A comma-separated list of fields to order by, sorted in ascending order. Use 'field_name desc' to specify descending order.

  - `Optional<Long> pageSize`

    The maximum number of items to return. The service may return fewer than this value. If unspecified, a default page size will be used. The maximum value is typically 1000; values above this will be coerced to the maximum.

  - `Optional<String> pageToken`

    A page token, received from a previous list call. Provide this to retrieve the subsequent page.

### Returns

- `class AgentData:`

  API Result for a single agent data item

  - `Data data`

  - `String deploymentName`

  - `Optional<String> id`

  - `Optional<String> collection`

  - `Optional<LocalDateTime> createdAt`

  - `Optional<String> projectId`

  - `Optional<LocalDateTime> updatedAt`

### Example

```java
package com.llamacloud_prod.api.example;

import com.llamacloud_prod.api.client.LlamaCloudClient;
import com.llamacloud_prod.api.client.okhttp.LlamaCloudOkHttpClient;
import com.llamacloud_prod.api.models.beta.agentdata.AgentDataSearchPage;
import com.llamacloud_prod.api.models.beta.agentdata.AgentDataSearchParams;

public final class Main {
    private Main() {}

    public static void main(String[] args) {
        LlamaCloudClient client = LlamaCloudOkHttpClient.fromEnv();

        AgentDataSearchParams params = AgentDataSearchParams.builder()
            .deploymentName("deployment_name")
            .build();
        AgentDataSearchPage page = client.beta().agentData().search(params);
    }
}
```

#### Response

```json
{
  "items": [
    {
      "data": {
        "foo": "bar"
      },
      "deployment_name": "deployment_name",
      "id": "id",
      "collection": "collection",
      "created_at": "2019-12-27T18:11:19.117Z",
      "project_id": "project_id",
      "updated_at": "2019-12-27T18:11:19.117Z"
    }
  ],
  "next_page_token": "next_page_token",
  "total_size": 0
}
```
