@linqapp/sdk 0.9.0 → 0.11.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.
Files changed (74) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/README.md +1 -1
  3. package/client.d.mts +16 -4
  4. package/client.d.mts.map +1 -1
  5. package/client.d.ts +16 -4
  6. package/client.d.ts.map +1 -1
  7. package/client.js +11 -0
  8. package/client.js.map +1 -1
  9. package/client.mjs +11 -0
  10. package/client.mjs.map +1 -1
  11. package/package.json +1 -1
  12. package/resources/capability.d.mts +17 -14
  13. package/resources/capability.d.mts.map +1 -1
  14. package/resources/capability.d.ts +17 -14
  15. package/resources/capability.d.ts.map +1 -1
  16. package/resources/capability.js +8 -6
  17. package/resources/capability.js.map +1 -1
  18. package/resources/capability.mjs +8 -6
  19. package/resources/capability.mjs.map +1 -1
  20. package/resources/chats/chats.d.mts +45 -37
  21. package/resources/chats/chats.d.mts.map +1 -1
  22. package/resources/chats/chats.d.ts +45 -37
  23. package/resources/chats/chats.d.ts.map +1 -1
  24. package/resources/chats/chats.js +25 -0
  25. package/resources/chats/chats.js.map +1 -1
  26. package/resources/chats/chats.mjs +25 -0
  27. package/resources/chats/chats.mjs.map +1 -1
  28. package/resources/chats/index.d.mts +1 -1
  29. package/resources/chats/index.d.mts.map +1 -1
  30. package/resources/chats/index.d.ts +1 -1
  31. package/resources/chats/index.d.ts.map +1 -1
  32. package/resources/chats/index.js.map +1 -1
  33. package/resources/chats/index.mjs.map +1 -1
  34. package/resources/contact-card.d.mts +144 -0
  35. package/resources/contact-card.d.mts.map +1 -0
  36. package/resources/contact-card.d.ts +144 -0
  37. package/resources/contact-card.d.ts.map +1 -0
  38. package/resources/contact-card.js +73 -0
  39. package/resources/contact-card.js.map +1 -0
  40. package/resources/contact-card.mjs +69 -0
  41. package/resources/contact-card.mjs.map +1 -0
  42. package/resources/index.d.mts +3 -2
  43. package/resources/index.d.mts.map +1 -1
  44. package/resources/index.d.ts +3 -2
  45. package/resources/index.d.ts.map +1 -1
  46. package/resources/index.js +3 -1
  47. package/resources/index.js.map +1 -1
  48. package/resources/index.mjs +1 -0
  49. package/resources/index.mjs.map +1 -1
  50. package/resources/shared.d.mts +17 -19
  51. package/resources/shared.d.mts.map +1 -1
  52. package/resources/shared.d.ts +17 -19
  53. package/resources/shared.d.ts.map +1 -1
  54. package/resources/webhooks.d.mts +1 -19
  55. package/resources/webhooks.d.mts.map +1 -1
  56. package/resources/webhooks.d.ts +1 -19
  57. package/resources/webhooks.d.ts.map +1 -1
  58. package/src/client.ts +36 -4
  59. package/src/resources/capability.ts +18 -15
  60. package/src/resources/chats/chats.ts +54 -41
  61. package/src/resources/chats/index.ts +2 -0
  62. package/src/resources/contact-card.ts +185 -0
  63. package/src/resources/index.ts +12 -2
  64. package/src/resources/shared.ts +20 -22
  65. package/src/resources/webhooks.ts +1 -22
  66. package/src/version.ts +1 -1
  67. package/version.d.mts +1 -1
  68. package/version.d.mts.map +1 -1
  69. package/version.d.ts +1 -1
  70. package/version.d.ts.map +1 -1
  71. package/version.js +1 -1
  72. package/version.js.map +1 -1
  73. package/version.mjs +1 -1
  74. package/version.mjs.map +1 -1
