Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,17 @@ import type { AxiosRequestConfig } from "axios";
export default class HockeyTech {
/**
* Constructor
*
* @note The HockeyTech API can be slow; consider setting a timeout via axiosConfig
* or making requests more granular to avoid requesting large datasets.
*
* @param key string
* @param clientCode string
* @param language string Examples: en, fr
* @param proxyBaseUrl string Example: http://localhost:3001/proxy?url=
* @param axiosConfig AxiosRequestConfig Custom Axios configuration for all requests, e.g. to override the adapter for Cloudflare Workers
*/
constructor(key: string, clientCode: string, language?: string, proxyBaseUrl?: string, axoisConfig?: AxiosRequestConfig);
constructor(key: string, clientCode: string, language?: string, proxyBaseUrl?: string, axiosConfig?: AxiosRequestConfig);

/**
* Changes the default base url for the modulekit endpoints
Expand Down Expand Up @@ -70,6 +74,8 @@ export default class HockeyTech {
* Retrieves the scorebar
* @param numberOfDaysAhead number
* @param numberOfDaysBack number
*
* @note Large date ranges (e.g. 1000+ days) may cause timeouts or slow responses (>30s).
*/
getScorebar(numberOfDaysAhead: number, numberOfDaysBack: number): Promise<ScorebarResponse>;

Expand Down