ci: regenerated with OpenAPI Doc latest, Speakeasy CLI 1.134.1

This commit is contained in:
speakeasybot
2024-01-10 15:48:00 +00:00
parent 0231c2a428
commit 2af51a7827
589 changed files with 45363 additions and 0 deletions

View File

@@ -0,0 +1,276 @@
# Categories
(*categories*)
### Available Operations
* [createCategory](#createcategory) - Creates a category
* [getCategory](#getcategory) - Show category
* [getSite](#getsite) - Get site info
* [listCategories](#listcategories) - Retrieves a list of categories
* [listCategoryTopics](#listcategorytopics) - List topics
* [updateCategory](#updatecategory) - Updates a category
## createCategory
Creates a category
### Example Usage
```typescript
import { SDK } from "openapi";
async function run() {
const sdk = new SDK();
const res = await sdk.categories.createCategory({
color: "49d9e9",
formTemplateIds: [
"string",
],
name: "string",
permissions: {
"key": "string",
},
textColor: "f0fcfd",
});
if (res.statusCode == 200) {
// handle response
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ |
| `request` | [operations.CreateCategoryRequestBody](../../sdk/models/operations/createcategoryrequestbody.md) | :heavy_check_mark: | The request object to use for the request. |
| `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. |
### Response
**Promise<[operations.CreateCategoryResponse](../../sdk/models/operations/createcategoryresponse.md)>**
### Errors
| Error Object | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.SDKError | 4xx-5xx | */* |
## getCategory
Show category
### Example Usage
```typescript
import { SDK } from "openapi";
import { GetCategoryRequest } from "openapi/dist/sdk/models/operations";
async function run() {
const sdk = new SDK();
const id: number = 39147;
const res = await sdk.categories.getCategory(id);
if (res.statusCode == 200) {
// handle response
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
| `id` | *number* | :heavy_check_mark: | N/A |
| `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. |
### Response
**Promise<[operations.GetCategoryResponse](../../sdk/models/operations/getcategoryresponse.md)>**
### Errors
| Error Object | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.SDKError | 4xx-5xx | */* |
## getSite
Can be used to fetch all categories and subcategories
### Example Usage
```typescript
import { SDK } from "openapi";
async function run() {
const sdk = new SDK();
const res = await sdk.categories.getSite();
if (res.statusCode == 200) {
// handle response
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
| `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. |
### Response
**Promise<[operations.GetSiteResponse](../../sdk/models/operations/getsiteresponse.md)>**
### Errors
| Error Object | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.SDKError | 4xx-5xx | */* |
## listCategories
Retrieves a list of categories
### Example Usage
```typescript
import { SDK } from "openapi";
import { ListCategoriesRequest } from "openapi/dist/sdk/models/operations";
async function run() {
const sdk = new SDK();
const includeSubcategories: boolean = false;
const res = await sdk.categories.listCategories(includeSubcategories);
if (res.statusCode == 200) {
// handle response
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
| `includeSubcategories` | *boolean* | :heavy_minus_sign: | N/A |
| `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. |
### Response
**Promise<[operations.ListCategoriesResponse](../../sdk/models/operations/listcategoriesresponse.md)>**
### Errors
| Error Object | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.SDKError | 4xx-5xx | */* |
## listCategoryTopics
List topics
### Example Usage
```typescript
import { SDK } from "openapi";
import { ListCategoryTopicsRequest } from "openapi/dist/sdk/models/operations";
async function run() {
const sdk = new SDK();
const id: number = 394133;
const slug: string = "string";
const res = await sdk.categories.listCategoryTopics(id, slug);
if (res.statusCode == 200) {
// handle response
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ | ------------------------------------------------------------ |
| `id` | *number* | :heavy_check_mark: | N/A |
| `slug` | *string* | :heavy_check_mark: | N/A |
| `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. |
### Response
**Promise<[operations.ListCategoryTopicsResponse](../../sdk/models/operations/listcategorytopicsresponse.md)>**
### Errors
| Error Object | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.SDKError | 4xx-5xx | */* |
## updateCategory
Updates a category
### Example Usage
```typescript
import { SDK } from "openapi";
import { UpdateCategoryRequest, UpdateCategoryRequestBody } from "openapi/dist/sdk/models/operations";
async function run() {
const sdk = new SDK();
const id: number = 353500;
const requestBody: UpdateCategoryRequestBody = {
color: "49d9e9",
formTemplateIds: [
"string",
],
name: "string",
permissions: {
"key": "string",
},
textColor: "f0fcfd",
};
const res = await sdk.categories.updateCategory(id, requestBody);
if (res.statusCode == 200) {
// handle response
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------ |
| `id` | *number* | :heavy_check_mark: | N/A |
| `requestBody` | [operations.UpdateCategoryRequestBody](../../sdk/models/operations/updatecategoryrequestbody.md) | :heavy_minus_sign: | N/A |
| `config` | [AxiosRequestConfig](https://axios-http.com/docs/req_config) | :heavy_minus_sign: | Available config options for making requests. |
### Response
**Promise<[operations.UpdateCategoryResponse](../../sdk/models/operations/updatecategoryresponse.md)>**
### Errors
| Error Object | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.SDKError | 4xx-5xx | */* |