Sessions
Manage WhatsApp sessions
List only the sessions owned by your account. An empty data array means you have no sessions yet. Use each returned name in session parameters; status can be refreshed from the messaging service when available.
BearerAuthAuthorizationBearer <ch_live_... | ak_live_...>Direct WhatsApp Session Token (Authorization: Bearer ch_live_...) or Account API Key (ak_live_...). Generated in your dashboard at https://whatsapp-messaging.retentionstack.agency/start.
Owned sessions. Before creation, data is an empty array.
application/json- response
success*truetruedata*array<>timestamp*stringdate-timecurl -X GET 'https://wp-rapidapi.retentionstack.agency/v1/sessions'{ "success": true, "data": [], "timestamp": "2026-11-02T00:00:00.000Z"}Create and start one WhatsApp session. The server generates its name; save data.name and use it for later calls. A supplied name is ignored. A 403 can mean your plan already has its maximum number of sessions; reuse a session from error.details.availableSessions. A rare generated-name collision returns 409; retry creation in that case.
BearerAuthAuthorizationBearer <ch_live_... | ak_live_...>Direct WhatsApp Session Token (Authorization: Bearer ch_live_...) or Account API Key (ak_live_...). Generated in your dashboard at https://whatsapp-messaging.retentionstack.agency/start.
Session created and started. Save data.name; a requested name is ignored.
application/json- response
success*truetruedata*timestamp*stringdate-timecurl -X POST 'https://wp-rapidapi.retentionstack.agency/v1/sessions'{ "success": true, "data": { "name": "session_example_1793577600000_ab12cd", "status": "SCAN_QR_CODE", "me": null }, "timestamp": "2026-11-02T00:00:00.000Z"}Read your session state. Use the name returned by session creation. Wait for WORKING before sending; if the session needs linking, request its QR or pairing code.
BearerAuthAuthorizationBearer <ch_live_... | ak_live_...>Direct WhatsApp Session Token (Authorization: Bearer ch_live_...) or Account API Key (ak_live_...). Generated in your dashboard at https://whatsapp-messaging.retentionstack.agency/start.
session*stringWhatsApp session name (1-100 characters). With a session token (ch_live_...), me targets that token's session; with an account key, use the session name.
1 <= length <= 100Invalid request or session not ready. Inspect error.details for validation issues, currentStatus, nextSteps or nextStep; link WhatsApp before sending.
application/json- response
success*falsefalseerror*timestamp*stringdate-timecurl -X GET 'https://wp-rapidapi.retentionstack.agency/v1/sessions/me'{ "success": true, "data": {}, "timestamp": "2026-11-02T00:00:00.000Z"}Delete your session from the messaging service and the local session registry. This removes the API session; create and link a new session if you need it again.
BearerAuthAuthorizationBearer <ch_live_... | ak_live_...>Direct WhatsApp Session Token (Authorization: Bearer ch_live_...) or Account API Key (ak_live_...). Generated in your dashboard at https://whatsapp-messaging.retentionstack.agency/start.
session*stringWhatsApp session name (1-100 characters). With a session token (ch_live_...), me targets that token's session; with an account key, use the session name.
1 <= length <= 100Invalid request or session not ready. Inspect error.details for validation issues, currentStatus, nextSteps or nextStep; link WhatsApp before sending.
application/json- response
success*falsefalseerror*timestamp*stringdate-timecurl -X DELETE 'https://wp-rapidapi.retentionstack.agency/v1/sessions/me'{ "success": true, "data": {}, "timestamp": "2026-11-02T00:00:00.000Z"}Read the WhatsApp account linked to your session. This requires ownership of the session; account details depend on the messaging engine and whether linking is complete.
BearerAuthAuthorizationBearer <ch_live_... | ak_live_...>Direct WhatsApp Session Token (Authorization: Bearer ch_live_...) or Account API Key (ak_live_...). Generated in your dashboard at https://whatsapp-messaging.retentionstack.agency/start.
session*stringWhatsApp session name (1-100 characters). With a session token (ch_live_...), me targets that token's session; with an account key, use the session name.
1 <= length <= 100Invalid request or session not ready. Inspect error.details for validation issues, currentStatus, nextSteps or nextStep; link WhatsApp before sending.
application/json- response
success*falsefalseerror*timestamp*stringdate-timecurl -X GET 'https://wp-rapidapi.retentionstack.agency/v1/sessions/me/me'{ "success": true, "data": {}, "timestamp": "2026-11-02T00:00:00.000Z"}Start or recover your session using its name. Already connected sessions return their current state without restarting. An empty body auto-creates a session only when you have none; otherwise supply name. Auto-creation returns 201; existing sessions return 200.
BearerAuthAuthorizationBearer <ch_live_... | ak_live_...>Direct WhatsApp Session Token (Authorization: Bearer ch_live_...) or Account API Key (ak_live_...). Generated in your dashboard at https://whatsapp-messaging.retentionstack.agency/start.
Start a WhatsApp session
application/json- body
Start a WhatsApp session
name?stringSession name to start. If omitted and you have no sessions, one will be auto-created. If omitted and you have existing sessions, you must specify which one to start.
length <= 100Existing session started or its current connected state returned.
application/json- response
success*truetruedata*timestamp*stringdate-timecurl -X POST 'https://wp-rapidapi.retentionstack.agency/v1/sessions/start' \ -H 'Content-Type: application/json' \ -d '{ "name": "me"}'{ "success": true, "data": { "name": "session_example_1793577600000_ab12cd", "status": "WORKING" }, "timestamp": "2026-11-02T00:00:00.000Z"}Stop your named session. The optional logout flag also logs it out. Sending requires a running, linked session; start it again before sending.
BearerAuthAuthorizationBearer <ch_live_... | ak_live_...>Direct WhatsApp Session Token (Authorization: Bearer ch_live_...) or Account API Key (ak_live_...). Generated in your dashboard at https://whatsapp-messaging.retentionstack.agency/start.
Stop an active WhatsApp session
application/json- body
Stop an active WhatsApp session
name*stringSession name to stop
1 <= lengthlogout?booleanLogout the session when stopping (optional)
Invalid request or session not ready. Inspect error.details for validation issues, currentStatus, nextSteps or nextStep; link WhatsApp before sending.
application/json- response
success*falsefalseerror*timestamp*stringdate-timecurl -X POST 'https://wp-rapidapi.retentionstack.agency/v1/sessions/stop' \ -H 'Content-Type: application/json' \ -d '{ "name": "me"}'{ "success": true, "data": {}, "timestamp": "2026-11-02T00:00:00.000Z"}Log WhatsApp out of your named session. Link the account again with a QR or pairing code before sending more messages.
BearerAuthAuthorizationBearer <ch_live_... | ak_live_...>Direct WhatsApp Session Token (Authorization: Bearer ch_live_...) or Account API Key (ak_live_...). Generated in your dashboard at https://whatsapp-messaging.retentionstack.agency/start.
Logout from a WhatsApp session
application/json- body
Logout from a WhatsApp session
name*stringSession name to logout
1 <= lengthInvalid request or session not ready. Inspect error.details for validation issues, currentStatus, nextSteps or nextStep; link WhatsApp before sending.
application/json- response
success*falsefalseerror*timestamp*stringdate-timecurl -X POST 'https://wp-rapidapi.retentionstack.agency/v1/sessions/logout' \ -H 'Content-Type: application/json' \ -d '{ "name": "me"}'{ "success": true, "data": {}, "timestamp": "2026-11-02T00:00:00.000Z"}Register an HTTPS callback for your session. events defaults to ["message"]. Optional hmacKey, retries and customHeaders configure delivery. The callback receives event, session and payload fields. The default retry policy is exponential with delaySeconds=2 and attempts=3. Handle duplicate deliveries in your receiver.
BearerAuthAuthorizationBearer <ch_live_... | ak_live_...>Direct WhatsApp Session Token (Authorization: Bearer ch_live_...) or Account API Key (ak_live_...). Generated in your dashboard at https://whatsapp-messaging.retentionstack.agency/start.
session*stringWhatsApp session name (1-100 characters). With a session token (ch_live_...), me targets that token's session; with an account key, use the session name.
1 <= length <= 100Webhook configuration for session events
application/json- body
Webhook configuration for session events
webhookUrl*stringURL to send webhook events
urievents?array<string>Specific events to subscribe to (e.g., message.create, presence.update)
1 <= itemshmacKey?stringOptional HMAC key for webhook signature verification
retries?|Optional retry configuration for webhook delivery
customHeaders?array<>Optional custom headers to include in webhook requests
Invalid request or session not ready. Inspect error.details for validation issues, currentStatus, nextSteps or nextStep; link WhatsApp before sending.
application/json- response
success*falsefalseerror*timestamp*stringdate-timecurl -X POST 'https://wp-rapidapi.retentionstack.agency/v1/sessions/me/webhooks' \ -H 'Content-Type: application/json' \ -d '{ "webhookUrl": "https://your-server.example/webhooks/whatsapp", "events": [ "message", "message.ack", "session.status" ]}'{ "success": true, "data": {}, "timestamp": "2026-11-02T00:00:00.000Z"}Remove a callback by sending the same webhookUrl in the JSON body. A missing registration returns 404. Other callbacks on this session remain registered.
BearerAuthAuthorizationBearer <ch_live_... | ak_live_...>Direct WhatsApp Session Token (Authorization: Bearer ch_live_...) or Account API Key (ak_live_...). Generated in your dashboard at https://whatsapp-messaging.retentionstack.agency/start.
session*stringWhatsApp session name (1-100 characters). With a session token (ch_live_...), me targets that token's session; with an account key, use the session name.
1 <= length <= 100Delete webhook configuration
application/json- body
Delete webhook configuration
webhookUrl*stringWebhook URL to delete
uriInvalid request or session not ready. Inspect error.details for validation issues, currentStatus, nextSteps or nextStep; link WhatsApp before sending.
application/json- response
success*falsefalseerror*timestamp*stringdate-timecurl -X DELETE 'https://wp-rapidapi.retentionstack.agency/v1/sessions/me/webhooks' \ -H 'Content-Type: application/json' \ -d '{ "webhookUrl": "https://your-server.example/webhooks/whatsapp"}'{ "success": true, "data": {}, "timestamp": "2026-11-02T00:00:00.000Z"}