@oursprivacy/platform-sdk 1.10.0 → 1.12.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 (64) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/client.d.mts +2 -2
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +2 -2
  5. package/client.d.ts.map +1 -1
  6. package/client.js.map +1 -1
  7. package/client.mjs.map +1 -1
  8. package/package.json +1 -1
  9. package/resources/allowed-events.d.mts +1 -1
  10. package/resources/allowed-events.d.mts.map +1 -1
  11. package/resources/allowed-events.d.ts +1 -1
  12. package/resources/allowed-events.d.ts.map +1 -1
  13. package/resources/consent-settings.d.mts +126 -12
  14. package/resources/consent-settings.d.mts.map +1 -1
  15. package/resources/consent-settings.d.ts +126 -12
  16. package/resources/consent-settings.d.ts.map +1 -1
  17. package/resources/destinations.d.mts +3 -3
  18. package/resources/destinations.d.mts.map +1 -1
  19. package/resources/destinations.d.ts +3 -3
  20. package/resources/destinations.d.ts.map +1 -1
  21. package/resources/global-dispatch-centers.d.mts +221 -7
  22. package/resources/global-dispatch-centers.d.mts.map +1 -1
  23. package/resources/global-dispatch-centers.d.ts +221 -7
  24. package/resources/global-dispatch-centers.d.ts.map +1 -1
  25. package/resources/global-dispatch-centers.js +2 -2
  26. package/resources/global-dispatch-centers.js.map +1 -1
  27. package/resources/global-dispatch-centers.mjs +2 -2
  28. package/resources/global-dispatch-centers.mjs.map +1 -1
  29. package/resources/index.d.mts +1 -1
  30. package/resources/index.d.mts.map +1 -1
  31. package/resources/index.d.ts +1 -1
  32. package/resources/index.d.ts.map +1 -1
  33. package/resources/index.js.map +1 -1
  34. package/resources/index.mjs.map +1 -1
  35. package/resources/replay-settings.d.mts +119 -12
  36. package/resources/replay-settings.d.mts.map +1 -1
  37. package/resources/replay-settings.d.ts +119 -12
  38. package/resources/replay-settings.d.ts.map +1 -1
  39. package/resources/replay-settings.js +14 -5
  40. package/resources/replay-settings.js.map +1 -1
  41. package/resources/replay-settings.mjs +14 -5
  42. package/resources/replay-settings.mjs.map +1 -1
  43. package/resources/sources.d.mts +6 -6
  44. package/resources/sources.d.mts.map +1 -1
  45. package/resources/sources.d.ts +6 -6
  46. package/resources/sources.d.ts.map +1 -1
  47. package/resources/versions.d.mts +11 -11
  48. package/resources/versions.d.mts.map +1 -1
  49. package/resources/versions.d.ts +11 -11
  50. package/resources/versions.d.ts.map +1 -1
  51. package/src/client.ts +2 -0
  52. package/src/resources/allowed-events.ts +1 -1
  53. package/src/resources/consent-settings.ts +196 -12
  54. package/src/resources/destinations.ts +3 -3
  55. package/src/resources/global-dispatch-centers.ts +251 -7
  56. package/src/resources/index.ts +1 -0
  57. package/src/resources/replay-settings.ts +125 -12
  58. package/src/resources/sources.ts +6 -6
  59. package/src/resources/versions.ts +11 -11
  60. package/src/version.ts +1 -1
  61. package/version.d.mts +1 -1
  62. package/version.d.ts +1 -1
  63. package/version.js +1 -1
  64. package/version.mjs +1 -1
@@ -7,21 +7,27 @@ import { path } from '../internal/utils/path';
7
7
 
