@curviate/sdk 0.12.0 → 0.14.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 +56 -0
- package/README.md +1 -1
- package/dist/index.d.ts +509 -253
- package/dist/index.js +114 -38
- package/package.json +1 -1
- package/src/generated/types.ts +352 -195
package/src/generated/types.ts
CHANGED
|
@@ -57,20 +57,20 @@ export interface paths {
|
|
|
57
57
|
seat_id?: string | null;
|
|
58
58
|
/** @description ISO-8601 UTC connection timestamp. */
|
|
59
59
|
connected_at?: string | null;
|
|
60
|
-
/** @description Cached account username.
|
|
60
|
+
/** @description Cached account username. No longer refreshed by background enrichment — null for newly connected accounts (a previously cached value is retained). */
|
|
61
61
|
username?: string | null;
|
|
62
|
-
/** @description Cached premium-membership id.
|
|
62
|
+
/** @description Cached premium-membership id. No longer refreshed by background enrichment — null for newly connected accounts, or for non-premium accounts (a previously cached value is retained). */
|
|
63
63
|
premium_id?: string | null;
|
|
64
|
-
/** @description Cached public profile identifier.
|
|
64
|
+
/** @description Cached public profile identifier. No longer refreshed by background enrichment — null for newly connected accounts (a previously cached value is retained). */
|
|
65
65
|
public_identifier?: string | null;
|
|
66
|
-
/** @description ISO-8601 UTC creation timestamp of the underlying LinkedIn account — distinct from connected_at. Null until
|
|
66
|
+
/** @description ISO-8601 UTC creation timestamp of the underlying LinkedIn account — distinct from connected_at. Null until the first background enrichment lands. */
|
|
67
67
|
substrate_created_at?: string | null;
|
|
68
|
-
/** @description Cached signature blocks (title + content) for
|
|
68
|
+
/** @description Cached signature blocks (title + content). No longer refreshed by background enrichment — empty for newly connected accounts (a previously cached value is retained). */
|
|
69
69
|
signatures?: {
|
|
70
70
|
title?: string;
|
|
71
71
|
content?: string;
|
|
72
72
|
}[];
|
|
73
|
-
/** @description Cached group names the account belongs to.
|
|
73
|
+
/** @description Cached group names the account belongs to. No longer refreshed by background enrichment — empty for newly connected accounts (a previously cached value is retained). */
|
|
74
74
|
groups?: string[];
|
|
75
75
|
}[];
|
|
76
76
|
/** @description Next-page cursor; null on the last page. */
|
|
@@ -242,7 +242,7 @@ export interface paths {
|
|
|
242
242
|
object?: "account";
|
|
243
243
|
account_id?: string;
|
|
244
244
|
/** @enum {string} */
|
|
245
|
-
status?: "active";
|
|
245
|
+
status?: "active" | "reconnect_needed" | "restricted" | "disconnected";
|
|
246
246
|
/** @enum {string} */
|
|
247
247
|
auth_method?: "credentials" | "cookie";
|
|
248
248
|
full_name?: string | null;
|
|
@@ -254,10 +254,12 @@ export interface paths {
|
|
|
254
254
|
* @description Deprecated — use seat_id (same value). Removed at the GA /v1 cutover.
|
|
255
255
|
*/
|
|
256
256
|
attached_seat_id?: string | null;
|
|
257
|
+
/** @description Present and true only when this connect recovered an existing LinkedIn identity already present on the workspace (claiming it into your account) instead of connecting a brand-new one. Absent on a normal connect. The account's status reflects its real observed state, which may need a reconnect. */
|
|
258
|
+
recovered?: boolean;
|
|
257
259
|
};
|
|
258
260
|
};
|
|
259
261
|
};
|
|
260
|
-
/** @description A verification challenge is required.
|
|
262
|
+
/** @description A verification challenge is required. Resolve it via the checkpoint sub-resource (POST /v1/accounts/{account_id}/checkpoint/solve) using the returned account_id. */
|
|
261
263
|
202: {
|
|
262
264
|
headers: {
|
|
263
265
|
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
@@ -273,19 +275,24 @@ export interface paths {
|
|
|
273
275
|
object?: "checkpoint";
|
|
274
276
|
/** @enum {string} */
|
|
275
277
|
status?: "checkpoint_required";
|
|
276
|
-
/** @description The (provisional) account_id to pass to
|
|
278
|
+
/** @description The (provisional) account_id to pass to the checkpoint sub-resource (POST /v1/accounts/{account_id}/checkpoint/solve). */
|
|
277
279
|
account_id?: string;
|
|
278
280
|
/**
|
|
279
281
|
* @description The verification challenge LinkedIn issued.
|
|
280
282
|
* @enum {string}
|
|
281
283
|
*/
|
|
282
|
-
challenge_type?: "otp" | "two_factor_sms" | "two_factor_app" | "mobile_app_approval";
|
|
284
|
+
challenge_type?: "otp" | "two_factor_sms" | "two_factor_app" | "two_factor_whatsapp" | "mobile_app_approval" | "otp_or_mobile_app_approval" | "contract_selection";
|
|
285
|
+
/** @description Contract picker options (contract_selection only). Solve with the chosen id as the code. */
|
|
286
|
+
contracts?: {
|
|
287
|
+
id?: string;
|
|
288
|
+
name?: string;
|
|
289
|
+
}[];
|
|
283
290
|
/** @description ISO-8601 expiry of the challenge. */
|
|
284
291
|
expires_at?: string;
|
|
285
292
|
};
|
|
286
293
|
};
|
|
287
294
|
};
|
|
288
|
-
/** @description Invalid request — missing seat_id
|
|
295
|
+
/** @description Invalid request — missing seat_id, a malformed auth block, or a cookie connect without user_agent. */
|
|
289
296
|
400: {
|
|
290
297
|
headers: {
|
|
291
298
|
[name: string]: unknown;
|
|
@@ -312,7 +319,16 @@ export interface paths {
|
|
|
312
319
|
"application/json": components["schemas"]["Error"];
|
|
313
320
|
};
|
|
314
321
|
};
|
|
315
|
-
/** @description
|
|
322
|
+
/** @description This LinkedIn account is already linked (names your own account_id when your tenant owns it). */
|
|
323
|
+
409: {
|
|
324
|
+
headers: {
|
|
325
|
+
[name: string]: unknown;
|
|
326
|
+
};
|
|
327
|
+
content: {
|
|
328
|
+
"application/json": components["schemas"]["Error"];
|
|
329
|
+
};
|
|
330
|
+
};
|
|
331
|
+
/** @description The verification challenge cannot be resolved automatically (a dead-end challenge such as a CAPTCHA or a phone-number registration). For those two dead-ends the error body carries a machine-readable challenge_type (captcha | phone_register) so a client can render the right guidance; other unsupported challenges carry no challenge_type. */
|
|
316
332
|
422: {
|
|
317
333
|
headers: {
|
|
318
334
|
[name: string]: unknown;
|
|
@@ -426,20 +442,20 @@ export interface paths {
|
|
|
426
442
|
last_checked_at?: string;
|
|
427
443
|
/** @description The seat this account occupies (null for an admin seatless account). */
|
|
428
444
|
seat_id?: string | null;
|
|
429
|
-
/** @description Cached account username.
|
|
445
|
+
/** @description Cached account username. No longer refreshed by background enrichment — null for newly connected accounts (a previously cached value is retained). */
|
|
430
446
|
username?: string | null;
|
|
431
|
-
/** @description Cached premium-membership id.
|
|
447
|
+
/** @description Cached premium-membership id. No longer refreshed by background enrichment — null for newly connected accounts, or for non-premium accounts (a previously cached value is retained). */
|
|
432
448
|
premium_id?: string | null;
|
|
433
|
-
/** @description Cached public profile identifier.
|
|
449
|
+
/** @description Cached public profile identifier. No longer refreshed by background enrichment — null for newly connected accounts (a previously cached value is retained). */
|
|
434
450
|
public_identifier?: string | null;
|
|
435
|
-
/** @description ISO-8601 UTC creation timestamp of the underlying LinkedIn account — distinct from connected_at. Null until
|
|
451
|
+
/** @description ISO-8601 UTC creation timestamp of the underlying LinkedIn account — distinct from connected_at. Null until the first background enrichment lands. */
|
|
436
452
|
substrate_created_at?: string | null;
|
|
437
|
-
/** @description Cached signature blocks (title + content) for
|
|
453
|
+
/** @description Cached signature blocks (title + content). No longer refreshed by background enrichment — empty for newly connected accounts (a previously cached value is retained). */
|
|
438
454
|
signatures?: {
|
|
439
455
|
title?: string;
|
|
440
456
|
content?: string;
|
|
441
457
|
}[];
|
|
442
|
-
/** @description Cached group names the account belongs to.
|
|
458
|
+
/** @description Cached group names the account belongs to. No longer refreshed by background enrichment — empty for newly connected accounts (a previously cached value is retained). */
|
|
443
459
|
groups?: string[];
|
|
444
460
|
/** @description Usage-safety recommendations for this account — one entry per tracked family (messages.daily, connection_requests.daily, profile_views.daily, inmail.daily, profile.endorse, account.per_minute). These are advisory only: Curviate never rejects a request because a daily recommendation is exceeded; only account.per_minute is a binding limit enforced with HTTP 429. */
|
|
445
461
|
quotas?: {
|
|
@@ -628,8 +644,8 @@ export interface paths {
|
|
|
628
644
|
options?: never;
|
|
629
645
|
head?: never;
|
|
630
646
|
/**
|
|
631
|
-
* Update
|
|
632
|
-
* @description Update the
|
|
647
|
+
* Update account metadata / proxy configuration
|
|
648
|
+
* @description Update an account's custom metadata (a flat string map that replaces the store wholesale) and/or its custom proxy egress — supply a proxy object to set one, or null to clear it (revert to automatic proxy protection). Credentials and seat binding are untouched. The proxy password is encrypted at rest and never returned.
|
|
633
649
|
*/
|
|
634
650
|
patch: {
|
|
635
651
|
parameters: {
|
|
@@ -644,7 +660,9 @@ export interface paths {
|
|
|
644
660
|
requestBody: {
|
|
645
661
|
content: {
|
|
646
662
|
"application/json": {
|
|
647
|
-
/** @description
|
|
663
|
+
/** @description Flat string→string map that replaces this account's custom-data store wholesale (unprovided keys are removed). */
|
|
664
|
+
metadata?: unknown;
|
|
665
|
+
/** @description Custom-proxy egress config, or null to clear it (revert to automatic proxy protection). Omit to leave it unchanged. */
|
|
648
666
|
proxy?: {
|
|
649
667
|
/**
|
|
650
668
|
* @description Proxy protocol. One of http, https, socks5.
|
|
@@ -659,16 +677,12 @@ export interface paths {
|
|
|
659
677
|
username?: string;
|
|
660
678
|
/** @description Proxy auth password (optional). Encrypted at rest, never logged or returned. */
|
|
661
679
|
password?: string;
|
|
662
|
-
};
|
|
663
|
-
/** @description Managed proxy location hint as an ISO 3166-1 alpha-2 country code (e.g. US, DE). */
|
|
664
|
-
country?: string;
|
|
665
|
-
/** @description IPv4 address used to infer the managed proxy location. */
|
|
666
|
-
ip?: string;
|
|
680
|
+
} | null;
|
|
667
681
|
};
|
|
668
682
|
};
|
|
669
683
|
};
|
|
670
684
|
responses: {
|
|
671
|
-
/** @description The
|
|
685
|
+
/** @description The account metadata / proxy configuration was updated. */
|
|
672
686
|
200: {
|
|
673
687
|
headers: {
|
|
674
688
|
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
@@ -686,7 +700,7 @@ export interface paths {
|
|
|
686
700
|
};
|
|
687
701
|
};
|
|
688
702
|
};
|
|
689
|
-
/** @description Invalid proxy
|
|
703
|
+
/** @description Invalid request — a malformed proxy object or an unsupported field (country/ip are no longer accepted). */
|
|
690
704
|
400: {
|
|
691
705
|
headers: {
|
|
692
706
|
[name: string]: unknown;
|
|
@@ -725,7 +739,7 @@ export interface paths {
|
|
|
725
739
|
"application/json": components["schemas"]["Error"];
|
|
726
740
|
};
|
|
727
741
|
};
|
|
728
|
-
/** @description This
|
|
742
|
+
/** @description This proxy configuration is not supported for this account (e.g. the requested proxy mode is unavailable on the account's current plan). Not retryable as-is — change the request rather than resubmitting. */
|
|
729
743
|
501: {
|
|
730
744
|
headers: {
|
|
731
745
|
[name: string]: unknown;
|
|
@@ -776,7 +790,7 @@ export interface paths {
|
|
|
776
790
|
put?: never;
|
|
777
791
|
/**
|
|
778
792
|
* Generate a hosted connection link
|
|
779
|
-
* @description Mint a one-time hosted URL the end user opens to authorize a LinkedIn connection. Credentials land server-side and never transit the API or LLM context. `
|
|
793
|
+
* @description Mint a one-time hosted URL the end user opens to authorize a NEW LinkedIn connection. Credentials land server-side and never transit the API or LLM context. `seat_id` (the empty seat the new account fills) is required; `expires_in_seconds` (60–3600, default 900) and `redirect_url` are optional. To re-authorize an EXISTING account, use POST /v1/accounts/{account_id}/reconnect-link instead.
|
|
780
794
|
*/
|
|
781
795
|
post: {
|
|
782
796
|
parameters: {
|
|
@@ -788,28 +802,20 @@ export interface paths {
|
|
|
788
802
|
requestBody: {
|
|
789
803
|
content: {
|
|
790
804
|
"application/json": {
|
|
791
|
-
/** @description
|
|
792
|
-
seat_id
|
|
793
|
-
/** @description Account to reconnect for 'reconnect' purpose (required when purpose=reconnect) */
|
|
794
|
-
account_id?: string;
|
|
795
|
-
/**
|
|
796
|
-
* @description 'create' = new account onboarding; 'reconnect' = re-auth of existing account
|
|
797
|
-
* @default create
|
|
798
|
-
* @enum {string}
|
|
799
|
-
*/
|
|
800
|
-
purpose?: "create" | "reconnect";
|
|
805
|
+
/** @description The empty seat the newly connected account will fill. */
|
|
806
|
+
seat_id: string;
|
|
801
807
|
/**
|
|
802
808
|
* @description Seconds until the link expires (60–3600, default 900)
|
|
803
809
|
* @default 900
|
|
804
810
|
*/
|
|
805
811
|
expires_in_seconds?: number;
|
|
806
|
-
/** @description
|
|
812
|
+
/** @description Where the user's browser is sent after the connect flow completes. Must be an absolute https URL you control; you are responsible for its safety. Omit to return the user to a Curviate confirmation page. */
|
|
807
813
|
redirect_url?: string;
|
|
808
814
|
};
|
|
809
815
|
};
|
|
810
816
|
};
|
|
811
817
|
responses: {
|
|
812
|
-
/** @description A one-time hosted authorization link. Contains no credential material. */
|
|
818
|
+
/** @description A one-time hosted authorization link for a new connection. Contains no credential material. */
|
|
813
819
|
201: {
|
|
814
820
|
headers: {
|
|
815
821
|
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
@@ -828,12 +834,12 @@ export interface paths {
|
|
|
828
834
|
/** @description Poll handle for GET /v1/accounts/connect-sessions/{session_id}. */
|
|
829
835
|
session_id?: string;
|
|
830
836
|
expires_at?: string;
|
|
831
|
-
|
|
832
|
-
|
|
837
|
+
/** @description The seat the new account will fill. */
|
|
838
|
+
seat_id?: string;
|
|
833
839
|
};
|
|
834
840
|
};
|
|
835
841
|
};
|
|
836
|
-
/** @description Invalid request — missing
|
|
842
|
+
/** @description Invalid request — missing or invalid seat_id. */
|
|
837
843
|
400: {
|
|
838
844
|
headers: {
|
|
839
845
|
[name: string]: unknown;
|
|
@@ -851,7 +857,133 @@ export interface paths {
|
|
|
851
857
|
"application/json": components["schemas"]["Error"];
|
|
852
858
|
};
|
|
853
859
|
};
|
|
854
|
-
/** @description The referenced seat
|
|
860
|
+
/** @description The referenced seat was not found. */
|
|
861
|
+
404: {
|
|
862
|
+
headers: {
|
|
863
|
+
[name: string]: unknown;
|
|
864
|
+
};
|
|
865
|
+
content: {
|
|
866
|
+
"application/json": components["schemas"]["Error"];
|
|
867
|
+
};
|
|
868
|
+
};
|
|
869
|
+
/** @description Rate limited — slow down and retry after the hinted delay. */
|
|
870
|
+
429: {
|
|
871
|
+
headers: {
|
|
872
|
+
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
873
|
+
RateLimit: components["headers"]["RateLimit"];
|
|
874
|
+
"Retry-After": components["headers"]["Retry-After"];
|
|
875
|
+
[name: string]: unknown;
|
|
876
|
+
};
|
|
877
|
+
content: {
|
|
878
|
+
"application/json": components["schemas"]["Error"];
|
|
879
|
+
};
|
|
880
|
+
};
|
|
881
|
+
/** @description Internal error. */
|
|
882
|
+
500: {
|
|
883
|
+
headers: {
|
|
884
|
+
[name: string]: unknown;
|
|
885
|
+
};
|
|
886
|
+
content: {
|
|
887
|
+
"application/json": components["schemas"]["Error"];
|
|
888
|
+
};
|
|
889
|
+
};
|
|
890
|
+
/** @description A temporary error occurred. Please try again. */
|
|
891
|
+
502: {
|
|
892
|
+
headers: {
|
|
893
|
+
[name: string]: unknown;
|
|
894
|
+
};
|
|
895
|
+
content: {
|
|
896
|
+
"application/json": components["schemas"]["Error"];
|
|
897
|
+
};
|
|
898
|
+
};
|
|
899
|
+
/** @description Service unavailable. */
|
|
900
|
+
503: {
|
|
901
|
+
headers: {
|
|
902
|
+
[name: string]: unknown;
|
|
903
|
+
};
|
|
904
|
+
content: {
|
|
905
|
+
"application/json": components["schemas"]["Error"];
|
|
906
|
+
};
|
|
907
|
+
};
|
|
908
|
+
/** @description Gateway timeout. */
|
|
909
|
+
504: {
|
|
910
|
+
headers: {
|
|
911
|
+
[name: string]: unknown;
|
|
912
|
+
};
|
|
913
|
+
content: {
|
|
914
|
+
"application/json": components["schemas"]["Error"];
|
|
915
|
+
};
|
|
916
|
+
};
|
|
917
|
+
};
|
|
918
|
+
};
|
|
919
|
+
delete?: never;
|
|
920
|
+
options?: never;
|
|
921
|
+
head?: never;
|
|
922
|
+
patch?: never;
|
|
923
|
+
trace?: never;
|
|
924
|
+
};
|
|
925
|
+
"/v1/accounts/{account_id}/reconnect-link": {
|
|
926
|
+
parameters: {
|
|
927
|
+
query?: never;
|
|
928
|
+
header?: never;
|
|
929
|
+
path?: never;
|
|
930
|
+
cookie?: never;
|
|
931
|
+
};
|
|
932
|
+
get?: never;
|
|
933
|
+
put?: never;
|
|
934
|
+
/**
|
|
935
|
+
* Generate a hosted re-authorization link
|
|
936
|
+
* @description Mint a one-time hosted URL the end user opens to re-authorize an EXISTING connected account in place (same account_id, same seat) after it became disconnected. Credentials land server-side and never transit the API or LLM context. `expires_in_seconds` (60–3600, default 900) and `redirect_url` are optional. For a brand-new connection, use POST /v1/accounts/connect-link instead.
|
|
937
|
+
*/
|
|
938
|
+
post: {
|
|
939
|
+
parameters: {
|
|
940
|
+
query?: never;
|
|
941
|
+
header?: never;
|
|
942
|
+
path: {
|
|
943
|
+
/** @description The account ID (`acc_…`) of the account to re-authorize. */
|
|
944
|
+
account_id: string;
|
|
945
|
+
};
|
|
946
|
+
cookie?: never;
|
|
947
|
+
};
|
|
948
|
+
requestBody: {
|
|
949
|
+
content: {
|
|
950
|
+
"application/json": {
|
|
951
|
+
/**
|
|
952
|
+
* @description Seconds until the link expires (60–3600, default 900)
|
|
953
|
+
* @default 900
|
|
954
|
+
*/
|
|
955
|
+
expires_in_seconds?: number;
|
|
956
|
+
/** @description Where the user's browser is sent after the connect flow completes. Must be an absolute https URL you control; you are responsible for its safety. Omit to return the user to a Curviate confirmation page. */
|
|
957
|
+
redirect_url?: string;
|
|
958
|
+
};
|
|
959
|
+
};
|
|
960
|
+
};
|
|
961
|
+
responses: {
|
|
962
|
+
/** @description A one-time hosted re-authorization link for an existing account. Contains no credential material. */
|
|
963
|
+
201: {
|
|
964
|
+
headers: {
|
|
965
|
+
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
966
|
+
RateLimit: components["headers"]["RateLimit"];
|
|
967
|
+
[name: string]: unknown;
|
|
968
|
+
};
|
|
969
|
+
content: {
|
|
970
|
+
"application/json": {
|
|
971
|
+
/**
|
|
972
|
+
* @description Response type discriminator.
|
|
973
|
+
* @enum {string}
|
|
974
|
+
*/
|
|
975
|
+
object?: "hosted_auth_url";
|
|
976
|
+
/** @description The hosted URL the end user opens. */
|
|
977
|
+
url?: string;
|
|
978
|
+
/** @description Poll handle for GET /v1/accounts/connect-sessions/{session_id}. */
|
|
979
|
+
session_id?: string;
|
|
980
|
+
expires_at?: string;
|
|
981
|
+
/** @description The account being re-authorized. */
|
|
982
|
+
account_id?: string;
|
|
983
|
+
};
|
|
984
|
+
};
|
|
985
|
+
};
|
|
986
|
+
/** @description No such account for this tenant. */
|
|
855
987
|
404: {
|
|
856
988
|
headers: {
|
|
857
989
|
[name: string]: unknown;
|
|
@@ -1045,7 +1177,7 @@ export interface paths {
|
|
|
1045
1177
|
put?: never;
|
|
1046
1178
|
/**
|
|
1047
1179
|
* Reconnect a LinkedIn account
|
|
1048
|
-
* @description Re-authorize an account in place (same account_id, same seat) after it became disconnected. Accepts the same auth methods and optional auth-knob set as link.
|
|
1180
|
+
* @description Re-authorize an account in place (same account_id, same seat) after it became disconnected. Accepts the same auth methods and optional auth-knob set as link. May return a 202 checkpoint challenge (resolve it via the checkpoint sub-resource) exactly like link.
|
|
1049
1181
|
*/
|
|
1050
1182
|
post: {
|
|
1051
1183
|
parameters: {
|
|
@@ -1136,7 +1268,7 @@ export interface paths {
|
|
|
1136
1268
|
};
|
|
1137
1269
|
};
|
|
1138
1270
|
};
|
|
1139
|
-
/** @description A verification challenge is required (same as link).
|
|
1271
|
+
/** @description A verification challenge is required (same as link). Resolve it via the checkpoint sub-resource (POST /v1/accounts/{account_id}/checkpoint/solve). */
|
|
1140
1272
|
202: {
|
|
1141
1273
|
headers: {
|
|
1142
1274
|
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
@@ -1152,13 +1284,18 @@ export interface paths {
|
|
|
1152
1284
|
object?: "checkpoint";
|
|
1153
1285
|
/** @enum {string} */
|
|
1154
1286
|
status?: "checkpoint_required";
|
|
1155
|
-
/** @description The (provisional) account_id to pass to
|
|
1287
|
+
/** @description The (provisional) account_id to pass to the checkpoint sub-resource (POST /v1/accounts/{account_id}/checkpoint/solve). */
|
|
1156
1288
|
account_id?: string;
|
|
1157
1289
|
/**
|
|
1158
1290
|
* @description The verification challenge LinkedIn issued.
|
|
1159
1291
|
* @enum {string}
|
|
1160
1292
|
*/
|
|
1161
|
-
challenge_type?: "otp" | "two_factor_sms" | "two_factor_app" | "mobile_app_approval";
|
|
1293
|
+
challenge_type?: "otp" | "two_factor_sms" | "two_factor_app" | "two_factor_whatsapp" | "mobile_app_approval" | "otp_or_mobile_app_approval" | "contract_selection";
|
|
1294
|
+
/** @description Contract picker options (contract_selection only). Solve with the chosen id as the code. */
|
|
1295
|
+
contracts?: {
|
|
1296
|
+
id?: string;
|
|
1297
|
+
name?: string;
|
|
1298
|
+
}[];
|
|
1162
1299
|
/** @description ISO-8601 expiry of the challenge. */
|
|
1163
1300
|
expires_at?: string;
|
|
1164
1301
|
};
|
|
@@ -1191,56 +1328,8 @@ export interface paths {
|
|
|
1191
1328
|
"application/json": components["schemas"]["Error"];
|
|
1192
1329
|
};
|
|
1193
1330
|
};
|
|
1194
|
-
/** @description
|
|
1195
|
-
|
|
1196
|
-
headers: {
|
|
1197
|
-
[name: string]: unknown;
|
|
1198
|
-
};
|
|
1199
|
-
content: {
|
|
1200
|
-
"application/json": components["schemas"]["Error"];
|
|
1201
|
-
};
|
|
1202
|
-
};
|
|
1203
|
-
/** @description Rate limited — slow down and retry after the hinted delay. */
|
|
1204
|
-
429: {
|
|
1205
|
-
headers: {
|
|
1206
|
-
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
1207
|
-
RateLimit: components["headers"]["RateLimit"];
|
|
1208
|
-
"Retry-After": components["headers"]["Retry-After"];
|
|
1209
|
-
[name: string]: unknown;
|
|
1210
|
-
};
|
|
1211
|
-
content: {
|
|
1212
|
-
"application/json": components["schemas"]["Error"];
|
|
1213
|
-
};
|
|
1214
|
-
};
|
|
1215
|
-
/** @description Internal error. */
|
|
1216
|
-
500: {
|
|
1217
|
-
headers: {
|
|
1218
|
-
[name: string]: unknown;
|
|
1219
|
-
};
|
|
1220
|
-
content: {
|
|
1221
|
-
"application/json": components["schemas"]["Error"];
|
|
1222
|
-
};
|
|
1223
|
-
};
|
|
1224
|
-
/** @description A temporary error occurred. Please try again. */
|
|
1225
|
-
502: {
|
|
1226
|
-
headers: {
|
|
1227
|
-
[name: string]: unknown;
|
|
1228
|
-
};
|
|
1229
|
-
content: {
|
|
1230
|
-
"application/json": components["schemas"]["Error"];
|
|
1231
|
-
};
|
|
1232
|
-
};
|
|
1233
|
-
/** @description Service unavailable. */
|
|
1234
|
-
503: {
|
|
1235
|
-
headers: {
|
|
1236
|
-
[name: string]: unknown;
|
|
1237
|
-
};
|
|
1238
|
-
content: {
|
|
1239
|
-
"application/json": components["schemas"]["Error"];
|
|
1240
|
-
};
|
|
1241
|
-
};
|
|
1242
|
-
/** @description Gateway timeout. */
|
|
1243
|
-
504: {
|
|
1331
|
+
/** @description This LinkedIn account is already linked. */
|
|
1332
|
+
409: {
|
|
1244
1333
|
headers: {
|
|
1245
1334
|
[name: string]: unknown;
|
|
1246
1335
|
};
|
|
@@ -1248,66 +1337,8 @@ export interface paths {
|
|
|
1248
1337
|
"application/json": components["schemas"]["Error"];
|
|
1249
1338
|
};
|
|
1250
1339
|
};
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
delete?: never;
|
|
1254
|
-
options?: never;
|
|
1255
|
-
head?: never;
|
|
1256
|
-
patch?: never;
|
|
1257
|
-
trace?: never;
|
|
1258
|
-
};
|
|
1259
|
-
"/v1/accounts/{account_id}/refresh": {
|
|
1260
|
-
parameters: {
|
|
1261
|
-
query?: never;
|
|
1262
|
-
header?: never;
|
|
1263
|
-
path?: never;
|
|
1264
|
-
cookie?: never;
|
|
1265
|
-
};
|
|
1266
|
-
get?: never;
|
|
1267
|
-
put?: never;
|
|
1268
|
-
/**
|
|
1269
|
-
* Refresh a frozen account's sources
|
|
1270
|
-
* @description Force a state re-sync to restart sources on a frozen account, without changing credentials or seat binding. Returns the current account status inline.
|
|
1271
|
-
*/
|
|
1272
|
-
post: {
|
|
1273
|
-
parameters: {
|
|
1274
|
-
query?: never;
|
|
1275
|
-
header?: never;
|
|
1276
|
-
path: {
|
|
1277
|
-
/** @description The account ID (`acc_…`) of the account to refresh. */
|
|
1278
|
-
account_id: string;
|
|
1279
|
-
};
|
|
1280
|
-
cookie?: never;
|
|
1281
|
-
};
|
|
1282
|
-
requestBody: {
|
|
1283
|
-
content: {
|
|
1284
|
-
"application/json": Record<string, never>;
|
|
1285
|
-
};
|
|
1286
|
-
};
|
|
1287
|
-
responses: {
|
|
1288
|
-
/** @description The account's sources were restarted; current status returned. */
|
|
1289
|
-
200: {
|
|
1290
|
-
headers: {
|
|
1291
|
-
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
1292
|
-
RateLimit: components["headers"]["RateLimit"];
|
|
1293
|
-
[name: string]: unknown;
|
|
1294
|
-
};
|
|
1295
|
-
content: {
|
|
1296
|
-
"application/json": {
|
|
1297
|
-
/**
|
|
1298
|
-
* @description Response type discriminator.
|
|
1299
|
-
* @enum {string}
|
|
1300
|
-
*/
|
|
1301
|
-
object?: "account";
|
|
1302
|
-
account_id?: string;
|
|
1303
|
-
/** @enum {string} */
|
|
1304
|
-
status?: "active" | "reconnect_needed" | "restricted";
|
|
1305
|
-
last_checked_at?: string;
|
|
1306
|
-
};
|
|
1307
|
-
};
|
|
1308
|
-
};
|
|
1309
|
-
/** @description No such account for this tenant. */
|
|
1310
|
-
404: {
|
|
1340
|
+
/** @description The account is restricted and cannot be re-authorized. */
|
|
1341
|
+
422: {
|
|
1311
1342
|
headers: {
|
|
1312
1343
|
[name: string]: unknown;
|
|
1313
1344
|
};
|
|
@@ -1371,7 +1402,7 @@ export interface paths {
|
|
|
1371
1402
|
patch?: never;
|
|
1372
1403
|
trace?: never;
|
|
1373
1404
|
};
|
|
1374
|
-
"/v1/accounts/
|
|
1405
|
+
"/v1/accounts/{account_id}/checkpoint/solve": {
|
|
1375
1406
|
parameters: {
|
|
1376
1407
|
query?: never;
|
|
1377
1408
|
header?: never;
|
|
@@ -1381,28 +1412,29 @@ export interface paths {
|
|
|
1381
1412
|
get?: never;
|
|
1382
1413
|
put?: never;
|
|
1383
1414
|
/**
|
|
1384
|
-
*
|
|
1385
|
-
* @description Resolve the pending verification challenge for an account by submitting the OTP / 2FA code
|
|
1415
|
+
* Solve a checkpoint verification challenge
|
|
1416
|
+
* @description Resolve the pending verification challenge for an account by submitting the code — an OTP / 2FA code, the chosen contract id (for a contract_selection challenge), or the special value TRY_ANOTHER_WAY to switch the challenge method. A chained challenge returns another 202.
|
|
1386
1417
|
*/
|
|
1387
1418
|
post: {
|
|
1388
1419
|
parameters: {
|
|
1389
1420
|
query?: never;
|
|
1390
1421
|
header?: never;
|
|
1391
|
-
path
|
|
1422
|
+
path: {
|
|
1423
|
+
/** @description The account ID (`acc_…`) whose checkpoint is mid-flight (returned with the 202 checkpoint_required response). */
|
|
1424
|
+
account_id: string;
|
|
1425
|
+
};
|
|
1392
1426
|
cookie?: never;
|
|
1393
1427
|
};
|
|
1394
1428
|
requestBody: {
|
|
1395
1429
|
content: {
|
|
1396
1430
|
"application/json": {
|
|
1397
|
-
/** @description The
|
|
1398
|
-
account_id: string;
|
|
1399
|
-
/** @description The OTP / 2FA verification code. Special value TRY_ANOTHER_WAY switches the challenge type (e.g. in-app → 2FA). */
|
|
1431
|
+
/** @description The OTP / 2FA verification code, the chosen contract id (contract_selection), or the special value TRY_ANOTHER_WAY to switch the challenge method. */
|
|
1400
1432
|
code: string;
|
|
1401
1433
|
};
|
|
1402
1434
|
};
|
|
1403
1435
|
};
|
|
1404
1436
|
responses: {
|
|
1405
|
-
/** @description The challenge was resolved; the account is now
|
|
1437
|
+
/** @description The challenge was resolved; the account is now connected. */
|
|
1406
1438
|
201: {
|
|
1407
1439
|
headers: {
|
|
1408
1440
|
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
@@ -1418,7 +1450,7 @@ export interface paths {
|
|
|
1418
1450
|
object?: "account";
|
|
1419
1451
|
account_id?: string;
|
|
1420
1452
|
/** @enum {string} */
|
|
1421
|
-
status?: "active";
|
|
1453
|
+
status?: "active" | "reconnect_needed" | "restricted" | "disconnected";
|
|
1422
1454
|
/** @description The seat this account occupies (canonical — supersedes the deprecated attached_seat_id). */
|
|
1423
1455
|
seat_id?: string | null;
|
|
1424
1456
|
/**
|
|
@@ -1426,10 +1458,12 @@ export interface paths {
|
|
|
1426
1458
|
* @description Deprecated — use seat_id (same value). Removed at the GA /v1 cutover.
|
|
1427
1459
|
*/
|
|
1428
1460
|
attached_seat_id?: string | null;
|
|
1461
|
+
/** @description Present and true only when this connect recovered an existing LinkedIn identity already present on the workspace (claiming it into your account) instead of connecting a brand-new one. Absent on a normal connect. The account's status reflects its real observed state, which may need a reconnect. */
|
|
1462
|
+
recovered?: boolean;
|
|
1429
1463
|
};
|
|
1430
1464
|
};
|
|
1431
1465
|
};
|
|
1432
|
-
/** @description A chained challenge follows (e.g. OTP -> 2FA).
|
|
1466
|
+
/** @description A chained challenge follows (e.g. OTP -> 2FA). Solve the next code at the same account's checkpoint/solve. */
|
|
1433
1467
|
202: {
|
|
1434
1468
|
headers: {
|
|
1435
1469
|
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
@@ -1445,13 +1479,18 @@ export interface paths {
|
|
|
1445
1479
|
object?: "checkpoint";
|
|
1446
1480
|
/** @enum {string} */
|
|
1447
1481
|
status?: "checkpoint_required";
|
|
1448
|
-
/** @description The (provisional) account_id to pass to
|
|
1482
|
+
/** @description The (provisional) account_id to pass to the checkpoint sub-resource (POST /v1/accounts/{account_id}/checkpoint/solve). */
|
|
1449
1483
|
account_id?: string;
|
|
1450
1484
|
/**
|
|
1451
1485
|
* @description The verification challenge LinkedIn issued.
|
|
1452
1486
|
* @enum {string}
|
|
1453
1487
|
*/
|
|
1454
|
-
challenge_type?: "otp" | "two_factor_sms" | "two_factor_app" | "mobile_app_approval";
|
|
1488
|
+
challenge_type?: "otp" | "two_factor_sms" | "two_factor_app" | "two_factor_whatsapp" | "mobile_app_approval" | "otp_or_mobile_app_approval" | "contract_selection";
|
|
1489
|
+
/** @description Contract picker options (contract_selection only). Solve with the chosen id as the code. */
|
|
1490
|
+
contracts?: {
|
|
1491
|
+
id?: string;
|
|
1492
|
+
name?: string;
|
|
1493
|
+
}[];
|
|
1455
1494
|
/** @description ISO-8601 expiry of the challenge. */
|
|
1456
1495
|
expires_at?: string;
|
|
1457
1496
|
};
|
|
@@ -1540,7 +1579,7 @@ export interface paths {
|
|
|
1540
1579
|
patch?: never;
|
|
1541
1580
|
trace?: never;
|
|
1542
1581
|
};
|
|
1543
|
-
"/v1/accounts/
|
|
1582
|
+
"/v1/accounts/{account_id}/checkpoint/request": {
|
|
1544
1583
|
parameters: {
|
|
1545
1584
|
query?: never;
|
|
1546
1585
|
header?: never;
|
|
@@ -1550,22 +1589,22 @@ export interface paths {
|
|
|
1550
1589
|
get?: never;
|
|
1551
1590
|
put?: never;
|
|
1552
1591
|
/**
|
|
1553
|
-
*
|
|
1554
|
-
* @description Re-
|
|
1592
|
+
* Re-request a checkpoint verification notification
|
|
1593
|
+
* @description Re-issue the pending verification challenge notification for an account. Meaningful for code-delivery challenges (otp / two_factor_sms / mobile_app_approval); a two_factor_app challenge has nothing to re-request (the code is generated on the device) and returns resent:false rather than an error — the response never claims a re-send that did not happen. Does not reset the checkpoint's expiry.
|
|
1555
1594
|
*/
|
|
1556
1595
|
post: {
|
|
1557
1596
|
parameters: {
|
|
1558
1597
|
query?: never;
|
|
1559
1598
|
header?: never;
|
|
1560
|
-
path
|
|
1599
|
+
path: {
|
|
1600
|
+
/** @description The account ID (`acc_…`) whose pending checkpoint notification should be re-issued. */
|
|
1601
|
+
account_id: string;
|
|
1602
|
+
};
|
|
1561
1603
|
cookie?: never;
|
|
1562
1604
|
};
|
|
1563
1605
|
requestBody: {
|
|
1564
1606
|
content: {
|
|
1565
|
-
"application/json":
|
|
1566
|
-
/** @description The account whose pending checkpoint notification should be re-sent (returned with the 202 checkpoint_required response, or from link/poll). */
|
|
1567
|
-
account_id: string;
|
|
1568
|
-
};
|
|
1607
|
+
"application/json": Record<string, never>;
|
|
1569
1608
|
};
|
|
1570
1609
|
};
|
|
1571
1610
|
responses: {
|
|
@@ -1671,7 +1710,7 @@ export interface paths {
|
|
|
1671
1710
|
patch?: never;
|
|
1672
1711
|
trace?: never;
|
|
1673
1712
|
};
|
|
1674
|
-
"/v1/accounts/
|
|
1713
|
+
"/v1/accounts/{account_id}/checkpoint/poll": {
|
|
1675
1714
|
parameters: {
|
|
1676
1715
|
query?: never;
|
|
1677
1716
|
header?: never;
|
|
@@ -1682,21 +1721,21 @@ export interface paths {
|
|
|
1682
1721
|
put?: never;
|
|
1683
1722
|
/**
|
|
1684
1723
|
* Poll a mobile-app-approval checkpoint
|
|
1685
|
-
* @description Poll the pending mobile-app-approval challenge for an account to check whether the user has approved the sign-in on their LinkedIn mobile app.
|
|
1724
|
+
* @description Poll the pending mobile-app-approval challenge for an account to check whether the user has approved the sign-in on their LinkedIn mobile app. There is no code to submit — approve on the phone, then poll. Returns status:"pending" while waiting, status:"active" once approved, or status:"expired"/"failed" on timeout/failure. Valid for mobile_app_approval and the in-app branch of otp_or_mobile_app_approval — use solve for code-based challenges.
|
|
1686
1725
|
*/
|
|
1687
1726
|
post: {
|
|
1688
1727
|
parameters: {
|
|
1689
1728
|
query?: never;
|
|
1690
1729
|
header?: never;
|
|
1691
|
-
path
|
|
1730
|
+
path: {
|
|
1731
|
+
/** @description The account ID (`acc_…`) whose mobile-app-approval connect is mid-flight (returned with the 202 checkpoint_required response). */
|
|
1732
|
+
account_id: string;
|
|
1733
|
+
};
|
|
1692
1734
|
cookie?: never;
|
|
1693
1735
|
};
|
|
1694
1736
|
requestBody: {
|
|
1695
1737
|
content: {
|
|
1696
|
-
"application/json":
|
|
1697
|
-
/** @description The account whose mobile-app-approval connect is mid-flight (returned with the 202 checkpoint_required response). */
|
|
1698
|
-
account_id: string;
|
|
1699
|
-
};
|
|
1738
|
+
"application/json": Record<string, never>;
|
|
1700
1739
|
};
|
|
1701
1740
|
};
|
|
1702
1741
|
responses: {
|
|
@@ -1731,6 +1770,13 @@ export interface paths {
|
|
|
1731
1770
|
attached_seat_id?: string | null;
|
|
1732
1771
|
/** @description ISO-8601 expiry. Present on status:"pending". */
|
|
1733
1772
|
expires_at?: string;
|
|
1773
|
+
/**
|
|
1774
|
+
* @description Machine-readable challenge discriminator. Present on status:"expired" so a client can render the right recovery guidance without parsing prose.
|
|
1775
|
+
* @enum {string}
|
|
1776
|
+
*/
|
|
1777
|
+
challenge_type?: "mobile_app_approval";
|
|
1778
|
+
/** @description Human-readable, actionable next step when the approval timed out. Present on status:"expired". */
|
|
1779
|
+
recovery_hint?: string;
|
|
1734
1780
|
};
|
|
1735
1781
|
};
|
|
1736
1782
|
};
|
|
@@ -2897,7 +2943,7 @@ export interface paths {
|
|
|
2897
2943
|
"application/json": components["schemas"]["Error"];
|
|
2898
2944
|
};
|
|
2899
2945
|
};
|
|
2900
|
-
/** @description
|
|
2946
|
+
/** @description The account does not have the required Core seat. */
|
|
2901
2947
|
403: {
|
|
2902
2948
|
headers: {
|
|
2903
2949
|
[name: string]: unknown;
|
|
@@ -2906,7 +2952,7 @@ export interface paths {
|
|
|
2906
2952
|
"application/json": components["schemas"]["Error"];
|
|
2907
2953
|
};
|
|
2908
2954
|
};
|
|
2909
|
-
/** @description
|
|
2955
|
+
/** @description Company not found, or you do not administer this company's page. */
|
|
2910
2956
|
404: {
|
|
2911
2957
|
headers: {
|
|
2912
2958
|
[name: string]: unknown;
|
|
@@ -16571,7 +16617,7 @@ export interface paths {
|
|
|
16571
16617
|
value: string;
|
|
16572
16618
|
}[];
|
|
16573
16619
|
/** @description Messaging events to subscribe to (default: [message.received]) */
|
|
16574
|
-
events?: ("message.received" | "message.delivered" | "message.read" | "message.reaction" | "message.edited" | "message.deleted")[];
|
|
16620
|
+
events?: ("message.received" | "message.delivered" | "message.read" | "message.reaction" | "message.edited" | "message.deleted" | "chat.updated" | "chat.deleted")[];
|
|
16575
16621
|
/**
|
|
16576
16622
|
* @description Field-remapping keys for the messaging delivery payload
|
|
16577
16623
|
* @default []
|
|
@@ -16606,7 +16652,7 @@ export interface paths {
|
|
|
16606
16652
|
value: string;
|
|
16607
16653
|
}[];
|
|
16608
16654
|
/** @description User/relation events to subscribe to (default: [connection.accepted]) */
|
|
16609
|
-
events?: "connection.accepted"[];
|
|
16655
|
+
events?: ("connection.accepted" | "connection.new")[];
|
|
16610
16656
|
/**
|
|
16611
16657
|
* @description Field-remapping keys for the user/relation delivery payload
|
|
16612
16658
|
* @default []
|
|
@@ -16641,7 +16687,7 @@ export interface paths {
|
|
|
16641
16687
|
value: string;
|
|
16642
16688
|
}[];
|
|
16643
16689
|
/** @description Account-status events to subscribe to (default: all 7) */
|
|
16644
|
-
events?: ("account.created" | "account.connected" | "account.synced" | "account.reconnected" | "account.reconnect_needed" | "account.creation_failed" | "account.disconnected" | "account.error" | "account.paused" | "account.connecting" | "account.permission_revoked")[];
|
|
16690
|
+
events?: ("account.created" | "account.connected" | "account.synced" | "account.reconnected" | "account.reconnect_needed" | "account.creation_failed" | "account.disconnected" | "account.error" | "account.paused" | "account.connecting" | "account.permission_revoked" | "account.initial_sync.running" | "account.initial_sync.completed" | "account.initial_sync.failed")[];
|
|
16645
16691
|
};
|
|
16646
16692
|
};
|
|
16647
16693
|
};
|
|
@@ -16763,7 +16809,7 @@ export interface paths {
|
|
|
16763
16809
|
};
|
|
16764
16810
|
/**
|
|
16765
16811
|
* List webhook event types
|
|
16766
|
-
* @description Returns the complete canonical event catalogue (
|
|
16812
|
+
* @description Returns the complete canonical event catalogue (27 events) grouped by source: messaging (8), user (2), account_status (14), plus 3 tier-gated events. No quota consumed.
|
|
16767
16813
|
*/
|
|
16768
16814
|
get: {
|
|
16769
16815
|
parameters: {
|
|
@@ -16805,6 +16851,11 @@ export interface paths {
|
|
|
16805
16851
|
* @enum {string}
|
|
16806
16852
|
*/
|
|
16807
16853
|
tier?: "recruiter" | "sales_nav";
|
|
16854
|
+
/**
|
|
16855
|
+
* @description Delivery timing. Omitted (equivalent to 'realtime') on every live-pushed event. 'no_longer_realtime' means no push exists for this event; 'not_realtime' means the event is polled, not pushed, and may lag the underlying LinkedIn event.
|
|
16856
|
+
* @enum {string}
|
|
16857
|
+
*/
|
|
16858
|
+
availability?: "realtime" | "no_longer_realtime" | "not_realtime";
|
|
16808
16859
|
}[];
|
|
16809
16860
|
}[];
|
|
16810
16861
|
};
|
|
@@ -16848,7 +16899,113 @@ export interface paths {
|
|
|
16848
16899
|
path?: never;
|
|
16849
16900
|
cookie?: never;
|
|
16850
16901
|
};
|
|
16851
|
-
|
|
16902
|
+
/**
|
|
16903
|
+
* Get a webhook
|
|
16904
|
+
* @description Returns a single webhook owned by the calling tenant. The plaintext secret is never present on a read — only the prefix.
|
|
16905
|
+
*/
|
|
16906
|
+
get: {
|
|
16907
|
+
parameters: {
|
|
16908
|
+
query?: never;
|
|
16909
|
+
header?: never;
|
|
16910
|
+
path: {
|
|
16911
|
+
/** @description Webhook id (wh_-prefixed ULID). */
|
|
16912
|
+
id: string;
|
|
16913
|
+
};
|
|
16914
|
+
cookie?: never;
|
|
16915
|
+
};
|
|
16916
|
+
requestBody?: never;
|
|
16917
|
+
responses: {
|
|
16918
|
+
/** @description The webhook, if owned by the calling tenant. The signing secret is never returned on a read — only the prefix. */
|
|
16919
|
+
200: {
|
|
16920
|
+
headers: {
|
|
16921
|
+
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
16922
|
+
RateLimit: components["headers"]["RateLimit"];
|
|
16923
|
+
[name: string]: unknown;
|
|
16924
|
+
};
|
|
16925
|
+
content: {
|
|
16926
|
+
"application/json": {
|
|
16927
|
+
/**
|
|
16928
|
+
* @description Response type discriminator.
|
|
16929
|
+
* @enum {string}
|
|
16930
|
+
*/
|
|
16931
|
+
object?: "webhook";
|
|
16932
|
+
/** @description Webhook id (wh_-prefixed ULID). */
|
|
16933
|
+
id?: string;
|
|
16934
|
+
/**
|
|
16935
|
+
* @description The event source this webhook subscribes to (immutable).
|
|
16936
|
+
* @enum {string}
|
|
16937
|
+
*/
|
|
16938
|
+
source?: "messaging" | "user" | "account_status";
|
|
16939
|
+
/** @description The URL that receives delivery POST requests. */
|
|
16940
|
+
request_url?: string;
|
|
16941
|
+
/** @description Human-readable label. */
|
|
16942
|
+
name?: string | null;
|
|
16943
|
+
/**
|
|
16944
|
+
* @description Delivery body encoding.
|
|
16945
|
+
* @enum {string}
|
|
16946
|
+
*/
|
|
16947
|
+
format?: "json" | "form";
|
|
16948
|
+
/** @description Accounts targeted by this webhook. Non-empty — each id is owned by the tenant. */
|
|
16949
|
+
account_ids?: string[];
|
|
16950
|
+
/** @description A disabled webhook is kept but delivers nothing. */
|
|
16951
|
+
enabled?: boolean;
|
|
16952
|
+
/** @description Custom headers added to each delivery POST. */
|
|
16953
|
+
headers?: {
|
|
16954
|
+
key?: string;
|
|
16955
|
+
value?: string;
|
|
16956
|
+
}[];
|
|
16957
|
+
/** @description Canonical event names this webhook subscribes to. */
|
|
16958
|
+
events?: string[];
|
|
16959
|
+
/** @description Field-remapping keys for the delivery payload (messaging and user sources only). */
|
|
16960
|
+
data?: string[];
|
|
16961
|
+
/** @description First 8 characters of the signing secret. The full secret is never returned on edit — it is preserved unchanged. */
|
|
16962
|
+
secret_prefix?: string;
|
|
16963
|
+
/** @description ISO-8601 creation timestamp. */
|
|
16964
|
+
created_at?: string;
|
|
16965
|
+
};
|
|
16966
|
+
};
|
|
16967
|
+
};
|
|
16968
|
+
/** @description Malformed or empty webhook id. */
|
|
16969
|
+
400: {
|
|
16970
|
+
headers: {
|
|
16971
|
+
[name: string]: unknown;
|
|
16972
|
+
};
|
|
16973
|
+
content: {
|
|
16974
|
+
"application/json": components["schemas"]["Error"];
|
|
16975
|
+
};
|
|
16976
|
+
};
|
|
16977
|
+
/** @description Missing or invalid API key. */
|
|
16978
|
+
401: {
|
|
16979
|
+
headers: {
|
|
16980
|
+
[name: string]: unknown;
|
|
16981
|
+
};
|
|
16982
|
+
content: {
|
|
16983
|
+
"application/json": components["schemas"]["Error"];
|
|
16984
|
+
};
|
|
16985
|
+
};
|
|
16986
|
+
/** @description Webhook not found or not owned by this tenant. */
|
|
16987
|
+
404: {
|
|
16988
|
+
headers: {
|
|
16989
|
+
[name: string]: unknown;
|
|
16990
|
+
};
|
|
16991
|
+
content: {
|
|
16992
|
+
"application/json": components["schemas"]["Error"];
|
|
16993
|
+
};
|
|
16994
|
+
};
|
|
16995
|
+
/** @description Rate limited — slow down and retry after the hinted delay. */
|
|
16996
|
+
429: {
|
|
16997
|
+
headers: {
|
|
16998
|
+
"RateLimit-Policy": components["headers"]["RateLimit-Policy"];
|
|
16999
|
+
RateLimit: components["headers"]["RateLimit"];
|
|
17000
|
+
"Retry-After": components["headers"]["Retry-After"];
|
|
17001
|
+
[name: string]: unknown;
|
|
17002
|
+
};
|
|
17003
|
+
content: {
|
|
17004
|
+
"application/json": components["schemas"]["Error"];
|
|
17005
|
+
};
|
|
17006
|
+
};
|
|
17007
|
+
};
|
|
17008
|
+
};
|
|
16852
17009
|
put?: never;
|
|
16853
17010
|
post?: never;
|
|
16854
17011
|
/**
|
|
@@ -16951,7 +17108,7 @@ export interface paths {
|
|
|
16951
17108
|
/** @description Replace the delivery URL. Must be an HTTPS URL. */
|
|
16952
17109
|
request_url?: string;
|
|
16953
17110
|
/** @description Replace the human-readable name (1–100 chars), or null to clear it. */
|
|
16954
|
-
name?: string;
|
|
17111
|
+
name?: string | null;
|
|
16955
17112
|
/** @description Enable or disable the webhook. A disabled webhook delivers nothing. */
|
|
16956
17113
|
enabled?: boolean;
|
|
16957
17114
|
/** @description Replace the custom headers added to each delivery POST (whole-array). */
|