shipmail 0.4.15 → 0.4.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +14 -4
- package/dist/index.cjs +9 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +20 -1
- package/dist/index.d.ts +20 -1
- package/dist/index.js +9 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -454,8 +454,16 @@ const newsletter = await shipmail.newsletters.create({
|
|
|
454
454
|
preview_text: "A quick product update",
|
|
455
455
|
blocks: [
|
|
456
456
|
{ type: "heading", level: 1, text: "July updates" },
|
|
457
|
-
{
|
|
458
|
-
|
|
457
|
+
{
|
|
458
|
+
type: "callout",
|
|
459
|
+
variant: "info",
|
|
460
|
+
title: "Quick note",
|
|
461
|
+
body: "A <strong>short</strong> intro.",
|
|
462
|
+
},
|
|
463
|
+
{
|
|
464
|
+
type: "paragraph",
|
|
465
|
+
body: 'Read the <a href="https://example.com/launch">full announcement</a>.',
|
|
466
|
+
},
|
|
459
467
|
{ type: "image", url: hero.url, alt: "Product screenshot" },
|
|
460
468
|
{ type: "image", url: existingHero.url, alt: "Existing CDN screenshot" },
|
|
461
469
|
{
|
|
@@ -484,8 +492,10 @@ Newsletter test sends and schedules must pass preflight. Guardrail failures thro
|
|
|
484
492
|
`ValidationError` with the failed preflight items in `error.details`.
|
|
485
493
|
Preflight responses include `url_breakdown` so you can see which links, image
|
|
486
494
|
URLs, and video thumbnails contribute to deliverability checks.
|
|
487
|
-
|
|
488
|
-
|
|
495
|
+
Paragraph, quote, callout, list-item, and column bodies accept bare text or
|
|
496
|
+
sanitized inline HTML. Use `<p>` and `<br>` for line breaks. Allowed tags are
|
|
497
|
+
`a`, `b`, `br`, `code`, `em`, `i`, `p`, `s`, `span`, `strong`, and `u`. Use
|
|
498
|
+
`body_html` or `custom_html` for a fully custom email-safe layout.
|
|
489
499
|
Concurrent newsletter updates can throw `ConflictError` (409). Fetch the latest
|
|
490
500
|
newsletter, merge your changes, and retry the update.
|
|
491
501
|
|
package/dist/index.cjs
CHANGED
|
@@ -1180,6 +1180,14 @@ var NewsletterAssets = class extends ApiResource {
|
|
|
1180
1180
|
methodOptions: options
|
|
1181
1181
|
});
|
|
1182
1182
|
}
|
|
1183
|
+
prepareUpload(params, options) {
|
|
1184
|
+
return this.client.request({
|
|
1185
|
+
method: "POST",
|
|
1186
|
+
path: "/newsletter-assets/upload-tokens",
|
|
1187
|
+
body: params,
|
|
1188
|
+
methodOptions: options
|
|
1189
|
+
});
|
|
1190
|
+
}
|
|
1183
1191
|
registerFromUrl(params, options) {
|
|
1184
1192
|
return this.client.request({
|
|
1185
1193
|
method: "POST",
|
|
@@ -1613,7 +1621,7 @@ var Webhooks = class extends ApiResource {
|
|
|
1613
1621
|
};
|
|
1614
1622
|
|
|
1615
1623
|
// src/version.ts
|
|
1616
|
-
var VERSION = "0.4.
|
|
1624
|
+
var VERSION = "0.4.16";
|
|
1617
1625
|
|
|
1618
1626
|
// src/client.ts
|
|
1619
1627
|
var DEFAULT_BASE_URL = "https://shipmail.to/api/v1";
|