@@ -0,0 +1,144 @@
1
+ import { APIResource } from "../core/resource.mjs";
2
+ import { APIPromise } from "../core/api-promise.mjs";
3
+ import { RequestOptions } from "../internal/request-options.mjs";
4
+ /**
5
+ * Contact Card lets you set and share your contact information (name and profile photo) with chat participants via iMessage Name and Photo Sharing.
6
+ *
7
+ * Use `POST /v3/contact_card` to create or update a card for a phone number.
8
+ * Use `PATCH /v3/contact_card` to update an existing active card.
9
+ * Use `GET /v3/contact_card` to retrieve the active card(s) for your partner account.
10
+ */
11
+ export declare class ContactCard extends APIResource {
12
+ /**
13
+ * Creates a contact card for a phone number.
14
+ *
15
+ * The contact card is stored in an inactive state first. Once it's applied
16
+ * successfully, it is activated and `is_active` is returned as `true`. On failure,
17
+ * `is_active` is `false`.
18
+ *
19
+ * @example
20
+ * ```ts
21
+ * const setContactCard = await client.contactCard.create({
22
+ * first_name: 'John',
23
+ * phone_number: '+15551234567',
24
+ * image_url:
25
+ * 'https://cdn.linqapp.com/contact-card/example.jpg',
26
+ * last_name: 'Doe',
27
+ * });
28
+ * ```
29
+ */
30
+ create(body: ContactCardCreateParams, options?: RequestOptions): APIPromise<SetContactCard>;
31
+ /**
32
+ * Returns the contact card for a specific phone number, or all contact cards for
33
+ * the authenticated partner if no `phone_number` is provided.
34
+ *
35
+ * @example
36
+ * ```ts
37
+ * const contactCard = await client.contactCard.retrieve();
38
+ * ```
39
+ */
40
+ retrieve(query?: ContactCardRetrieveParams | null | undefined, options?: RequestOptions): APIPromise<ContactCardRetrieveResponse>;
41
+ /**
42
+ * Partially updates an existing active contact card for a phone number.
43
+ *
44
+ * Fetches the current active contact card and merges the provided fields. Only
45
+ * fields present in the request body are updated; omitted fields retain their
46
+ * existing values.
47
+ *
48
+ * Requires an active contact card to exist for the phone number.
49
+ *
50
+ * @example
51
+ * ```ts
52
+ * const setContactCard = await client.contactCard.update({
53
+ * phone_number: '+15551234567',
54
+ * first_name: 'John',
55
+ * image_url:
56
+ * 'https://cdn.linqapp.com/contact-card/example.jpg',
57
+ * last_name: 'Doe',
58
+ * });
59
+ * ```
60
+ */
61
+ update(params: ContactCardUpdateParams, options?: RequestOptions): APIPromise<SetContactCard>;
62
+ }
63
+ export interface SetContactCard {
64
+ /**
65
+ * First name on the contact card
66
+ */
67
+ first_name: string;
68
+ /**
69
+ * Whether the contact card was successfully applied to the device
70
+ */
71
+ is_active: boolean;
72
+ /**
73
+ * The phone number the contact card is associated with
74
+ */
75
+ phone_number: string;
76
+ /**
77
+ * Image URL on the contact card
78
+ */
79
+ image_url?: string;
80
+ /**
81
+ * Last name on the contact card
82
+ */
83
+ last_name?: string;
84
+ }
85
+ export interface ContactCardRetrieveResponse {
86
+ contact_cards: Array<ContactCardRetrieveResponse.ContactCard>;
87
+ }
88
+ export declare namespace ContactCardRetrieveResponse {
89
+ interface ContactCard {
90
+ first_name: string;
91
+ is_active: boolean;
92
+ phone_number: string;
93
+ image_url?: string;
94
+ last_name?: string;
95
+ }
96
+ }
97
+ export interface ContactCardCreateParams {
98
+ /**
99
+ * First name for the contact card. Required.
100
+ */
101
+ first_name: string;
102
+ /**
103
+ * E.164 phone number to associate the contact card with
104
+ */
105
+ phone_number: string;
106
+ /**
107
+ * URL of the profile image to rehost on the CDN. Only re-uploaded when a new value
108
+ * is provided.
109
+ */
110
+ image_url?: string;
111
+ /**
112
+ * Last name for the contact card. Optional.
113
+ */
114
+ last_name?: string;
115
+ }
116
+ export interface ContactCardRetrieveParams {
117
+ /**
118
+ * E.164 phone number to filter by. If omitted, all my cards for the partner are
119
+ * returned.
120
+ */
121
+ phone_number?: string;
122
+ }
123
+ export interface ContactCardUpdateParams {
124
+ /**
125
+ * Query param: E.164 phone number of the contact card to update
126
+ */
127
+ phone_number: string;
128
+ /**
129
+ * Body param: Updated first name. If omitted, the existing value is kept.
130
+ */
131
+ first_name?: string;
132
+ /**
133
+ * Body param: Updated profile image URL. If omitted, the existing image is kept.
134
+ */
135
+ image_url?: string;
136
+ /**
137
+ * Body param: Updated last name. If omitted, the existing value is kept.
138
+ */
139
+ last_name?: string;
140
+ }
141
+ export declare namespace ContactCard {
142
+ export { type SetContactCard as SetContactCard, type ContactCardRetrieveResponse as ContactCardRetrieveResponse, type ContactCardCreateParams as ContactCardCreateParams, type ContactCardRetrieveParams as ContactCardRetrieveParams, type ContactCardUpdateParams as ContactCardUpdateParams, };
143
+ }
144
+ //# sourceMappingURL=contact-card.d.mts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contact-card.d.mts","sourceRoot":"","sources":["../src/resources/contact-card.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB;;;;;;GAMG;AACH,qBAAa,WAAY,SAAQ,WAAW;IAC1C;;;;;;;;;;;;;;;;;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AY,CAAC,EAAE,MAAM,CAAC;CACvB;AAED,MAAM,WAAW,uBAAuB;IACtC;;OAEG;IACH,YAAY,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,UAAU,CAAC,EAAE,MAAM,CAAC;IAEpB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,CAAC,OAAO,WAAW,WAAW,CAAC;IACnC,OAAO,EACL,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,uBAAuB,IAAI,uBAAuB,GACxD,CAAC;CACH"}
@@ -0,0 +1,144 @@
1
+ import { APIResource } from "../core/resource.js";
2
+ import { APIPromise } from "../core/api-promise.js";
3
+ import { RequestOptions } from "../internal/request-options.js";
4
+ /**
5
+ * Contact Card lets you set and share your contact information (name and profile photo) with chat participants via iMessage Name and Photo Sharing.
6
+ *
7
+ * Use `POST /v3/contact_card` to create or update a card for a phone number.
8
+ * Use `PATCH /v3/contact_card` to update an existing active card.
9
+ * Use `GET /v3/contact_card` to retrieve the active card(s) for your partner account.
10
+ */
11
+ export declare class ContactCard extends APIResource {
12
+ /**
13
+ * Creates a contact card for a phone number.
14
+ *
15
+ * The contact card is stored in an inactive state first. Once it's applied
16
+ * successfully, it is activated and `is_active` is returned as `true`. On failure,
17
+ * `is_active` is `false`.
18
+ *
19
+ * @example
20
+ * ```ts
21
+ * const setContactCard = await client.contactCard.create({
22
+ * first_name: 'John',
23
+ * phone_number: '+15551234567',
24
+ * image_url:
25
+ * 'https://cdn.linqapp.com/contact-card/example.jpg',
26
+ * last_name: 'Doe',
27
+ * });
28
+ * ```
29
+ */
30
+ create(body: ContactCardCreateParams, options?: RequestOptions): APIPromise<SetContactCard>;
31
+ /**
32
+ * Returns the contact card for a specific phone number, or all contact cards for
33
+ * the authenticated partner if no `phone_number` is provided.
34
+ *
35
+ * @example
36
+ * ```ts
37
+ * const contactCard = await client.contactCard.retrieve();
38
+ * ```
39
+ */
40
+ retrieve(query?: ContactCardRetrieveParams | null | undefined, options?: RequestOptions): APIPromise<ContactCardRetrieveResponse>;
41
+ /**
42
+ * Partially updates an existing active contact card for a phone number.
43
+ *
44
+ * Fetches the current active contact card and merges the provided fields. Only
45
+ * fields present in the request body are updated; omitted fields retain their
46
+ * existing values.
47
+ *
48
+ * Requires an active contact card to exist for the phone number.
49
+ *
50
+ * @example
51
+ * ```ts
52
+ * const setContactCard = await client.contactCard.update({
53
+ * phone_number: '+15551234567',
54
+ * first_name: 'John',
55
+ * image_url:
56
+ * 'https://cdn.linqapp.com/contact-card/example.jpg',
57
+ * last_name: 'Doe',
58
+ * });
59
+ * ```
60
+ */
61
+ update(params: ContactCardUpdateParams, options?: RequestOptions): APIPromise<SetContactCard>;
62
+ }
63
+ export interface SetContactCard {
64
+ /**
65
+ * First name on the contact card
66
+ */
67
+ first_name: string;
68
+ /**
69
+ * Whether the contact card was successfully applied to the device
70
+ */
71
+ is_active: boolean;
72
+ /**
73
+ * The phone number the contact card is associated with
74
+ */
75
+ phone_number: string;
76
+ /**
77
+ * Image URL on the contact card
78
+ */
79
+ image_url?: string;
80
+ /**
81
+ * Last name on the contact card
82
+ */
83
+ last_name?: string;
84
+ }
85
+ export interface ContactCardRetrieveResponse {
86
+ contact_cards: Array<ContactCardRetrieveResponse.ContactCard>;
87
+ }
88
+ export declare namespace ContactCardRetrieveResponse {
89
+ interface ContactCard {
90
+ first_name: string;
91
+ is_active: boolean;
92
+ phone_number: string;
93
+ image_url?: string;
94
+ last_name?: string;
95
+ }
96
+ }
97
+ export interface ContactCardCreateParams {
98
+ /**
99
+ * First name for the contact card. Required.
100
+ */
101
+ first_name: string;
102
+ /**
103
+ * E.164 phone number to associate the contact card with
104
+ */
105
+ phone_number: string;
106
+ /**
107
+ * URL of the profile image to rehost on the CDN. Only re-uploaded when a new value
108
+ * is provided.
109
+ */
110
+ image_url?: string;
111
+ /**
112
+ * Last name for the contact card. Optional.
113
+ */
114
+ last_name?: string;
115
+ }
116
+ export interface ContactCardRetrieveParams {
117
+ /**
118
+ * E.164 phone number to filter by. If omitted, all my cards for the partner are
119
+ * returned.
120
+ */
121
+ phone_number?: string;
122
+ }
123
+ export interface ContactCardUpdateParams {
124
+ /**
125
+ * Query param: E.164 phone number of the contact card to update
126
+ */
127
+ phone_number: string;
128
+ /**
129
+ * Body param: Updated first name. If omitted, the existing value is kept.
130
+ */
131
+ first_name?: string;
132
+ /**
133
+ * Body param: Updated profile image URL. If omitted, the existing image is kept.
134
+ */
135
+ image_url?: string;
136
+ /**
137
+ * Body param: Updated last name. If omitted, the existing value is kept.
138
+ */
139
+ last_name?: string;
140
+ }
141
+ export declare namespace ContactCard {
142
+ export { type SetContactCard as SetContactCard, type ContactCardRetrieveResponse as ContactCardRetrieveResponse, type ContactCardCreateParams as ContactCardCreateParams, type ContactCardRetrieveParams as ContactCardRetrieveParams, type ContactCardUpdateParams as ContactCardUpdateParams, };
143
+ }
144
+ //# sourceMappingURL=contact-card.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contact-card.d.ts","sourceRoot":"","sources":["../src/resources/contact-card.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,EAAE,UAAU,EAAE;OACd,EAAE,cAAc,EAAE;AAEzB;;;;;;GAMG;AACH,qBAAa,WAAY,SAAQ,WAAW;IAC1C;;;;;;;;;;;;;;;;;OAiBG;IACH,MAAM,CAAC,IAAI,EAAE,uBAAuB,EAAE,OAAO,CAAC,EAAE,cAAc,GAAG,UAAU,CAAC,cAAc,CAAC;IAI3F;;;;;;;;OAQG;IACH,QAAQ,CACN,KAAK,GAAE,yBAAyB,GAAG,IAAI,GAAG,SAAc,EACxD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,2BAA2B,CAAC;IAI1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AED,MAAM,CAAC,OAAO,WAAW,WAAW,CAAC;IACnC,OAAO,EACL,KAAK,cAAc,IAAI,cAAc,EACrC,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,uBAAuB,IAAI,uBAAuB,GACxD,CAAC;CACH"}
@@ -0,0 +1,73 @@
1
+ "use strict";
2
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.ContactCard = void 0;
5
+ const resource_1 = require("../core/resource.js");
6
+ /**
7
+ * Contact Card lets you set and share your contact information (name and profile photo) with chat participants via iMessage Name and Photo Sharing.
8
+ *
9
+ * Use `POST /v3/contact_card` to create or update a card for a phone number.
10
+ * Use `PATCH /v3/contact_card` to update an existing active card.
11
+ * Use `GET /v3/contact_card` to retrieve the active card(s) for your partner account.
12
+ */
13
+ class ContactCard extends resource_1.APIResource {
14
+ /**
15
+ * Creates a contact card for a phone number.
16
+ *
17
+ * The contact card is stored in an inactive state first. Once it's applied
18
+ * successfully, it is activated and `is_active` is returned as `true`. On failure,
19
+ * `is_active` is `false`.
20
+ *
21
+ * @example
22
+ * ```ts
23
+ * const setContactCard = await client.contactCard.create({
24
+ * first_name: 'John',
25
+ * phone_number: '+15551234567',
26
+ * image_url:
27
+ * 'https://cdn.linqapp.com/contact-card/example.jpg',
28
+ * last_name: 'Doe',
29
+ * });
30
+ * ```
31
+ */
32
+ create(body, options) {
33
+ return this._client.post('/v3/contact_card', { body, ...options });
34
+ }
35
+ /**
36
+ * Returns the contact card for a specific phone number, or all contact cards for
37
+ * the authenticated partner if no `phone_number` is provided.
38
+ *
39
+ * @example
40
+ * ```ts
41
+ * const contactCard = await client.contactCard.retrieve();
42
+ * ```
43
+ */
44
+ retrieve(query = {}, options) {
45
+ return this._client.get('/v3/contact_card', { query, ...options });
46
+ }
47
+ /**
48
+ * Partially updates an existing active contact card for a phone number.
49
+ *
50
+ * Fetches the current active contact card and merges the provided fields. Only
51
+ * fields present in the request body are updated; omitted fields retain their
52
+ * existing values.
53
+ *
54
+ * Requires an active contact card to exist for the phone number.
55
+ *
56
+ * @example
57
+ * ```ts
58
+ * const setContactCard = await client.contactCard.update({
59
+ * phone_number: '+15551234567',
60
+ * first_name: 'John',
61
+ * image_url:
62
+ * 'https://cdn.linqapp.com/contact-card/example.jpg',
63
+ * last_name: 'Doe',
64
+ * });
65
+ * ```
66
+ */
67
+ update(params, options) {
68
+ const { phone_number, ...body } = params;
69
+ return this._client.patch('/v3/contact_card', { query: { phone_number }, body, ...options });
70
+ }
71
+ }
72
+ exports.ContactCard = ContactCard;
73
+ //# sourceMappingURL=contact-card.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contact-card.js","sourceRoot":"","sources":["../src/resources/contact-card.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;AAI/C;;;;;;GAMG;AACH,MAAa,WAAY,SAAQ,sBAAW;IAC1C;;;;;;;;;;;;;;;;;OAiBG;IACH,MAAM,CAAC,IAA6B,EAAE,OAAwB;QAC5D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,kBAAkB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACrE,CAAC;IAED;;;;;;;;OAQG;IACH,QAAQ,CACN,QAAsD,EAAE,EACxD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,kBAAkB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACrE,CAAC;IAED;;;;;;;;;;;;;;;;;;;OAmBG;IACH,MAAM,CAAC,MAA+B,EAAE,OAAwB;QAC9D,MAAM,EAAE,YAAY,EAAE,GAAG,IAAI,EAAE,GAAG,MAAM,CAAC;QACzC,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,EAAE,EAAE,KAAK,EAAE,EAAE,YAAY,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC/F,CAAC;CACF;AA/DD,kCA+DC"}
@@ -0,0 +1,69 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+ import { APIResource } from "../core/resource.mjs";
3
+ /**
4
+ * Contact Card lets you set and share your contact information (name and profile photo) with chat participants via iMessage Name and Photo Sharing.
5
+ *
6
+ * Use `POST /v3/contact_card` to create or update a card for a phone number.
7
+ * Use `PATCH /v3/contact_card` to update an existing active card.
8
+ * Use `GET /v3/contact_card` to retrieve the active card(s) for your partner account.
9
+ */
10
+ export class ContactCard extends APIResource {
11
+ /**
12
+ * Creates a contact card for a phone number.
13
+ *
14
+ * The contact card is stored in an inactive state first. Once it's applied
15
+ * successfully, it is activated and `is_active` is returned as `true`. On failure,
16
+ * `is_active` is `false`.
17
+ *
18
+ * @example
19
+ * ```ts
20
+ * const setContactCard = await client.contactCard.create({
21
+ * first_name: 'John',
22
+ * phone_number: '+15551234567',
23
+ * image_url:
24
+ * 'https://cdn.linqapp.com/contact-card/example.jpg',
25
+ * last_name: 'Doe',
26
+ * });
27
+ * ```
28
+ */
29
+ create(body, options) {
30
+ return this._client.post('/v3/contact_card', { body, ...options });
31
+ }
32
+ /**
33
+ * Returns the contact card for a specific phone number, or all contact cards for
34
+ * the authenticated partner if no `phone_number` is provided.
35
+ *
36
+ * @example
37
+ * ```ts
38
+ * const contactCard = await client.contactCard.retrieve();
39
+ * ```
40
+ */
41
+ retrieve(query = {}, options) {
42
+ return this._client.get('/v3/contact_card', { query, ...options });
43
+ }
44
+ /**
45
+ * Partially updates an existing active contact card for a phone number.
46
+ *
47
+ * Fetches the current active contact card and merges the provided fields. Only
48
+ * fields present in the request body are updated; omitted fields retain their
49
+ * existing values.
50
+ *
51
+ * Requires an active contact card to exist for the phone number.
52
+ *
53
+ * @example
54
+ * ```ts
55
+ * const setContactCard = await client.contactCard.update({
56
+ * phone_number: '+15551234567',
57
+ * first_name: 'John',
58
+ * image_url:
59
+ * 'https://cdn.linqapp.com/contact-card/example.jpg',
60
+ * last_name: 'Doe',
61
+ * });
62
+ * ```
63
+ */
64
+ update(params, options) {
65
+ const { phone_number, ...body } = params;
66
+ return this._client.patch('/v3/contact_card', { query: { phone_number }, body, ...options });
67
+ }
68
+ }
69
+ //# sourceMappingURL=contact-card.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"contact-card.mjs","sourceRoot":"","sources":["../src/resources/contact-card.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;AAItB;;;;;;GAMG;AACH,MAAM,OAAO,WAAY,SAAQ,WAAW;IAC1C;;;;;;;;;;;;;;;;;OAiBG;IACH,MAAM,CAAC,IAA6B,EAAE,OAAwB;QAC5D,OAAO,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC,kBAAkB,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACrE,CAAC;IAED;;;;;;;;OAQG;IACH,QAAQ,CACN,QAAsD,EAAE,EACxD,OAAwB;QAExB,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,kBAAkB,EAAE,EAAE,KAAK,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IACrE,CAAC;IAED;;;;;;;;;;;;;;;;;;;OAmBG;IACH,MAAM,CAAC,MAA+B,EAAE,OAAwB;QAC9D,MAAM,EAAE,YAAY,EAAE,GAAG,IAAI,EAAE,GAAG,MAAM,CAAC;QACzC,OAAO,IAAI,CAAC,OAAO,CAAC,KAAK,CAAC,kBAAkB,EAAE,EAAE,KAAK,EAAE,EAAE,YAAY,EAAE,EAAE,IAAI,EAAE,GAAG,OAAO,EAAE,CAAC,CAAC;IAC/F,CAAC;CACF"}
@@ -1,7 +1,8 @@
1
1
  export * from "./shared.mjs";
