push

Embed
Preview of the card
<a href="https://hermeticor.com/docs/ref-push"><img src="https://hermeticor.com/docs/_api/public/orgs/5fcd8b3c-a27c-4688-972f-de710125592f/spaces/caf5dc05-15f7-4e0c-bdb8-ab29ede6211e/pages/01d5381a-8fd9-4459-a219-291e9fa5495a/social-card.svg?v=3e7ae33eec8b" alt="push" width="600" height="315"></a>
POSThttps://hermeticor.com/v1/push/live

Start a live notification for one contact (order tracking, a match score...). Push consent applies to marketing ones; suppression always applies. Needs an idempotencyKey (body) or Idempotency-Key header

Request body

application/json
profileIdstringrequired
kindstringrequired
ios_live_activity | android_ongoing
activityTypestringrequired
attributesobject
= {}
contentStateobject
= {}
alertobject
Show child parameters
titlestringrequired
bodystringrequired
staleAtstring
purposestring
transactional | marketing = transactional
connectionIdstring
idempotencyKeystring
{
  "profileId": "string",
  "kind": "ios_live_activity",
  "activityType": "string",
  "attributes": {},
  "contentState": {},
  "alert": {
    "title": "string",
    "body": "string"
  },
  "staleAt": "2024-01-01T00:00:00Z",
  "purpose": "transactional",
  "connectionId": "string",
  "idempotencyKey": "string"
}

Code samples

cURL
curl -X POST "https://hermeticor.com/v1/push/live" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"profileId":"string","kind":"ios_live_activity","activityType":"string","attributes":{},"contentState":{},"alert":{"title":"string","body":"string"},"staleAt":"2024-01-01T00:00:00Z","purpose":"transactional","connectionId":"string","idempotencyKey":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

201 Default Response
Example
{
  "id": "string",
  "profileId": "string",
  "kind": "ios_live_activity",
  "activityType": "string",
  "attributes": {},
  "contentState": {},
  "status": "active",
  "purpose": "string",
  "updates": 0,
  "hasUpdateToken": true,
  "lastError": "string",
  "staleAt": "string",
  "endedAt": "string",
  "createdAt": "string",
  "updatedAt": "string"
}
Schema
idstringrequired
profileIdstringrequired
kindstringrequired
ios_live_activity | android_ongoing
activityTypestringrequired
attributesobjectrequired
contentStateobjectrequired
statusstringrequired
active | ended | blocked | failed
purposestringrequired
updatesintegerrequired
hasUpdateTokenbooleanrequired
lastErrorstringrequired
staleAtstringrequired
endedAtstringrequired
createdAtstringrequired
updatedAtstringrequired
4XX Default Response
Example
{
  "error": {
    "code": "string",
    "message": "string",
    "details": {}
  }
}
Schema
errorobjectrequired
Show child parameters
codestringrequired
messagestringrequired
detailsobject
5XX Default Response

Same as 4XX · POST /v1/push/live

GEThttps://hermeticor.com/v1/push/live/{id}

One live notification and its status

Parameters

idstringpathrequired

Code samples

cURL
curl -X GET "https://hermeticor.com/v1/push/live/{id}" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response

Same as 201 · POST /v1/push/live

4XX Default Response

Same as 4XX · POST /v1/push/live

5XX Default Response

Same as 4XX · POST /v1/push/live

PATCHhttps://hermeticor.com/v1/push/live/{id}

Update what the live notification shows

Parameters

idstringpathrequired

Request body

application/json
contentStateobjectrequired
alertobject
Show child parameters
titlestringrequired
bodystringrequired
staleAtstring
prioritystring
high | normal = normal
{
  "contentState": {},
  "alert": {
    "title": "string",
    "body": "string"
  },
  "staleAt": "2024-01-01T00:00:00Z",
  "priority": "normal"
}

Code samples

cURL
curl -X PATCH "https://hermeticor.com/v1/push/live/{id}" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"contentState":{},"alert":{"title":"string","body":"string"},"staleAt":"2024-01-01T00:00:00Z","priority":"normal"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response

Same as 201 · POST /v1/push/live

4XX Default Response

Same as 4XX · POST /v1/push/live

5XX Default Response

Same as 4XX · POST /v1/push/live

POSThttps://hermeticor.com/v1/push/live/{id}/end

End the live notification (optionally with a final state and when to dismiss it)

Parameters

idstringpathrequired

Request body

application/json
contentStateobject
alertobject
Show child parameters
titlestringrequired
bodystringrequired
dismissAtstring
{
  "contentState": {},
  "alert": {
    "title": "string",
    "body": "string"
  },
  "dismissAt": "2024-01-01T00:00:00Z"
}

Code samples

cURL
curl -X POST "https://hermeticor.com/v1/push/live/{id}/end" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"contentState":{},"alert":{"title":"string","body":"string"},"dismissAt":"2024-01-01T00:00:00Z"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response

Same as 201 · POST /v1/push/live

4XX Default Response

Same as 4XX · POST /v1/push/live

5XX Default Response

Same as 4XX · POST /v1/push/live

POSThttps://hermeticor.com/client/push-live-tokens

The app reports an ActivityKit push-to-start token or a running activity's update token

Parameters

company_idstringquery

Request body

application/json
kindstringrequired
push_to_start | update
tokenstringrequired
activityTypestring
activityIdstring
environmentstring
sandbox | production = production
appIdstring
profileobjectrequired
Show child parameters
externalIdstring
emailstring
phoneNumberstring
anonymousIdstring
{
  "kind": "push_to_start",
  "token": "string",
  "activityType": "string",
  "activityId": "string",
  "environment": "production",
  "appId": "string",
  "profile": {
    "externalId": "string",
    "email": "string",
    "phoneNumber": "string",
    "anonymousId": "string"
  }
}

Code samples

cURL
curl -X POST "https://hermeticor.com/client/push-live-tokens" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"kind":"push_to_start","token":"string","activityType":"string","activityId":"string","environment":"production","appId":"string","profile":{"externalId":"string","email":"string","phoneNumber":"string","anonymousId":"string"}}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

202 Default Response
Example
{
  "ok": true
}
Schema
okbooleanrequired
true
4XX Default Response

Same as 4XX · POST /v1/push/live

5XX Default Response

Same as 4XX · POST /v1/push/live

Updated