feat: Add Be and tbd skill, also added Roadmap file

This commit is contained in:
2026-05-10 16:32:12 -04:00
parent 3500ade13f
commit 0bb8885802
29587 changed files with 10611695 additions and 0 deletions

View File

@@ -0,0 +1,223 @@
export interface GenreToID {
[genre: string]: number;
}
export declare const IHeartGenres: GenreToID;
export interface ResultWithHits<T> {
duration: number;
total: number;
hits: T[];
}
export interface IHeartError {
code: number;
debugInfo: any;
description: string;
httpCode: number;
}
export interface ClientConfigResult {
clientConfigData?: ClientConfig;
duration: number;
errors?: IHeartError[];
firstError?: IHeartError;
}
export interface ClientConfig {
amp_version: string;
billing_detail_url: string;
current_url: string;
download_url: string;
genre_url: string;
host_name: string;
image_server: string;
need_upgrade: boolean;
subscribe_upgrade: any;
tc_url: string;
tour_url: string;
transform_prefix: string;
tutorial1_url: string;
tutorial2_url: string;
tutorial3_url: string;
use_cdn: boolean;
royalty_report_time: any;
create_account_url: string;
use_create_account_url: boolean;
faq_url: string;
privacy_policy_url: string;
}
export interface OAuth {
oauthUuid: string;
type: string;
}
export interface Session {
accountType: string;
countryCode: string;
duration: number;
errors: IHeartError[];
firstError: IHeartError;
newUser: boolean;
oauths: OAuth[];
profileId: number;
sessionId: string;
success: boolean;
}
export interface Country {
abbreviation: string;
id: string;
name: string;
stationCount: number;
}
export interface State {
abbreviation: string;
id: string;
name: string;
country: Country;
stationCount: number;
}
export interface City {
id: string;
abbreviation: string;
name: string;
state: State;
stationCount: number;
}
export interface Location {
lat: number;
lon: number;
}
export interface LocationConfig {
apiUrl: string;
hostName: string;
terminalId: number;
}
export interface GetLocationConfigResponse {
config: LocationConfig;
countryCode: string;
}
export interface Market {
city: string;
countryAbbreviation: string;
countryId: string;
countryName: string;
loc: Location;
marketId: number;
name: string;
stateAbbreviation: string;
stateId: string;
stateName: string;
stationCount: number;
}
export interface IHeartGenre {
id: number;
name: string;
count: number;
rank: any;
}
export interface Adswizz {
adswizzHost: string;
enableAdswizzTargeting: string;
publisher_id: string;
}
export interface AdswizzZones {
"audio-exchange-zone": string;
"audio-fill-zone": string;
"audio-zone": string;
"display-zone": string;
"optimized-audio-fill-zone": string;
}
export interface StationFeeds {
feed: string;
site_id: string;
}
export interface StationGenre {
id: number;
name: string;
primary: boolean;
sortIndex: boolean;
}
export interface StationMarket {
city: string;
cityId: number;
country: string;
countryId: number;
marketId: string;
name: string;
origin: boolean;
primary: boolean;
sortIndex: number;
stateAbbreviation: string;
stateId: number;
}
export interface StationSocial {
facebook: string;
instagram: string;
twitter: string;
}
export interface StationStreams {
hls_stream: string;
pls_stream: string;
secure_hls_stream: string;
secure_pls_stream: string;
secure_rtmp_stream: string;
secure_shoutcast_stream: string;
shoutcast_stream: string;
}
export interface IHeartStation {
adswizz: Adswizz;
adswizzZones: AdswizzZones;
band: string;
callLetterAlias: string;
callLetterRoaylty: string;
callLetters: string;
countries: string;
cume: number;
description: string;
esid: string;
feeds: StationFeeds;
format: string;
freq: string;
genres: StationGenre[];
id: number;
isActive: boolean;
logo: string;
markets: StationMarket[];
modified: string;
name: string;
provider: string;
rds: string;
responseType: string;
score: number;
social: StationSocial;
streams: StationStreams;
website: string;
}
export interface FragmentParse {
frag: Fragment;
id: string;
samples: FragSample[];
}
export interface Fragment {
autoLevel: boolean;
baseurl: string;
bitrateTest: boolean;
cc: number;
duration: number;
endDTS: number;
endPTS: number;
level: number;
loadCounter: number;
loadIdx: number;
loaded: number;
maxStartPTS: number;
relurl: string;
sn: number;
start: number;
startDTS: number;
startPTS: number;
tagList: string[][];
title: string;
type: string;
url: string;
}
export interface FragSample {
data: Uint8Array;
dts: number;
pts: number;
}

View File

@@ -0,0 +1,38 @@
import RadioPlayer, { GetStationsOptions, ListenEvents, SongData, StationData, VolumePlugin } from '../RadioPlayer';
export default class IHeartPlayer extends RadioPlayer {
private _countryCode;
private _iHeartBaseURI;
private _iHeartHostname;
private _iHeartLog;
private _iHeartTerminal;
private _initError;
private _initPromise;
private _locationConfigError;
private _locationConfigPromise;
private _session;
private _station;
private _stationCache;
private static _getMediaType(fromIHeart);
init(serialNumber: string, releaseVersion: string, country: string, lat: number, lng: number, listenEvents: ListenEvents, volumePlugin: VolumePlugin): Promise<void>;
getCountry(): Promise<string>;
getStations(options?: GetStationsOptions): Promise<StationData[]>;
play(callLetters: string): Promise<void>;
resizeArtwork(uri: string, width: number): string;
destroy(): void;
protected _processHLSMetadata(titleField: string): SongData;
protected _processShoutcastMetadata(metadata: any): SongData;
protected _getSidebandData: () => Promise<SongData>;
protected _handleStreamError(data?: any): void;
protected _streamStarted(): void;
private _init();
private _getLocation();
private _getURI(endpoint);
private _login();
private _get<T>(endpoint, options?);
private _getHits<T>(endpoint, options?);
private _post<T>(endpoint, data?, options?);
private _getLiveStations(params?);
private _getSongData(params?);
private _streamStation();
private _iHeartStreamHLS(stream);
}

View File

@@ -0,0 +1,2 @@
import IHeartPlayer from './IHeartPlayer';
export { IHeartPlayer };