2
2
  export { Attachments, type SupportedContentType, type AttachmentCreateResponse, type AttachmentRetrieveResponse, type AttachmentCreateParams, } from "./attachments.mjs";
3
- export { Capability, type CapabilityCheckiMessageResponse, type CapabilityCheckRCSResponse, type CapabilityCheckiMessageParams, type CapabilityCheckRCSParams, } from "./capability.mjs";
4
- export { Chats, type Chat, type MediaPart, type MessageContent, type TextPart, type ChatCreateResponse, type ChatUpdateResponse, type ChatSendVoicememoResponse, type ChatCreateParams, type ChatUpdateParams, type ChatListChatsParams, type ChatSendVoicememoParams, type ChatsListChatsPagination, } from "./chats/chats.mjs";
3
+ export { Capability, type HandleCheck, type HandleCheckResponse, type CapabilityCheckiMessageParams, type CapabilityCheckRCSParams, } from "./capability.mjs";
4
+ export { Chats, type Chat, type LinkPart, type MediaPart, type MessageContent, type TextPart, type ChatCreateResponse, type ChatUpdateResponse, type ChatLeaveChatResponse, type ChatSendVoicememoResponse, type ChatCreateParams, type ChatUpdateParams, type ChatListChatsParams, type ChatSendVoicememoParams, type ChatsListChatsPagination, } from "./chats/chats.mjs";
5
+ export { ContactCard, type SetContactCard, type ContactCardRetrieveResponse, type ContactCardCreateParams, type ContactCardRetrieveParams, type ContactCardUpdateParams, } from "./contact-card.mjs";
5
6
  export { Messages, type Message, type MessageEffect, type ReplyTo, type MessageAddReactionResponse, type MessageUpdateParams, type MessageAddReactionParams, type MessageListMessagesThreadParams, type MessagesListMessagesPagination, } from "./messages.mjs";
