This documentation goes in detail how to interact with Session Manager's API. For a more top-level approach, check the design documentation.
curl \ -H "X-VTEX-API-AppKey: $API_KEY" \ https://vtex.local/segments
curl \ -H "X-VTEX-API-AppKey: $API_KEY" \ https://vtex.local/sessions