@postpeer/node 0.4.0 → 0.6.0
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/CHANGELOG.md +35 -0
- package/client.d.mts +3 -3
- package/client.d.mts.map +1 -1
- package/client.d.ts +3 -3
- package/client.d.ts.map +1 -1
- package/client.js +14 -3
- package/client.js.map +1 -1
- package/client.mjs +14 -3
- package/client.mjs.map +1 -1
- package/internal/types.d.mts +6 -6
- package/internal/types.d.mts.map +1 -1
- package/internal/types.d.ts +6 -6
- package/internal/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/resources/connect/connect.d.mts +3 -3
- package/resources/connect/connect.d.mts.map +1 -1
- package/resources/connect/connect.d.ts +3 -3
- package/resources/connect/connect.d.ts.map +1 -1
- package/resources/connect/connect.js.map +1 -1
- package/resources/connect/connect.mjs +1 -1
- package/resources/connect/connect.mjs.map +1 -1
- package/resources/connect/index.d.mts +1 -1
- package/resources/connect/index.d.mts.map +1 -1
- package/resources/connect/index.d.ts +1 -1
- package/resources/connect/index.d.ts.map +1 -1
- package/resources/connect/index.js.map +1 -1
- package/resources/connect/index.mjs.map +1 -1
- package/resources/connect/integrations.d.mts +21 -4
- package/resources/connect/integrations.d.mts.map +1 -1
- package/resources/connect/integrations.d.ts +21 -4
- package/resources/connect/integrations.d.ts.map +1 -1
- package/resources/connect/integrations.js +3 -3
- package/resources/connect/integrations.js.map +1 -1
- package/resources/connect/integrations.mjs +3 -3
- package/resources/connect/integrations.mjs.map +1 -1
- package/resources/index.d.mts +1 -1
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +1 -1
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/platforms.d.mts +1 -1
- package/resources/platforms.d.mts.map +1 -1
- package/resources/platforms.d.ts +1 -1
- package/resources/platforms.d.ts.map +1 -1
- package/resources/posts/index.d.mts +1 -1
- package/resources/posts/index.d.mts.map +1 -1
- package/resources/posts/index.d.ts +1 -1
- package/resources/posts/index.d.ts.map +1 -1
- package/resources/posts/index.js.map +1 -1
- package/resources/posts/index.mjs.map +1 -1
- package/resources/posts/posts.d.mts +106 -264
- package/resources/posts/posts.d.mts.map +1 -1
- package/resources/posts/posts.d.ts +106 -264
- package/resources/posts/posts.d.ts.map +1 -1
- package/resources/posts/posts.js.map +1 -1
- package/resources/posts/posts.mjs.map +1 -1
- package/resources/posts/scheduled.d.mts +2 -8
- package/resources/posts/scheduled.d.mts.map +1 -1
- package/resources/posts/scheduled.d.ts +2 -8
- package/resources/posts/scheduled.d.ts.map +1 -1
- package/src/client.ts +15 -5
- package/src/internal/types.ts +6 -8
- package/src/resources/connect/connect.ts +8 -2
- package/src/resources/connect/index.ts +1 -0
- package/src/resources/connect/integrations.ts +31 -4
- package/src/resources/index.ts +0 -1
- package/src/resources/platforms.ts +1 -1
- package/src/resources/posts/index.ts +0 -1
- package/src/resources/posts/posts.ts +146 -329
- package/src/resources/posts/scheduled.ts +2 -8
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
3
|
import { APIResource } from '../../core/resource';
|
|
4
|
-
import * as PostsAPI from './posts';
|
|
5
4
|
import * as ScheduledAPI from './scheduled';
|
|
6
5
|
import {
|
|
7
6
|
Scheduled,
|
|
@@ -76,67 +75,6 @@ export class Posts extends APIResource {
|
|
|
76
75
|
}
|
|
77
76
|
}
|
|
78
77
|
|
|
79
|
-
export interface PostSummary {
|
|
80
|
-
content: string;
|
|
81
|
-
|
|
82
|
-
createdAt: string;
|
|
83
|
-
|
|
84
|
-
crosspostingEnabled: boolean;
|
|
85
|
-
|
|
86
|
-
mediaItems: Array<PostSummary.MediaItem>;
|
|
87
|
-
|
|
88
|
-
platforms: Array<PostSummary.Platform>;
|
|
89
|
-
|
|
90
|
-
/**
|
|
91
|
-
* MongoDB ObjectId of the Post document
|
|
92
|
-
*/
|
|
93
|
-
postId: string;
|
|
94
|
-
|
|
95
|
-
rawRequestBody: { [key: string]: unknown };
|
|
96
|
-
|
|
97
|
-
/**
|
|
98
|
-
* ISO 8601 scheduled datetime
|
|
99
|
-
*/
|
|
100
|
-
scheduledFor: string | null;
|
|
101
|
-
|
|
102
|
-
status: Status;
|
|
103
|
-
|
|
104
|
-
timezone: string;
|
|
105
|
-
|
|
106
|
-
updatedAt: string;
|
|
107
|
-
}
|
|
108
|
-
|
|
109
|
-
export namespace PostSummary {
|
|
110
|
-
export interface MediaItem {
|
|
111
|
-
filename: string;
|
|
112
|
-
|
|
113
|
-
mimeType: string;
|
|
114
|
-
|
|
115
|
-
size: number;
|
|
116
|
-
|
|
117
|
-
type: 'image' | 'video' | 'gif';
|
|
118
|
-
|
|
119
|
-
url: string;
|
|
120
|
-
}
|
|
121
|
-
|
|
122
|
-
export interface Platform {
|
|
123
|
-
errorMessage: string | null;
|
|
124
|
-
|
|
125
|
-
platform: 'twitter' | 'instagram' | 'youtube' | 'tiktok' | 'pinterest' | 'linkedin';
|
|
126
|
-
|
|
127
|
-
platformPostId: string | null;
|
|
128
|
-
|
|
129
|
-
/**
|
|
130
|
-
* Direct URL to the published post
|
|
131
|
-
*/
|
|
132
|
-
platformPostUrl: string | null;
|
|
133
|
-
|
|
134
|
-
publishedAt: string | null;
|
|
135
|
-
|
|
136
|
-
status: PostsAPI.Status;
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
|
|
140
78
|
export type Status = 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
|
|
141
79
|
|
|
142
80
|
export interface PostCreateResponse {
|
|
@@ -147,7 +85,7 @@ export interface PostCreateResponse {
|
|
|
147
85
|
*/
|
|
148
86
|
postId: string;
|
|
149
87
|
|
|
150
|
-
status:
|
|
88
|
+
status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
|
|
151
89
|
|
|
152
90
|
/**
|
|
153
91
|
* false only when every platform failed
|
|
@@ -162,7 +100,7 @@ export interface PostCreateResponse {
|
|
|
162
100
|
|
|
163
101
|
export namespace PostCreateResponse {
|
|
164
102
|
export interface Platform {
|
|
165
|
-
platform: 'twitter' | 'instagram' | 'youtube' | 'tiktok' | 'pinterest' | 'linkedin';
|
|
103
|
+
platform: 'twitter' | 'instagram' | 'youtube' | 'tiktok' | 'pinterest' | 'linkedin' | 'bluesky';
|
|
166
104
|
|
|
167
105
|
success: boolean;
|
|
168
106
|
|
|
@@ -175,330 +113,213 @@ export namespace PostCreateResponse {
|
|
|
175
113
|
* Direct URL to the published post
|
|
176
114
|
*/
|
|
177
115
|
platformPostUrl?: string;
|
|
116
|
+
|
|
117
|
+
/**
|
|
118
|
+
* Warning message when the post published but a non-critical follow-up action
|
|
119
|
+
* failed
|
|
120
|
+
*/
|
|
121
|
+
warningMessage?: string;
|
|
178
122
|
}
|
|
179
123
|
}
|
|
180
124
|
|
|
181
125
|
export interface PostRetrieveResponse {
|
|
182
|
-
post:
|
|
126
|
+
post: PostRetrieveResponse.Post;
|
|
183
127
|
|
|
184
128
|
success: boolean;
|
|
185
129
|
}
|
|
186
130
|
|
|
187
|
-
export
|
|
188
|
-
|
|
131
|
+
export namespace PostRetrieveResponse {
|
|
132
|
+
export interface Post {
|
|
133
|
+
content: string;
|
|
189
134
|
|
|
190
|
-
|
|
135
|
+
createdAt: string;
|
|
191
136
|
|
|
192
|
-
|
|
193
|
-
* Total matched posts across all pages
|
|
194
|
-
*/
|
|
195
|
-
total: number;
|
|
196
|
-
}
|
|
137
|
+
crosspostingEnabled: boolean;
|
|
197
138
|
|
|
198
|
-
|
|
199
|
-
success: boolean;
|
|
200
|
-
}
|
|
139
|
+
mediaItems: Array<Post.MediaItem>;
|
|
201
140
|
|
|
202
|
-
|
|
203
|
-
/**
|
|
204
|
-
* Post text body
|
|
205
|
-
*/
|
|
206
|
-
content: string;
|
|
141
|
+
platforms: Array<Post.Platform>;
|
|
207
142
|
|
|
208
|
-
/**
|
|
209
|
-
* Target platform accounts to publish to
|
|
210
|
-
*/
|
|
211
|
-
platforms: Array<PostCreateParams.Platform>;
|
|
212
|
-
|
|
213
|
-
/**
|
|
214
|
-
* Media attachments (images, videos, GIFs)
|
|
215
|
-
*/
|
|
216
|
-
mediaItems?: Array<PostCreateParams.MediaItem>;
|
|
217
|
-
|
|
218
|
-
/**
|
|
219
|
-
* Publish immediately. Required when scheduledFor is omitted.
|
|
220
|
-
*/
|
|
221
|
-
publishNow?: boolean;
|
|
222
|
-
|
|
223
|
-
/**
|
|
224
|
-
* ISO 8601 datetime to schedule the post for future publishing
|
|
225
|
-
*/
|
|
226
|
-
scheduledFor?: string;
|
|
227
|
-
|
|
228
|
-
/**
|
|
229
|
-
* IANA timezone for the scheduled time (e.g. America/New_York). Defaults to UTC.
|
|
230
|
-
*/
|
|
231
|
-
timezone?: string;
|
|
232
|
-
}
|
|
233
|
-
|
|
234
|
-
export namespace PostCreateParams {
|
|
235
|
-
export interface Platform {
|
|
236
143
|
/**
|
|
237
|
-
*
|
|
144
|
+
* MongoDB ObjectId of the Post document
|
|
238
145
|
*/
|
|
239
|
-
|
|
146
|
+
postId: string;
|
|
240
147
|
|
|
241
|
-
|
|
148
|
+
rawRequestBody: { [key: string]: unknown };
|
|
242
149
|
|
|
243
150
|
/**
|
|
244
|
-
*
|
|
245
|
-
* TikTokConfigurations, PinterestConfigurations, or LinkedInConfigurations
|
|
246
|
-
* depending on the target platform.
|
|
151
|
+
* ISO 8601 scheduled datetime
|
|
247
152
|
*/
|
|
248
|
-
|
|
249
|
-
| Platform.TwitterConfigurations
|
|
250
|
-
| Platform.YouTubeConfigurations
|
|
251
|
-
| Platform.TikTokConfigurations
|
|
252
|
-
| Platform.PinterestConfigurations
|
|
253
|
-
| Platform.LinkedInConfigurations;
|
|
254
|
-
}
|
|
153
|
+
scheduledFor: string | null;
|
|
255
154
|
|
|
256
|
-
|
|
257
|
-
/**
|
|
258
|
-
* Pass this object in platformSpecificData when posting to Twitter/X, including
|
|
259
|
-
* Community post options.
|
|
260
|
-
*/
|
|
261
|
-
export interface TwitterConfigurations {
|
|
262
|
-
/**
|
|
263
|
-
* Community ID to publish this post into.
|
|
264
|
-
*/
|
|
265
|
-
communityId?: string;
|
|
155
|
+
status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
|
|
266
156
|
|
|
267
|
-
|
|
268
|
-
* Cannot be combined with media or threadItems.
|
|
269
|
-
*/
|
|
270
|
-
poll?: TwitterConfigurations.Poll;
|
|
157
|
+
timezone: string;
|
|
271
158
|
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
*/
|
|
275
|
-
replySettings?: 'following' | 'mentionedUsers' | 'subscribers' | 'verified';
|
|
159
|
+
updatedAt: string;
|
|
160
|
+
}
|
|
276
161
|
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
replyToTweetId?: string;
|
|
162
|
+
export namespace Post {
|
|
163
|
+
export interface MediaItem {
|
|
164
|
+
filename: string;
|
|
281
165
|
|
|
282
|
-
|
|
283
|
-
* When posting to a Community, also share the post with followers.
|
|
284
|
-
*/
|
|
285
|
-
shareWithFollowers?: boolean;
|
|
166
|
+
mimeType: string;
|
|
286
167
|
|
|
287
|
-
|
|
288
|
-
* Additional tweets to chain as a thread. The root tweet uses post.content.
|
|
289
|
-
*/
|
|
290
|
-
threadItems?: Array<TwitterConfigurations.ThreadItem>;
|
|
291
|
-
}
|
|
168
|
+
size: number;
|
|
292
169
|
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
*/
|
|
297
|
-
export interface Poll {
|
|
298
|
-
/**
|
|
299
|
-
* Poll duration in minutes (5 min – 7 days).
|
|
300
|
-
*/
|
|
301
|
-
duration_minutes: number;
|
|
302
|
-
|
|
303
|
-
/**
|
|
304
|
-
* 2–4 poll options.
|
|
305
|
-
*/
|
|
306
|
-
options: Array<string>;
|
|
307
|
-
}
|
|
308
|
-
|
|
309
|
-
export interface ThreadItem {
|
|
310
|
-
/**
|
|
311
|
-
* Text of this thread tweet (max 280 chars)
|
|
312
|
-
*/
|
|
313
|
-
content: string;
|
|
314
|
-
|
|
315
|
-
mediaItems?: Array<ThreadItem.MediaItem>;
|
|
316
|
-
}
|
|
317
|
-
|
|
318
|
-
export namespace ThreadItem {
|
|
319
|
-
export interface MediaItem {
|
|
320
|
-
type: 'image' | 'video' | 'gif';
|
|
321
|
-
|
|
322
|
-
url: string;
|
|
323
|
-
}
|
|
324
|
-
}
|
|
170
|
+
type: 'image' | 'video' | 'gif';
|
|
171
|
+
|
|
172
|
+
url: string;
|
|
325
173
|
}
|
|
326
174
|
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
*/
|
|
330
|
-
export interface YouTubeConfigurations {
|
|
331
|
-
/**
|
|
332
|
-
* YouTube category ID. Defaults to "22" (People & Blogs). Common values: "1" Film
|
|
333
|
-
* & Animation, "10" Music, "20" Gaming, "22" People & Blogs, "27" Education, "28"
|
|
334
|
-
* Science & Technology.
|
|
335
|
-
*/
|
|
336
|
-
categoryId?: string;
|
|
175
|
+
export interface Platform {
|
|
176
|
+
errorMessage: string | null;
|
|
337
177
|
|
|
338
|
-
|
|
339
|
-
* AI-generated content disclosure. YouTube is increasingly enforcing this
|
|
340
|
-
* requirement. Defaults to false.
|
|
341
|
-
*/
|
|
342
|
-
containsSyntheticMedia?: boolean;
|
|
178
|
+
platform: 'twitter' | 'instagram' | 'youtube' | 'tiktok' | 'pinterest' | 'linkedin' | 'bluesky';
|
|
343
179
|
|
|
344
|
-
|
|
345
|
-
* Auto-posted comment after the video goes live. Max 10,000 characters. For
|
|
346
|
-
* publishNow posts: posted immediately after upload. For scheduled posts: posted
|
|
347
|
-
* when the video becomes public.
|
|
348
|
-
*/
|
|
349
|
-
firstComment?: string;
|
|
180
|
+
platformPostId: string | null;
|
|
350
181
|
|
|
351
182
|
/**
|
|
352
|
-
*
|
|
353
|
-
* notification bell, personalized ads, end screens, and cards on the video.
|
|
354
|
-
* Defaults to false.
|
|
183
|
+
* Direct URL to the published post
|
|
355
184
|
*/
|
|
356
|
-
|
|
185
|
+
platformPostUrl: string | null;
|
|
357
186
|
|
|
358
|
-
|
|
359
|
-
* Video tags. Total characters across all tags must be ≤500.
|
|
360
|
-
*/
|
|
361
|
-
tags?: Array<string>;
|
|
187
|
+
publishedAt: string | null;
|
|
362
188
|
|
|
363
|
-
|
|
364
|
-
* Video title (max 100 chars, no < or >). Defaults to first 100 chars of content,
|
|
365
|
-
* or "Untitled Video".
|
|
366
|
-
*/
|
|
367
|
-
title?: string;
|
|
189
|
+
status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
|
|
368
190
|
|
|
369
|
-
|
|
370
|
-
* Who can see the video. Defaults to "public". Scheduled posts upload as private
|
|
371
|
-
* and flip to this value at publish time.
|
|
372
|
-
*/
|
|
373
|
-
visibility?: 'public' | 'private' | 'unlisted';
|
|
191
|
+
warningMessage: string | null;
|
|
374
192
|
}
|
|
193
|
+
}
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
export interface PostListResponse {
|
|
197
|
+
posts: Array<PostListResponse.Post>;
|
|
198
|
+
|
|
199
|
+
success: boolean;
|
|
200
|
+
|
|
201
|
+
/**
|
|
202
|
+
* Total matched posts across all pages
|
|
203
|
+
*/
|
|
204
|
+
total: number;
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
export namespace PostListResponse {
|
|
208
|
+
export interface Post {
|
|
209
|
+
content: string;
|
|
210
|
+
|
|
211
|
+
createdAt: string;
|
|
212
|
+
|
|
213
|
+
crosspostingEnabled: boolean;
|
|
214
|
+
|
|
215
|
+
mediaItems: Array<Post.MediaItem>;
|
|
216
|
+
|
|
217
|
+
platforms: Array<Post.Platform>;
|
|
375
218
|
|
|
376
219
|
/**
|
|
377
|
-
*
|
|
220
|
+
* MongoDB ObjectId of the Post document
|
|
378
221
|
*/
|
|
379
|
-
|
|
380
|
-
/**
|
|
381
|
-
* Automatically add background music to photo carousels. Photo posts only.
|
|
382
|
-
* Defaults to true.
|
|
383
|
-
*/
|
|
384
|
-
auto_add_music?: boolean;
|
|
222
|
+
postId: string;
|
|
385
223
|
|
|
386
|
-
|
|
387
|
-
* Mark as branded content (paid partnership). Defaults to false.
|
|
388
|
-
*/
|
|
389
|
-
brand_content_toggle?: boolean;
|
|
224
|
+
rawRequestBody: { [key: string]: unknown };
|
|
390
225
|
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
226
|
+
/**
|
|
227
|
+
* ISO 8601 scheduled datetime
|
|
228
|
+
*/
|
|
229
|
+
scheduledFor: string | null;
|
|
395
230
|
|
|
396
|
-
|
|
397
|
-
* Disable comments on this post. Defaults to false.
|
|
398
|
-
*/
|
|
399
|
-
disable_comment?: boolean;
|
|
231
|
+
status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
|
|
400
232
|
|
|
401
|
-
|
|
402
|
-
* Disable duet for this video. Videos only. Defaults to false.
|
|
403
|
-
*/
|
|
404
|
-
disable_duet?: boolean;
|
|
233
|
+
timezone: string;
|
|
405
234
|
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
*/
|
|
409
|
-
disable_stitch?: boolean;
|
|
235
|
+
updatedAt: string;
|
|
236
|
+
}
|
|
410
237
|
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
*/
|
|
415
|
-
draft?: boolean;
|
|
238
|
+
export namespace Post {
|
|
239
|
+
export interface MediaItem {
|
|
240
|
+
filename: string;
|
|
416
241
|
|
|
417
|
-
|
|
418
|
-
* AI-generated content disclosure. Defaults to false.
|
|
419
|
-
*/
|
|
420
|
-
is_aigc?: boolean;
|
|
242
|
+
mimeType: string;
|
|
421
243
|
|
|
422
|
-
|
|
423
|
-
* 0-indexed position of the cover image in a photo carousel. Photo posts only.
|
|
424
|
-
* Defaults to 0.
|
|
425
|
-
*/
|
|
426
|
-
photo_cover_index?: number;
|
|
244
|
+
size: number;
|
|
427
245
|
|
|
428
|
-
|
|
429
|
-
* Who can see this post. Defaults to "SELF_ONLY" (required for unreviewed apps).
|
|
430
|
-
* Upgrade to PUBLIC_TO_EVERYONE after TikTok app review.
|
|
431
|
-
*/
|
|
432
|
-
privacy_level?: 'PUBLIC_TO_EVERYONE' | 'MUTUAL_FOLLOW_FRIENDS' | 'FOLLOWER_OF_CREATOR' | 'SELF_ONLY';
|
|
246
|
+
type: 'image' | 'video' | 'gif';
|
|
433
247
|
|
|
434
|
-
|
|
435
|
-
* Timestamp in milliseconds to use as the video cover frame. Videos only. Defaults
|
|
436
|
-
* to 1000ms.
|
|
437
|
-
*/
|
|
438
|
-
video_cover_timestamp_ms?: number;
|
|
248
|
+
url: string;
|
|
439
249
|
}
|
|
440
250
|
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
*/
|
|
444
|
-
export interface PinterestConfigurations {
|
|
445
|
-
/**
|
|
446
|
-
* Target board ID. Retrieve available boards via GET /connect/pinterest/boards.
|
|
447
|
-
*/
|
|
448
|
-
boardId: string;
|
|
251
|
+
export interface Platform {
|
|
252
|
+
errorMessage: string | null;
|
|
449
253
|
|
|
450
|
-
|
|
451
|
-
* Accessible image description. Max 500 characters.
|
|
452
|
-
*/
|
|
453
|
-
altText?: string;
|
|
254
|
+
platform: 'twitter' | 'instagram' | 'youtube' | 'tiktok' | 'pinterest' | 'linkedin' | 'bluesky';
|
|
454
255
|
|
|
455
|
-
|
|
456
|
-
* Custom cover image URL for video pins.
|
|
457
|
-
*/
|
|
458
|
-
coverImageUrl?: string;
|
|
256
|
+
platformPostId: string | null;
|
|
459
257
|
|
|
460
258
|
/**
|
|
461
|
-
*
|
|
259
|
+
* Direct URL to the published post
|
|
462
260
|
*/
|
|
463
|
-
|
|
261
|
+
platformPostUrl: string | null;
|
|
464
262
|
|
|
465
|
-
|
|
466
|
-
* HTTPS destination URL when the pin is clicked. Important for driving traffic.
|
|
467
|
-
*/
|
|
468
|
-
link?: string;
|
|
263
|
+
publishedAt: string | null;
|
|
469
264
|
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
title?: string;
|
|
265
|
+
status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
|
|
266
|
+
|
|
267
|
+
warningMessage: string | null;
|
|
474
268
|
}
|
|
269
|
+
}
|
|
270
|
+
}
|
|
271
|
+
|
|
272
|
+
export interface PostDeleteResponse {
|
|
273
|
+
success: boolean;
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
export interface PostCreateParams {
|
|
277
|
+
/**
|
|
278
|
+
* Post text body
|
|
279
|
+
*/
|
|
280
|
+
content: string;
|
|
281
|
+
|
|
282
|
+
/**
|
|
283
|
+
* Target platform accounts to publish to
|
|
284
|
+
*/
|
|
285
|
+
platforms: Array<PostCreateParams.Platform>;
|
|
286
|
+
|
|
287
|
+
/**
|
|
288
|
+
* Media attachments (images, videos, GIFs)
|
|
289
|
+
*/
|
|
290
|
+
mediaItems?: Array<PostCreateParams.MediaItem>;
|
|
291
|
+
|
|
292
|
+
/**
|
|
293
|
+
* Publish immediately. Required when scheduledFor is omitted.
|
|
294
|
+
*/
|
|
295
|
+
publishNow?: boolean;
|
|
296
|
+
|
|
297
|
+
/**
|
|
298
|
+
* ISO 8601 datetime to schedule the post for future publishing
|
|
299
|
+
*/
|
|
300
|
+
scheduledFor?: string;
|
|
475
301
|
|
|
302
|
+
/**
|
|
303
|
+
* IANA timezone for the scheduled time (e.g. America/New_York). Defaults to UTC.
|
|
304
|
+
*/
|
|
305
|
+
timezone?: string;
|
|
306
|
+
}
|
|
307
|
+
|
|
308
|
+
export namespace PostCreateParams {
|
|
309
|
+
export interface Platform {
|
|
476
310
|
/**
|
|
477
|
-
*
|
|
311
|
+
* Integration.\_id — find yours via GET /connect/integrations
|
|
478
312
|
*/
|
|
479
|
-
|
|
480
|
-
/**
|
|
481
|
-
* Description for the article preview card. Max 400 characters.
|
|
482
|
-
*/
|
|
483
|
-
article_description?: string;
|
|
313
|
+
accountId: string;
|
|
484
314
|
|
|
485
|
-
|
|
486
|
-
* Title for the article preview card. Max 400 characters.
|
|
487
|
-
*/
|
|
488
|
-
article_title?: string;
|
|
315
|
+
platform: 'twitter' | 'instagram' | 'youtube' | 'tiktok' | 'pinterest' | 'linkedin' | 'bluesky';
|
|
489
316
|
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
/**
|
|
497
|
-
* Post visibility. "PUBLIC" = visible to everyone, "CONNECTIONS" = visible to
|
|
498
|
-
* connections only. Defaults to "PUBLIC".
|
|
499
|
-
*/
|
|
500
|
-
visibility?: 'PUBLIC' | 'CONNECTIONS';
|
|
501
|
-
}
|
|
317
|
+
/**
|
|
318
|
+
* Platform-specific options. See TwitterConfigurations, YouTubeConfigurations,
|
|
319
|
+
* TikTokConfigurations, PinterestConfigurations, or LinkedInConfigurations in the
|
|
320
|
+
* schema reference for available fields per platform.
|
|
321
|
+
*/
|
|
322
|
+
platformSpecificData?: { [key: string]: unknown };
|
|
502
323
|
}
|
|
503
324
|
|
|
504
325
|
export interface MediaItem {
|
|
@@ -538,7 +359,7 @@ export interface PostListParams {
|
|
|
538
359
|
/**
|
|
539
360
|
* Filter by platform (repeatable — OR logic)
|
|
540
361
|
*/
|
|
541
|
-
platform?: Array<'twitter' | 'instagram' | 'youtube' | 'tiktok' | 'pinterest' | 'linkedin'>;
|
|
362
|
+
platform?: Array<'twitter' | 'instagram' | 'youtube' | 'tiktok' | 'pinterest' | 'linkedin' | 'bluesky'>;
|
|
542
363
|
|
|
543
364
|
/**
|
|
544
365
|
* ISO 8601 lower bound on scheduledFor
|
|
@@ -550,19 +371,15 @@ export interface PostListParams {
|
|
|
550
371
|
*/
|
|
551
372
|
scheduledBefore?: string;
|
|
552
373
|
|
|
553
|
-
/**
|
|
554
|
-
* Sort direction by createdAt
|
|
555
|
-
*/
|
|
556
374
|
sort?: 'asc' | 'desc';
|
|
557
375
|
|
|
558
|
-
status?:
|
|
376
|
+
status?: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
|
|
559
377
|
}
|
|
560
378
|
|
|
561
379
|
Posts.Scheduled = Scheduled;
|
|
562
380
|
|
|
563
381
|
export declare namespace Posts {
|
|
564
382
|
export {
|
|
565
|
-
type PostSummary as PostSummary,
|
|
566
383
|
type Status as Status,
|
|
567
384
|
type PostCreateResponse as PostCreateResponse,
|
|
568
385
|
type PostRetrieveResponse as PostRetrieveResponse,
|
|
@@ -92,15 +92,9 @@ export namespace ScheduledListResponse {
|
|
|
92
92
|
|
|
93
93
|
export namespace Post {
|
|
94
94
|
export interface Platform {
|
|
95
|
-
|
|
96
|
-
* Platform name (twitter, instagram, youtube)
|
|
97
|
-
*/
|
|
98
|
-
platform: string;
|
|
95
|
+
platform: 'twitter' | 'instagram' | 'youtube' | 'tiktok' | 'pinterest' | 'linkedin' | 'bluesky';
|
|
99
96
|
|
|
100
|
-
|
|
101
|
-
* Current status of this platform target
|
|
102
|
-
*/
|
|
103
|
-
status: string;
|
|
97
|
+
status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
|
|
104
98
|
}
|
|
105
99
|
|
|
106
100
|
export interface MediaItem {
|
package/src/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.6.0'; // x-release-please-version
|
package/version.d.mts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.6.0";
|
|
2
2
|
//# sourceMappingURL=version.d.mts.map
|
package/version.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export declare const VERSION = "0.
|
|
1
|
+
export declare const VERSION = "0.6.0";
|
|
2
2
|
//# sourceMappingURL=version.d.ts.map
|
package/version.js
CHANGED
package/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export const VERSION = '0.
|
|
1
|
+
export const VERSION = '0.6.0'; // x-release-please-version
|
|
2
2
|
//# sourceMappingURL=version.mjs.map
|