6
7
  export { PhoneNumbers, type PhoneNumberListResponse } from "./phone-numbers.mjs";
7
8
  export { Phonenumbers, type PhonenumberListResponse } from "./phonenumbers.mjs";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":";OAGO,EACL,WAAW,EACX,KAAK,oBAAoB,EACzB,KAAK,wBAAwB,EAC7B,KAAK,0BAA0B,EAC/B,KAAK,sBAAsB,GAC5B;OACM,EACL,UAAU,EACV,KAAK,+BAA+B,EACpC,KAAK,0BAA0B,EAC/B,KAAK,6BAA6B,EAClC,KAAK,wBAAwB,GA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C,EAC9C,KAAK,4BAA4B,EACjC,KAAK,gCAAgC,EACrC,KAAK,4BAA4B,EACjC,KAAK,iCAAiC,EACtC,KAAK,8BAA8B,EACnC,KAAK,8BAA8B,EACnC,KAAK,gCAAgC,EACrC,KAAK,iCAAiC,EACtC,KAAK,mCAAmC,EACxC,KAAK,qCAAqC,EAC1C,KAAK,qCAAqC,EAC1C,KAAK,0CAA0C,EAC/C,KAAK,0CAA0C,EAC/C,KAAK,4BAA4B,EACjC,KAAK,2CAA2C,EAChD,KAAK,2CAA2C,EAChD,KAAK,yCAAyC,EAC9C,KAAK,kBAAkB,GACxB"}
