newsletter

Embed
Preview of the card
<a href="https://hermeticor.com/docs/ref-newsletter"><img src="https://hermeticor.com/docs/_api/public/orgs/5fcd8b3c-a27c-4688-972f-de710125592f/spaces/caf5dc05-15f7-4e0c-bdb8-ab29ede6211e/pages/6ddb6b60-e4af-4ab8-9e30-d59475817fd4/social-card.svg?v=3e7ae33eec8b" alt="newsletter" width="600" height="315"></a>
POSThttps://hermeticor.com/v1/newsletter/posts

Request body

application/json
publicationIdstringrequired
titlestringrequired
subtitlestring
slugstring
coverUrlstring
coverAltstring
markdownstring
excerptstring
authorIdsstring[]
= []
sectionIdsstring[]
= []
tagsstring[]
= []
audienceobject
= {"kind":"everyone"}
Show child parameters
kindstringrequired
everyone | free | paid | tiers
tierIdsstring[]
deliverystring
web | email | both = both
featuredboolean
= false
seoTitlestring
seoDescriptionstring
seoImageUrlstring
noindexboolean
= false
{
  "publicationId": "string",
  "title": "string",
  "subtitle": "string",
  "slug": "string",
  "coverUrl": "string",
  "coverAlt": "string",
  "markdown": "",
  "excerpt": "string",
  "authorIds": [],
  "sectionIds": [],
  "tags": [],
  "audience": {
    "kind": "everyone"
  },
  "delivery": "both",
  "featured": false,
  "seoTitle": "string",
  "seoDescription": "string",
  "seoImageUrl": "string",
  "noindex": false
}

Code samples

cURL
curl -X POST "https://hermeticor.com/v1/newsletter/posts" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"publicationId":"string","title":"string","subtitle":"string","slug":"string","coverUrl":"string","coverAlt":"string","markdown":"","excerpt":"string","authorIds":[],"sectionIds":[],"tags":[],"audience":{"kind":"everyone"},"delivery":"both","featured":false,"seoTitle":"string","seoDescription":"string","seoImageUrl":"string","noindex":false}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

201 Default Response
Example
{
  "id": "string",
  "publicationId": "string",
  "title": "string",
  "subtitle": "string",
  "slug": "string",
  "coverUrl": "string",
  "coverAlt": "string",
  "markdown": "string",
  "excerpt": "string",
  "authorIds": [
    "string"
  ],
  "sectionIds": [
    "string"
  ],
  "tags": [
    "string"
  ],
  "audience": {
    "kind": "everyone",
    "tierIds": [
      "string"
    ]
  },
  "delivery": "web",
  "featured": true,
  "seoTitle": "string",
  "seoDescription": "string",
  "seoImageUrl": "string",
  "noindex": true,
  "status": "draft",
  "publishedAt": "2024-01-01T00:00:00Z",
  "scheduledAt": "2024-01-01T00:00:00Z",
  "campaignId": "string",
  "paidCampaignId": "string",
  "emailError": "string",
  "wordCount": 0,
  "readMinutes": 0,
  "url": "string",
  "createdAt": "2024-01-01T00:00:00Z",
  "updatedAt": "2024-01-01T00:00:00Z"
}
Schema
idstringrequired
publicationIdstringrequired
titlestringrequired
subtitlestringrequired
slugstringrequired
coverUrlstringrequired
coverAltstringrequired
markdownstringrequired
excerptstringrequired
authorIdsstring[]required
sectionIdsstring[]required
tagsstring[]required
audienceobjectrequired
Show child parameters
kindstringrequired
everyone | free | paid | tiers
tierIdsstring[]
deliverystringrequired
web | email | both
featuredbooleanrequired
seoTitlestringrequired
seoDescriptionstringrequired
seoImageUrlstringrequired
noindexbooleanrequired
statusstringrequired
draft | scheduled | published | archived
publishedAtstringrequired
scheduledAtstringrequired
campaignIdstringrequired
paidCampaignIdstringrequired
emailErrorstringrequired
wordCountintegerrequired
readMinutesintegerrequired
urlstringrequired
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/newsletter/posts

GEThttps://hermeticor.com/v1/newsletter/posts/{id}

Parameters

idstringpathrequired

Code samples

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

Responses

200 Default Response

Same as 201 · POST /v1/newsletter/posts

4XX Default Response

Same as 4XX · POST /v1/newsletter/posts

5XX Default Response

Same as 4XX · POST /v1/newsletter/posts

DELETEhttps://hermeticor.com/v1/newsletter/posts/{id}

Parameters

idstringpathrequired

Code samples

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

Responses

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

Same as 4XX · POST /v1/newsletter/posts

5XX Default Response

Same as 4XX · POST /v1/newsletter/posts

PATCHhttps://hermeticor.com/v1/newsletter/posts/{id}

