@adeli/sdk 0.0.0-stage → 0.1.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/LICENSE +21 -0
- package/README.md +30 -2
- package/dist/comments-C_vDnwix.d.cts +8268 -0
- package/dist/comments-Dx3195Ty.d.ts +8268 -0
- package/dist/helpers/index.cjs +482 -0
- package/dist/helpers/index.cjs.map +1 -0
- package/dist/helpers/index.d.cts +207 -0
- package/dist/helpers/index.d.ts +207 -0
- package/dist/helpers/index.js +471 -0
- package/dist/helpers/index.js.map +1 -0
- package/dist/index.cjs +878 -0
- package/dist/index.cjs.map +1 -0
- package/dist/index.d.cts +360 -0
- package/dist/index.d.ts +360 -0
- package/dist/index.js +860 -0
- package/dist/index.js.map +1 -0
- package/dist/uploads-MGVSU99R.d.cts +100 -0
- package/dist/uploads-MGVSU99R.d.ts +100 -0
- package/dist/uploads.cjs +45 -0
- package/dist/uploads.cjs.map +1 -0
- package/dist/uploads.d.cts +1 -0
- package/dist/uploads.d.ts +1 -0
- package/dist/uploads.js +41 -0
- package/dist/uploads.js.map +1 -0
- package/docs/api-reference.md +72 -0
- package/docs/availability.md +26 -0
- package/docs/client.md +72 -0
- package/docs/maintenance.md +30 -0
- package/docs/publishing.md +39 -0
- package/openapi/adeli.openapi.json +20505 -0
- package/openapi/docs-links.json +71 -0
- package/openapi/provenance.json +8 -0
- package/package.json +85 -4
package/dist/index.d.cts
ADDED
|
@@ -0,0 +1,360 @@
|
|
|
1
|
+
import { T as Transport, R as RequestOptions, A as ApiResponse, C as ClientOptions } from './uploads-MGVSU99R.cjs';
|
|
2
|
+
export { D as DirectUploadDescriptor, a as DirectUploadOptions, b as DirectUploadProgress, F as FileUploadOptions, O as OperationMetadata, c as OperationOptions, d as blobFromPath, f as fileFromPath } from './uploads-MGVSU99R.cjs';
|
|
3
|
+
import { c as components, O as OperationSuccessBody, d as OperationQuery, e as OperationPath, f as OperationJsonBody, g as ProfilesResource, h as PostsResource, i as CommentsResource, j as PublicPlatform } from './comments-C_vDnwix.cjs';
|
|
4
|
+
export { B as BinaryUpload, k as CommentMutationResponse, a as CommentsQuery, b as CommentsResponse, C as ConnectionSession, l as ConnectionSessionError, m as CreateCommentBody, n as CreateMediaUploadsBody, o as CreateMediaUploadsResponse, p as CreatePostBody, q as CreatePostWithFiles, r as CreateProfileBody, D as DeletePostPath, s as DeletePostQuery, t as DeleteProfileResponse, F as FacebookPostStatusResponse, I as InstagramPostStatusResponse, J as JsonObject, u as JsonValue, L as ListCommentsQuery, v as ListPostsQuery, w as PostListResponse, x as PostStatusQuery, y as Profile, S as StartConnectionBody, z as TikTokCreatorInfoResponse, A as TikTokMultipartBody, T as TikTokPostStatusResponse, U as UpdateCommentBody, E as UpdateProfileBody, G as UpdatedCommentResponse, H as UploadYouTubeVideoBody, K as YouTubeStagedUploadBody, M as YouTubeUploadBody, N as YouTubeUploadResponse, Y as YouTubeVideoStatusResponse } from './comments-C_vDnwix.cjs';
|
|
5
|
+
|
|
6
|
+
/** Wire types for the account services and profile-scoped account handlers. */
|
|
7
|
+
type AccountSchema = components['schemas']['Account'];
|
|
8
|
+
type CapabilityDescriptor = AccountSchema['recommendedPermissions'][number];
|
|
9
|
+
type ReconnectGuidance = AccountSchema['reconnect'];
|
|
10
|
+
type AccountPermissionState = Pick<AccountSchema, 'grantedPermissions' | 'recommendedPermissions' | 'missingRecommendedPermissions' | 'capabilities' | 'capabilityRequirements' | 'reconnect'>;
|
|
11
|
+
interface XCapabilities {
|
|
12
|
+
readonly analytics: boolean;
|
|
13
|
+
readonly inbox: boolean;
|
|
14
|
+
}
|
|
15
|
+
/** Aggregate account responses include the full capability/scope state. */
|
|
16
|
+
type Account = AccountSchema;
|
|
17
|
+
/** Detail/update handlers additionally return X-specific capability toggles. */
|
|
18
|
+
type AccountDetailResponse = OperationSuccessBody<'getAccount'> & {
|
|
19
|
+
readonly xCapabilities?: XCapabilities;
|
|
20
|
+
};
|
|
21
|
+
type AccountUpdateResponse = OperationSuccessBody<'updateAccount'> & {
|
|
22
|
+
readonly xCapabilities?: XCapabilities;
|
|
23
|
+
};
|
|
24
|
+
type AccountsAggregateResponse = OperationSuccessBody<'listAccounts'>;
|
|
25
|
+
type RefreshAccountsResponse = OperationSuccessBody<'refreshAccounts'>;
|
|
26
|
+
/** At least one capability must be supplied; the API rejects an empty object. */
|
|
27
|
+
type XCapabilitiesUpdate = {
|
|
28
|
+
readonly analytics: boolean;
|
|
29
|
+
readonly inbox?: boolean;
|
|
30
|
+
} | {
|
|
31
|
+
readonly analytics?: boolean;
|
|
32
|
+
readonly inbox: boolean;
|
|
33
|
+
};
|
|
34
|
+
type UpdateAccountBody = OperationJsonBody<'updateAccount'>;
|
|
35
|
+
type ListAccountsQuery = OperationQuery<'listAccounts'>;
|
|
36
|
+
type AccountPath = OperationPath<'getAccount'>;
|
|
37
|
+
type DisconnectAccountResponse = OperationSuccessBody<'disconnectAccount'>;
|
|
38
|
+
declare class AccountsResource {
|
|
39
|
+
private readonly transport;
|
|
40
|
+
constructor(transport: Transport);
|
|
41
|
+
listAccounts(args?: {
|
|
42
|
+
readonly query?: ListAccountsQuery;
|
|
43
|
+
}, options?: RequestOptions): Promise<ApiResponse<AccountsAggregateResponse>>;
|
|
44
|
+
listProfileAccounts(args: {
|
|
45
|
+
readonly path: {
|
|
46
|
+
readonly profileId: string;
|
|
47
|
+
};
|
|
48
|
+
}, options?: RequestOptions): Promise<ApiResponse<AccountsAggregateResponse>>;
|
|
49
|
+
getAccount(args: {
|
|
50
|
+
readonly path: AccountPath;
|
|
51
|
+
}, options?: RequestOptions): Promise<ApiResponse<AccountDetailResponse>>;
|
|
52
|
+
updateAccount(args: {
|
|
53
|
+
readonly path: AccountPath;
|
|
54
|
+
readonly body: UpdateAccountBody;
|
|
55
|
+
}, options?: RequestOptions): Promise<ApiResponse<AccountUpdateResponse>>;
|
|
56
|
+
disconnectAccount(args: {
|
|
57
|
+
readonly path: AccountPath;
|
|
58
|
+
}, options?: RequestOptions): Promise<ApiResponse<DisconnectAccountResponse>>;
|
|
59
|
+
refreshAccounts(args: {
|
|
60
|
+
readonly path: {
|
|
61
|
+
readonly profileId: string;
|
|
62
|
+
};
|
|
63
|
+
}, options?: RequestOptions): Promise<ApiResponse<RefreshAccountsResponse>>;
|
|
64
|
+
}
|
|
65
|
+
|
|
66
|
+
type MessagesQuery = OperationQuery<'listMessages'>;
|
|
67
|
+
type ListMessagesQuery = MessagesQuery;
|
|
68
|
+
type SendMessageBody = OperationJsonBody<'sendMessage'>;
|
|
69
|
+
type MessagesResponse = OperationSuccessBody<'listMessages'>;
|
|
70
|
+
type SentMessage = OperationSuccessBody<'sendMessage'>;
|
|
71
|
+
type SendInstagramMessageBody = OperationJsonBody<'sendInstagramMessage'>;
|
|
72
|
+
type SentInstagramMessage = OperationSuccessBody<'sendInstagramMessage'>;
|
|
73
|
+
declare class MessagesResource {
|
|
74
|
+
private readonly transport;
|
|
75
|
+
constructor(transport: Transport);
|
|
76
|
+
listMessages(args?: {
|
|
77
|
+
readonly query?: MessagesQuery;
|
|
78
|
+
}, options?: RequestOptions): Promise<ApiResponse<MessagesResponse>>;
|
|
79
|
+
sendMessage(args: {
|
|
80
|
+
readonly body: SendMessageBody;
|
|
81
|
+
}, options?: RequestOptions): Promise<ApiResponse<SentMessage>>;
|
|
82
|
+
sendInstagramMessage(args: {
|
|
83
|
+
readonly body: SendInstagramMessageBody;
|
|
84
|
+
}, options?: RequestOptions): Promise<ApiResponse<SentInstagramMessage>>;
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
type InstagramAccountInsightsQuery = OperationQuery<'getInstagramAccountInsights'>;
|
|
88
|
+
type FacebookPageMetricsQuery = OperationQuery<'getFacebookPageMetrics'>;
|
|
89
|
+
type TikTokAccountAnalyticsQuery = OperationQuery<'getTikTokAccountAnalytics'>;
|
|
90
|
+
type TikTokAccountInsightsQuery = OperationQuery<'getTikTokAccountInsights'>;
|
|
91
|
+
type TikTokVideoInsightsQuery = OperationQuery<'getTikTokVideoInsights'>;
|
|
92
|
+
type YouTubeChannelInsightsQuery = OperationQuery<'getYouTubeChannelInsights'>;
|
|
93
|
+
type YouTubeVideoInsightsQuery = OperationQuery<'getYouTubeVideoInsights'>;
|
|
94
|
+
type InstagramAccountInsightsResponse = OperationSuccessBody<'getInstagramAccountInsights'>;
|
|
95
|
+
type FacebookPageMetricsResponse = OperationSuccessBody<'getFacebookPageMetrics'>;
|
|
96
|
+
type TikTokAccountAnalyticsResponse = OperationSuccessBody<'getTikTokAccountAnalytics'>;
|
|
97
|
+
type TikTokAccountInsightsResponse = OperationSuccessBody<'getTikTokAccountInsights'>;
|
|
98
|
+
type TikTokVideoInsightsResponse = OperationSuccessBody<'getTikTokVideoInsights'>;
|
|
99
|
+
type YouTubeChannelInsightsResponse = OperationSuccessBody<'getYouTubeChannelInsights'>;
|
|
100
|
+
type YouTubeVideoInsightsResponse = OperationSuccessBody<'getYouTubeVideoInsights'>;
|
|
101
|
+
declare class AnalyticsResource {
|
|
102
|
+
private readonly transport;
|
|
103
|
+
constructor(transport: Transport);
|
|
104
|
+
getInstagramAccountInsights(args: {
|
|
105
|
+
readonly query: InstagramAccountInsightsQuery;
|
|
106
|
+
}, options?: RequestOptions): Promise<ApiResponse<InstagramAccountInsightsResponse>>;
|
|
107
|
+
getFacebookPageMetrics(args: {
|
|
108
|
+
readonly query?: FacebookPageMetricsQuery;
|
|
109
|
+
}, options?: RequestOptions): Promise<ApiResponse<FacebookPageMetricsResponse>>;
|
|
110
|
+
getTikTokAccountAnalytics(args: {
|
|
111
|
+
readonly query: TikTokAccountAnalyticsQuery;
|
|
112
|
+
}, options?: RequestOptions): Promise<ApiResponse<TikTokAccountAnalyticsResponse>>;
|
|
113
|
+
getTikTokAccountInsights(args: {
|
|
114
|
+
readonly query: TikTokAccountInsightsQuery;
|
|
115
|
+
}, options?: RequestOptions): Promise<ApiResponse<TikTokAccountInsightsResponse>>;
|
|
116
|
+
getTikTokVideoInsights(args: {
|
|
117
|
+
readonly query: TikTokVideoInsightsQuery;
|
|
118
|
+
}, options?: RequestOptions): Promise<ApiResponse<TikTokVideoInsightsResponse>>;
|
|
119
|
+
getYouTubeChannelInsights(args: {
|
|
120
|
+
readonly query: YouTubeChannelInsightsQuery;
|
|
121
|
+
}, options?: RequestOptions): Promise<ApiResponse<YouTubeChannelInsightsResponse>>;
|
|
122
|
+
getYouTubeVideoInsights(args: {
|
|
123
|
+
readonly query: YouTubeVideoInsightsQuery;
|
|
124
|
+
}, options?: RequestOptions): Promise<ApiResponse<YouTubeVideoInsightsResponse>>;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
type IdempotentOptions = RequestOptions & {
|
|
128
|
+
readonly idempotencyKey: string;
|
|
129
|
+
};
|
|
130
|
+
type AdBusinessesQuery = OperationQuery<'listAdBusinesses'>;
|
|
131
|
+
type ListAdBusinessesQuery = AdBusinessesQuery;
|
|
132
|
+
type AdAccountsQuery = OperationQuery<'listAdAccounts'>;
|
|
133
|
+
type ListAdAccountsQuery = AdAccountsQuery;
|
|
134
|
+
type CreateAdAccountQuery = OperationQuery<'createAdAccount'>;
|
|
135
|
+
type AdAccountQuery = OperationQuery<'getAdAccount'>;
|
|
136
|
+
type AdTreeQuery = OperationQuery<'getAdTree'>;
|
|
137
|
+
type AdInsightsQuery = OperationQuery<'getAdInsights'>;
|
|
138
|
+
type AdLeadsQuery = OperationQuery<'listAdLeads'>;
|
|
139
|
+
type ListAdLeadsQuery = AdLeadsQuery;
|
|
140
|
+
type CreateCampaignQuery = OperationQuery<'createCampaign'>;
|
|
141
|
+
type CreateAdAccountBody = OperationJsonBody<'createAdAccount'>;
|
|
142
|
+
type UpdateAdAccountBody = OperationJsonBody<'updateAdAccount'>;
|
|
143
|
+
type CreateCampaignBody = OperationJsonBody<'createCampaign'>;
|
|
144
|
+
type SetAdStatusBody = OperationJsonBody<'setAdStatus'>;
|
|
145
|
+
type AdAccountPath = OperationPath<'getAdAccount'>;
|
|
146
|
+
type UpdateAdAccountPath = OperationPath<'updateAdAccount'>;
|
|
147
|
+
type DeleteCampaignPath = OperationPath<'deleteCampaign'>;
|
|
148
|
+
type ListAdBusinessesResponse = OperationSuccessBody<'listAdBusinesses'>;
|
|
149
|
+
type ListAdAccountsResponse = OperationSuccessBody<'listAdAccounts'>;
|
|
150
|
+
type CreateAdAccountResponse = OperationSuccessBody<'createAdAccount'>;
|
|
151
|
+
type AdAccountResponse = OperationSuccessBody<'getAdAccount'>;
|
|
152
|
+
type AdTreeResponse = OperationSuccessBody<'getAdTree'>;
|
|
153
|
+
type AdInsightsResponse = OperationSuccessBody<'getAdInsights'>;
|
|
154
|
+
type AdLeadsResponse = OperationSuccessBody<'listAdLeads'>;
|
|
155
|
+
type CampaignResponse = OperationSuccessBody<'createCampaign'>;
|
|
156
|
+
type AdStatusResponse = OperationSuccessBody<'setAdStatus'>;
|
|
157
|
+
/** TikTok Ads only: an ad group's budget, end date or name. */
|
|
158
|
+
type UpdateAdGroupPath = OperationPath<'updateAdGroup'>;
|
|
159
|
+
type UpdateAdGroupQuery = OperationQuery<'updateAdGroup'>;
|
|
160
|
+
type UpdateAdGroupBody = OperationJsonBody<'updateAdGroup'>;
|
|
161
|
+
type AdGroupResponse = OperationSuccessBody<'updateAdGroup'>;
|
|
162
|
+
/** TikTok Ads only: location, language and interest options. */
|
|
163
|
+
type AdTargetingQuery = OperationQuery<'listAdTargeting'>;
|
|
164
|
+
type AdTargetingResponse = OperationSuccessBody<'listAdTargeting'>;
|
|
165
|
+
/** TikTok Ads only: the brand identities an ad runs as. */
|
|
166
|
+
type AdIdentitiesQuery = OperationQuery<'listAdIdentities'>;
|
|
167
|
+
type AdIdentitiesResponse = OperationSuccessBody<'listAdIdentities'>;
|
|
168
|
+
type CreateAdIdentityQuery = OperationQuery<'createAdIdentity'>;
|
|
169
|
+
type CreateAdIdentityBody = OperationJsonBody<'createAdIdentity'>;
|
|
170
|
+
type AdIdentityResponse = OperationSuccessBody<'createAdIdentity'>;
|
|
171
|
+
declare class AdsResource {
|
|
172
|
+
private readonly transport;
|
|
173
|
+
constructor(transport: Transport);
|
|
174
|
+
listAdBusinesses(args?: {
|
|
175
|
+
readonly query?: AdBusinessesQuery;
|
|
176
|
+
}, options?: RequestOptions): Promise<ApiResponse<ListAdBusinessesResponse>>;
|
|
177
|
+
listAdAccounts(args?: {
|
|
178
|
+
readonly query?: AdAccountsQuery;
|
|
179
|
+
}, options?: RequestOptions): Promise<ApiResponse<ListAdAccountsResponse>>;
|
|
180
|
+
createAdAccount(args: {
|
|
181
|
+
readonly query?: CreateAdAccountQuery;
|
|
182
|
+
readonly body: CreateAdAccountBody;
|
|
183
|
+
}, options: IdempotentOptions): Promise<ApiResponse<CreateAdAccountResponse>>;
|
|
184
|
+
getAdAccount(args: {
|
|
185
|
+
readonly path: AdAccountPath;
|
|
186
|
+
readonly query?: AdAccountQuery;
|
|
187
|
+
}, options?: RequestOptions): Promise<ApiResponse<AdAccountResponse>>;
|
|
188
|
+
updateAdAccount(args: {
|
|
189
|
+
readonly path: UpdateAdAccountPath;
|
|
190
|
+
readonly query?: AdAccountQuery;
|
|
191
|
+
readonly body: UpdateAdAccountBody;
|
|
192
|
+
}, options?: RequestOptions): Promise<ApiResponse<AdAccountResponse>>;
|
|
193
|
+
getAdTree(args: {
|
|
194
|
+
readonly query: AdTreeQuery;
|
|
195
|
+
}, options?: RequestOptions): Promise<ApiResponse<AdTreeResponse>>;
|
|
196
|
+
getAdInsights(args: {
|
|
197
|
+
readonly query: AdInsightsQuery;
|
|
198
|
+
}, options?: RequestOptions): Promise<ApiResponse<AdInsightsResponse>>;
|
|
199
|
+
listAdLeads(args?: {
|
|
200
|
+
readonly query?: AdLeadsQuery;
|
|
201
|
+
}, options?: RequestOptions): Promise<ApiResponse<AdLeadsResponse>>;
|
|
202
|
+
createCampaign(args: {
|
|
203
|
+
readonly query?: CreateCampaignQuery;
|
|
204
|
+
readonly body: CreateCampaignBody;
|
|
205
|
+
}, options: IdempotentOptions): Promise<ApiResponse<CampaignResponse>>;
|
|
206
|
+
deleteCampaign(args: {
|
|
207
|
+
readonly path: DeleteCampaignPath;
|
|
208
|
+
readonly query: OperationQuery<'deleteCampaign'>;
|
|
209
|
+
}, options?: RequestOptions): Promise<ApiResponse<undefined>>;
|
|
210
|
+
setAdStatus(args: {
|
|
211
|
+
readonly query?: OperationQuery<'setAdStatus'>;
|
|
212
|
+
readonly body: SetAdStatusBody;
|
|
213
|
+
}, options?: RequestOptions): Promise<ApiResponse<AdStatusResponse>>;
|
|
214
|
+
updateAdGroup(args: {
|
|
215
|
+
readonly path: UpdateAdGroupPath;
|
|
216
|
+
readonly query?: UpdateAdGroupQuery;
|
|
217
|
+
readonly body: UpdateAdGroupBody;
|
|
218
|
+
}, options?: RequestOptions): Promise<ApiResponse<AdGroupResponse>>;
|
|
219
|
+
listAdTargeting(args: {
|
|
220
|
+
readonly query: AdTargetingQuery;
|
|
221
|
+
}, options?: RequestOptions): Promise<ApiResponse<AdTargetingResponse>>;
|
|
222
|
+
listAdIdentities(args: {
|
|
223
|
+
readonly query: AdIdentitiesQuery;
|
|
224
|
+
}, options?: RequestOptions): Promise<ApiResponse<AdIdentitiesResponse>>;
|
|
225
|
+
createAdIdentity(args: {
|
|
226
|
+
readonly query?: CreateAdIdentityQuery;
|
|
227
|
+
readonly body: CreateAdIdentityBody;
|
|
228
|
+
}, options?: RequestOptions): Promise<ApiResponse<AdIdentityResponse>>;
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
type XUsageResponse = OperationSuccessBody<'getXUsage'>;
|
|
232
|
+
declare class UsageResource {
|
|
233
|
+
private readonly transport;
|
|
234
|
+
constructor(transport: Transport);
|
|
235
|
+
getXUsage(_args?: Record<never, never>, options?: RequestOptions): Promise<ApiResponse<XUsageResponse>>;
|
|
236
|
+
}
|
|
237
|
+
|
|
238
|
+
type ListWebhooksQuery = OperationQuery<'listWebhooks'>;
|
|
239
|
+
type CreateWebhookBody = OperationJsonBody<'createWebhook'>;
|
|
240
|
+
type WebhooksResponse = OperationSuccessBody<'listWebhooks'>;
|
|
241
|
+
type Webhook = WebhooksResponse['webhooks'][number];
|
|
242
|
+
/** The created webhook and its signing secret. The secret is returned only here. */
|
|
243
|
+
type CreatedWebhook = OperationSuccessBody<'createWebhook'>;
|
|
244
|
+
declare class WebhooksResource {
|
|
245
|
+
private readonly transport;
|
|
246
|
+
constructor(transport: Transport);
|
|
247
|
+
listWebhooks(args: {
|
|
248
|
+
readonly query: ListWebhooksQuery;
|
|
249
|
+
}, options?: RequestOptions): Promise<ApiResponse<WebhooksResponse>>;
|
|
250
|
+
createWebhook(args: {
|
|
251
|
+
readonly body: CreateWebhookBody;
|
|
252
|
+
}, options?: RequestOptions): Promise<ApiResponse<CreatedWebhook>>;
|
|
253
|
+
deleteWebhook(args: {
|
|
254
|
+
readonly path: OperationPath<'deleteWebhook'>;
|
|
255
|
+
}, options?: RequestOptions): Promise<ApiResponse<undefined>>;
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
/** Wire alias for the object serialized by apps/web/lib/public-api/me.ts. */
|
|
259
|
+
interface Identity {
|
|
260
|
+
readonly message: string;
|
|
261
|
+
readonly you: {
|
|
262
|
+
readonly name: string | null;
|
|
263
|
+
readonly organization: string | null;
|
|
264
|
+
readonly profile: {
|
|
265
|
+
readonly id: string;
|
|
266
|
+
readonly name: string;
|
|
267
|
+
};
|
|
268
|
+
};
|
|
269
|
+
readonly apiKey: {
|
|
270
|
+
readonly label: string | null;
|
|
271
|
+
readonly prefix: string;
|
|
272
|
+
readonly createdAt: string;
|
|
273
|
+
};
|
|
274
|
+
readonly accountsConnected: readonly {
|
|
275
|
+
readonly accountId: string;
|
|
276
|
+
readonly platform: PublicPlatform;
|
|
277
|
+
readonly username: string | null;
|
|
278
|
+
}[];
|
|
279
|
+
readonly docs: string;
|
|
280
|
+
}
|
|
281
|
+
interface GetMeQuery {
|
|
282
|
+
readonly profileId?: string;
|
|
283
|
+
}
|
|
284
|
+
declare class Adeli {
|
|
285
|
+
readonly profiles: ProfilesResource;
|
|
286
|
+
readonly accounts: AccountsResource;
|
|
287
|
+
readonly posts: PostsResource;
|
|
288
|
+
readonly comments: CommentsResource;
|
|
289
|
+
readonly messages: MessagesResource;
|
|
290
|
+
readonly analytics: AnalyticsResource;
|
|
291
|
+
readonly ads: AdsResource;
|
|
292
|
+
readonly usage: UsageResource;
|
|
293
|
+
readonly webhooks: WebhooksResource;
|
|
294
|
+
private readonly transport;
|
|
295
|
+
constructor(options?: ClientOptions);
|
|
296
|
+
/** Do not serialize client internals or its API key. */
|
|
297
|
+
toJSON(): Record<string, never>;
|
|
298
|
+
getMe(args?: {
|
|
299
|
+
readonly query?: GetMeQuery;
|
|
300
|
+
}, options?: RequestOptions): Promise<ApiResponse<Identity>>;
|
|
301
|
+
}
|
|
302
|
+
|
|
303
|
+
type PermissionRequiredDetails = NonNullable<components['schemas']['PermissionRequiredError']['error']['details']>;
|
|
304
|
+
/** Conservative recognition, not normalization or proof that a URL is safe to follow.
|
|
305
|
+
* Sparse known fields are allowed; unknown-only objects and malformed known fields are not.
|
|
306
|
+
*/
|
|
307
|
+
declare function isPermissionRequiredDetails(value: unknown): value is PermissionRequiredDetails;
|
|
308
|
+
declare class AdeliError extends Error {
|
|
309
|
+
readonly name: string;
|
|
310
|
+
constructor(message: string);
|
|
311
|
+
}
|
|
312
|
+
declare class ConfigurationError extends AdeliError {
|
|
313
|
+
readonly name = "ConfigurationError";
|
|
314
|
+
}
|
|
315
|
+
declare class NetworkError extends AdeliError {
|
|
316
|
+
readonly name: string;
|
|
317
|
+
}
|
|
318
|
+
/** Redirects are refused and must never be retried with credentials. */
|
|
319
|
+
declare class RedirectError extends NetworkError {
|
|
320
|
+
readonly name: string;
|
|
321
|
+
}
|
|
322
|
+
/** A timeout only cancels this client request; a write may still have completed remotely. */
|
|
323
|
+
declare class TimeoutError extends AdeliError {
|
|
324
|
+
readonly name = "TimeoutError";
|
|
325
|
+
}
|
|
326
|
+
declare class CancellationError extends AdeliError {
|
|
327
|
+
readonly name = "CancellationError";
|
|
328
|
+
}
|
|
329
|
+
declare class MalformedResponseError extends AdeliError {
|
|
330
|
+
readonly name = "MalformedResponseError";
|
|
331
|
+
}
|
|
332
|
+
interface AdeliApiErrorOptions {
|
|
333
|
+
status: number;
|
|
334
|
+
code?: string;
|
|
335
|
+
details?: unknown;
|
|
336
|
+
headers?: Headers;
|
|
337
|
+
}
|
|
338
|
+
declare class AdeliApiError extends AdeliError {
|
|
339
|
+
readonly name: string;
|
|
340
|
+
readonly status: number;
|
|
341
|
+
readonly code: string;
|
|
342
|
+
readonly details: unknown;
|
|
343
|
+
readonly headers: Headers;
|
|
344
|
+
constructor(message: string, options: AdeliApiErrorOptions);
|
|
345
|
+
}
|
|
346
|
+
declare class AuthenticationError extends AdeliApiError {
|
|
347
|
+
readonly name = "AuthenticationError";
|
|
348
|
+
}
|
|
349
|
+
declare class ValidationError extends AdeliApiError {
|
|
350
|
+
readonly name = "ValidationError";
|
|
351
|
+
}
|
|
352
|
+
declare class RateLimitError extends AdeliApiError {
|
|
353
|
+
readonly name = "RateLimitError";
|
|
354
|
+
}
|
|
355
|
+
declare class PermissionRequiredError extends AdeliApiError {
|
|
356
|
+
readonly name = "PermissionRequiredError";
|
|
357
|
+
}
|
|
358
|
+
declare function isAdeliApiError(error: unknown): error is AdeliApiError;
|
|
359
|
+
|
|
360
|
+
export { type Account, type AccountDetailResponse, type AccountPermissionState, type AccountUpdateResponse, type AccountsAggregateResponse, type AdAccountPath, type AdAccountResponse, type AdAccountsQuery, type AdBusinessesQuery, type AdGroupResponse, type AdIdentitiesQuery, type AdIdentitiesResponse, type AdIdentityResponse, type AdInsightsQuery, type AdInsightsResponse, type AdLeadsQuery, type AdLeadsResponse, type AdStatusResponse, type AdTargetingQuery, type AdTargetingResponse, type AdTreeQuery, type AdTreeResponse, Adeli, AdeliApiError, AdeliError, AnalyticsResource, ApiResponse, AuthenticationError, type CampaignResponse, CancellationError, type CapabilityDescriptor, ClientOptions, ConfigurationError, type CreateAdAccountBody, type CreateAdAccountQuery, type CreateAdAccountResponse, type CreateAdIdentityBody, type CreateAdIdentityQuery, type CreateCampaignBody, type CreateCampaignQuery, type CreateWebhookBody, type CreatedWebhook, type DisconnectAccountResponse, type GetMeQuery, type Identity, type ListAdAccountsQuery, type ListAdBusinessesQuery, type ListAdLeadsQuery, type ListMessagesQuery, type ListWebhooksQuery, MalformedResponseError, type MessagesQuery, type MessagesResponse, NetworkError, type PermissionRequiredDetails, PermissionRequiredError, PublicPlatform, RateLimitError, type ReconnectGuidance, RedirectError, RequestOptions, type SendInstagramMessageBody, type SendMessageBody, type SentInstagramMessage, type SentMessage, type SetAdStatusBody, TimeoutError, type UpdateAccountBody, type UpdateAdGroupBody, type UpdateAdGroupPath, type UpdateAdGroupQuery, ValidationError, type Webhook, type WebhooksResponse, type XCapabilities, type XCapabilitiesUpdate, type XUsageResponse, isAdeliApiError, isPermissionRequiredDetails };
|