1
+ {"version":3,"file":"index.d.mts","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":";OAGO,EACL,WAAW,EACX,KAAK,oBAAoB,EACzB,KAAK,wBAAwB,EAC7B,KAAK,0BAA0B,EAC/B,KAAK,sBAAsB,GAC5B;OACM,EACL,UAAU,EACV,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,6BAA6B,EAClC,KAAK,wBAAwB,GAC9B;OACM,EACL,KAAK,EACL,KAAK,IAAI,EACT,KAAK,QAAQ,EACb,KAAK,SAAS,EACd,KAAK,cAAc,EACnB,KAAK,QAAQ,EACb,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,qBAAqB,EAC1B,KAAK,yBAAyB,EAC9B,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,wBAAwB,GAC9B;OACM,EACL,WAAW,EACX,KAAK,cAAc,EACnB,KAAK,2BAA2B,EAChC,KAAK,uBAAuB,EAC5B,KAAK,yBAAyB,EAC9B,KAAK,uBAAuB,GAC7B;OACM,EACL,QAAQ,EACR,KAAK,OAAO,EACZ,KAAK,aAAa,EAClB,KAAK,OAAO,EACZ,KAAK,0BAA0B,EAC/B,KAAK,mBAAmB,EACxB,KAAK,wBAAwB,EAC7B,KAAK,+B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  export * from "./shared.js";
2
2
  export { Attachments, type SupportedContentType, type AttachmentCreateResponse, type AttachmentRetrieveResponse, type AttachmentCreateParams, } from "./attachments.js";
3
- export { Capability, type CapabilityCheckiMessageResponse, type CapabilityCheckRCSResponse, type CapabilityCheckiMessageParams, type CapabilityCheckRCSParams, } from "./capability.js";
4
- export { Chats, type Chat, type MediaPart, type MessageContent, type TextPart, type ChatCreateResponse, type ChatUpdateResponse, type ChatSendVoicememoResponse, type ChatCreateParams, type ChatUpdateParams, type ChatListChatsParams, type ChatSendVoicememoParams, type ChatsListChatsPagination, } from "./chats/chats.js";
3
+ export { Capability, type HandleCheck, type HandleCheckResponse, type CapabilityCheckiMessageParams, type CapabilityCheckRCSParams, } from "./capability.js";
4
+ export { Chats, type Chat, type LinkPart, type MediaPart, type MessageContent, type TextPart, type ChatCreateResponse, type ChatUpdateResponse, type ChatLeaveChatResponse, type ChatSendVoicememoResponse, type ChatCreateParams, type ChatUpdateParams, type ChatListChatsParams, type ChatSendVoicememoParams, type ChatsListChatsPagination, } from "./chats/chats.js";
5
+ export { ContactCard, type SetContactCard, type ContactCardRetrieveResponse, type ContactCardCreateParams, type ContactCardRetrieveParams, type ContactCardUpdateParams, } from "./contact-card.js";
5
6
  export { Messages, type Message, type MessageEffect, type ReplyTo, type MessageAddReactionResponse, type MessageUpdateParams, type MessageAddReactionParams, type MessageListMessagesThreadParams, type MessagesListMessagesPagination, } from "./messages.js";
6
7
  export { PhoneNumbers, type PhoneNumberListResponse } from "./phone-numbers.js";
7
8
  export { Phonenumbers, type PhonenumberListResponse } from "./phonenumbers.js";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":";OAGO,EACL,WAAW,EACX,KAAK,oBAAoB,EACzB,KAAK,wBAAwB,EAC7B,KAAK,0BAA0B,EAC/B,KAAK,sBAAsB,GAC5B;OACM,EACL,UAAU,EACV,KAAK,+BAA+B,EACpC,KAAK,0BAA0B,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AA2C,EAChD,KAAK,8BAA8B,EACnC,KAAK,yCAAyC,EAC9C,KAAK,4BAA4B,EACjC,KAAK,gCAAgC,EACrC,KAAK,4BAA4B,EACjC,KAAK,iCAAiC,EACtC,KAAK,8BAA8B,EACnC,KAAK,8BAA8B,EACnC,KAAK,gCAAgC,EACrC,KAAK,iCAAiC,EACtC,KAAK,mCAAmC,EACxC,KAAK,qCAAqC,EAC1C,KAAK,qCAAqC,EAC1C,KAAK,0CAA0C,EAC/C,KAAK,0CAA0C,EAC/C,KAAK,4BAA4B,EACjC,KAAK,2CAA2C,EAChD,KAAK,2CAA2C,EAChD,KAAK,yCAAyC,EAC9C,KAAK,kBAAkB,GACxB"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":";OAGO,EACL,WAAW,EACX,KAAK,oBAAoB,EACzB,KAAK,wBAAwB,EAC7B,KAAK,0BAA0B,EAC/B,KAAK,sBAAsB,GAC5B;OACM,EACL,UAAU,EACV,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,6BAA6B,EAClC,KAAK,wBAAwB,GAC9B;OACM,EACL,KAAK,EACL,KAAK,IAAI,EACT,KAAK,QAAQ,EACb,KAAK,SAAS,EACd,KAAK,cAAc,EACnB,KAAK,QAAQ,EACb,KAAK,kBAAkB,EACvB,KAAK,kBAAkB,EACvB,KAAK,qBAAqB,EAC1B,KAAK,yBAAyB,EAC9B,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACxB,KAAK,uBAAuB,EAC5B,KAAK,wBAAwB,GAC9B;OACM,EACL,WAAW,EACX,KAAK,cAAc,EACnB,KAAK,2BAA2B,EAChC,KAAK,uBAAuB,EAC5B,KAAK,yBAAyB,EAC9B,KAAK,uBAAuB,GAC7B;OACM,EACL,QAAQ,EACR,KAAK,OAAO,EACZ,KAAK,aAAa,EAClB,KAAK,OAAO,EACZ,KAAK,0BAA0B,EAC/B,KAAK,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AK,kBAAkB,GACxB"}