8
8
  export class ReplaySettings extends APIResource {
9
9
  /**
10
- * Create a new replay setting. Requires scope: replaySettings:create
10
+ * Create the replay configuration for this account. Each account is limited to one
11
+ * replay configuration — calls made when one already exists return HTTP 409 with
12
+ * the reason in the response `error` field. Requires scope: replaySettings:create
11
13
  */
12
14
  create(body: ReplaySettingCreateParams, options?: RequestOptions): APIPromise<ReplaySettingCreateResponse> {
13
15
  return this._client.post('/rest/v1/replay-settings', { body, ...options });
14
16
  }
15
17
 
16
18
  /**
17
- * Find a single replay setting by ID. Requires scope: replaySettings:find
19
+ * Fetch a single replay configuration by ID, including its whitelisted domains and
20
+ * custom domain. Requires scope: replaySettings:find
18
21
  */
19
- retrieve(id: string, options?: RequestOptions): APIPromise<unknown> {
22
+ retrieve(id: string, options?: RequestOptions): APIPromise<ReplaySettingRetrieveResponse | null> {
20
23
  return this._client.get(path`/rest/v1/replay-settings/${id}`, options);
21
24
  }
22
25
 
23
26
  /**
24
- * Update a replay setting. Requires scope: replaySettings:update
27
+ * Update one or more fields on an existing replay configuration. Only the fields
28
+ * you send are changed; omitted fields keep their current value. Note that
29
+ * `whitelistDomains` is replaced wholesale (not merged with the existing list).
30
+ * Requires scope: replaySettings:update
25
31
  */
26
32
  update(
27
33
  id: string,
@@ -32,14 +38,17 @@ export class ReplaySettings extends APIResource {
32
38
  }
33
39
 
34
40
  /**
35
- * List all replay settings. Requires scope: replaySettings:list
41
+ * List the replay configurations on this account. Replay settings control which
42
+ * domains may capture session replays and where the capture script is hosted.
43
+ * Requires scope: replaySettings:list
36
44
  */
37
45
  list(options?: RequestOptions): APIPromise<ReplaySettingListResponse> {
38
46
  return this._client.get('/rest/v1/replay-settings', options);
39
47
  }
40
48
 
41
49
  /**
42
- * Delete a replay setting. Requires scope: replaySettings:delete
50
+ * Delete the replay configuration. Capture stops immediately for all whitelisted
51
+ * domains. Requires scope: replaySettings:delete
43
52
  */
44
53
  delete(id: string, options?: RequestOptions): APIPromise<ReplaySettingDeleteResponse> {
45
54
  return this._client.delete(path`/rest/v1/replay-settings/${id}`, options);
@@ -54,7 +63,48 @@ export interface ReplaySettingCreateResponse {
54
63
  replaySettings?: unknown | null;
55
64
  }
56
65
 
57
- export type ReplaySettingRetrieveResponse = unknown;
66
+ export interface ReplaySettingRetrieveResponse {
67
+ /**
68
+ * Stable identifier (UUID) for this replay configuration.
69
+ */
70
+ id: string;
71
+
72
+ /**
73
+ * ISO-8601 timestamp when this configuration was created.
74
+ */
75
+ createdAt: string;
76
+
77
+ /**
78
+ * Human-readable label for this replay configuration. Shown in the dashboard. May
79
+ * be empty.
80
+ */
81
+ name: string;
82
+
83
+ /**
84
+ * Whether session replay capture is currently active. Set to "Enabled" to start
85
+ * capturing replays from whitelisted domains, or "Disabled" to pause capture
86
+ * without losing the configuration.
87
+ */
88
+ status: 'Disabled' | 'Enabled';
89
+
90
+ /**
91
+ * Optional custom domain (CNAME) for hosting the replay capture script. Leave null
92
+ * to use the default Ours Privacy domain.
93
+ */
94
+ customDomain?: string | null;
95
+
96
+ /**
97
+ * ISO-8601 timestamp of the most recent update, or null if never updated.
98
+ */
99
+ updatedAt?: string | null;
100
+
101
+ /**
102
+ * Hostnames where session replay capture is permitted. Replays initiated from any
103
+ * host not in this list are dropped. PATCH replaces the list — partial updates are
104
+ * not merged.
105
+ */
106
+ whitelistDomains?: Array<string> | null;
107
+ }
58
108
 
59
109
  export interface ReplaySettingUpdateResponse {
60
110
  isSuccess: boolean;
@@ -70,19 +120,46 @@ export interface ReplaySettingListResponse {
70
120
 
71
121
  export namespace ReplaySettingListResponse {
72
122
  export interface Entity {
123
+ /**
124
+ * Stable identifier (UUID) for this replay configuration.
125
+ */
73
126
  id: string;
74
127
 
128
+ /**
129
+ * ISO-8601 timestamp when this configuration was created.
130
+ */
75
131
  createdAt: string;
76
132
 
133
+ /**
134
+ * Human-readable label for this replay configuration. Shown in the dashboard. May
135
+ * be empty.
136
+ */
77
137
  name: string;
78
138
 
139
+ /**
140
+ * Whether session replay capture is currently active. Set to "Enabled" to start
141
+ * capturing replays from whitelisted domains, or "Disabled" to pause capture
142
+ * without losing the configuration.
143
+ */
79
144
  status: 'Disabled' | 'Enabled';
80
145
 
146
+ /**
147
+ * Optional custom domain (CNAME) for hosting the replay capture script. Leave null
148
+ * to use the default Ours Privacy domain.
149
+ */
81
150
  customDomain?: string | null;
82
151
 
152
+ /**
153
+ * ISO-8601 timestamp of the most recent update, or null if never updated.
154
+ */
83
155
  updatedAt?: string | null;
84
156
 
85
- whitelistDomains?: Array<unknown> | null;
157
+ /**
158
+ * Hostnames where session replay capture is permitted. Replays initiated from any
159
+ * host not in this list are dropped. PATCH replaces the list — partial updates are
160
+ * not merged.
161
+ */
162
+ whitelistDomains?: Array<string> | null;
86
163
  }
87
164
  }
88
165
 
@@ -95,23 +172,59 @@ export interface ReplaySettingDeleteResponse {
95
172
  }
96
173
 
97
174
  export interface ReplaySettingCreateParams {
175
+ /**
176
+ * Optional custom domain (CNAME) for hosting the replay capture script. Leave null
177
+ * to use the default Ours Privacy domain.
178
+ */
98
179
  customDomain?: string | null;
99
180
 
181
+ /**
182
+ * Human-readable label for this replay configuration. Shown in the dashboard. May
183
+ * be empty.
184
+ */
100
185
  name?: string | null;
101
186
 
102
- status?: string | null;
187
+ /**
188
+ * Whether session replay capture is currently active. Set to "Enabled" to start
189
+ * capturing replays from whitelisted domains, or "Disabled" to pause capture
190
+ * without losing the configuration.
191
+ */
192
+ status?: 'Disabled' | 'Enabled' | null;
103
193
 
104
- whitelistDomains?: Array<unknown> | null;
194
+ /**
195
+ * Hostnames where session replay capture is permitted. Replays initiated from any
196
+ * host not in this list are dropped. PATCH replaces the list — partial updates are
197
+ * not merged.
198
+ */
199
+ whitelistDomains?: Array<string> | null;
105
200
  }
106
201
 
107
202
  export interface ReplaySettingUpdateParams {
203
+ /**
204
+ * Optional custom domain (CNAME) for hosting the replay capture script. Leave null
205
+ * to use the default Ours Privacy domain.
206
+ */
108
207
  customDomain?: string | null;
109
208
 
209
+ /**
210
+ * Human-readable label for this replay configuration. Shown in the dashboard. May
211
+ * be empty.
212
+ */
110
213
  name?: string | null;
111
214
 
112
- status?: string | null;
215
+ /**
216
+ * Whether session replay capture is currently active. Set to "Enabled" to start
217
+ * capturing replays from whitelisted domains, or "Disabled" to pause capture
218
+ * without losing the configuration.
219
+ */
220
+ status?: 'Disabled' | 'Enabled' | null;
113
221
 
114
- whitelistDomains?: Array<unknown> | null;
222
+ /**
223
+ * Hostnames where session replay capture is permitted. Replays initiated from any
224
+ * host not in this list are dropped. PATCH replaces the list — partial updates are
225
+ * not merged.
226
+ */
227
+ whitelistDomains?: Array<string> | null;
115
228
  }
116
229
 
117
230
  export declare namespace ReplaySettings {
@@ -141,9 +141,9 @@ export interface SourceRetrieveResponse {
141
141
 
142
142
  selectedAccountId?: string | null;
143
143
 
144
- whitelistDomains?: Array<unknown> | null;
144
+ whitelistDomains?: Array<string> | null;
145
145
 
146
- whitelistIps?: Array<unknown> | null;
146
+ whitelistIps?: Array<string> | null;
147
147
  }
148
148
 
149
149
  export interface SourceUpdateResponse {
@@ -250,9 +250,9 @@ export namespace SourceListResponse {
250
250
 
251
251
  selectedAccountId?: string | null;
252
252
 
253
- whitelistDomains?: Array<unknown> | null;
253
+ whitelistDomains?: Array<string> | null;
254
254
 
255
- whitelistIps?: Array<unknown> | null;
255
+ whitelistIps?: Array<string> | null;
256
256
  }
257
257
  }
258
258
 
@@ -314,9 +314,9 @@ export interface SourceUpdateParams {
314
314
 
315
315
  selectedAccountId?: string | null;
316
316
 
317
- whitelistDomains?: Array<unknown> | null;
317
+ whitelistDomains?: Array<string> | null;
318
318
 
319
- whitelistIps?: Array<unknown> | null;
319
+ whitelistIps?: Array<string> | null;
320
320
  }
321
321
 
322
322
  export declare namespace Sources {
@@ -92,27 +92,27 @@ export namespace VersionListResponse {
92
92
  }
93
93
 
94
94
  export interface VersionCreateParams {
95
- includeAllowedEvents?: Array<unknown> | null;
95
+ includeAllowedEvents?: Array<string> | null;
96
96
 
97
- includeConsentSettings?: Array<unknown> | null;
97
+ includeConsentSettings?: Array<string> | null;
98
98
 
99
- includeDestinations?: Array<unknown> | null;
99
+ includeDestinations?: Array<string> | null;
100
100
 
101
- includeExternalAllowedEventData?: Array<unknown> | null;
101
+ includeExternalAllowedEventData?: Array<string> | null;
102
102
 
103
- includeGlobalDispatchCenters?: Array<unknown> | null;
103
+ includeGlobalDispatchCenters?: Array<string> | null;
104
104
 
105
- includeMappings?: Array<unknown> | null;
105
+ includeMappings?: Array<string> | null;
106
106
 
107
- includeReplaySettings?: Array<unknown> | null;
107
+ includeReplaySettings?: Array<string> | null;
108
108
 
109
- includeSources?: Array<unknown> | null;
109
+ includeSources?: Array<string> | null;
110
110
 
111
- includeTagManagerTags?: Array<unknown> | null;
111
+ includeTagManagerTags?: Array<string> | null;
112
112
 
113
- includeTagManagerTriggers?: Array<unknown> | null;
113
+ includeTagManagerTriggers?: Array<string> | null;
114
114
 
115
- includeTagManagerVariables?: Array<unknown> | null;
115
+ includeTagManagerVariables?: Array<string> | null;
116
116
 
117
117
  name?: string | null;
118
118
 
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '1.10.0'; // x-release-please-version
1
+ export const VERSION = '1.12.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "1.10.0";
1
+ export declare const VERSION = "1.12.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "1.10.0";
1
+ export declare const VERSION = "1.12.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '1.10.0'; // x-release-please-version
4
+ exports.VERSION = '1.12.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '1.10.0'; // x-release-please-version
1
+ export const VERSION = '1.12.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map