engagement

Embed
Preview of the card
<a href="https://hermeticor.com/docs/ref-engagement"><img src="https://hermeticor.com/docs/_api/public/orgs/5fcd8b3c-a27c-4688-972f-de710125592f/spaces/caf5dc05-15f7-4e0c-bdb8-ab29ede6211e/pages/3918a56f-6a77-482b-ab0a-92946bdb316a/social-card.svg?v=3e7ae33eec8b" alt="engagement" width="600" height="315"></a>
GEThttps://hermeticor.com/v1/newsletter/engagement/posts/{postId}/reactions

Reaction counts for a post

Parameters

postIdstringpathrequired

Code samples

cURL
curl -X GET "https://hermeticor.com/v1/newsletter/engagement/posts/{postId}/reactions" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response
Example
{
  "postId": "string",
  "counts": {},
  "total": 0
}
Schema
postIdstringrequired
countsobjectrequired
totalintegerrequired
4XX Default Response
Example
{
  "error": {
    "code": "string",
    "message": "string",
    "details": {}
  }
}
Schema
errorobjectrequired
Show child parameters
codestringrequired
messagestringrequired
detailsobject
GEThttps://hermeticor.com/v1/newsletter/engagement/posts/{postId}/highlights

Most read sections of a post (from the read-depth beacon)

Parameters

postIdstringpathrequired

Code samples

cURL
curl -X GET "https://hermeticor.com/v1/newsletter/engagement/posts/{postId}/highlights" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response
Example
{
  "postId": "string",
  "sample": 0,
  "sections": [
    {
      "section": "string",
      "readers": 0,
      "share": 0
    }
  ]
}
Schema
postIdstringrequired
sampleintegerrequired
sectionsobject[]required
Show child parameters
sectionstringrequired
readersintegerrequired
sharenumberrequired
GEThttps://hermeticor.com/v1/newsletter/engagement/posts/{postId}/passages

Most highlighted passages of a post (counts; names only beside notes readers chose to share)

Parameters

postIdstringpathrequired

Code samples

cURL
curl -X GET "https://hermeticor.com/v1/newsletter/engagement/posts/{postId}/passages" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response
Example
{
  "postId": "string",
  "passages": [
    {
      "quote": "string",
      "readers": 0,
      "notes": [
        {
          "name": "string",
          "note": "string"
        }
      ]
    }
  ]
}
Schema
postIdstringrequired
passagesobject[]required
Show child parameters
quotestringrequired
readersintegerrequired
notesobject[]required
Show child parameters
namestringrequired
notestringrequired
GEThttps://hermeticor.com/v1/newsletter/engagement/surveys

Polls and surveys

Parameters

kindstringquery
poll | survey
publicationIdstringquery
limitintegerquery
= 50
cursorstringquery

Code samples

cURL
curl -X GET "https://hermeticor.com/v1/newsletter/engagement/surveys" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response
Example
{
  "items": [
    {
      "id": "string",
      "kind": "poll",
      "publicationId": "string",
      "postId": "string",
      "title": "string",
      "description": "string",
      "status": "open",
      "questions": [
        {
          "id": "string",
          "prompt": "string",
          "kind": "single",
          "options": [
            {
              "id": "string",
              "label": "string"
            }
          ],
          "required": true,
          "attributeKey": "string",
          "position": 0
        }
      ],
      "responses": 0,
      "createdAt": "2024-01-01T00:00:00Z",
      "block": {},
      "listId": "string",
      "thankYouText": "string",
      "views": 0,
      "anonymousPath": "string"
    }
  ],
  "nextCursor": "string"
}
Schema
itemsItemsItem204[]required
Show child parameters
idstringrequired
kindstringrequired
poll | survey
publicationIdstringrequired
postIdstringrequired
titlestringrequired
descriptionstringrequired
statusstringrequired
open | closed
questionsQuestionsItem[]required
Show child parameters
idstringrequired
promptstringrequired
kindstringrequired
single | multi | text | rating | email
optionsOptionsItem[]required
requiredbooleanrequired
attributeKeystringrequired
positionintegerrequired
responsesintegerrequired
createdAtstringrequired
blockobjectrequired
listIdstringrequired
thankYouTextstringrequired
viewsintegerrequired
anonymousPathstringrequired
nextCursorstringrequired
POSThttps://hermeticor.com/v1/newsletter/engagement/surveys

Create a poll (one question) or a survey

Request body

application/json
kindstringrequired
poll | survey
publicationIdstring
postIdstring
titlestringrequired
descriptionstring
questionsQuestionsItem2[]required
Show child parameters
idstring
promptstringrequired
kindstringrequired
single | multi | text | rating | email
optionsOptionsItem2[]
requiredboolean
= true
attributeKeystring
listIdstring
thankYouTextstring
anonymousboolean
{
  "kind": "poll",
  "publicationId": "string",
  "postId": "string",
  "title": "string",
  "description": "string",
  "questions": [
    {
      "id": "string",
      "prompt": "string",
      "kind": "single",
      "options": [
        "string"
      ],
      "required": true,
      "attributeKey": "string"
    }
  ],
  "listId": "string",
  "thankYouText": "string",
  "anonymous": true
}

Code samples

cURL
curl -X POST "https://hermeticor.com/v1/newsletter/engagement/surveys" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"kind":"poll","publicationId":"string","postId":"string","title":"string","description":"string","questions":[{"id":"string","prompt":"string","kind":"single","options":["string"],"required":true,"attributeKey":"string"}],"listId":"string","thankYouText":"string","anonymous":true}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

201 Default Response
Example
{
  "id": "string",
  "kind": "poll",
  "publicationId": "string",
  "postId": "string",
  "title": "string",
  "description": "string",
  "status": "open",
  "questions": [
    {
      "id": "string",
      "prompt": "string",
      "kind": "single",
      "options": [
        {
          "id": "string",
          "label": "string"
        }
      ],
      "required": true,
      "attributeKey": "string",
      "position": 0
    }
  ],
  "responses": 0,
  "createdAt": "2024-01-01T00:00:00Z",
  "block": {},
  "listId": "string",
  "thankYouText": "string",
  "views": 0,
  "anonymousPath": "string"
}
Schema
idstringrequired
kindstringrequired
poll | survey
publicationIdstringrequired
postIdstringrequired
titlestringrequired
descriptionstringrequired
statusstringrequired
open | closed
questionsQuestionsItem[]required
Show child parameters
idstringrequired
promptstringrequired
kindstringrequired
single | multi | text | rating | email
optionsOptionsItem[]required
Show child parameters
idstringrequired
labelstringrequired
requiredbooleanrequired
attributeKeystringrequired
positionintegerrequired
responsesintegerrequired
createdAtstringrequired
blockobjectrequired
listIdstringrequired
thankYouTextstringrequired
viewsintegerrequired
anonymousPathstringrequired
GEThttps://hermeticor.com/v1/newsletter/engagement/surveys/{id}

One poll or survey, with the poll block for editors

Parameters

idstringpathrequired

Code samples

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

Responses

DELETEhttps://hermeticor.com/v1/newsletter/engagement/surveys/{id}

Delete a poll or survey and its answers

Parameters

idstringpathrequired

Code samples

cURL
curl -X DELETE "https://hermeticor.com/v1/newsletter/engagement/surveys/{id}" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY"
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response
Example
{
  "ok": true
}
Schema
okbooleanrequired
true

Updated