@@ -1,7 +1,7 @@
1
1
  "use strict";
2
2
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
3
3
  Object.defineProperty(exports, "__esModule", { value: true });
4
- exports.Webhooks = exports.WebhookSubscriptions = exports.WebhookEvents = exports.Phonenumbers = exports.PhoneNumbers = exports.Messages = exports.Chats = exports.Capability = exports.Attachments = void 0;
4
+ exports.Webhooks = exports.WebhookSubscriptions = exports.WebhookEvents = exports.Phonenumbers = exports.PhoneNumbers = exports.Messages = exports.ContactCard = exports.Chats = exports.Capability = exports.Attachments = void 0;
5
5
  const tslib_1 = require("../internal/tslib.js");
6
6
  tslib_1.__exportStar(require("./shared.js"), exports);
7
7
  var attachments_1 = require("./attachments.js");
@@ -10,6 +10,8 @@ var capability_1 = require("./capability.js");
10
10
  Object.defineProperty(exports, "Capability", { enumerable: true, get: function () { return capability_1.Capability; } });
11
11
  var chats_1 = require("./chats/chats.js");
12
12
  Object.defineProperty(exports, "Chats", { enumerable: true, get: function () { return chats_1.Chats; } });
13
+ var contact_card_1 = require("./contact-card.js");
14
+ Object.defineProperty(exports, "ContactCard", { enumerable: true, get: function () { return contact_card_1.ContactCard; } });
13
15
  var messages_1 = require("./messages.js");