Parameters

idstringpathrequired

Request body

application/json
titlestring
subtitlestring
slugstring
coverUrlstring
coverAltstring
markdownstring
excerptstring
authorIdsstring[]
sectionIdsstring[]
tagsstring[]
audienceobject
Show child parameters
kindstringrequired
everyone | free | paid | tiers
tierIdsstring[]
deliverystring
web | email | both
featuredboolean
seoTitlestring
seoDescriptionstring
seoImageUrlstring
noindexboolean
notestring
{
  "title": "string",
  "subtitle": "string",
  "slug": "string",
  "coverUrl": "string",
  "coverAlt": "string",
  "markdown": "string",
  "excerpt": "string",
  "authorIds": [
    "string"
  ],
  "sectionIds": [
    "string"
  ],
  "tags": [
    "string"
  ],
  "audience": {
    "kind": "everyone",
    "tierIds": [
      "string"
    ]
  },
  "delivery": "web",
  "featured": true,
  "seoTitle": "string",
  "seoDescription": "string",
  "seoImageUrl": "string",
  "noindex": true,
  "note": "string"
}

Code samples

cURL
curl -X PATCH "https://hermeticor.com/v1/newsletter/posts/{id}" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"title":"string","subtitle":"string","slug":"string","coverUrl":"string","coverAlt":"string","markdown":"string","excerpt":"string","authorIds":["string"],"sectionIds":["string"],"tags":["string"],"audience":{"kind":"everyone","tierIds":["string"]},"delivery":"web","featured":true,"seoTitle":"string","seoDescription":"string","seoImageUrl":"string","noindex":true,"note":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response

Same as 201 · POST /v1/newsletter/posts

4XX Default Response

Same as 4XX · POST /v1/newsletter/posts

5XX Default Response

Same as 4XX · POST /v1/newsletter/posts

POSThttps://hermeticor.com/v1/newsletter/posts/{id}/duplicate

Parameters

idstringpathrequired

Code samples

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

Responses

201 Default Response

Same as 201 · POST /v1/newsletter/posts

4XX Default Response

Same as 4XX · POST /v1/newsletter/posts

5XX Default Response

Same as 4XX · POST /v1/newsletter/posts

POSThttps://hermeticor.com/v1/newsletter/posts/{id}/publish

Publish on the web; when the post delivers by email it goes to the campaign pipeline (never sent directly)

Parameters

idstringpathrequired

Request body

application/json
subjectstring
subjectBstring
previewTextstring
listIdstring
segmentIdstring
{
  "subject": "string",
  "subjectB": "string",
  "previewText": "string",
  "listId": "string",
  "segmentId": "string"
}

Code samples

cURL
curl -X POST "https://hermeticor.com/v1/newsletter/posts/{id}/publish" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"subject":"string","subjectB":"string","previewText":"string","listId":"string","segmentId":"string"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response

Same as 201 · POST /v1/newsletter/posts

4XX Default Response

Same as 4XX · POST /v1/newsletter/posts

5XX Default Response

Same as 4XX · POST /v1/newsletter/posts

POSThttps://hermeticor.com/v1/newsletter/posts/{id}/schedule

Parameters

idstringpathrequired

Request body

application/json
atstringrequired
{
  "at": "2024-01-01T00:00:00Z"
}

Code samples

cURL
curl -X POST "https://hermeticor.com/v1/newsletter/posts/{id}/schedule" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"at":"2024-01-01T00:00:00Z"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response

Same as 201 · POST /v1/newsletter/posts

4XX Default Response

Same as 4XX · POST /v1/newsletter/posts

5XX Default Response

Same as 4XX · POST /v1/newsletter/posts

DELETEhttps://hermeticor.com/v1/newsletter/posts/{id}/schedule

Parameters

idstringpathrequired

Code samples

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

Responses

200 Default Response

Same as 201 · POST /v1/newsletter/posts

4XX Default Response

Same as 4XX · POST /v1/newsletter/posts

5XX Default Response

Same as 4XX · POST /v1/newsletter/posts

POSThttps://hermeticor.com/v1/newsletter/posts/{id}/unpublish

Take a post off the web: back to draft, or archived (hidden from lists, link still works)

Parameters

idstringpathrequired

Request body

application/json
tostring
draft | archived = draft
{
  "to": "draft"
}

Code samples

cURL
curl -X POST "https://hermeticor.com/v1/newsletter/posts/{id}/unpublish" \
  -H "Authorization: Bearer $HERMETICOR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"to":"draft"}'
TypeScript
Python
Go
PHP
Ruby
Java

Responses

200 Default Response

Same as 201 · POST /v1/newsletter/posts

4XX Default Response

Same as 4XX · POST /v1/newsletter/posts

5XX Default Response

Same as 4XX · POST /v1/newsletter/posts

Updated