# List Google posts

`GET /google-posts`

Returns the Google Business Profile posts of one shop (`shop_id`) or
all your shops, sorted by creation date descending, with their content,
publication status, medias and call-to-action.

Requires the `google_posts:read` scope.

**Returns** a `data` array of up to `limit` posts and a
`pagination` object. Fetch the next page by passing
`pagination.next_cursor` back as `cursor`, until `has_more` is
`false`. `data` is empty when nothing matches the filters.

`source` tells apart posts created through Dokaa and posts fetched from
Google. `event` and `offer` are `null` for standard posts.

## Example request

```bash
curl "https://api.dokaa.app/v1/google-posts" \
  -H "Authorization: Bearer dk_live_..."
```

## Query parameters

- `shop_id` (string) – Restrict to a single shop (omit to query all your shops)
- `status` (string) (one of: draft, sending, ended, cancelled, error) – Filter by publication status
- `type` (string) (one of: STANDARD, EVENT, OFFER, NONE) – Filter by post type
- `from` (string) (format: date) – Only posts created on or after this date
- `to` (string) (format: date) – Only posts created on or before this date
- `cursor` (string) – Opaque cursor from the previous response's `pagination.next_cursor`
- `limit` (integer) (default: 25; min: 1; max: 100) – Number of items per page

## Responses

### 200 – Paginated list of Google posts

```json
{
  "data": [
    {
      "id": "66c9d0e1f2a3b4c5d6e7f8a9",
      "shop_id": "64f1a2b3c4d5e6f7a8b9c0d1",
      "type": "EVENT",
      "content": "Soirée dégustation ce vendredi, places limitées.",
      "status": "ended",
      "url": "https://local.google.com/posts/123",
      "medias": [
        "https://res.cloudinary.com/dokaa/image.jpg"
      ],
      "action": {
        "type": "BOOK",
        "url": "https://book.example.com"
      },
      "event": {
        "title": "Soirée dégustation",
        "start_date": "2026-08-14T19:00:00Z",
        "end_date": "2026-08-14T23:00:00Z"
      },
      "offer": null,
      "source": "manual",
      "scheduled_at": null,
      "published_at": "2026-08-08T10:00:00Z",
      "date": "2026-08-07T15:12:00Z"
    }
  ],
  "pagination": {
    "next_cursor": null,
    "has_more": false
  }
}
```

### 401 – Missing, invalid, or revoked API key

### 403 – The API key does not grant access to this resource

### 422 – Invalid request parameters

Errors are `application/problem+json` (RFC 9457) with `type`, `title`, `status` and `detail` fields.