14
16
  Object.defineProperty(exports, "Messages", { enumerable: true, get: function () { return messages_1.Messages; } });
15
17
  var phone_numbers_1 = require("./phone-numbers.js");
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,sDAAyB;AACzB,gDAMuB;AALrB,0GAAA,WAAW,OAAA;AAMb,8CAMsB;AALpB,wGAAA,UAAU,OAAA;AAMZ,0CAcuB;AAbrB,8FAAA,KAAK,OAAA;AAcP,0CAUoB;AATlB,oGAAA,QAAQ,OAAA;AAUV,oDAA6E;AAApE,6GAAA,YAAY,OAAA;AACrB,kDAA4E;AAAnE,4GAAA,YAAY,OAAA;AACrB,sDAAuG;AAA9F,+GAAA,aAAa,OAAA;AACtB,oEAOiC;AAN/B,6HAAA,oBAAoB,OAAA;AAOtB,0CA4CoB;AA3ClB,oGAAA,QAAQ,OAAA"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;;AAEtF,sDAAyB;AACzB,gDAMuB;AALrB,0GAAA,WAAW,OAAA;AAMb,8CAMsB;AALpB,wGAAA,UAAU,OAAA;AAMZ,0CAgBuB;AAfrB,8FAAA,KAAK,OAAA;AAgBP,kDAOwB;AANtB,2GAAA,WAAW,OAAA;AAOb,0CAUoB;AATlB,oGAAA,QAAQ,OAAA;AAUV,oDAA6E;AAApE,6GAAA,YAAY,OAAA;AACrB,kDAA4E;AAAnE,4GAAA,YAAY,OAAA;AACrB,sDAAuG;AAA9F,+GAAA,aAAa,OAAA;AACtB,oEAOiC;AAN/B,6HAAA,oBAAoB,OAAA;AAOtB,0CA4CoB;AA3ClB,oGAAA,QAAQ,OAAA"}
@@ -3,6 +3,7 @@ export * from "./shared.mjs";
3
3
  export { Attachments, } from "./attachments.mjs";
4
4
  export { Capability, } from "./capability.mjs";
5
5
  export { Chats, } from "./chats/chats.mjs";
6
+ export { ContactCard, } from "./contact-card.mjs";
6
7
  export { Messages, } from "./messages.mjs";
7
8
  export { PhoneNumbers } from "./phone-numbers.mjs";
8
9
  export { Phonenumbers } from "./phonenumbers.mjs";
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;;OAG/E,EACL,WAAW,GAKZ;OACM,EACL,UAAU,GAKX;OACM,EACL,KAAK,GAaN;OACM,EACL,QAAQ,GAST;OACM,EAAE,YAAY,EAAgC;OAC9C,EAAE,YAAY,EAAgC;OAC9C,EAAE,aAAa,EAAwD;OACvE,EACL,oBAAoB,GAMrB;OACM,EACL,QAAQ,GA2CT"}
1
+ {"version":3,"file":"index.mjs","sourceRoot":"","sources":["../src/resources/index.ts"],"names":[],"mappings":"AAAA,sFAAsF;;OAG/E,EACL,WAAW,GAKZ;OACM,EACL,UAAU,GAKX;OACM,EACL,KAAK,GAeN;OACM,EACL,WAAW,GAMZ;OACM,EACL,QAAQ,GAST;OACM,EAAE,YAAY,EAAgC;OAC9C,EAAE,YAAY,EAAgC;OAC9C,EAAE,aAAa,EAAwD;OACvE,EACL,oBAAoB,GAMrB;OACM,EACL,QAAQ,GA2CT"}
@@ -123,6 +123,22 @@ export type ReactionType = 'love' | 'like' | 'dislike' | 'laugh' | 'emphasize' |
123
123
  * Messaging service type
124
124
  */
125
125
  export type ServiceType = 'iMessage' | 'SMS' | 'RCS';
126
+ export interface TextDecoration {
127
+ /**
128
+ * Character range `[start, end)` in the `value` string where the decoration
129
+ * applies. `start` is inclusive, `end` is exclusive. _Characters are measured as
130
+ * UTF-16 code units. Most characters count as 1; some emoji count as 2._
131
+ */
132
+ range: Array<number>;
133
+ /**
134
+ * Animated text effect to apply. Mutually exclusive with `style`.
135
+ */
136
+ animation?: 'big' | 'small' | 'shake' | 'nod' | 'explode' | 'ripple' | 'bloom' | 'jitter';
137
+ /**
138
+ * Text style to apply. Mutually exclusive with `animation`.
139
+ */
140
+ style?: 'bold' | 'italic' | 'strikethrough' | 'underline';
141
+ }
126
142
  /**
127
143
  * A text message part
128
144
  */
@@ -142,24 +158,6 @@ export interface TextPartResponse {
142
158
  /**
143
159
  * Text decorations applied to character ranges in the value
144
160
  */
145
- text_decorations?: Array<TextPartResponse.TextDecoration> | null;
146
- }
147
- export declare namespace TextPartResponse {
148
- interface TextDecoration {
149
- /**
150
- * Character range `[start, end)` in the `value` string where the decoration
151
- * applies. `start` is inclusive, `end` is exclusive. _Characters are measured as
152
- * UTF-16 code units. Most characters count as 1; some emoji count as 2._
153
- */
154
- range: Array<number>;
155
- /**
156
- * Animated text effect to apply. Mutually exclusive with `style`.
157
- */
158
- animation?: 'big' | 'small' | 'shake' | 'nod' | 'explode' | 'ripple' | 'bloom' | 'jitter';
159
- /**
160
- * Text style to apply. Mutually exclusive with `animation`.
161
- */
162
- style?: 'bold' | 'italic' | 'strikethrough' | 'underline';
163
- }
161
+ text_decorations?: Array<TextDecoration> | null;
164
162
  }
