@jellyfin/sdk
Version:
A TypeScript SDK for Jellyfin.
162 lines (161 loc) • 5.66 kB
TypeScript
/**
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* Do not edit the class manually.
*
* Jellyfin API
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
import type { Configuration } from '../configuration';
import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
import { type RequestArgs, BaseAPI } from '../base';
import type { AuthenticationInfoQueryResult } from '../models';
/**
* ApiKeyApi - axios parameter creator
* @export
*/
export declare const ApiKeyApiAxiosParamCreator: (configuration?: Configuration) => {
/**
*
* @summary Create a new api key.
* @param {string} app Name of the app using the authentication key.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
createKey: (app: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
*
* @summary Get all keys.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getKeys: (options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
*
* @summary Remove an api key.
* @param {string} key The access token to delete.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
revokeKey: (key: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
};
/**
* ApiKeyApi - functional programming interface
* @export
*/
export declare const ApiKeyApiFp: (configuration?: Configuration) => {
/**
*
* @summary Create a new api key.
* @param {string} app Name of the app using the authentication key.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
createKey(app: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
/**
*
* @summary Get all keys.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getKeys(options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<AuthenticationInfoQueryResult>>;
/**
*
* @summary Remove an api key.
* @param {string} key The access token to delete.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
revokeKey(key: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<void>>;
};
/**
* ApiKeyApi - factory interface
* @export
*/
export declare const ApiKeyApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
/**
*
* @summary Create a new api key.
* @param {ApiKeyApiCreateKeyRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
createKey(requestParameters: ApiKeyApiCreateKeyRequest, options?: RawAxiosRequestConfig): AxiosPromise<void>;
/**
*
* @summary Get all keys.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getKeys(options?: RawAxiosRequestConfig): AxiosPromise<AuthenticationInfoQueryResult>;
/**
*
* @summary Remove an api key.
* @param {ApiKeyApiRevokeKeyRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
revokeKey(requestParameters: ApiKeyApiRevokeKeyRequest, options?: RawAxiosRequestConfig): AxiosPromise<void>;
};
/**
* Request parameters for createKey operation in ApiKeyApi.
* @export
* @interface ApiKeyApiCreateKeyRequest
*/
export interface ApiKeyApiCreateKeyRequest {
/**
* Name of the app using the authentication key.
* @type {string}
* @memberof ApiKeyApiCreateKey
*/
readonly app: string;
}
/**
* Request parameters for revokeKey operation in ApiKeyApi.
* @export
* @interface ApiKeyApiRevokeKeyRequest
*/
export interface ApiKeyApiRevokeKeyRequest {
/**
* The access token to delete.
* @type {string}
* @memberof ApiKeyApiRevokeKey
*/
readonly key: string;
}
/**
* ApiKeyApi - object-oriented interface
* @export
* @class ApiKeyApi
* @extends {BaseAPI}
*/
export declare class ApiKeyApi extends BaseAPI {
/**
*
* @summary Create a new api key.
* @param {ApiKeyApiCreateKeyRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ApiKeyApi
*/
createKey(requestParameters: ApiKeyApiCreateKeyRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any>>;
/**
*
* @summary Get all keys.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ApiKeyApi
*/
getKeys(options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<AuthenticationInfoQueryResult, any>>;
/**
*
* @summary Remove an api key.
* @param {ApiKeyApiRevokeKeyRequest} requestParameters Request parameters.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof ApiKeyApi
*/
revokeKey(requestParameters: ApiKeyApiRevokeKeyRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<void, any>>;
}