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

# Get Suggestions

> Retrieve all suggestions from your project

Retrieve all suggestions from your project. This endpoint returns a paginated list of all suggestions with vote counts and status information.

<ParamField query="userId" type="string" required>
  ID of user who created this suggestion (CUID format, e.g., clm7x1a2b000008l7h3k1b2c3)
</ParamField>

<ParamField query="status" type="string" required default="IN_PROGRESS">
  Status of suggestion (PENDING, PLANNED, IN\_PROGRESS, COMPLETED, CLOSED) (default: IN\_PROGRESS)
</ParamField>

<ParamField query="limit" type="number">
  Number of suggestions to return (1-100, default: 20)
</ParamField>

<ParamField query="offset" type="number">
  Number of suggestions to skip (default: 0)
</ParamField>

## Response Fields

Returns an object with suggestions array and pagination info:

| Field              | Type    | Required | Description                        |
| ------------------ | ------- | -------- | ---------------------------------- |
| suggestions        | array   | Yes      | Array of suggestion objects        |
| pagination.limit   | number  | Yes      | Number of suggestions returned     |
| pagination.offset  | number  | Yes      | Number of suggestions skipped      |
| pagination.total   | number  | Yes      | Total number of suggestions        |
| pagination.hasMore | boolean | Yes      | Whether there are more suggestions |

### Suggestion Object Fields

| Field        | Type    | Required | Description                                                |
| ------------ | ------- | -------- | ---------------------------------------------------------- |
| id           | string  | Yes      | Unique suggestion identifier                               |
| title        | string  | Yes      | Suggestion title                                           |
| description  | string  | Yes      | Suggestion description                                     |
| status       | string  | Yes      | Status (PENDING, PLANNED, IN\_PROGRESS, COMPLETED, CLOSED) |
| projectId    | string  | Yes      | Project this suggestion belongs to                         |
| label        | object  | No       | Label information (id, name, color)                        |
| voteCount    | number  | Yes      | Total number of votes                                      |
| hasUserVoted | boolean | Yes      | Whether the user has voted for this suggestion             |
| createdAt    | string  | Yes      | Creation timestamp (ISO 8601)                              |
| updatedAt    | string  | Yes      | Last update timestamp (ISO 8601)                           |

## Example Request

```
GET /api/v1/sdk/suggestions?limit=10&offset=0
```

## Example Response

```json theme={null}
{
  "suggestions": [
    {
      "id": "clm7x1a2b000008l7h3k1b2c3",
      "title": "Add dark mode",
      "description": "Please add dark mode support for better user experience",
      "status": "PENDING",
      "projectId": "clm7x1a2b000008l7h3k1b2c3",
      "label": null,
      "voteCount": 15,
      "hasUserVoted": true,
      "createdAt": "2024-01-15T10:30:00.000Z",
      "updatedAt": "2024-01-15T10:30:00.000Z"
    }
  ],
  "pagination": {
    "limit": 10,
    "offset": 0,
    "total": 23,
    "hasMore": true
  }
}
```

## Error Responses

| Status Code | Description                      | Example Response                               |
| :---------- | :------------------------------- | :--------------------------------------------- |
| 400         | Bad request - Invalid parameters | `{"error": "limit must be between 1 and 100"}` |
| 401         | Unauthorized - Invalid API key   | `{"error": "Unauthorized"}`                    |
| 500         | Internal server error            | `{"error": "Failed to get suggestions"}`       |
