fix: improve types

This commit is contained in:
Vitaly Gashkov
2025-08-26 12:22:10 +05:00
parent 6152873a50
commit 03c74c53a3
+17 -3
View File
@@ -1,10 +1,24 @@
export function extractSecrets(): Promise<{ export type CrunchyrollAppCredentials = {
// Crunchyroll app ID // Crunchyroll app ID
id: string; id: string;
// Crunchyroll app secret // Crunchyroll app secret
secret: string; secret: string;
// Base64 encoded `id:secret` string // Base64 encoded `id:secret` string
encoded: string; encoded: string;
// HTTP header with Basic Authorization to access Crunchyroll mobile APIs // Ready HTTP header in the format `Basic <encoded>`, can be used to access some Crunchyroll APIs
authorization: string; authorization: string;
}>; };
/**
* Extract credentials from the Crunchyroll Android APK using jadx.
*/
export function extract(options?: {
target?: 'mobile' | 'tv';
output?: string;
cleanup?: boolean;
}): Promise<CrunchyrollAppCredentials>;
/**
* Fetch ready credentials from the GitHub repository.
*/
export function pull(options?: { target: 'mobile' | 'tv' }): Promise<CrunchyrollAppCredentials>;