Files
Prowlarr-TS-SDK/docs/sdks/application/README.md

812 lines
60 KiB
Markdown

# Application
(*application*)
## Overview
### Available Operations
* [getApiV1ApplicationsId](#getapiv1applicationsid)
* [putApiV1ApplicationsId](#putapiv1applicationsid)
* [deleteApiV1ApplicationsId](#deleteapiv1applicationsid)
* [getApiV1Applications](#getapiv1applications)
* [postApiV1Applications](#postapiv1applications)
* [putApiV1ApplicationsBulk](#putapiv1applicationsbulk)
* [deleteApiV1ApplicationsBulk](#deleteapiv1applicationsbulk)
* [getApiV1ApplicationsSchema](#getapiv1applicationsschema)
* [postApiV1ApplicationsTest](#postapiv1applicationstest)
* [postApiV1ApplicationsTestall](#postapiv1applicationstestall)
* [postApiV1ApplicationsActionName](#postapiv1applicationsactionname)
## getApiV1ApplicationsId
### Example Usage
<!-- UsageSnippet language="typescript" operationID="get_/api/v1/applications/{id}" method="get" path="/api/v1/applications/{id}" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const result = await prowlarr.application.getApiV1ApplicationsId({
id: 282902,
});
console.log(result);
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationGetApiV1ApplicationsId } from "prowlarr/funcs/applicationGetApiV1ApplicationsId.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationGetApiV1ApplicationsId(prowlarr, {
id: 282902,
});
if (res.ok) {
const { value: result } = res;
console.log(result);
} else {
console.log("applicationGetApiV1ApplicationsId failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `request` | [operations.GetApiV1ApplicationsIdRequest](../../models/operations/getapiv1applicationsidrequest.md) | :heavy_check_mark: | The request object to use for the request. |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<[models.ApplicationResource](../../models/applicationresource.md)\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |
## putApiV1ApplicationsId
### Example Usage
<!-- UsageSnippet language="typescript" operationID="put_/api/v1/applications/{id}" method="put" path="/api/v1/applications/{id}" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const result = await prowlarr.application.putApiV1ApplicationsId({
id: "<id>",
});
console.log(result);
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationPutApiV1ApplicationsId } from "prowlarr/funcs/applicationPutApiV1ApplicationsId.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationPutApiV1ApplicationsId(prowlarr, {
id: "<id>",
});
if (res.ok) {
const { value: result } = res;
console.log(result);
} else {
console.log("applicationPutApiV1ApplicationsId failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `request` | [operations.PutApiV1ApplicationsIdRequest](../../models/operations/putapiv1applicationsidrequest.md) | :heavy_check_mark: | The request object to use for the request. |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<[models.ApplicationResource](../../models/applicationresource.md)\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |
## deleteApiV1ApplicationsId
### Example Usage
<!-- UsageSnippet language="typescript" operationID="delete_/api/v1/applications/{id}" method="delete" path="/api/v1/applications/{id}" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
await prowlarr.application.deleteApiV1ApplicationsId({
id: 915442,
});
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationDeleteApiV1ApplicationsId } from "prowlarr/funcs/applicationDeleteApiV1ApplicationsId.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationDeleteApiV1ApplicationsId(prowlarr, {
id: 915442,
});
if (res.ok) {
const { value: result } = res;
} else {
console.log("applicationDeleteApiV1ApplicationsId failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `request` | [operations.DeleteApiV1ApplicationsIdRequest](../../models/operations/deleteapiv1applicationsidrequest.md) | :heavy_check_mark: | The request object to use for the request. |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<void\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |
## getApiV1Applications
### Example Usage
<!-- UsageSnippet language="typescript" operationID="get_/api/v1/applications" method="get" path="/api/v1/applications" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const result = await prowlarr.application.getApiV1Applications();
console.log(result);
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationGetApiV1Applications } from "prowlarr/funcs/applicationGetApiV1Applications.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationGetApiV1Applications(prowlarr);
if (res.ok) {
const { value: result } = res;
console.log(result);
} else {
console.log("applicationGetApiV1Applications failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<[models.ApplicationResource[]](../../models/.md)\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |
## postApiV1Applications
### Example Usage
<!-- UsageSnippet language="typescript" operationID="post_/api/v1/applications" method="post" path="/api/v1/applications" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const result = await prowlarr.application.postApiV1Applications({});
console.log(result);
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationPostApiV1Applications } from "prowlarr/funcs/applicationPostApiV1Applications.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationPostApiV1Applications(prowlarr, {});
if (res.ok) {
const { value: result } = res;
console.log(result);
} else {
console.log("applicationPostApiV1Applications failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `request` | [operations.PostApiV1ApplicationsRequest](../../models/operations/postapiv1applicationsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<[models.ApplicationResource](../../models/applicationresource.md)\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |
## putApiV1ApplicationsBulk
### Example Usage
<!-- UsageSnippet language="typescript" operationID="put_/api/v1/applications/bulk" method="put" path="/api/v1/applications/bulk" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const result = await prowlarr.application.putApiV1ApplicationsBulk();
console.log(result);
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationPutApiV1ApplicationsBulk } from "prowlarr/funcs/applicationPutApiV1ApplicationsBulk.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationPutApiV1ApplicationsBulk(prowlarr);
if (res.ok) {
const { value: result } = res;
console.log(result);
} else {
console.log("applicationPutApiV1ApplicationsBulk failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `request` | [models.ApplicationBulkResource](../../models/applicationbulkresource.md) | :heavy_check_mark: | The request object to use for the request. |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<[models.ApplicationResource](../../models/applicationresource.md)\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |
## deleteApiV1ApplicationsBulk
### Example Usage
<!-- UsageSnippet language="typescript" operationID="delete_/api/v1/applications/bulk" method="delete" path="/api/v1/applications/bulk" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
await prowlarr.application.deleteApiV1ApplicationsBulk();
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationDeleteApiV1ApplicationsBulk } from "prowlarr/funcs/applicationDeleteApiV1ApplicationsBulk.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationDeleteApiV1ApplicationsBulk(prowlarr);
if (res.ok) {
const { value: result } = res;
} else {
console.log("applicationDeleteApiV1ApplicationsBulk failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `request` | [models.ApplicationBulkResource](../../models/applicationbulkresource.md) | :heavy_check_mark: | The request object to use for the request. |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<void\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |
## getApiV1ApplicationsSchema
### Example Usage
<!-- UsageSnippet language="typescript" operationID="get_/api/v1/applications/schema" method="get" path="/api/v1/applications/schema" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const result = await prowlarr.application.getApiV1ApplicationsSchema();
console.log(result);
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationGetApiV1ApplicationsSchema } from "prowlarr/funcs/applicationGetApiV1ApplicationsSchema.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationGetApiV1ApplicationsSchema(prowlarr);
if (res.ok) {
const { value: result } = res;
console.log(result);
} else {
console.log("applicationGetApiV1ApplicationsSchema failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<[models.ApplicationResource[]](../../models/.md)\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |
## postApiV1ApplicationsTest
### Example Usage
<!-- UsageSnippet language="typescript" operationID="post_/api/v1/applications/test" method="post" path="/api/v1/applications/test" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
await prowlarr.application.postApiV1ApplicationsTest({});
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationPostApiV1ApplicationsTest } from "prowlarr/funcs/applicationPostApiV1ApplicationsTest.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationPostApiV1ApplicationsTest(prowlarr, {});
if (res.ok) {
const { value: result } = res;
} else {
console.log("applicationPostApiV1ApplicationsTest failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `request` | [operations.PostApiV1ApplicationsTestRequest](../../models/operations/postapiv1applicationstestrequest.md) | :heavy_check_mark: | The request object to use for the request. |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<void\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |
## postApiV1ApplicationsTestall
### Example Usage
<!-- UsageSnippet language="typescript" operationID="post_/api/v1/applications/testall" method="post" path="/api/v1/applications/testall" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
await prowlarr.application.postApiV1ApplicationsTestall();
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationPostApiV1ApplicationsTestall } from "prowlarr/funcs/applicationPostApiV1ApplicationsTestall.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationPostApiV1ApplicationsTestall(prowlarr);
if (res.ok) {
const { value: result } = res;
} else {
console.log("applicationPostApiV1ApplicationsTestall failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<void\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |
## postApiV1ApplicationsActionName
### Example Usage
<!-- UsageSnippet language="typescript" operationID="post_/api/v1/applications/action/{name}" method="post" path="/api/v1/applications/action/{name}" -->
```typescript
import { Prowlarr } from "prowlarr";
const prowlarr = new Prowlarr({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
await prowlarr.application.postApiV1ApplicationsActionName({
name: "<value>",
});
}
run();
```
### Standalone function
The standalone function version of this method:
```typescript
import { ProwlarrCore } from "prowlarr/core.js";
import { applicationPostApiV1ApplicationsActionName } from "prowlarr/funcs/applicationPostApiV1ApplicationsActionName.js";
// Use `ProwlarrCore` for best tree-shaking performance.
// You can create one instance of it to use across an application.
const prowlarr = new ProwlarrCore({
security: {
xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
},
});
async function run() {
const res = await applicationPostApiV1ApplicationsActionName(prowlarr, {
name: "<value>",
});
if (res.ok) {
const { value: result } = res;
} else {
console.log("applicationPostApiV1ApplicationsActionName failed:", res.error);
}
}
run();
```
### Parameters
| Parameter | Type | Required | Description |
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `request` | [operations.PostApiV1ApplicationsActionNameRequest](../../models/operations/postapiv1applicationsactionnamerequest.md) | :heavy_check_mark: | The request object to use for the request. |
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
### Response
**Promise\<void\>**
### Errors
| Error Type | Status Code | Content Type |
| --------------- | --------------- | --------------- |
| errors.APIError | 4XX, 5XX | \*/\* |