engagement
PATCH
https://hermeticor.com /v1/newsletter/engagement/surveys/{id} Rename, describe, open or close, link a list, set the thank-you, turn the anonymous link on or off, edit questions
Parameters
idstringpathrequiredRequest body
application/json
titlestringdescriptionstringstatusstringlistIdstringthankYouTextstringanonymousbooleanquestionsQuestionsItem2[]Show child parameters
idstringpromptstringrequiredkindstringrequiredoptionsOptionsItem2[]requiredbooleanattributeKeystring{
"title": "string",
"description": "string",
"status": "open",
"listId": "string",
"thankYouText": "string",
"anonymous": true,
"questions": [
{
"id": "string",
"prompt": "string",
"kind": "single",
"options": [
"string"
],
"required": true,
"attributeKey": "string"
}
]
}Code samples
cURL
curl -X PATCH "https://hermeticor.com/v1/newsletter/engagement/surveys/{id}" \
-H "Authorization: Bearer $HERMETICOR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"title":"string","description":"string","status":"open","listId":"string","thankYouText":"string","anonymous":true,"questions":[{"id":"string","prompt":"string","kind":"single","options":["string"],"required":true,"attributeKey":"string"}]}'TypeScript
Python
Go
PHP
Ruby
Java
Responses
200 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
idstringrequiredkindstringrequiredpublicationIdstringrequiredpostIdstringrequiredtitlestringrequireddescriptionstringrequiredstatusstringrequiredquestionsQuestionsItem[]requiredShow child parameters
idstringrequiredpromptstringrequiredkindstringrequiredoptionsOptionsItem[]requiredShow child parameters
idstringrequiredlabelstringrequiredrequiredbooleanrequiredattributeKeystringrequiredpositionintegerrequiredresponsesintegerrequiredcreatedAtstringrequiredblockobjectrequiredlistIdstringrequiredthankYouTextstringrequiredviewsintegerrequiredanonymousPathstringrequired4XX Default Response
Example
{
"error": {
"code": "string",
"message": "string",
"details": {}
}
}Schema
errorobjectrequiredShow child parameters
codestringrequiredmessagestringrequireddetailsobjectGET
https://hermeticor.com /v1/newsletter/engagement/surveys/{id}/results Results per question
Parameters
idstringpathrequiredCode samples
cURL
curl -X GET "https://hermeticor.com/v1/newsletter/engagement/surveys/{id}/results" \
-H "Authorization: Bearer $HERMETICOR_API_KEY"TypeScript
Python
Go
PHP
Ruby
Java
Responses
200 Default Response
Example
{
"surveyId": "string",
"responses": 0,
"questions": [
{
"questionId": "string",
"prompt": "string",
"kind": "single",
"total": 0,
"options": [
{
"id": "string",
"label": "string",
"votes": 0
}
],
"average": 0,
"texts": [
"string"
]
}
]
}Schema
surveyIdstringrequiredresponsesintegerrequiredquestionsobject[]requiredShow child parameters
questionIdstringrequiredpromptstringrequiredkindstringrequiredtotalintegerrequiredoptionsOptionsItem3[]requiredShow child parameters
idstringrequiredlabelstringrequiredvotesintegerrequiredaveragenumberrequiredtextsstring[]requiredGET
https://hermeticor.com /v1/newsletter/engagement/surveys/{id}/responses Individual responses (respondent, time, answers), newest first
Parameters
limitintegerquerycursorstringqueryidstringpathrequiredCode samples
cURL
curl -X GET "https://hermeticor.com/v1/newsletter/engagement/surveys/{id}/responses" \
-H "Authorization: Bearer $HERMETICOR_API_KEY"TypeScript
Python
Go
PHP
Ruby
Java
Responses
200 Default Response
Example
{
"items": [
{
"respondent": "string",
"profileId": "string",
"contactProfileId": "string",
"anonymous": true,
"submittedAt": "2024-01-01T00:00:00Z",
"answers": [
{
"questionId": "string",
"optionIds": [
"string"
],
"value": "string"
}
]
}
],
"nextCursor": "string"
}Schema
itemsItemsItem205[]requiredShow child parameters
respondentstringrequiredprofileIdstringrequiredcontactProfileIdstringrequiredanonymousbooleanrequiredsubmittedAtstringrequiredanswersAnswersItem[]requiredShow child parameters
questionIdstringrequiredoptionIdsstring[]requiredvaluestringrequirednextCursorstringrequiredGET
https://hermeticor.com /v1/newsletter/engagement/surveys/{id}/responses/{respondent} One respondent's answers
Parameters
idstringpathrequiredrespondentstringpathrequiredCode samples
cURL
curl -X GET "https://hermeticor.com/v1/newsletter/engagement/surveys/{id}/responses/{respondent}" \
-H "Authorization: Bearer $HERMETICOR_API_KEY"TypeScript
Python
Go
PHP
Ruby
Java
Responses
200 Default Response
Example
{
"respondent": "string",
"profileId": "string",
"contactProfileId": "string",
"anonymous": true,
"submittedAt": "2024-01-01T00:00:00Z",
"answers": [
{
"questionId": "string",
"optionIds": [
"string"
],
"value": "string"
}
]
}Schema
respondentstringrequiredprofileIdstringrequiredcontactProfileIdstringrequiredanonymousbooleanrequiredsubmittedAtstringrequiredanswersAnswersItem[]requiredShow child parameters
questionIdstringrequiredoptionIdsstring[]requiredvaluestringrequiredPOST
https://hermeticor.com /v1/newsletter/engagement/surveys/{id}/duplicate Copy a survey (questions and settings, no answers)
Parameters
idstringpathrequiredCode samples
cURL
curl -X POST "https://hermeticor.com/v1/newsletter/engagement/surveys/{id}/duplicate" \
-H "Authorization: Bearer $HERMETICOR_API_KEY"TypeScript
Python
Go
PHP
Ruby
Java
Responses
POST
https://hermeticor.com /v1/newsletter/engagement/surveys/{id}/campaign Draft an email campaign to the survey's list, with a new template that links each recipient to the survey (signed per reader)
Parameters
idstringpathrequiredRequest body
application/json
namestring{
"name": "string"
}Code samples
cURL
curl -X POST "https://hermeticor.com/v1/newsletter/engagement/surveys/{id}/campaign" \
-H "Authorization: Bearer $HERMETICOR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"name":"string"}'TypeScript
Python
Go
PHP
Ruby
Java
Responses
201 Default Response
Example
{
"campaignId": "string"
}Schema
campaignIdstringrequiredGET
https://hermeticor.com /v1/newsletter/engagement/replies Replies to the publication's post emails (reply-to-author inbox)
Parameters
publicationIdstringqueryrequiredunreadbooleanquerylimitintegerquerycursorstringqueryCode samples
cURL
curl -X GET "https://hermeticor.com/v1/newsletter/engagement/replies?publicationId=<publicationId>" \
-H "Authorization: Bearer $HERMETICOR_API_KEY"TypeScript
Python
Go
PHP
Ruby
Java
Responses
200 Default Response
Example
{
"items": [
{
"id": "string",
"fromAddr": "string",
"subject": "string",
"text": "string",
"receivedAt": "2024-01-01T00:00:00Z",
"profileId": "string",
"read": true,
"archived": true,
"campaignId": "string"
}
],
"nextCursor": "string"
}Schema
itemsobject[]requiredShow child parameters
idstringrequiredfromAddrstringrequiredsubjectstringrequiredtextstringrequiredreceivedAtstringrequiredprofileIdstringrequiredreadbooleanrequiredarchivedbooleanrequiredcampaignIdstringrequirednextCursorstringrequiredUpdated