# Feedback Options API

API for managing feedback options and templates

**Version:** 1.0.0

## Overview

### Base URLs

- **Production server**: `https://api.repzo.me/v1`

### API Categories

- **Feedback Options**: Feedback options management operations

## Authentication

This API uses the following authentication methods:

- **ApiKeyAuth**

## Endpoints

### `/feedback-options`

#### GET /feedback-options

**Summary:** Get all feedback options

**Description:** Retrieve a list of all feedback options with optional filtering and pagination

**Tags:** Feedback Options

##### Parameters

| Name | Location | Type | Required | Description |
| ---- | -------- | ---- | -------- | ----------- |

| `page` | query | integer | No | Page number for pagination |

| `per_page` | query | integer | No | Number of items per page |

| `sort` | query | string | No | Sort field |

| `company_namespace` | query | array | No | Company namespace for filtering |

| `category` | query | string | No | Filter by category |

| `is_active` | query | boolean | No | Filter by active status |

| `template_type` | query | string | No | Filter by template type |

| `_id` | query | array | No | Filter by ID |

##### Responses

**200** - Successful response

Content-Type: `application/json`

**400** - No description

**401** - No description

**403** - No description

**500** - No description

---

#### POST /feedback-options

**Summary:** Create new feedback options

**Description:** Create a new feedback options template

**Tags:** Feedback Options

##### Request Body

**Content Types:**

- `application/json`

##### Responses

**201** - Feedback options created successfully

Content-Type: `application/json`

**400** - No description

**401** - No description

**403** - No description

**422** - No description

**500** - No description

---

### `/feedback-options/{id}`

#### GET /feedback-options/{id}

**Summary:** Get feedback options by ID

**Description:** Retrieve a specific feedback options template by its ID

**Tags:** Feedback Options

##### Parameters

| Name | Location | Type | Required | Description |
| ---- | -------- | ---- | -------- | ----------- |

| `id` | path | string | Yes | Feedback options ID |

##### Responses

**200** - Successful response

Content-Type: `application/json`

**400** - No description

**401** - No description

**403** - No description

**404** - No description

**500** - No description

---

#### PATCH /feedback-options/{id}

**Summary:** Update feedback options

**Description:** Update an existing feedback options template

**Tags:** Feedback Options

##### Parameters

| Name | Location | Type | Required | Description |
| ---- | -------- | ---- | -------- | ----------- |

| `id` | path | string | Yes | Feedback options ID |

##### Request Body

**Content Types:**

- `application/json`

##### Responses

**200** - Feedback options updated successfully

Content-Type: `application/json`

**400** - No description

**401** - No description

**403** - No description

**404** - No description

**422** - No description

**500** - No description

---

#### DELETE /feedback-options/{id}

**Summary:** Delete feedback options

**Description:** Delete a feedback options template by ID

**Tags:** Feedback Options

##### Parameters

| Name | Location | Type | Required | Description |
| ---- | -------- | ---- | -------- | ----------- |

| `id` | path | string | Yes | Feedback options ID |

##### Responses

**200** - Feedback options deleted successfully

Content-Type: `application/json`

**400** - No description

**401** - No description

**403** - No description

**404** - No description

**500** - No description

---

### `/feedback-options/{id}/preview`

#### GET /feedback-options/{id}/preview

**Summary:** Preview feedback template

**Description:** Get a preview of how the feedback template will appear

**Tags:** Feedback Options

##### Parameters

| Name | Location | Type | Required | Description |
| ---- | -------- | ---- | -------- | ----------- |

| `id` | path | string | Yes | Feedback options ID |

##### Responses

**200** - Template preview retrieved successfully

Content-Type: `application/json`

**400** - No description

**401** - No description

**403** - No description

**404** - No description

**500** - No description

---

### `/feedback-options/templates`

#### GET /feedback-options/templates

**Summary:** Get predefined templates

**Description:** Get a list of predefined feedback templates

**Tags:** Feedback Options

##### Parameters

| Name | Location | Type | Required | Description |
| ---- | -------- | ---- | -------- | ----------- |

| `category` | query | string | No | Filter by category |

| `template_type` | query | string | No | Filter by template type |

##### Responses

**200** - Predefined templates retrieved successfully

Content-Type: `application/json`

**400** - No description

**401** - No description

**403** - No description

**500** - No description

---

## Data Models

### FeedbackOptions

| Property | Type | Required | Description |
| -------- | ---- | -------- | ----------- |

| `_id` | string | No | Unique identifier |

| `name` | string | Yes | Template name |

| `description` | string | No | Template description |

| `category` | string | No | Category of the template |

| `template_type` | string | Yes | Type of feedback template |

| `questions` | array | Yes | List of questions in the template |

| `settings` | object | No | No description |

| `styling` | object | No | No description |

| `notification_settings` | object | No | No description |

| `is_active` | boolean | No | Whether the template is active |

| `usage_count` | integer | No | Number of times template has been used |

| `company_namespace` | array | No | Company namespace |

| `createdAt` | string | No | Creation timestamp |

| `modifiedAt` | string | No | Last modification timestamp |

| `SVClient` | integer | No | Client version |

| `__v` | integer | No | Document version |

### FeedbackQuestion

| Property | Type | Required | Description |
| -------- | ---- | -------- | ----------- |

| `question_id` | string | No | Unique question identifier |

| `question_text` | string | Yes | The question text |

| `question_type` | string | Yes | Type of question |

| `is_required` | boolean | No | Whether the question is required |

| `options` | array | No | Options for multiple choice questions |

| `validation` | object | No | No description |

| `display_settings` | object | No | No description |

| `conditional_logic` | object | No | No description |

### CreateFeedbackOptionsRequest

| Property | Type | Required | Description |
| -------- | ---- | -------- | ----------- |

| `name` | string | Yes | Template name |

| `description` | string | No | Template description |

| `category` | string | No | Category of the template |

| `template_type` | string | Yes | Type of feedback template |

| `questions` | array | Yes | No description |

| `settings` | object | No | No description |

| `styling` | object | No | No description |

| `notification_settings` | object | No | No description |

| `is_active` | boolean | No | Whether the template is active |

| `company_namespace` | array | No | Company namespace |

### UpdateFeedbackOptionsRequest

| Property | Type | Required | Description |
| -------- | ---- | -------- | ----------- |

| `name` | string | No | Template name |

| `description` | string | No | Template description |

| `category` | string | No | Category of the template |

| `questions` | array | No | No description |

| `settings` | object | No | No description |

| `styling` | object | No | No description |

| `notification_settings` | object | No | No description |

| `is_active` | boolean | No | Whether the template is active |

| `company_namespace` | array | No | Company namespace |

### PagingInfo

| Property | Type | Required | Description |
| -------- | ---- | -------- | ----------- |

| `total` | integer | No | Total number of items |

| `page` | integer | No | Current page number |

| `per_page` | integer | No | Items per page |

| `pages` | integer | No | Total number of pages |

## TypeScript Usage

See [feedback-options-examples.md](./feedback-options-examples.md) for detailed TypeScript usage examples.
