kalshi-typescript
Version:
OpenAPI client for kalshi-typescript
133 lines (132 loc) • 8.84 kB
TypeScript
/**
* Kalshi Trade API Manual Endpoints
* Manually defined OpenAPI spec for endpoints being migrated to spec-first approach
*
* The version of the OpenAPI document: 3.11.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import type { Configuration } from '../configuration';
import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
import { type RequestArgs, BaseAPI } from '../base';
import type { GetMilestoneResponse } from '../models';
import type { GetMilestonesResponse } from '../models';
/**
* MilestoneApi - axios parameter creator
*/
export declare const MilestoneApiAxiosParamCreator: (configuration?: Configuration) => {
/**
* Endpoint for getting data about a specific milestone by its ID.
* @summary Get Milestone
* @param {string} milestoneId Milestone ID
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getMilestone: (milestoneId: string, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
/**
* Minimum start date to filter milestones. Format: RFC3339 timestamp
* @summary Get Milestones
* @param {number} limit Number of milestones to return per page
* @param {string} [minimumStartDate] Minimum start date to filter milestones. Format RFC3339 timestamp
* @param {string} [category] Filter by milestone category. E.g. Sports, Elections, Esports, Crypto.
* @param {string} [competition] Filter by competition. E.g. Pro Football, Pro Basketball (M), Pro Baseball, Pro Hockey, College Football.
* @param {string} [sourceId] Filter by source id
* @param {string} [type] Filter by milestone type. E.g. football_game, basketball_game, soccer_tournament_multi_leg, baseball_game, hockey_match, political_race.
* @param {string} [relatedEventTicker] Filter by related event ticker
* @param {string} [cursor] Pagination cursor. Use the cursor value returned from the previous response to get the next page of results
* @param {number} [minUpdatedTs] Filter milestones with metadata updated after this Unix timestamp (in seconds). Use this to efficiently poll for changes.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getMilestones: (limit: number, minimumStartDate?: string, category?: string, competition?: string, sourceId?: string, type?: string, relatedEventTicker?: string, cursor?: string, minUpdatedTs?: number, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
};
/**
* MilestoneApi - functional programming interface
*/
export declare const MilestoneApiFp: (configuration?: Configuration) => {
/**
* Endpoint for getting data about a specific milestone by its ID.
* @summary Get Milestone
* @param {string} milestoneId Milestone ID
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getMilestone(milestoneId: string, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetMilestoneResponse>>;
/**
* Minimum start date to filter milestones. Format: RFC3339 timestamp
* @summary Get Milestones
* @param {number} limit Number of milestones to return per page
* @param {string} [minimumStartDate] Minimum start date to filter milestones. Format RFC3339 timestamp
* @param {string} [category] Filter by milestone category. E.g. Sports, Elections, Esports, Crypto.
* @param {string} [competition] Filter by competition. E.g. Pro Football, Pro Basketball (M), Pro Baseball, Pro Hockey, College Football.
* @param {string} [sourceId] Filter by source id
* @param {string} [type] Filter by milestone type. E.g. football_game, basketball_game, soccer_tournament_multi_leg, baseball_game, hockey_match, political_race.
* @param {string} [relatedEventTicker] Filter by related event ticker
* @param {string} [cursor] Pagination cursor. Use the cursor value returned from the previous response to get the next page of results
* @param {number} [minUpdatedTs] Filter milestones with metadata updated after this Unix timestamp (in seconds). Use this to efficiently poll for changes.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getMilestones(limit: number, minimumStartDate?: string, category?: string, competition?: string, sourceId?: string, type?: string, relatedEventTicker?: string, cursor?: string, minUpdatedTs?: number, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<GetMilestonesResponse>>;
};
/**
* MilestoneApi - factory interface
*/
export declare const MilestoneApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
/**
* Endpoint for getting data about a specific milestone by its ID.
* @summary Get Milestone
* @param {string} milestoneId Milestone ID
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getMilestone(milestoneId: string, options?: RawAxiosRequestConfig): AxiosPromise<GetMilestoneResponse>;
/**
* Minimum start date to filter milestones. Format: RFC3339 timestamp
* @summary Get Milestones
* @param {number} limit Number of milestones to return per page
* @param {string} [minimumStartDate] Minimum start date to filter milestones. Format RFC3339 timestamp
* @param {string} [category] Filter by milestone category. E.g. Sports, Elections, Esports, Crypto.
* @param {string} [competition] Filter by competition. E.g. Pro Football, Pro Basketball (M), Pro Baseball, Pro Hockey, College Football.
* @param {string} [sourceId] Filter by source id
* @param {string} [type] Filter by milestone type. E.g. football_game, basketball_game, soccer_tournament_multi_leg, baseball_game, hockey_match, political_race.
* @param {string} [relatedEventTicker] Filter by related event ticker
* @param {string} [cursor] Pagination cursor. Use the cursor value returned from the previous response to get the next page of results
* @param {number} [minUpdatedTs] Filter milestones with metadata updated after this Unix timestamp (in seconds). Use this to efficiently poll for changes.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getMilestones(limit: number, minimumStartDate?: string, category?: string, competition?: string, sourceId?: string, type?: string, relatedEventTicker?: string, cursor?: string, minUpdatedTs?: number, options?: RawAxiosRequestConfig): AxiosPromise<GetMilestonesResponse>;
};
/**
* MilestoneApi - object-oriented interface
*/
export declare class MilestoneApi extends BaseAPI {
/**
* Endpoint for getting data about a specific milestone by its ID.
* @summary Get Milestone
* @param {string} milestoneId Milestone ID
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getMilestone(milestoneId: string, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<GetMilestoneResponse, any, {}>>;
/**
* Minimum start date to filter milestones. Format: RFC3339 timestamp
* @summary Get Milestones
* @param {number} limit Number of milestones to return per page
* @param {string} [minimumStartDate] Minimum start date to filter milestones. Format RFC3339 timestamp
* @param {string} [category] Filter by milestone category. E.g. Sports, Elections, Esports, Crypto.
* @param {string} [competition] Filter by competition. E.g. Pro Football, Pro Basketball (M), Pro Baseball, Pro Hockey, College Football.
* @param {string} [sourceId] Filter by source id
* @param {string} [type] Filter by milestone type. E.g. football_game, basketball_game, soccer_tournament_multi_leg, baseball_game, hockey_match, political_race.
* @param {string} [relatedEventTicker] Filter by related event ticker
* @param {string} [cursor] Pagination cursor. Use the cursor value returned from the previous response to get the next page of results
* @param {number} [minUpdatedTs] Filter milestones with metadata updated after this Unix timestamp (in seconds). Use this to efficiently poll for changes.
* @param {*} [options] Override http request option.
* @throws {RequiredError}
*/
getMilestones(limit: number, minimumStartDate?: string, category?: string, competition?: string, sourceId?: string, type?: string, relatedEventTicker?: string, cursor?: string, minUpdatedTs?: number, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<GetMilestonesResponse, any, {}>>;
}