Default API Reference¶
Endpoints¶
Get Exchange Announcements¶
Synchronous API Call
kalshi_py.api.default.get_exchange_announcements.sync(*, client: Union[AuthenticatedClient, Client]) -> Optional[ModelGetExchangeAnnouncementsResponse]
¶
Get Exchange Announcements
Endpoint for getting all exchange-wide announcements.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Optional[ModelGetExchangeAnnouncementsResponse]
|
ModelGetExchangeAnnouncementsResponse |
Source code in kalshi_py/api/default/get_exchange_announcements.py
Asynchronous API Call
kalshi_py.api.default.get_exchange_announcements.asyncio(*, client: Union[AuthenticatedClient, Client]) -> Optional[ModelGetExchangeAnnouncementsResponse]
async
¶
Get Exchange Announcements
Endpoint for getting all exchange-wide announcements.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Optional[ModelGetExchangeAnnouncementsResponse]
|
ModelGetExchangeAnnouncementsResponse |
Source code in kalshi_py/api/default/get_exchange_announcements.py
Synchronous Detailed Response
kalshi_py.api.default.get_exchange_announcements.sync_detailed(*, client: Union[AuthenticatedClient, Client]) -> Response[ModelGetExchangeAnnouncementsResponse]
¶
Get Exchange Announcements
Endpoint for getting all exchange-wide announcements.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Response[ModelGetExchangeAnnouncementsResponse]
|
Response[ModelGetExchangeAnnouncementsResponse] |
Source code in kalshi_py/api/default/get_exchange_announcements.py
Asynchronous Detailed Response
kalshi_py.api.default.get_exchange_announcements.asyncio_detailed(*, client: Union[AuthenticatedClient, Client]) -> Response[ModelGetExchangeAnnouncementsResponse]
async
¶
Get Exchange Announcements
Endpoint for getting all exchange-wide announcements.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Response[ModelGetExchangeAnnouncementsResponse]
|
Response[ModelGetExchangeAnnouncementsResponse] |
Source code in kalshi_py/api/default/get_exchange_announcements.py
Get Exchange Schedule¶
Synchronous API Call
kalshi_py.api.default.get_exchange_schedule.sync(*, client: Union[AuthenticatedClient, Client]) -> Optional[ModelGetExchangeScheduleResponse]
¶
Get Exchange Schedule
Endpoint for getting the exchange schedule.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Optional[ModelGetExchangeScheduleResponse]
|
ModelGetExchangeScheduleResponse |
Source code in kalshi_py/api/default/get_exchange_schedule.py
Asynchronous API Call
kalshi_py.api.default.get_exchange_schedule.asyncio(*, client: Union[AuthenticatedClient, Client]) -> Optional[ModelGetExchangeScheduleResponse]
async
¶
Get Exchange Schedule
Endpoint for getting the exchange schedule.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Optional[ModelGetExchangeScheduleResponse]
|
ModelGetExchangeScheduleResponse |
Source code in kalshi_py/api/default/get_exchange_schedule.py
Synchronous Detailed Response
kalshi_py.api.default.get_exchange_schedule.sync_detailed(*, client: Union[AuthenticatedClient, Client]) -> Response[ModelGetExchangeScheduleResponse]
¶
Get Exchange Schedule
Endpoint for getting the exchange schedule.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Response[ModelGetExchangeScheduleResponse]
|
Response[ModelGetExchangeScheduleResponse] |
Source code in kalshi_py/api/default/get_exchange_schedule.py
Asynchronous Detailed Response
kalshi_py.api.default.get_exchange_schedule.asyncio_detailed(*, client: Union[AuthenticatedClient, Client]) -> Response[ModelGetExchangeScheduleResponse]
async
¶
Get Exchange Schedule
Endpoint for getting the exchange schedule.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Response[ModelGetExchangeScheduleResponse]
|
Response[ModelGetExchangeScheduleResponse] |
Source code in kalshi_py/api/default/get_exchange_schedule.py
Get Exchange Status¶
Synchronous API Call
kalshi_py.api.default.get_exchange_status.sync(*, client: Union[AuthenticatedClient, Client]) -> Optional[ModelExchangeStatus]
¶
Get Exchange Status
Endpoint for getting the exchange status.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Optional[ModelExchangeStatus]
|
ModelExchangeStatus |
Source code in kalshi_py/api/default/get_exchange_status.py
Asynchronous API Call
kalshi_py.api.default.get_exchange_status.asyncio(*, client: Union[AuthenticatedClient, Client]) -> Optional[ModelExchangeStatus]
async
¶
Get Exchange Status
Endpoint for getting the exchange status.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Optional[ModelExchangeStatus]
|
ModelExchangeStatus |
Source code in kalshi_py/api/default/get_exchange_status.py
Synchronous Detailed Response
kalshi_py.api.default.get_exchange_status.sync_detailed(*, client: Union[AuthenticatedClient, Client]) -> Response[ModelExchangeStatus]
¶
Get Exchange Status
Endpoint for getting the exchange status.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Response[ModelExchangeStatus]
|
Response[ModelExchangeStatus] |
Source code in kalshi_py/api/default/get_exchange_status.py
Asynchronous Detailed Response
kalshi_py.api.default.get_exchange_status.asyncio_detailed(*, client: Union[AuthenticatedClient, Client]) -> Response[ModelExchangeStatus]
async
¶
Get Exchange Status
Endpoint for getting the exchange status.
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Response[ModelExchangeStatus]
|
Response[ModelExchangeStatus] |
Source code in kalshi_py/api/default/get_exchange_status.py
Get User Data Timestamp¶
Synchronous API Call
kalshi_py.api.default.get_user_data_timestamp.sync(*, client: Union[AuthenticatedClient, Client]) -> Optional[ModelGetUserDataTimestampResponse]
¶
Get User Data Timestamp
There is typically a short delay before exchange events are reflected in the API endpoints. Whenever possible, combine API responses to PUT/POST/DELETE requests with websocket data to obtain the most accurate view of the exchange state. This endpoint provides an approximate indication of when the data from the following endpoints was last validated: GetBalance, GetOrder(s), GetFills, GetPositions
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Optional[ModelGetUserDataTimestampResponse]
|
ModelGetUserDataTimestampResponse |
Source code in kalshi_py/api/default/get_user_data_timestamp.py
Asynchronous API Call
kalshi_py.api.default.get_user_data_timestamp.asyncio(*, client: Union[AuthenticatedClient, Client]) -> Optional[ModelGetUserDataTimestampResponse]
async
¶
Get User Data Timestamp
There is typically a short delay before exchange events are reflected in the API endpoints. Whenever possible, combine API responses to PUT/POST/DELETE requests with websocket data to obtain the most accurate view of the exchange state. This endpoint provides an approximate indication of when the data from the following endpoints was last validated: GetBalance, GetOrder(s), GetFills, GetPositions
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Optional[ModelGetUserDataTimestampResponse]
|
ModelGetUserDataTimestampResponse |
Source code in kalshi_py/api/default/get_user_data_timestamp.py
Synchronous Detailed Response
kalshi_py.api.default.get_user_data_timestamp.sync_detailed(*, client: Union[AuthenticatedClient, Client]) -> Response[ModelGetUserDataTimestampResponse]
¶
Get User Data Timestamp
There is typically a short delay before exchange events are reflected in the API endpoints. Whenever possible, combine API responses to PUT/POST/DELETE requests with websocket data to obtain the most accurate view of the exchange state. This endpoint provides an approximate indication of when the data from the following endpoints was last validated: GetBalance, GetOrder(s), GetFills, GetPositions
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Response[ModelGetUserDataTimestampResponse]
|
Response[ModelGetUserDataTimestampResponse] |
Source code in kalshi_py/api/default/get_user_data_timestamp.py
Asynchronous Detailed Response
kalshi_py.api.default.get_user_data_timestamp.asyncio_detailed(*, client: Union[AuthenticatedClient, Client]) -> Response[ModelGetUserDataTimestampResponse]
async
¶
Get User Data Timestamp
There is typically a short delay before exchange events are reflected in the API endpoints. Whenever possible, combine API responses to PUT/POST/DELETE requests with websocket data to obtain the most accurate view of the exchange state. This endpoint provides an approximate indication of when the data from the following endpoints was last validated: GetBalance, GetOrder(s), GetFills, GetPositions
Raises:
Type | Description |
---|---|
UnexpectedStatus
|
If the server returns an undocumented status code and Client.raise_on_unexpected_status is True. |
TimeoutException
|
If the request takes longer than Client.timeout. |
Returns:
Type | Description |
---|---|
Response[ModelGetUserDataTimestampResponse]
|
Response[ModelGetUserDataTimestampResponse] |