This change will be deployed to Lighter Core Mainnet this Sunday (the exact time will be shared shortly), there will be no breaking changes for existing markets, which will maintain their current index - however, newly deployed markets (both perpetual, and spot ones) will pick the next free index >= 4095. For both cases, no other changes are required.
Traders can differentiate the type of market using the
"market_type" field returned by the orderBookDetails, orderBooks endpoints - we strongly advise against making assumptions based on IDs going forward, e.g. assuming that whenever market_id >= 2048, it'll be a spot market.That is particularly important for using WebSockets, as some channels are specific to a certain type of markets (e.g.
spot_market_stats; market_stats); or when updating perp-specific parameters, such as isolated/cross margining of a position.Mind that you're required to update your SDK to the latest version in order to support trading for these newly deployed markets.