> ## Documentation Index
> Fetch the complete documentation index at: https://docs.ocoya.com/llms.txt
> Use this file to discover all available pages before exploring further.

# ocoya_list_posts

> List Ocoya post groups for a workspace.

# `ocoya_list_posts`

Lists Ocoya post groups for a workspace. Use this to find post IDs before previewing, updating, scheduling, or deleting a post.

## Arguments

| Name          | Type      | Required | Description                                 |
| ------------- | --------- | -------- | ------------------------------------------- |
| `workspaceId` | string    | Yes      | Workspace ID from `ocoya_list_workspaces`.  |
| `statuses`    | string\[] | No       | Optional post statuses to filter by.        |
| `query`       | string    | No       | Optional caption search query.              |
| `page`        | number    | No       | Zero-based page number.                     |
| `perPage`     | number    | No       | Maximum number of posts to return per page. |

## Example

```json theme={null}
{
  "name": "ocoya_list_posts",
  "arguments": {
    "workspaceId": "cmayvq3hk00017apshay5qezu",
    "statuses": ["SCHEDULED"],
    "page": 0,
    "perPage": 20
  }
}
```

## Returns

Returns paginated Ocoya post group results.
