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

60 KiB
Raw Blame History

Indexer

(indexer)

Overview

Available Operations

getApiV1IndexerId

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  const result = await prowlarr.indexer.getApiV1IndexerId({
    id: 596285,
  });

  console.log(result);
}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerGetApiV1IndexerId } from "prowlarr/funcs/indexerGetApiV1IndexerId.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 indexerGetApiV1IndexerId(prowlarr, {
    id: 596285,
  });
  if (res.ok) {
    const { value: result } = res;
    console.log(result);
  } else {
    console.log("indexerGetApiV1IndexerId failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
request operations.GetApiV1IndexerIdRequest ✔️ The request object to use for the request.
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<models.IndexerResource>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*

putApiV1IndexerId

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  const result = await prowlarr.indexer.putApiV1IndexerId({
    id: "<id>",
  });

  console.log(result);
}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerPutApiV1IndexerId } from "prowlarr/funcs/indexerPutApiV1IndexerId.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 indexerPutApiV1IndexerId(prowlarr, {
    id: "<id>",
  });
  if (res.ok) {
    const { value: result } = res;
    console.log(result);
  } else {
    console.log("indexerPutApiV1IndexerId failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
request operations.PutApiV1IndexerIdRequest ✔️ The request object to use for the request.
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<models.IndexerResource>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*

deleteApiV1IndexerId

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  await prowlarr.indexer.deleteApiV1IndexerId({
    id: 158662,
  });


}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerDeleteApiV1IndexerId } from "prowlarr/funcs/indexerDeleteApiV1IndexerId.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 indexerDeleteApiV1IndexerId(prowlarr, {
    id: 158662,
  });
  if (res.ok) {
    const { value: result } = res;
    
  } else {
    console.log("indexerDeleteApiV1IndexerId failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
request operations.DeleteApiV1IndexerIdRequest ✔️ The request object to use for the request.
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<void>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*

getApiV1Indexer

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  const result = await prowlarr.indexer.getApiV1Indexer();

  console.log(result);
}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerGetApiV1Indexer } from "prowlarr/funcs/indexerGetApiV1Indexer.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 indexerGetApiV1Indexer(prowlarr);
  if (res.ok) {
    const { value: result } = res;
    console.log(result);
  } else {
    console.log("indexerGetApiV1Indexer failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<models.IndexerResource[]>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*

postApiV1Indexer

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  const result = await prowlarr.indexer.postApiV1Indexer({});

  console.log(result);
}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerPostApiV1Indexer } from "prowlarr/funcs/indexerPostApiV1Indexer.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 indexerPostApiV1Indexer(prowlarr, {});
  if (res.ok) {
    const { value: result } = res;
    console.log(result);
  } else {
    console.log("indexerPostApiV1Indexer failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
request operations.PostApiV1IndexerRequest ✔️ The request object to use for the request.
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<models.IndexerResource>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*

putApiV1IndexerBulk

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  const result = await prowlarr.indexer.putApiV1IndexerBulk();

  console.log(result);
}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerPutApiV1IndexerBulk } from "prowlarr/funcs/indexerPutApiV1IndexerBulk.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 indexerPutApiV1IndexerBulk(prowlarr);
  if (res.ok) {
    const { value: result } = res;
    console.log(result);
  } else {
    console.log("indexerPutApiV1IndexerBulk failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
request models.IndexerBulkResource ✔️ The request object to use for the request.
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<models.IndexerResource>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*

deleteApiV1IndexerBulk

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  await prowlarr.indexer.deleteApiV1IndexerBulk();


}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerDeleteApiV1IndexerBulk } from "prowlarr/funcs/indexerDeleteApiV1IndexerBulk.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 indexerDeleteApiV1IndexerBulk(prowlarr);
  if (res.ok) {
    const { value: result } = res;
    
  } else {
    console.log("indexerDeleteApiV1IndexerBulk failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
request models.IndexerBulkResource ✔️ The request object to use for the request.
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<void>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*

getApiV1IndexerSchema

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  const result = await prowlarr.indexer.getApiV1IndexerSchema();

  console.log(result);
}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerGetApiV1IndexerSchema } from "prowlarr/funcs/indexerGetApiV1IndexerSchema.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 indexerGetApiV1IndexerSchema(prowlarr);
  if (res.ok) {
    const { value: result } = res;
    console.log(result);
  } else {
    console.log("indexerGetApiV1IndexerSchema failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<models.IndexerResource[]>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*

postApiV1IndexerTest

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  await prowlarr.indexer.postApiV1IndexerTest({});


}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerPostApiV1IndexerTest } from "prowlarr/funcs/indexerPostApiV1IndexerTest.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 indexerPostApiV1IndexerTest(prowlarr, {});
  if (res.ok) {
    const { value: result } = res;
    
  } else {
    console.log("indexerPostApiV1IndexerTest failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
request operations.PostApiV1IndexerTestRequest ✔️ The request object to use for the request.
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<void>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*

postApiV1IndexerTestall

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  await prowlarr.indexer.postApiV1IndexerTestall();


}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerPostApiV1IndexerTestall } from "prowlarr/funcs/indexerPostApiV1IndexerTestall.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 indexerPostApiV1IndexerTestall(prowlarr);
  if (res.ok) {
    const { value: result } = res;
    
  } else {
    console.log("indexerPostApiV1IndexerTestall failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<void>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*

postApiV1IndexerActionName

Example Usage

import { Prowlarr } from "prowlarr";

const prowlarr = new Prowlarr({
  security: {
    xApiKey: process.env["PROWLARR_X_API_KEY"] ?? "",
  },
});

async function run() {
  await prowlarr.indexer.postApiV1IndexerActionName({
    name: "<value>",
  });


}

run();

Standalone function

The standalone function version of this method:

import { ProwlarrCore } from "prowlarr/core.js";
import { indexerPostApiV1IndexerActionName } from "prowlarr/funcs/indexerPostApiV1IndexerActionName.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 indexerPostApiV1IndexerActionName(prowlarr, {
    name: "<value>",
  });
  if (res.ok) {
    const { value: result } = res;
    
  } else {
    console.log("indexerPostApiV1IndexerActionName failed:", res.error);
  }
}

run();

Parameters

Parameter Type Required Description
request operations.PostApiV1IndexerActionNameRequest ✔️ The request object to use for the request.
options RequestOptions Used to set various options for making HTTP requests.
options.fetchOptions RequestInit 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 Enables retrying HTTP requests under certain failure conditions.

Response

Promise<void>

Errors

Error Type Status Code Content Type
errors.APIError 4XX, 5XX */*