165
163
  //# sourceMappingURL=shared.d.mts.map
@@ -1 +1 @@
1
- {"version":3,"file":"shared.d.mts","sourceRoot":"","sources":["../src/resources/shared.ts"],"names":[],"mappings":"AAEA,MAAM,WAAW,UAAU;IACzB;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;IAEf;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,OAAO,EAAE,WAAW,CAAC;IAErB;;OAEG;IACH,KAAK,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;IAEvB;;OAEG;IACH,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAExB;;OAEG;IACH,MAAM,CAAC,EAAE,QAAQ,GAAG,MAAM,GAAG,SAAS,GAAG,IAAI,CAAC;CAC/C;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;IAEjB;;OAEG;IACH,SAAS,EAAE,MAAM,CAAC;IAElB;;OAEG;IACH,SAAS,EAAE,KAAK,CAAC,QAAQ,CAAC,GAAG,IAAI,CAAC;IAElC;;OAEG;IACH,UAAU,EAAE,MAAM,CAAC;IAEnB;;OAEG;IACH,IAAI,EAAE,OAAO,CAAC;IAEd;;OAEG;IACH,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,WAAW,QAAQ;IACvB,MAAM,EAAE,UAAU,CAAC;IAEnB;;OAEG;IACH,KAAK,EAAE,OAAO,CAAC;IAEf;;;;;OAKG;IACH,IAAI,EAAE,YAAY,CAAC;IAEnB;;OAEG;IACH,YAAY,CAAC,EAAE,M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OAAO;QACtB;;WAEG;QACH,SAAS,CAAC,EAAE,MAAM,CAAC;QAEnB;;WAEG;QACH,MAAM,CAAC,EAAE,MAAM,CAAC;QAEhB;;WAEG;QACH,SAAS,CAAC,EAAE,MAAM,CAAC;QAEnB;;WAEG;QACH,GAAG,CAAC,EAAE,MAAM,CAAC;QAEb;;WAEG;QACH,KAAK,CAAC,EAAE,MAAM,CAAC;KAChB;CACF;AAED;;;;;GAKG;AACH,MAAM,MAAM,YAAY,GACpB,MAAM,GACN,MAAM,GACN,SAAS,GACT,OAAO,GACP,WAAW,GACX,UAAU,GACV,QAAQ,GACR,SAAS,CAAC;AAEd;;GAEG;AACH,MAAM,MAAM,WAAW,GAAG,UAAU,GAAG,KAAK,GAAG,KAAK,CAAC;AAErD,MAAM,WAAW,cAAc;IAC7B;;;;OAIG;IACH,KAAK,EAAE,KAAK,CAAC,MAAM,CAAC,CAAC;IAErB;;OAEG;IACH,SAAS,CAAC,EAAE,KAAK,GAAG,OAAO,GAAG,OAAO,GAAG,KAAK,GAAG,SAAS,GAAG,QAAQ,GAAG,OAAO,GAAG,QAAQ,CAAC;IAE1F;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,eAAe,GAAG,WAAW,CAAC;CAC3D;AAED;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;OAEG;IACH,SAAS,EAAE,KAAK,CAAC,QAAQ,CAAC,GAAG,IAAI,CAAC;IAElC;;OAEG;IACH,IAAI,EAAE,MAAM,CAAC;IAEb;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd;;OAEG;IACH,gBAAgB,CAAC,EAAE,KAAK,CAAC,cAAc,CAAC,GAAG,IAAI,CAAC;CACjD"}
@@ -123,6 +123,22 @@ export type ReactionType = 'love' | 'like' | 'dislike' | 'laugh' | 'emphasize' |
123
123
  * Messaging service type
124
124
  */
125
125
  export type ServiceType = 'iMessage' | 'SMS' | 'RCS';
126
+ export interface TextDecoration {
127
+ /**
128
+ * Character range `[start, end)` in the `value` string where the decoration
129
+ * applies. `start` is inclusive, `end` is exclusive. _Characters are measured as
130
+ * UTF-16 code units. Most characters count as 1; some emoji count as 2._
131
+ */
132
+ range: Array<number>;
133
+ /**
134
+ * Animated text effect to apply. Mutually exclusive with `style`.
135
+ */
136
+ animation?: 'big' | 'small' | 'shake' | 'nod' | 'explode' | 'ripple' | 'bloom' | 'jitter';
137
+ /**
138
+ * Text style to apply. Mutually exclusive with `animation`.
139
+ */
140
+ style?: 'bold' | 'italic' | 'strikethrough' | 'underline';
141
+ }
126
142
  /**
127
143
  * A text message part
128
144
  */
@@ -142,24 +158,6 @@ export interface TextPartResponse {
142
158
  /**
143
159
  * Text decorations applied to character ranges in the value
144
160
  */
145
- text_decorations?: Array<TextPartResponse.TextDecoration> | null;
146
- }
147
- export declare namespace TextPartResponse {
148
- interface TextDecoration {
149
- /**
150
- * Character range `[start, end)` in the `value` string where the decoration
151
- * applies. `start` is inclusive, `end` is exclusive. _Characters are measured as
152
- * UTF-16 code units. Most characters count as 1; some emoji count as 2._
153
- */
154
- range: Array<number>;
155
- /**
156
- * Animated text effect to apply. Mutually exclusive with `style`.
157
- */
158
- animation?: 'big' | 'small' | 'shake' | 'nod' | 'explode' | 'ripple' | 'bloom' | 'jitter';
159
- /**
160
- * Text style to apply. Mutually exclusive with `animation`.
161
- */
162
- style?: 'bold' | 'italic' | 'strikethrough' | 'underline';
163
- }
161
+ text_decorations?: Array<TextDecoration> | null;
164
162
  }
165
163
  //# sourceMappingURL=shared.d.ts.map