Skip to content

CEX Announcement

Exchange announcements such as listings and delistings.

Usage

Sync
from datamaxi import Datamaxi

maxi = Datamaxi(api_key="YOUR_API_KEY")

data, next_request = maxi.cex.announcement(
    exchange="binance",
    category="listing",
    page=1,
    limit=50,
    sort="desc",
)

more_data, _ = next_request()
Async
import asyncio
from datamaxi.aio import AsyncDatamaxi


async def main():
    async with AsyncDatamaxi(api_key="YOUR_API_KEY") as client:
        data, next_request = await client.cex.announcement(
            exchange="binance",
            category="listing",
            page=1,
            limit=50,
            sort="desc",
        )

        more_data, _ = await next_request()


asyncio.run(main())

Notes

  • Pagination returns a next_request function for the next page.

Bases: Resource

Client to fetch announcement data from DataMaxi+ API.

Parameters:

  • api_key (str, default: None ) –

    The DataMaxi+ API key

  • **kwargs (Any, default: {} ) –

    Keyword arguments used by datamaxi.api.API.

__call__

__call__(
    page: int = 1,
    limit: int = 1000,
    sort: SortOrder = DESC,
    key: Optional[str] = None,
    exchange: Optional[str] = None,
    category: Optional[str] = None,
) -> Tuple[AnnouncementResponse, Callable]

Get exchange announcements

GET /api/v1/cex/announcements

https://docs.datamaxiplus.com/rest/cex/announcements

Parameters:

  • page (int, default: 1 ) –

    Page number

  • limit (int, default: 1000 ) –

    Limit of data

  • sort (str, default: DESC ) –

    Sort order

  • key (str, default: None ) –

    Key to sort by

  • exchange (str, default: None ) –

    Exchange name filter

  • category (str, default: None ) –

    Announcement category

Returns:

  • Tuple[AnnouncementResponse, Callable]

    Tuple of announcement response and next request function