/**
 * This file was auto-generated by openapi-typescript.
 * Do not make direct changes to the file.
 */
export interface paths {
    '/api/auth': {
        post: operations['auth'];
    };
    '/api/usage': {
        get: operations['getUsage'];
    };
    '/api/torrents': {
        get: operations['getTorrents'];
        post: operations['createTorrent'];
    };
    '/api/torrents/{infoHash}': {
        get: operations['getTorrent'];
    };
    '/stream/{torrent}': {
        /** Create a file stream from torrents by `torrent` parameter. By default the biggest file will be returned, but it is possible to select file manually using `file`, `fileType`, `fileIndex` parameters. Endpoint can be protected by passing signed payload with JWT token (`token` parameter). */
        get: operations['getStream'];
    };
    '/stream': {
        /** Create a file stream from torrents by `torrent` parameter. By default the biggest file will be returned, but it is possible to select file manually using `file`, `fileType`, `fileIndex` parameters. Endpoint can be protected by passing signed payload with JWT token (`token` parameter). */
        get: operations['getStream2'];
    };
    '/playlist/{torrent}': {
        /** Returns [m3u multimedia playlist](https://en.wikipedia.org/wiki/M3U) of the torrent. Supports same parameters as stream endpoint. */
        get: operations['getPlaylist'];
    };
    '/playlist': {
        /** Returns [m3u multimedia playlist](https://en.wikipedia.org/wiki/M3U) of the torrent. Supports same parameters as stream endpoint. */
        get: operations['getPlaylist2'];
    };
    '/api/browse/providers': {
        get: operations['getProviders'];
    };
    '/api/browse/providers/{provider}/magnet/{torrentId}': {
        get: operations['getMagnet'];
    };
    '/api/browse/search': {
        get: operations['searchTorrents'];
    };
}
export interface components {
    schemas: {
        UsageModel: {
            totalDiskSpace: number;
            freeDiskSpace: number;
            usedTorrentSpace: number;
        };
        TorrentModel: {
            link: string;
            infoHash: string;
            name: string;
            started: number;
            updated: number;
            files: components['schemas']['TorrentFileModel'][];
            downloaded: number;
            downloadSpeed: number;
            playlist: string;
        };
        TorrentFileModel: {
            name: string;
            path: string;
            type: string;
            length: number;
            stream: string;
        };
        ProviderModel: {
            name: string;
            categories: components['schemas']['ProviderCategoryModel'][];
        };
        ProviderCategoryModel: {
            name: string;
            id: string;
            subcategories: {
                name: string;
                id: string;
            }[];
        };
        ProviderTorrentModel: {
            id: string;
            name: string;
            magnet?: string;
            seeds: number;
            downloads?: number;
            peers: number;
            comments?: number;
            size: string;
            time?: number;
            link?: string;
            isVip?: boolean;
            imdb?: string;
            numFiles?: number;
            category?: {
                name: string;
                id: string;
            };
        };
        MagnetModel: {
            magnet: string;
        };
        ApiErrorModel: {
            error: string;
        };
        SuccessModel: {
            success: boolean;
        };
    };
    responses: {
        /** Successful operation */
        204: never;
        /** Bad Request */
        400: {
            content: {
                'application/json': components['schemas']['ApiErrorModel'];
            };
        };
        /** Unauthorized */
        401: {
            content: {
                'application/json': components['schemas']['ApiErrorModel'];
            };
        };
        /** Forbidden */
        403: {
            content: {
                'application/json': components['schemas']['ApiErrorModel'];
            };
        };
        /** Resource not found */
        404: {
            content: {
                'application/json': components['schemas']['ApiErrorModel'];
            };
        };
        /** Conflict */
        409: {
            content: {
                'application/json': components['schemas']['ApiErrorModel'];
            };
        };
        /** Server is busy */
        503: {
            content: {
                'application/json': components['schemas']['ApiErrorModel'];
            };
        };
    };
    parameters: {
        /** Can be torrent infoHash, magnet or link to torrent file. If security is enabled, it should be JWT encoded whole payload (including all `query` parameters) with extra `torrent` parameter. */
        torrentParam: string;
        /** Can be torrent infoHash, magnet or link to torrent file. If security is enabled, it should be JWT encoded whole payload (including all `query` parameters) with extra `torrent` parameter. */
        torrent: string;
        /** Case insensitive file name or path */
        file: string;
        /** Case insensitive file mime type (e.g. `video`, `video/mp4`, `mp4`) or file extension (e.g. `.mp4`, `mp4`) */
        fileType: string;
        /** File index (starting from `1`) */
        fileIndex: number;
    };
}
export interface operations {
    auth: {
        responses: {
            /** OK */
            200: {
                content: {
                    'application/json': components['schemas']['SuccessModel'];
                };
            };
            401: components['responses']['401'];
            403: components['responses']['403'];
        };
    };
    getUsage: {
        responses: {
            /** OK */
            200: {
                content: {
                    'application/json': components['schemas']['UsageModel'];
                };
            };
            401: components['responses']['401'];
            403: components['responses']['403'];
        };
    };
    getTorrents: {
        responses: {
            /** OK */
            200: {
                content: {
                    'application/json': components['schemas']['TorrentModel'][];
                };
            };
            401: components['responses']['401'];
            403: components['responses']['403'];
        };
    };
    createTorrent: {
        parameters: {
            query: {
                /** magnet or torrent link */
                torrent: string;
            };
        };
        responses: {
            /** OK */
            200: {
                content: {
                    'application/json': components['schemas']['TorrentModel'];
                };
            };
            400: components['responses']['400'];
            401: components['responses']['401'];
            403: components['responses']['403'];
        };
    };
    getTorrent: {
        parameters: {
            path: {
                /** torrent info hash */
                infoHash: string;
            };
        };
        responses: {
            /** OK */
            200: {
                content: {
                    'application/json': components['schemas']['TorrentModel'];
                };
            };
            401: components['responses']['401'];
            403: components['responses']['403'];
            404: components['responses']['404'];
        };
    };
    /** Create a file stream from torrents by `torrent` parameter. By default the biggest file will be returned, but it is possible to select file manually using `file`, `fileType`, `fileIndex` parameters. Endpoint can be protected by passing signed payload with JWT token (`token` parameter). */
    getStream: {
        parameters: {
            path: {
                /** Can be torrent infoHash, magnet or link to torrent file. If security is enabled, it should be JWT encoded whole payload (including all `query` parameters) with extra `torrent` parameter. */
                torrent: components['parameters']['torrentParam'];
            };
            query: {
                /** Case insensitive file name or path */
                file?: components['parameters']['file'];
                /** Case insensitive file mime type (e.g. `video`, `video/mp4`, `mp4`) or file extension (e.g. `.mp4`, `mp4`) */
                fileType?: components['parameters']['fileType'];
                /** File index (starting from `1`) */
                fileIndex?: components['parameters']['fileIndex'];
            };
        };
        responses: {
            /** OK */
            200: {
                content: {
                    'application/octet-stream': string;
                };
            };
            400: components['responses']['400'];
            401: components['responses']['401'];
            403: components['responses']['403'];
            404: components['responses']['404'];
        };
    };
    /** Create a file stream from torrents by `torrent` parameter. By default the biggest file will be returned, but it is possible to select file manually using `file`, `fileType`, `fileIndex` parameters. Endpoint can be protected by passing signed payload with JWT token (`token` parameter). */
    getStream2: {
        parameters: {
            query: {
                /** Can be torrent infoHash, magnet or link to torrent file. If security is enabled, it should be JWT encoded whole payload (including all `query` parameters) with extra `torrent` parameter. */
                torrent: components['parameters']['torrent'];
                /** Case insensitive file name or path */
                file?: components['parameters']['file'];
                /** Case insensitive file mime type (e.g. `video`, `video/mp4`, `mp4`) or file extension (e.g. `.mp4`, `mp4`) */
                fileType?: components['parameters']['fileType'];
                /** File index (starting from `1`) */
                fileIndex?: components['parameters']['fileIndex'];
            };
        };
        responses: {
            /** OK */
            200: {
                content: {
                    'application/octet-stream': string;
                };
            };
            400: components['responses']['400'];
            401: components['responses']['401'];
            403: components['responses']['403'];
            404: components['responses']['404'];
        };
    };
    /** Returns [m3u multimedia playlist](https://en.wikipedia.org/wiki/M3U) of the torrent. Supports same parameters as stream endpoint. */
    getPlaylist: {
        parameters: {
            path: {
                /** Can be torrent infoHash, magnet or link to torrent file. If security is enabled, it should be JWT encoded whole payload (including all `query` parameters) with extra `torrent` parameter. */
                torrent: components['parameters']['torrentParam'];
            };
            query: {
                /** Case insensitive file name or path */
                file?: components['parameters']['file'];
                /** Case insensitive file mime type (e.g. `video`, `video/mp4`, `mp4`) or file extension (e.g. `.mp4`, `mp4`) */
                fileType?: components['parameters']['fileType'];
                /** File index (starting from `1`) */
                fileIndex?: components['parameters']['fileIndex'];
            };
        };
        responses: {
            /** OK */
            200: {
                content: {
                    'application/octet-stream': string;
                };
            };
            400: components['responses']['400'];
            401: components['responses']['401'];
            403: components['responses']['403'];
            404: components['responses']['404'];
        };
    };
    /** Returns [m3u multimedia playlist](https://en.wikipedia.org/wiki/M3U) of the torrent. Supports same parameters as stream endpoint. */
    getPlaylist2: {
        parameters: {
            query: {
                /** Can be torrent infoHash, magnet or link to torrent file. If security is enabled, it should be JWT encoded whole payload (including all `query` parameters) with extra `torrent` parameter. */
                torrent: components['parameters']['torrent'];
                /** Case insensitive file name or path */
                file?: components['parameters']['file'];
                /** Case insensitive file mime type (e.g. `video`, `video/mp4`, `mp4`) or file extension (e.g. `.mp4`, `mp4`) */
                fileType?: components['parameters']['fileType'];
                /** File index (starting from `1`) */
                fileIndex?: components['parameters']['fileIndex'];
            };
        };
        responses: {
            /** OK */
            200: {
                content: {
                    'application/octet-stream': string;
                };
            };
            400: components['responses']['400'];
            401: components['responses']['401'];
            403: components['responses']['403'];
            404: components['responses']['404'];
        };
    };
    getProviders: {
        responses: {
            /** OK */
            200: {
                content: {
                    'application/json': components['schemas']['ProviderModel'][];
                };
            };
            401: components['responses']['401'];
            403: components['responses']['403'];
        };
    };
    getMagnet: {
        parameters: {
            path: {
                /** provider name */
                provider: string;
                /** torrent id */
                torrentId: string;
            };
        };
        responses: {
            /** OK */
            200: {
                content: {
                    'application/json': components['schemas']['MagnetModel'];
                };
            };
            401: components['responses']['401'];
            403: components['responses']['403'];
            404: components['responses']['404'];
        };
    };
    searchTorrents: {
        parameters: {
            query: {
                /** search query */
                query: string;
                /** provider name */
                provider: string;
                /** provider category */
                category?: string;
            };
        };
        responses: {
            /** OK */
            200: {
                content: {
                    'application/json': components['schemas']['ProviderTorrentModel'][];
                };
            };
            400: components['responses']['400'];
            401: components['responses']['401'];
            403: components['responses']['403'];
        };
    };
}
export interface external {
}
