Skip to content
Shortcut: /, ⌘K or Ctrl+K

Presence

View as Markdown

Get presence

GET/messaging/{session}/presenceMessaging APILinked Device API
Base URL
https://api.polymorfa.com
Required permission
presence:read

Path parameters

  • sessionstringrequired

    Identifier of the connected Polymorfa session.

Responses

  • 200Presence info
    • successbooleanrequired

      Whether the request succeeded.

      Allowed valuestrue
    • dataobjectrequired

      Structured data carried by this object.

      Show 5 child fields
    Show 3 headers
  • 400Bad request — request body or params failed validation
  • 401Missing or invalid authentication token
  • 403Authenticated but not permitted (missing scope or rule violation)
  • 404Resource not found
  • 500Internal server error
GET /messaging/{session}/presencecURL
Not available with the Test key. Use a team key or project token.
curl "https://api.polymorfa.com/messaging/<session>/presence" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Polymorfa-Version: 2026-09-22"
Response
{
  "success": true,
  "data": {
    "authoritative": false
  }
}

Get chat presence

GET/messaging/{session}/presence/{conversation}Messaging APILinked Device API
Base URL
https://api.polymorfa.com
Required permission
presence:read

Path parameters

  • sessionstringrequired

    Identifier of the connected Polymorfa session.

  • conversationstringrequired

    Public conversation identifier or E.164 phone number.

Responses

  • 200Chat presence
    • successbooleanrequired

      Whether the request succeeded.

      Allowed valuestrue
    • dataobjectrequired

      Structured data carried by this object.

      Show 12 child fields
    Show 3 headers
  • 400Bad request — request body or params failed validation
  • 401Missing or invalid authentication token
  • 403Authenticated but not permitted (missing scope or rule violation)
  • 404Resource not found
  • 500Internal server error
GET /messaging/{session}/presence/{conversation}cURL
Not available with the Test key. Use a team key or project token.
curl "https://api.polymorfa.com/messaging/<session>/presence/<conversation>" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Polymorfa-Version: 2026-09-22"
Response
{
  "success": true,
  "data": {
    "policy": "off",
    "status": "unknown",
    "stale": true,
    "typingPolicy": "off",
    "typingStatus": "unknown"
  }
}

Get project observation policy

GET/messaging/projects/{projectId}/observation-policyMessaging API
Base URL
https://api.polymorfa.com
Required permission
presence:read

Path parameters

  • projectIdstring (uuid)required

    Identifier of the Polymorfa project that owns this resource.

Responses

  • 200Project observation ceiling
    • successbooleanrequired

      Whether the request succeeded.

      Allowed valuestrue
    • dataobjectrequired

      Structured data carried by this object.

      Show 5 child fields
    Show 3 headers
  • 400Bad request — request body or params failed validation
  • 401Missing or invalid authentication token
  • 403Authenticated but not permitted (missing scope or rule violation)
  • 404Resource not found
  • 500Internal server error
GET /messaging/projects/{projectId}/observation-policycURL
Not available with the Test key. Use a team key or project token.
curl "https://api.polymorfa.com/messaging/projects/<projectId>/observation-policy" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Polymorfa-Version: 2026-09-22"
Response
{
  "success": true,
  "data": {
    "projectId": "00000000-0000-4000-8000-000000000000",
    "presenceMode": "off",
    "typingMode": "off",
    "labelMode": "off",
    "quickReplyMode": "off"
  }
}

Get session observation policy

GET/messaging/{session}/observation-policyMessaging APILinked Device API
Base URL
https://api.polymorfa.com
Required permission
presence:read

Path parameters

  • sessionstringrequiredmin length1

    Identifier of the connected Polymorfa session.

Responses

  • 200Effective session observation policy
    • successbooleanrequired

      Whether the request succeeded.

      Allowed valuestrue
    • dataobjectrequired

      Structured data carried by this object.

      Show 5 child fields
    Show 3 headers
  • 400Bad request — request body or params failed validation
  • 401Missing or invalid authentication token
  • 403Authenticated but not permitted (missing scope or rule violation)
  • 404Resource not found
  • 500Internal server error
GET /messaging/{session}/observation-policycURL
Not available with the Test key. Use a team key or project token.
curl "https://api.polymorfa.com/messaging/<session>/observation-policy" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Polymorfa-Version: 2026-09-22"
Response
{
  "success": true,
  "data": {
    "sessionName": "string",
    "projectId": "00000000-0000-4000-8000-000000000000",
    "project": {
      "presenceMode": "off",
      "typingMode": "off",
      "labelMode": "off",
      "quickReplyMode": "off"
    },
    "override": {
      "presenceMode": "inherit",
      "typingMode": "inherit",
      "labelMode": "inherit",
      "quickReplyMode": "inherit"
    },
    "effective": {
      "presenceMode": "off",
      "typingMode": "off",
      "labelMode": "off",
      "quickReplyMode": "off"
    }
  }
}

Set presence

POST/messaging/{session}/presenceMessaging APILinked Device API
Base URL
https://api.polymorfa.com
Required permission
presence:write

Path parameters

  • sessionstringrequired

    Identifier of the connected Polymorfa session.

Body

  • presencestringrequired

    Specifies presence for this native set presence request.

    Allowed valuesavailableunavailable

Responses

  • 200Presence updated
    • successbooleanrequired

      Whether the request succeeded.

    • messagestring

      Human-readable message associated with this result.

    Show 3 headers
  • 202Accepted for asynchronous processing in response to `Prefer: respond-async`; the result is not included
  • 400Bad request — request body or params failed validation
  • 401Missing or invalid authentication token
  • 403Authenticated but not permitted (missing scope or rule violation)
  • 404Resource not found
  • 500Internal server error
POST /messaging/{session}/presencecURL
Not available with the Test key. Use a team key or project token.
curl -X POST "https://api.polymorfa.com/messaging/<session>/presence" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Polymorfa-Version: 2026-09-22" \
  -H "Content-Type: application/json" \
  -d '{
  "presence": "available"
}'
Response
{
  "success": true
}

Subscribe presence

POST/messaging/{session}/presence/{conversation}/subscribeMessaging APILinked Device API
Base URL
https://api.polymorfa.com
Required permission
presence:observe

Path parameters

  • sessionstringrequired

    Identifier of the connected Polymorfa session.

  • conversationstringrequired

    Public conversation identifier or E.164 phone number.

Responses

  • 200Subscribed
    • successbooleanrequired

      Whether the request succeeded.

      Allowed valuestrue
    • dataobjectrequired

      Structured data carried by this object.

      Show 2 child fields
    Show 3 headers
  • 202Accepted for asynchronous processing in response to `Prefer: respond-async`; the result is not included
  • 400Bad request — request body or params failed validation
  • 401Missing or invalid authentication token
  • 403Authenticated but not permitted (missing scope or rule violation)
  • 404Resource not found
  • 429Observation limit exceeded, or the session is inside the suspension window that follows
  • 500Internal server error
POST /messaging/{session}/presence/{conversation}/subscribecURL
Not available with the Test key. Use a team key or project token.
curl -X POST "https://api.polymorfa.com/messaging/<session>/presence/<conversation>/subscribe" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Polymorfa-Version: 2026-09-22"
Response
{
  "success": true,
  "data": {
    "status": "SUBSCRIBED",
    "expiresAt": "2026-09-22T12:00:00Z"
  }
}