@contractspec/lib.metering 1.57.0 → 1.58.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 (65) hide show
  1. package/dist/aggregation/index.d.ts +119 -122
  2. package/dist/aggregation/index.d.ts.map +1 -1
  3. package/dist/aggregation/index.js +257 -265
  4. package/dist/analytics/posthog-metering-reader.d.ts +32 -36
  5. package/dist/analytics/posthog-metering-reader.d.ts.map +1 -1
  6. package/dist/analytics/posthog-metering-reader.js +239 -179
  7. package/dist/analytics/posthog-metering.d.ts +30 -34
  8. package/dist/analytics/posthog-metering.d.ts.map +1 -1
  9. package/dist/analytics/posthog-metering.js +45 -45
  10. package/dist/browser/aggregation/index.js +265 -0
  11. package/dist/browser/analytics/posthog-metering-reader.js +266 -0
  12. package/dist/browser/analytics/posthog-metering.js +45 -0
  13. package/dist/browser/contracts/index.js +617 -0
  14. package/dist/browser/docs/index.js +62 -0
  15. package/dist/browser/docs/metering.docblock.js +62 -0
  16. package/dist/browser/entities/index.js +350 -0
  17. package/dist/browser/events.js +228 -0
  18. package/dist/browser/index.js +1879 -0
  19. package/dist/browser/metering.capability.js +28 -0
  20. package/dist/browser/metering.feature.js +52 -0
  21. package/dist/contracts/index.d.ts +1076 -1082
  22. package/dist/contracts/index.d.ts.map +1 -1
  23. package/dist/contracts/index.js +616 -1030
  24. package/dist/docs/index.d.ts +2 -1
  25. package/dist/docs/index.d.ts.map +1 -0
  26. package/dist/docs/index.js +63 -1
  27. package/dist/docs/metering.docblock.d.ts +2 -1
  28. package/dist/docs/metering.docblock.d.ts.map +1 -0
  29. package/dist/docs/metering.docblock.js +17 -22
  30. package/dist/entities/index.d.ts +186 -191
  31. package/dist/entities/index.d.ts.map +1 -1
  32. package/dist/entities/index.js +340 -407
  33. package/dist/events.d.ts +411 -417
  34. package/dist/events.d.ts.map +1 -1
  35. package/dist/events.js +226 -414
  36. package/dist/index.d.ts +9 -8
  37. package/dist/index.d.ts.map +1 -0
  38. package/dist/index.js +1880 -10
  39. package/dist/metering.capability.d.ts +2 -7
  40. package/dist/metering.capability.d.ts.map +1 -1
  41. package/dist/metering.capability.js +29 -33
  42. package/dist/metering.feature.d.ts +1 -6
  43. package/dist/metering.feature.d.ts.map +1 -1
  44. package/dist/metering.feature.js +51 -132
  45. package/dist/node/aggregation/index.js +265 -0
  46. package/dist/node/analytics/posthog-metering-reader.js +266 -0
  47. package/dist/node/analytics/posthog-metering.js +45 -0
  48. package/dist/node/contracts/index.js +617 -0
  49. package/dist/node/docs/index.js +62 -0
  50. package/dist/node/docs/metering.docblock.js +62 -0
  51. package/dist/node/entities/index.js +350 -0
  52. package/dist/node/events.js +228 -0
  53. package/dist/node/index.js +1879 -0
  54. package/dist/node/metering.capability.js +28 -0
  55. package/dist/node/metering.feature.js +52 -0
  56. package/package.json +133 -34
  57. package/dist/aggregation/index.js.map +0 -1
  58. package/dist/analytics/posthog-metering-reader.js.map +0 -1
  59. package/dist/analytics/posthog-metering.js.map +0 -1
  60. package/dist/contracts/index.js.map +0 -1
  61. package/dist/docs/metering.docblock.js.map +0 -1
  62. package/dist/entities/index.js.map +0 -1
  63. package/dist/events.js.map +0 -1
  64. package/dist/metering.capability.js.map +0 -1
  65. package/dist/metering.feature.js.map +0 -1
@@ -1,1139 +1,1133 @@
1
- import * as _contractspec_lib_schema0 from "@contractspec/lib.schema";
2
- import * as _contractspec_lib_contracts0 from "@contractspec/lib.contracts";
3
-
4
- //#region src/contracts/index.d.ts
5
- declare const MetricDefinitionModel: _contractspec_lib_schema0.SchemaModel<{
6
- id: {
7
- type: _contractspec_lib_schema0.FieldType<string, string>;
8
- isOptional: false;
9
- };
10
- key: {
11
- type: _contractspec_lib_schema0.FieldType<string, string>;
12
- isOptional: false;
13
- };
14
- name: {
15
- type: _contractspec_lib_schema0.FieldType<string, string>;
16
- isOptional: false;
17
- };
18
- description: {
19
- type: _contractspec_lib_schema0.FieldType<string, string>;
20
- isOptional: true;
21
- };
22
- unit: {
23
- type: _contractspec_lib_schema0.FieldType<string, string>;
24
- isOptional: false;
25
- };
26
- aggregationType: {
27
- type: _contractspec_lib_schema0.FieldType<string, string>;
28
- isOptional: false;
29
- };
30
- resetPeriod: {
31
- type: _contractspec_lib_schema0.FieldType<string, string>;
32
- isOptional: false;
33
- };
34
- category: {
35
- type: _contractspec_lib_schema0.FieldType<string, string>;
36
- isOptional: true;
37
- };
38
- isActive: {
39
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
40
- isOptional: false;
41
- };
42
- orgId: {
43
- type: _contractspec_lib_schema0.FieldType<string, string>;
44
- isOptional: true;
45
- };
46
- createdAt: {
47
- type: _contractspec_lib_schema0.FieldType<Date, string>;
48
- isOptional: false;
49
- };
50
- updatedAt: {
51
- type: _contractspec_lib_schema0.FieldType<Date, string>;
52
- isOptional: false;
53
- };
1
+ export declare const MetricDefinitionModel: import("@contractspec/lib.schema").SchemaModel<{
2
+ id: {
3
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
4
+ isOptional: false;
5
+ };
6
+ key: {
7
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
8
+ isOptional: false;
9
+ };
10
+ name: {
11
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
12
+ isOptional: false;
13
+ };
14
+ description: {
15
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
16
+ isOptional: true;
17
+ };
18
+ unit: {
19
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
20
+ isOptional: false;
21
+ };
22
+ aggregationType: {
23
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
24
+ isOptional: false;
25
+ };
26
+ resetPeriod: {
27
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
28
+ isOptional: false;
29
+ };
30
+ category: {
31
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
32
+ isOptional: true;
33
+ };
34
+ isActive: {
35
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
36
+ isOptional: false;
37
+ };
38
+ orgId: {
39
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
40
+ isOptional: true;
41
+ };
42
+ createdAt: {
43
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
44
+ isOptional: false;
45
+ };
46
+ updatedAt: {
47
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
48
+ isOptional: false;
49
+ };
54
50
  }>;
55
- declare const UsageRecordModel: _contractspec_lib_schema0.SchemaModel<{
56
- id: {
57
- type: _contractspec_lib_schema0.FieldType<string, string>;
58
- isOptional: false;
59
- };
60
- metricKey: {
61
- type: _contractspec_lib_schema0.FieldType<string, string>;
62
- isOptional: false;
63
- };
64
- subjectType: {
65
- type: _contractspec_lib_schema0.FieldType<string, string>;
66
- isOptional: false;
67
- };
68
- subjectId: {
69
- type: _contractspec_lib_schema0.FieldType<string, string>;
70
- isOptional: false;
71
- };
72
- quantity: {
73
- type: _contractspec_lib_schema0.FieldType<number, number>;
74
- isOptional: false;
75
- };
76
- source: {
77
- type: _contractspec_lib_schema0.FieldType<string, string>;
78
- isOptional: true;
79
- };
80
- resourceId: {
81
- type: _contractspec_lib_schema0.FieldType<string, string>;
82
- isOptional: true;
83
- };
84
- resourceType: {
85
- type: _contractspec_lib_schema0.FieldType<string, string>;
86
- isOptional: true;
87
- };
88
- metadata: {
89
- type: _contractspec_lib_schema0.FieldType<unknown, unknown>;
90
- isOptional: true;
91
- };
92
- timestamp: {
93
- type: _contractspec_lib_schema0.FieldType<Date, string>;
94
- isOptional: false;
95
- };
96
- createdAt: {
97
- type: _contractspec_lib_schema0.FieldType<Date, string>;
98
- isOptional: false;
99
- };
51
+ export declare const UsageRecordModel: import("@contractspec/lib.schema").SchemaModel<{
52
+ id: {
53
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
54
+ isOptional: false;
55
+ };
56
+ metricKey: {
57
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
58
+ isOptional: false;
59
+ };
60
+ subjectType: {
61
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
62
+ isOptional: false;
63
+ };
64
+ subjectId: {
65
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
66
+ isOptional: false;
67
+ };
68
+ quantity: {
69
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
70
+ isOptional: false;
71
+ };
72
+ source: {
73
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
74
+ isOptional: true;
75
+ };
76
+ resourceId: {
77
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
78
+ isOptional: true;
79
+ };
80
+ resourceType: {
81
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
82
+ isOptional: true;
83
+ };
84
+ metadata: {
85
+ type: import("@contractspec/lib.schema").FieldType<unknown, unknown>;
86
+ isOptional: true;
87
+ };
88
+ timestamp: {
89
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
90
+ isOptional: false;
91
+ };
92
+ createdAt: {
93
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
94
+ isOptional: false;
95
+ };
100
96
  }>;
101
- declare const UsageSummaryModel: _contractspec_lib_schema0.SchemaModel<{
102
- id: {
103
- type: _contractspec_lib_schema0.FieldType<string, string>;
104
- isOptional: false;
105
- };
106
- metricKey: {
107
- type: _contractspec_lib_schema0.FieldType<string, string>;
108
- isOptional: false;
109
- };
110
- subjectType: {
111
- type: _contractspec_lib_schema0.FieldType<string, string>;
112
- isOptional: false;
113
- };
114
- subjectId: {
115
- type: _contractspec_lib_schema0.FieldType<string, string>;
116
- isOptional: false;
117
- };
118
- periodType: {
119
- type: _contractspec_lib_schema0.FieldType<string, string>;
120
- isOptional: false;
121
- };
122
- periodStart: {
123
- type: _contractspec_lib_schema0.FieldType<Date, string>;
124
- isOptional: false;
125
- };
126
- periodEnd: {
127
- type: _contractspec_lib_schema0.FieldType<Date, string>;
128
- isOptional: false;
129
- };
130
- totalQuantity: {
131
- type: _contractspec_lib_schema0.FieldType<number, number>;
132
- isOptional: false;
133
- };
134
- recordCount: {
135
- type: _contractspec_lib_schema0.FieldType<number, number>;
136
- isOptional: false;
137
- };
138
- minQuantity: {
139
- type: _contractspec_lib_schema0.FieldType<number, number>;
140
- isOptional: true;
141
- };
142
- maxQuantity: {
143
- type: _contractspec_lib_schema0.FieldType<number, number>;
144
- isOptional: true;
145
- };
146
- avgQuantity: {
147
- type: _contractspec_lib_schema0.FieldType<number, number>;
148
- isOptional: true;
149
- };
97
+ export declare const UsageSummaryModel: import("@contractspec/lib.schema").SchemaModel<{
98
+ id: {
99
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
100
+ isOptional: false;
101
+ };
102
+ metricKey: {
103
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
104
+ isOptional: false;
105
+ };
106
+ subjectType: {
107
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
108
+ isOptional: false;
109
+ };
110
+ subjectId: {
111
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
112
+ isOptional: false;
113
+ };
114
+ periodType: {
115
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
116
+ isOptional: false;
117
+ };
118
+ periodStart: {
119
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
120
+ isOptional: false;
121
+ };
122
+ periodEnd: {
123
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
124
+ isOptional: false;
125
+ };
126
+ totalQuantity: {
127
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
128
+ isOptional: false;
129
+ };
130
+ recordCount: {
131
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
132
+ isOptional: false;
133
+ };
134
+ minQuantity: {
135
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
136
+ isOptional: true;
137
+ };
138
+ maxQuantity: {
139
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
140
+ isOptional: true;
141
+ };
142
+ avgQuantity: {
143
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
144
+ isOptional: true;
145
+ };
150
146
  }>;
151
- declare const UsageThresholdModel: _contractspec_lib_schema0.SchemaModel<{
152
- id: {
153
- type: _contractspec_lib_schema0.FieldType<string, string>;
154
- isOptional: false;
155
- };
156
- metricKey: {
157
- type: _contractspec_lib_schema0.FieldType<string, string>;
158
- isOptional: false;
159
- };
160
- subjectType: {
161
- type: _contractspec_lib_schema0.FieldType<string, string>;
162
- isOptional: true;
163
- };
164
- subjectId: {
165
- type: _contractspec_lib_schema0.FieldType<string, string>;
166
- isOptional: true;
167
- };
168
- name: {
169
- type: _contractspec_lib_schema0.FieldType<string, string>;
170
- isOptional: false;
171
- };
172
- threshold: {
173
- type: _contractspec_lib_schema0.FieldType<number, number>;
174
- isOptional: false;
175
- };
176
- warnThreshold: {
177
- type: _contractspec_lib_schema0.FieldType<number, number>;
178
- isOptional: true;
179
- };
180
- periodType: {
181
- type: _contractspec_lib_schema0.FieldType<string, string>;
182
- isOptional: false;
183
- };
184
- action: {
185
- type: _contractspec_lib_schema0.FieldType<string, string>;
186
- isOptional: false;
187
- };
188
- currentValue: {
189
- type: _contractspec_lib_schema0.FieldType<number, number>;
190
- isOptional: false;
191
- };
192
- isActive: {
193
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
194
- isOptional: false;
195
- };
196
- createdAt: {
197
- type: _contractspec_lib_schema0.FieldType<Date, string>;
198
- isOptional: false;
199
- };
147
+ export declare const UsageThresholdModel: import("@contractspec/lib.schema").SchemaModel<{
148
+ id: {
149
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
150
+ isOptional: false;
151
+ };
152
+ metricKey: {
153
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
154
+ isOptional: false;
155
+ };
156
+ subjectType: {
157
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
158
+ isOptional: true;
159
+ };
160
+ subjectId: {
161
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
162
+ isOptional: true;
163
+ };
164
+ name: {
165
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
166
+ isOptional: false;
167
+ };
168
+ threshold: {
169
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
170
+ isOptional: false;
171
+ };
172
+ warnThreshold: {
173
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
174
+ isOptional: true;
175
+ };
176
+ periodType: {
177
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
178
+ isOptional: false;
179
+ };
180
+ action: {
181
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
182
+ isOptional: false;
183
+ };
184
+ currentValue: {
185
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
186
+ isOptional: false;
187
+ };
188
+ isActive: {
189
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
190
+ isOptional: false;
191
+ };
192
+ createdAt: {
193
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
194
+ isOptional: false;
195
+ };
200
196
  }>;
201
197
  /**
202
198
  * Define a metric.
203
199
  */
204
- declare const DefineMetricContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
205
- key: {
206
- type: _contractspec_lib_schema0.FieldType<string, string>;
207
- isOptional: false;
208
- };
209
- name: {
210
- type: _contractspec_lib_schema0.FieldType<string, string>;
211
- isOptional: false;
212
- };
213
- description: {
214
- type: _contractspec_lib_schema0.FieldType<string, string>;
215
- isOptional: true;
216
- };
217
- unit: {
218
- type: _contractspec_lib_schema0.FieldType<string, string>;
219
- isOptional: false;
220
- };
221
- aggregationType: {
222
- type: _contractspec_lib_schema0.FieldType<string, string>;
223
- isOptional: true;
224
- };
225
- resetPeriod: {
226
- type: _contractspec_lib_schema0.FieldType<string, string>;
227
- isOptional: true;
228
- };
229
- category: {
230
- type: _contractspec_lib_schema0.FieldType<string, string>;
231
- isOptional: true;
232
- };
233
- orgId: {
234
- type: _contractspec_lib_schema0.FieldType<string, string>;
235
- isOptional: true;
236
- };
237
- metadata: {
238
- type: _contractspec_lib_schema0.FieldType<unknown, unknown>;
239
- isOptional: true;
240
- };
241
- }>, _contractspec_lib_schema0.SchemaModel<{
242
- id: {
243
- type: _contractspec_lib_schema0.FieldType<string, string>;
244
- isOptional: false;
245
- };
246
- key: {
247
- type: _contractspec_lib_schema0.FieldType<string, string>;
248
- isOptional: false;
249
- };
250
- name: {
251
- type: _contractspec_lib_schema0.FieldType<string, string>;
252
- isOptional: false;
253
- };
254
- description: {
255
- type: _contractspec_lib_schema0.FieldType<string, string>;
256
- isOptional: true;
257
- };
258
- unit: {
259
- type: _contractspec_lib_schema0.FieldType<string, string>;
260
- isOptional: false;
261
- };
262
- aggregationType: {
263
- type: _contractspec_lib_schema0.FieldType<string, string>;
264
- isOptional: false;
265
- };
266
- resetPeriod: {
267
- type: _contractspec_lib_schema0.FieldType<string, string>;
268
- isOptional: false;
269
- };
270
- category: {
271
- type: _contractspec_lib_schema0.FieldType<string, string>;
272
- isOptional: true;
273
- };
274
- isActive: {
275
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
276
- isOptional: false;
277
- };
278
- orgId: {
279
- type: _contractspec_lib_schema0.FieldType<string, string>;
280
- isOptional: true;
281
- };
282
- createdAt: {
283
- type: _contractspec_lib_schema0.FieldType<Date, string>;
284
- isOptional: false;
285
- };
286
- updatedAt: {
287
- type: _contractspec_lib_schema0.FieldType<Date, string>;
288
- isOptional: false;
289
- };
200
+ export declare const DefineMetricContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
201
+ key: {
202
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
203
+ isOptional: false;
204
+ };
205
+ name: {
206
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
207
+ isOptional: false;
208
+ };
209
+ description: {
210
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
211
+ isOptional: true;
212
+ };
213
+ unit: {
214
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
215
+ isOptional: false;
216
+ };
217
+ aggregationType: {
218
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
219
+ isOptional: true;
220
+ };
221
+ resetPeriod: {
222
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
223
+ isOptional: true;
224
+ };
225
+ category: {
226
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
227
+ isOptional: true;
228
+ };
229
+ orgId: {
230
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
231
+ isOptional: true;
232
+ };
233
+ metadata: {
234
+ type: import("@contractspec/lib.schema").FieldType<unknown, unknown>;
235
+ isOptional: true;
236
+ };
237
+ }>, import("@contractspec/lib.schema").SchemaModel<{
238
+ id: {
239
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
240
+ isOptional: false;
241
+ };
242
+ key: {
243
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
244
+ isOptional: false;
245
+ };
246
+ name: {
247
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
248
+ isOptional: false;
249
+ };
250
+ description: {
251
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
252
+ isOptional: true;
253
+ };
254
+ unit: {
255
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
256
+ isOptional: false;
257
+ };
258
+ aggregationType: {
259
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
260
+ isOptional: false;
261
+ };
262
+ resetPeriod: {
263
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
264
+ isOptional: false;
265
+ };
266
+ category: {
267
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
268
+ isOptional: true;
269
+ };
270
+ isActive: {
271
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
272
+ isOptional: false;
273
+ };
274
+ orgId: {
275
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
276
+ isOptional: true;
277
+ };
278
+ createdAt: {
279
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
280
+ isOptional: false;
281
+ };
282
+ updatedAt: {
283
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
284
+ isOptional: false;
285
+ };
290
286
  }>, undefined>;
291
287
  /**
292
288
  * Update a metric.
293
289
  */
294
- declare const UpdateMetricContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
295
- metricId: {
296
- type: _contractspec_lib_schema0.FieldType<string, string>;
297
- isOptional: false;
298
- };
299
- name: {
300
- type: _contractspec_lib_schema0.FieldType<string, string>;
301
- isOptional: true;
302
- };
303
- description: {
304
- type: _contractspec_lib_schema0.FieldType<string, string>;
305
- isOptional: true;
306
- };
307
- category: {
308
- type: _contractspec_lib_schema0.FieldType<string, string>;
309
- isOptional: true;
310
- };
311
- isActive: {
312
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
313
- isOptional: true;
314
- };
315
- metadata: {
316
- type: _contractspec_lib_schema0.FieldType<unknown, unknown>;
317
- isOptional: true;
318
- };
319
- }>, _contractspec_lib_schema0.SchemaModel<{
320
- id: {
321
- type: _contractspec_lib_schema0.FieldType<string, string>;
322
- isOptional: false;
323
- };
324
- key: {
325
- type: _contractspec_lib_schema0.FieldType<string, string>;
326
- isOptional: false;
327
- };
328
- name: {
329
- type: _contractspec_lib_schema0.FieldType<string, string>;
330
- isOptional: false;
331
- };
332
- description: {
333
- type: _contractspec_lib_schema0.FieldType<string, string>;
334
- isOptional: true;
335
- };
336
- unit: {
337
- type: _contractspec_lib_schema0.FieldType<string, string>;
338
- isOptional: false;
339
- };
340
- aggregationType: {
341
- type: _contractspec_lib_schema0.FieldType<string, string>;
342
- isOptional: false;
343
- };
344
- resetPeriod: {
345
- type: _contractspec_lib_schema0.FieldType<string, string>;
346
- isOptional: false;
347
- };
348
- category: {
349
- type: _contractspec_lib_schema0.FieldType<string, string>;
350
- isOptional: true;
351
- };
352
- isActive: {
353
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
354
- isOptional: false;
355
- };
356
- orgId: {
357
- type: _contractspec_lib_schema0.FieldType<string, string>;
358
- isOptional: true;
359
- };
360
- createdAt: {
361
- type: _contractspec_lib_schema0.FieldType<Date, string>;
362
- isOptional: false;
363
- };
364
- updatedAt: {
365
- type: _contractspec_lib_schema0.FieldType<Date, string>;
366
- isOptional: false;
367
- };
290
+ export declare const UpdateMetricContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
291
+ metricId: {
292
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
293
+ isOptional: false;
294
+ };
295
+ name: {
296
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
297
+ isOptional: true;
298
+ };
299
+ description: {
300
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
301
+ isOptional: true;
302
+ };
303
+ category: {
304
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
305
+ isOptional: true;
306
+ };
307
+ isActive: {
308
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
309
+ isOptional: true;
310
+ };
311
+ metadata: {
312
+ type: import("@contractspec/lib.schema").FieldType<unknown, unknown>;
313
+ isOptional: true;
314
+ };
315
+ }>, import("@contractspec/lib.schema").SchemaModel<{
316
+ id: {
317
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
318
+ isOptional: false;
319
+ };
320
+ key: {
321
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
322
+ isOptional: false;
323
+ };
324
+ name: {
325
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
326
+ isOptional: false;
327
+ };
328
+ description: {
329
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
330
+ isOptional: true;
331
+ };
332
+ unit: {
333
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
334
+ isOptional: false;
335
+ };
336
+ aggregationType: {
337
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
338
+ isOptional: false;
339
+ };
340
+ resetPeriod: {
341
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
342
+ isOptional: false;
343
+ };
344
+ category: {
345
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
346
+ isOptional: true;
347
+ };
348
+ isActive: {
349
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
350
+ isOptional: false;
351
+ };
352
+ orgId: {
353
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
354
+ isOptional: true;
355
+ };
356
+ createdAt: {
357
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
358
+ isOptional: false;
359
+ };
360
+ updatedAt: {
361
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
362
+ isOptional: false;
363
+ };
368
364
  }>, undefined>;
369
365
  /**
370
366
  * Delete a metric.
371
367
  */
372
- declare const DeleteMetricContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
373
- metricId: {
374
- type: _contractspec_lib_schema0.FieldType<string, string>;
375
- isOptional: false;
376
- };
377
- }>, _contractspec_lib_schema0.SchemaModel<{
378
- success: {
379
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
380
- isOptional: false;
381
- };
368
+ export declare const DeleteMetricContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
369
+ metricId: {
370
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
371
+ isOptional: false;
372
+ };
373
+ }>, import("@contractspec/lib.schema").SchemaModel<{
374
+ success: {
375
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
376
+ isOptional: false;
377
+ };
382
378
  }>, undefined>;
383
379
  /**
384
380
  * Get a metric by key.
385
381
  */
386
- declare const GetMetricContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
387
- key: {
388
- type: _contractspec_lib_schema0.FieldType<string, string>;
389
- isOptional: false;
390
- };
391
- orgId: {
392
- type: _contractspec_lib_schema0.FieldType<string, string>;
393
- isOptional: true;
394
- };
395
- }>, _contractspec_lib_schema0.SchemaModel<{
396
- id: {
397
- type: _contractspec_lib_schema0.FieldType<string, string>;
398
- isOptional: false;
399
- };
400
- key: {
401
- type: _contractspec_lib_schema0.FieldType<string, string>;
402
- isOptional: false;
403
- };
404
- name: {
405
- type: _contractspec_lib_schema0.FieldType<string, string>;
406
- isOptional: false;
407
- };
408
- description: {
409
- type: _contractspec_lib_schema0.FieldType<string, string>;
410
- isOptional: true;
411
- };
412
- unit: {
413
- type: _contractspec_lib_schema0.FieldType<string, string>;
414
- isOptional: false;
415
- };
416
- aggregationType: {
417
- type: _contractspec_lib_schema0.FieldType<string, string>;
418
- isOptional: false;
419
- };
420
- resetPeriod: {
421
- type: _contractspec_lib_schema0.FieldType<string, string>;
422
- isOptional: false;
423
- };
424
- category: {
425
- type: _contractspec_lib_schema0.FieldType<string, string>;
426
- isOptional: true;
427
- };
428
- isActive: {
429
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
430
- isOptional: false;
431
- };
432
- orgId: {
433
- type: _contractspec_lib_schema0.FieldType<string, string>;
434
- isOptional: true;
435
- };
436
- createdAt: {
437
- type: _contractspec_lib_schema0.FieldType<Date, string>;
438
- isOptional: false;
439
- };
440
- updatedAt: {
441
- type: _contractspec_lib_schema0.FieldType<Date, string>;
442
- isOptional: false;
443
- };
382
+ export declare const GetMetricContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
383
+ key: {
384
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
385
+ isOptional: false;
386
+ };
387
+ orgId: {
388
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
389
+ isOptional: true;
390
+ };
391
+ }>, import("@contractspec/lib.schema").SchemaModel<{
392
+ id: {
393
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
394
+ isOptional: false;
395
+ };
396
+ key: {
397
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
398
+ isOptional: false;
399
+ };
400
+ name: {
401
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
402
+ isOptional: false;
403
+ };
404
+ description: {
405
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
406
+ isOptional: true;
407
+ };
408
+ unit: {
409
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
410
+ isOptional: false;
411
+ };
412
+ aggregationType: {
413
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
414
+ isOptional: false;
415
+ };
416
+ resetPeriod: {
417
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
418
+ isOptional: false;
419
+ };
420
+ category: {
421
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
422
+ isOptional: true;
423
+ };
424
+ isActive: {
425
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
426
+ isOptional: false;
427
+ };
428
+ orgId: {
429
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
430
+ isOptional: true;
431
+ };
432
+ createdAt: {
433
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
434
+ isOptional: false;
435
+ };
436
+ updatedAt: {
437
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
438
+ isOptional: false;
439
+ };
444
440
  }>, undefined>;
445
441
  /**
446
442
  * List metrics.
447
443
  */
448
- declare const ListMetricsContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
449
- orgId: {
450
- type: _contractspec_lib_schema0.FieldType<string, string>;
451
- isOptional: true;
452
- };
453
- category: {
454
- type: _contractspec_lib_schema0.FieldType<string, string>;
455
- isOptional: true;
456
- };
457
- isActive: {
458
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
459
- isOptional: true;
460
- };
461
- limit: {
462
- type: _contractspec_lib_schema0.FieldType<number, number>;
463
- isOptional: true;
464
- };
465
- offset: {
466
- type: _contractspec_lib_schema0.FieldType<number, number>;
467
- isOptional: true;
468
- };
469
- }>, _contractspec_lib_schema0.SchemaModel<{
470
- metrics: {
471
- type: _contractspec_lib_schema0.SchemaModel<{
472
- id: {
473
- type: _contractspec_lib_schema0.FieldType<string, string>;
474
- isOptional: false;
475
- };
476
- key: {
477
- type: _contractspec_lib_schema0.FieldType<string, string>;
478
- isOptional: false;
479
- };
480
- name: {
481
- type: _contractspec_lib_schema0.FieldType<string, string>;
482
- isOptional: false;
483
- };
484
- description: {
485
- type: _contractspec_lib_schema0.FieldType<string, string>;
486
- isOptional: true;
487
- };
488
- unit: {
489
- type: _contractspec_lib_schema0.FieldType<string, string>;
490
- isOptional: false;
491
- };
492
- aggregationType: {
493
- type: _contractspec_lib_schema0.FieldType<string, string>;
494
- isOptional: false;
495
- };
496
- resetPeriod: {
497
- type: _contractspec_lib_schema0.FieldType<string, string>;
498
- isOptional: false;
499
- };
500
- category: {
501
- type: _contractspec_lib_schema0.FieldType<string, string>;
502
- isOptional: true;
503
- };
504
- isActive: {
505
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
506
- isOptional: false;
507
- };
508
- orgId: {
509
- type: _contractspec_lib_schema0.FieldType<string, string>;
510
- isOptional: true;
511
- };
512
- createdAt: {
513
- type: _contractspec_lib_schema0.FieldType<Date, string>;
514
- isOptional: false;
515
- };
516
- updatedAt: {
517
- type: _contractspec_lib_schema0.FieldType<Date, string>;
518
- isOptional: false;
519
- };
520
- }>;
521
- isArray: true;
522
- isOptional: false;
523
- };
524
- total: {
525
- type: _contractspec_lib_schema0.FieldType<number, number>;
526
- isOptional: false;
527
- };
444
+ export declare const ListMetricsContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
445
+ orgId: {
446
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
447
+ isOptional: true;
448
+ };
449
+ category: {
450
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
451
+ isOptional: true;
452
+ };
453
+ isActive: {
454
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
455
+ isOptional: true;
456
+ };
457
+ limit: {
458
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
459
+ isOptional: true;
460
+ };
461
+ offset: {
462
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
463
+ isOptional: true;
464
+ };
465
+ }>, import("@contractspec/lib.schema").SchemaModel<{
466
+ metrics: {
467
+ type: import("@contractspec/lib.schema").SchemaModel<{
468
+ id: {
469
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
470
+ isOptional: false;
471
+ };
472
+ key: {
473
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
474
+ isOptional: false;
475
+ };
476
+ name: {
477
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
478
+ isOptional: false;
479
+ };
480
+ description: {
481
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
482
+ isOptional: true;
483
+ };
484
+ unit: {
485
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
486
+ isOptional: false;
487
+ };
488
+ aggregationType: {
489
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
490
+ isOptional: false;
491
+ };
492
+ resetPeriod: {
493
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
494
+ isOptional: false;
495
+ };
496
+ category: {
497
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
498
+ isOptional: true;
499
+ };
500
+ isActive: {
501
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
502
+ isOptional: false;
503
+ };
504
+ orgId: {
505
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
506
+ isOptional: true;
507
+ };
508
+ createdAt: {
509
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
510
+ isOptional: false;
511
+ };
512
+ updatedAt: {
513
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
514
+ isOptional: false;
515
+ };
516
+ }>;
517
+ isArray: true;
518
+ isOptional: false;
519
+ };
520
+ total: {
521
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
522
+ isOptional: false;
523
+ };
528
524
  }>, undefined>;
529
525
  /**
530
526
  * Record usage.
531
527
  */
532
- declare const RecordUsageContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
533
- metricKey: {
534
- type: _contractspec_lib_schema0.FieldType<string, string>;
535
- isOptional: false;
536
- };
537
- subjectType: {
538
- type: _contractspec_lib_schema0.FieldType<string, string>;
539
- isOptional: false;
540
- };
541
- subjectId: {
542
- type: _contractspec_lib_schema0.FieldType<string, string>;
543
- isOptional: false;
544
- };
545
- quantity: {
546
- type: _contractspec_lib_schema0.FieldType<number, number>;
547
- isOptional: false;
548
- };
549
- timestamp: {
550
- type: _contractspec_lib_schema0.FieldType<Date, string>;
551
- isOptional: true;
552
- };
553
- source: {
554
- type: _contractspec_lib_schema0.FieldType<string, string>;
555
- isOptional: true;
556
- };
557
- resourceId: {
558
- type: _contractspec_lib_schema0.FieldType<string, string>;
559
- isOptional: true;
560
- };
561
- resourceType: {
562
- type: _contractspec_lib_schema0.FieldType<string, string>;
563
- isOptional: true;
564
- };
565
- metadata: {
566
- type: _contractspec_lib_schema0.FieldType<unknown, unknown>;
567
- isOptional: true;
568
- };
569
- idempotencyKey: {
570
- type: _contractspec_lib_schema0.FieldType<string, string>;
571
- isOptional: true;
572
- };
573
- }>, _contractspec_lib_schema0.SchemaModel<{
574
- id: {
575
- type: _contractspec_lib_schema0.FieldType<string, string>;
576
- isOptional: false;
577
- };
578
- metricKey: {
579
- type: _contractspec_lib_schema0.FieldType<string, string>;
580
- isOptional: false;
581
- };
582
- subjectType: {
583
- type: _contractspec_lib_schema0.FieldType<string, string>;
584
- isOptional: false;
585
- };
586
- subjectId: {
587
- type: _contractspec_lib_schema0.FieldType<string, string>;
588
- isOptional: false;
589
- };
590
- quantity: {
591
- type: _contractspec_lib_schema0.FieldType<number, number>;
592
- isOptional: false;
593
- };
594
- source: {
595
- type: _contractspec_lib_schema0.FieldType<string, string>;
596
- isOptional: true;
597
- };
598
- resourceId: {
599
- type: _contractspec_lib_schema0.FieldType<string, string>;
600
- isOptional: true;
601
- };
602
- resourceType: {
603
- type: _contractspec_lib_schema0.FieldType<string, string>;
604
- isOptional: true;
605
- };
606
- metadata: {
607
- type: _contractspec_lib_schema0.FieldType<unknown, unknown>;
608
- isOptional: true;
609
- };
610
- timestamp: {
611
- type: _contractspec_lib_schema0.FieldType<Date, string>;
612
- isOptional: false;
613
- };
614
- createdAt: {
615
- type: _contractspec_lib_schema0.FieldType<Date, string>;
616
- isOptional: false;
617
- };
528
+ export declare const RecordUsageContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
529
+ metricKey: {
530
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
531
+ isOptional: false;
532
+ };
533
+ subjectType: {
534
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
535
+ isOptional: false;
536
+ };
537
+ subjectId: {
538
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
539
+ isOptional: false;
540
+ };
541
+ quantity: {
542
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
543
+ isOptional: false;
544
+ };
545
+ timestamp: {
546
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
547
+ isOptional: true;
548
+ };
549
+ source: {
550
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
551
+ isOptional: true;
552
+ };
553
+ resourceId: {
554
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
555
+ isOptional: true;
556
+ };
557
+ resourceType: {
558
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
559
+ isOptional: true;
560
+ };
561
+ metadata: {
562
+ type: import("@contractspec/lib.schema").FieldType<unknown, unknown>;
563
+ isOptional: true;
564
+ };
565
+ idempotencyKey: {
566
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
567
+ isOptional: true;
568
+ };
569
+ }>, import("@contractspec/lib.schema").SchemaModel<{
570
+ id: {
571
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
572
+ isOptional: false;
573
+ };
574
+ metricKey: {
575
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
576
+ isOptional: false;
577
+ };
578
+ subjectType: {
579
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
580
+ isOptional: false;
581
+ };
582
+ subjectId: {
583
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
584
+ isOptional: false;
585
+ };
586
+ quantity: {
587
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
588
+ isOptional: false;
589
+ };
590
+ source: {
591
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
592
+ isOptional: true;
593
+ };
594
+ resourceId: {
595
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
596
+ isOptional: true;
597
+ };
598
+ resourceType: {
599
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
600
+ isOptional: true;
601
+ };
602
+ metadata: {
603
+ type: import("@contractspec/lib.schema").FieldType<unknown, unknown>;
604
+ isOptional: true;
605
+ };
606
+ timestamp: {
607
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
608
+ isOptional: false;
609
+ };
610
+ createdAt: {
611
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
612
+ isOptional: false;
613
+ };
618
614
  }>, undefined>;
619
615
  /**
620
616
  * Record batch usage.
621
617
  */
622
- declare const RecordBatchUsageContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
623
- records: {
624
- type: _contractspec_lib_schema0.SchemaModel<{
625
- metricKey: {
626
- type: _contractspec_lib_schema0.FieldType<string, string>;
627
- isOptional: false;
628
- };
629
- subjectType: {
630
- type: _contractspec_lib_schema0.FieldType<string, string>;
631
- isOptional: false;
632
- };
633
- subjectId: {
634
- type: _contractspec_lib_schema0.FieldType<string, string>;
635
- isOptional: false;
636
- };
637
- quantity: {
638
- type: _contractspec_lib_schema0.FieldType<number, number>;
639
- isOptional: false;
640
- };
641
- timestamp: {
642
- type: _contractspec_lib_schema0.FieldType<Date, string>;
643
- isOptional: true;
644
- };
645
- source: {
646
- type: _contractspec_lib_schema0.FieldType<string, string>;
647
- isOptional: true;
648
- };
649
- resourceId: {
650
- type: _contractspec_lib_schema0.FieldType<string, string>;
651
- isOptional: true;
652
- };
653
- resourceType: {
654
- type: _contractspec_lib_schema0.FieldType<string, string>;
655
- isOptional: true;
656
- };
657
- metadata: {
658
- type: _contractspec_lib_schema0.FieldType<unknown, unknown>;
659
- isOptional: true;
660
- };
661
- idempotencyKey: {
662
- type: _contractspec_lib_schema0.FieldType<string, string>;
663
- isOptional: true;
664
- };
665
- }>;
666
- isArray: true;
667
- isOptional: false;
668
- };
669
- }>, _contractspec_lib_schema0.SchemaModel<{
670
- recordedCount: {
671
- type: _contractspec_lib_schema0.FieldType<number, number>;
672
- isOptional: false;
673
- };
674
- skippedCount: {
675
- type: _contractspec_lib_schema0.FieldType<number, number>;
676
- isOptional: false;
677
- };
678
- recordIds: {
679
- type: _contractspec_lib_schema0.FieldType<unknown, unknown>;
680
- isOptional: false;
681
- };
618
+ export declare const RecordBatchUsageContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
619
+ records: {
620
+ type: import("@contractspec/lib.schema").SchemaModel<{
621
+ metricKey: {
622
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
623
+ isOptional: false;
624
+ };
625
+ subjectType: {
626
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
627
+ isOptional: false;
628
+ };
629
+ subjectId: {
630
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
631
+ isOptional: false;
632
+ };
633
+ quantity: {
634
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
635
+ isOptional: false;
636
+ };
637
+ timestamp: {
638
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
639
+ isOptional: true;
640
+ };
641
+ source: {
642
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
643
+ isOptional: true;
644
+ };
645
+ resourceId: {
646
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
647
+ isOptional: true;
648
+ };
649
+ resourceType: {
650
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
651
+ isOptional: true;
652
+ };
653
+ metadata: {
654
+ type: import("@contractspec/lib.schema").FieldType<unknown, unknown>;
655
+ isOptional: true;
656
+ };
657
+ idempotencyKey: {
658
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
659
+ isOptional: true;
660
+ };
661
+ }>;
662
+ isArray: true;
663
+ isOptional: false;
664
+ };
665
+ }>, import("@contractspec/lib.schema").SchemaModel<{
666
+ recordedCount: {
667
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
668
+ isOptional: false;
669
+ };
670
+ skippedCount: {
671
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
672
+ isOptional: false;
673
+ };
674
+ recordIds: {
675
+ type: import("@contractspec/lib.schema").FieldType<unknown, unknown>;
676
+ isOptional: false;
677
+ };
682
678
  }>, undefined>;
683
679
  /**
684
680
  * Get usage records.
685
681
  */
686
- declare const GetUsageContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
687
- metricKey: {
688
- type: _contractspec_lib_schema0.FieldType<string, string>;
689
- isOptional: false;
690
- };
691
- subjectType: {
692
- type: _contractspec_lib_schema0.FieldType<string, string>;
693
- isOptional: false;
694
- };
695
- subjectId: {
696
- type: _contractspec_lib_schema0.FieldType<string, string>;
697
- isOptional: false;
698
- };
699
- startDate: {
700
- type: _contractspec_lib_schema0.FieldType<Date, string>;
701
- isOptional: false;
702
- };
703
- endDate: {
704
- type: _contractspec_lib_schema0.FieldType<Date, string>;
705
- isOptional: false;
706
- };
707
- limit: {
708
- type: _contractspec_lib_schema0.FieldType<number, number>;
709
- isOptional: true;
710
- };
711
- offset: {
712
- type: _contractspec_lib_schema0.FieldType<number, number>;
713
- isOptional: true;
714
- };
715
- }>, _contractspec_lib_schema0.SchemaModel<{
716
- records: {
717
- type: _contractspec_lib_schema0.SchemaModel<{
718
- id: {
719
- type: _contractspec_lib_schema0.FieldType<string, string>;
720
- isOptional: false;
721
- };
722
- metricKey: {
723
- type: _contractspec_lib_schema0.FieldType<string, string>;
724
- isOptional: false;
725
- };
726
- subjectType: {
727
- type: _contractspec_lib_schema0.FieldType<string, string>;
728
- isOptional: false;
729
- };
730
- subjectId: {
731
- type: _contractspec_lib_schema0.FieldType<string, string>;
732
- isOptional: false;
733
- };
734
- quantity: {
735
- type: _contractspec_lib_schema0.FieldType<number, number>;
736
- isOptional: false;
737
- };
738
- source: {
739
- type: _contractspec_lib_schema0.FieldType<string, string>;
740
- isOptional: true;
741
- };
742
- resourceId: {
743
- type: _contractspec_lib_schema0.FieldType<string, string>;
744
- isOptional: true;
745
- };
746
- resourceType: {
747
- type: _contractspec_lib_schema0.FieldType<string, string>;
748
- isOptional: true;
749
- };
750
- metadata: {
751
- type: _contractspec_lib_schema0.FieldType<unknown, unknown>;
752
- isOptional: true;
753
- };
754
- timestamp: {
755
- type: _contractspec_lib_schema0.FieldType<Date, string>;
756
- isOptional: false;
757
- };
758
- createdAt: {
759
- type: _contractspec_lib_schema0.FieldType<Date, string>;
760
- isOptional: false;
761
- };
762
- }>;
763
- isArray: true;
764
- isOptional: false;
765
- };
766
- total: {
767
- type: _contractspec_lib_schema0.FieldType<number, number>;
768
- isOptional: false;
769
- };
770
- totalQuantity: {
771
- type: _contractspec_lib_schema0.FieldType<number, number>;
772
- isOptional: false;
773
- };
682
+ export declare const GetUsageContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
683
+ metricKey: {
684
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
685
+ isOptional: false;
686
+ };
687
+ subjectType: {
688
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
689
+ isOptional: false;
690
+ };
691
+ subjectId: {
692
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
693
+ isOptional: false;
694
+ };
695
+ startDate: {
696
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
697
+ isOptional: false;
698
+ };
699
+ endDate: {
700
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
701
+ isOptional: false;
702
+ };
703
+ limit: {
704
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
705
+ isOptional: true;
706
+ };
707
+ offset: {
708
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
709
+ isOptional: true;
710
+ };
711
+ }>, import("@contractspec/lib.schema").SchemaModel<{
712
+ records: {
713
+ type: import("@contractspec/lib.schema").SchemaModel<{
714
+ id: {
715
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
716
+ isOptional: false;
717
+ };
718
+ metricKey: {
719
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
720
+ isOptional: false;
721
+ };
722
+ subjectType: {
723
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
724
+ isOptional: false;
725
+ };
726
+ subjectId: {
727
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
728
+ isOptional: false;
729
+ };
730
+ quantity: {
731
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
732
+ isOptional: false;
733
+ };
734
+ source: {
735
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
736
+ isOptional: true;
737
+ };
738
+ resourceId: {
739
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
740
+ isOptional: true;
741
+ };
742
+ resourceType: {
743
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
744
+ isOptional: true;
745
+ };
746
+ metadata: {
747
+ type: import("@contractspec/lib.schema").FieldType<unknown, unknown>;
748
+ isOptional: true;
749
+ };
750
+ timestamp: {
751
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
752
+ isOptional: false;
753
+ };
754
+ createdAt: {
755
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
756
+ isOptional: false;
757
+ };
758
+ }>;
759
+ isArray: true;
760
+ isOptional: false;
761
+ };
762
+ total: {
763
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
764
+ isOptional: false;
765
+ };
766
+ totalQuantity: {
767
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
768
+ isOptional: false;
769
+ };
774
770
  }>, undefined>;
775
771
  /**
776
772
  * Get usage summary.
777
773
  */
778
- declare const GetUsageSummaryContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
779
- metricKey: {
780
- type: _contractspec_lib_schema0.FieldType<string, string>;
781
- isOptional: false;
782
- };
783
- subjectType: {
784
- type: _contractspec_lib_schema0.FieldType<string, string>;
785
- isOptional: false;
786
- };
787
- subjectId: {
788
- type: _contractspec_lib_schema0.FieldType<string, string>;
789
- isOptional: false;
790
- };
791
- periodType: {
792
- type: _contractspec_lib_schema0.FieldType<string, string>;
793
- isOptional: false;
794
- };
795
- startDate: {
796
- type: _contractspec_lib_schema0.FieldType<Date, string>;
797
- isOptional: false;
798
- };
799
- endDate: {
800
- type: _contractspec_lib_schema0.FieldType<Date, string>;
801
- isOptional: true;
802
- };
803
- }>, _contractspec_lib_schema0.SchemaModel<{
804
- summaries: {
805
- type: _contractspec_lib_schema0.SchemaModel<{
806
- id: {
807
- type: _contractspec_lib_schema0.FieldType<string, string>;
808
- isOptional: false;
809
- };
810
- metricKey: {
811
- type: _contractspec_lib_schema0.FieldType<string, string>;
812
- isOptional: false;
813
- };
814
- subjectType: {
815
- type: _contractspec_lib_schema0.FieldType<string, string>;
816
- isOptional: false;
817
- };
818
- subjectId: {
819
- type: _contractspec_lib_schema0.FieldType<string, string>;
820
- isOptional: false;
821
- };
822
- periodType: {
823
- type: _contractspec_lib_schema0.FieldType<string, string>;
824
- isOptional: false;
825
- };
826
- periodStart: {
827
- type: _contractspec_lib_schema0.FieldType<Date, string>;
828
- isOptional: false;
829
- };
830
- periodEnd: {
831
- type: _contractspec_lib_schema0.FieldType<Date, string>;
832
- isOptional: false;
833
- };
834
- totalQuantity: {
835
- type: _contractspec_lib_schema0.FieldType<number, number>;
836
- isOptional: false;
837
- };
838
- recordCount: {
839
- type: _contractspec_lib_schema0.FieldType<number, number>;
840
- isOptional: false;
841
- };
842
- minQuantity: {
843
- type: _contractspec_lib_schema0.FieldType<number, number>;
844
- isOptional: true;
845
- };
846
- maxQuantity: {
847
- type: _contractspec_lib_schema0.FieldType<number, number>;
848
- isOptional: true;
849
- };
850
- avgQuantity: {
851
- type: _contractspec_lib_schema0.FieldType<number, number>;
852
- isOptional: true;
853
- };
854
- }>;
855
- isArray: true;
856
- isOptional: false;
857
- };
858
- total: {
859
- type: _contractspec_lib_schema0.FieldType<number, number>;
860
- isOptional: false;
861
- };
774
+ export declare const GetUsageSummaryContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
775
+ metricKey: {
776
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
777
+ isOptional: false;
778
+ };
779
+ subjectType: {
780
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
781
+ isOptional: false;
782
+ };
783
+ subjectId: {
784
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
785
+ isOptional: false;
786
+ };
787
+ periodType: {
788
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
789
+ isOptional: false;
790
+ };
791
+ startDate: {
792
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
793
+ isOptional: false;
794
+ };
795
+ endDate: {
796
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
797
+ isOptional: true;
798
+ };
799
+ }>, import("@contractspec/lib.schema").SchemaModel<{
800
+ summaries: {
801
+ type: import("@contractspec/lib.schema").SchemaModel<{
802
+ id: {
803
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
804
+ isOptional: false;
805
+ };
806
+ metricKey: {
807
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
808
+ isOptional: false;
809
+ };
810
+ subjectType: {
811
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
812
+ isOptional: false;
813
+ };
814
+ subjectId: {
815
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
816
+ isOptional: false;
817
+ };
818
+ periodType: {
819
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
820
+ isOptional: false;
821
+ };
822
+ periodStart: {
823
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
824
+ isOptional: false;
825
+ };
826
+ periodEnd: {
827
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
828
+ isOptional: false;
829
+ };
830
+ totalQuantity: {
831
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
832
+ isOptional: false;
833
+ };
834
+ recordCount: {
835
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
836
+ isOptional: false;
837
+ };
838
+ minQuantity: {
839
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
840
+ isOptional: true;
841
+ };
842
+ maxQuantity: {
843
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
844
+ isOptional: true;
845
+ };
846
+ avgQuantity: {
847
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
848
+ isOptional: true;
849
+ };
850
+ }>;
851
+ isArray: true;
852
+ isOptional: false;
853
+ };
854
+ total: {
855
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
856
+ isOptional: false;
857
+ };
862
858
  }>, undefined>;
863
859
  /**
864
860
  * Create a threshold.
865
861
  */
866
- declare const CreateThresholdContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
867
- metricKey: {
868
- type: _contractspec_lib_schema0.FieldType<string, string>;
869
- isOptional: false;
870
- };
871
- subjectType: {
872
- type: _contractspec_lib_schema0.FieldType<string, string>;
873
- isOptional: true;
874
- };
875
- subjectId: {
876
- type: _contractspec_lib_schema0.FieldType<string, string>;
877
- isOptional: true;
878
- };
879
- name: {
880
- type: _contractspec_lib_schema0.FieldType<string, string>;
881
- isOptional: false;
882
- };
883
- threshold: {
884
- type: _contractspec_lib_schema0.FieldType<number, number>;
885
- isOptional: false;
886
- };
887
- warnThreshold: {
888
- type: _contractspec_lib_schema0.FieldType<number, number>;
889
- isOptional: true;
890
- };
891
- periodType: {
892
- type: _contractspec_lib_schema0.FieldType<string, string>;
893
- isOptional: true;
894
- };
895
- action: {
896
- type: _contractspec_lib_schema0.FieldType<string, string>;
897
- isOptional: true;
898
- };
899
- notifyEmails: {
900
- type: _contractspec_lib_schema0.FieldType<unknown, unknown>;
901
- isOptional: true;
902
- };
903
- notifyWebhook: {
904
- type: _contractspec_lib_schema0.FieldType<string, string>;
905
- isOptional: true;
906
- };
907
- }>, _contractspec_lib_schema0.SchemaModel<{
908
- id: {
909
- type: _contractspec_lib_schema0.FieldType<string, string>;
910
- isOptional: false;
911
- };
912
- metricKey: {
913
- type: _contractspec_lib_schema0.FieldType<string, string>;
914
- isOptional: false;
915
- };
916
- subjectType: {
917
- type: _contractspec_lib_schema0.FieldType<string, string>;
918
- isOptional: true;
919
- };
920
- subjectId: {
921
- type: _contractspec_lib_schema0.FieldType<string, string>;
922
- isOptional: true;
923
- };
924
- name: {
925
- type: _contractspec_lib_schema0.FieldType<string, string>;
926
- isOptional: false;
927
- };
928
- threshold: {
929
- type: _contractspec_lib_schema0.FieldType<number, number>;
930
- isOptional: false;
931
- };
932
- warnThreshold: {
933
- type: _contractspec_lib_schema0.FieldType<number, number>;
934
- isOptional: true;
935
- };
936
- periodType: {
937
- type: _contractspec_lib_schema0.FieldType<string, string>;
938
- isOptional: false;
939
- };
940
- action: {
941
- type: _contractspec_lib_schema0.FieldType<string, string>;
942
- isOptional: false;
943
- };
944
- currentValue: {
945
- type: _contractspec_lib_schema0.FieldType<number, number>;
946
- isOptional: false;
947
- };
948
- isActive: {
949
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
950
- isOptional: false;
951
- };
952
- createdAt: {
953
- type: _contractspec_lib_schema0.FieldType<Date, string>;
954
- isOptional: false;
955
- };
862
+ export declare const CreateThresholdContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
863
+ metricKey: {
864
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
865
+ isOptional: false;
866
+ };
867
+ subjectType: {
868
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
869
+ isOptional: true;
870
+ };
871
+ subjectId: {
872
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
873
+ isOptional: true;
874
+ };
875
+ name: {
876
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
877
+ isOptional: false;
878
+ };
879
+ threshold: {
880
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
881
+ isOptional: false;
882
+ };
883
+ warnThreshold: {
884
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
885
+ isOptional: true;
886
+ };
887
+ periodType: {
888
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
889
+ isOptional: true;
890
+ };
891
+ action: {
892
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
893
+ isOptional: true;
894
+ };
895
+ notifyEmails: {
896
+ type: import("@contractspec/lib.schema").FieldType<unknown, unknown>;
897
+ isOptional: true;
898
+ };
899
+ notifyWebhook: {
900
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
901
+ isOptional: true;
902
+ };
903
+ }>, import("@contractspec/lib.schema").SchemaModel<{
904
+ id: {
905
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
906
+ isOptional: false;
907
+ };
908
+ metricKey: {
909
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
910
+ isOptional: false;
911
+ };
912
+ subjectType: {
913
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
914
+ isOptional: true;
915
+ };
916
+ subjectId: {
917
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
918
+ isOptional: true;
919
+ };
920
+ name: {
921
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
922
+ isOptional: false;
923
+ };
924
+ threshold: {
925
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
926
+ isOptional: false;
927
+ };
928
+ warnThreshold: {
929
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
930
+ isOptional: true;
931
+ };
932
+ periodType: {
933
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
934
+ isOptional: false;
935
+ };
936
+ action: {
937
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
938
+ isOptional: false;
939
+ };
940
+ currentValue: {
941
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
942
+ isOptional: false;
943
+ };
944
+ isActive: {
945
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
946
+ isOptional: false;
947
+ };
948
+ createdAt: {
949
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
950
+ isOptional: false;
951
+ };
956
952
  }>, undefined>;
957
953
  /**
958
954
  * Update a threshold.
959
955
  */
960
- declare const UpdateThresholdContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
961
- thresholdId: {
962
- type: _contractspec_lib_schema0.FieldType<string, string>;
963
- isOptional: false;
964
- };
965
- name: {
966
- type: _contractspec_lib_schema0.FieldType<string, string>;
967
- isOptional: true;
968
- };
969
- threshold: {
970
- type: _contractspec_lib_schema0.FieldType<number, number>;
971
- isOptional: true;
972
- };
973
- warnThreshold: {
974
- type: _contractspec_lib_schema0.FieldType<number, number>;
975
- isOptional: true;
976
- };
977
- action: {
978
- type: _contractspec_lib_schema0.FieldType<string, string>;
979
- isOptional: true;
980
- };
981
- notifyEmails: {
982
- type: _contractspec_lib_schema0.FieldType<unknown, unknown>;
983
- isOptional: true;
984
- };
985
- notifyWebhook: {
986
- type: _contractspec_lib_schema0.FieldType<string, string>;
987
- isOptional: true;
988
- };
989
- isActive: {
990
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
991
- isOptional: true;
992
- };
993
- }>, _contractspec_lib_schema0.SchemaModel<{
994
- id: {
995
- type: _contractspec_lib_schema0.FieldType<string, string>;
996
- isOptional: false;
997
- };
998
- metricKey: {
999
- type: _contractspec_lib_schema0.FieldType<string, string>;
1000
- isOptional: false;
1001
- };
1002
- subjectType: {
1003
- type: _contractspec_lib_schema0.FieldType<string, string>;
1004
- isOptional: true;
1005
- };
1006
- subjectId: {
1007
- type: _contractspec_lib_schema0.FieldType<string, string>;
1008
- isOptional: true;
1009
- };
1010
- name: {
1011
- type: _contractspec_lib_schema0.FieldType<string, string>;
1012
- isOptional: false;
1013
- };
1014
- threshold: {
1015
- type: _contractspec_lib_schema0.FieldType<number, number>;
1016
- isOptional: false;
1017
- };
1018
- warnThreshold: {
1019
- type: _contractspec_lib_schema0.FieldType<number, number>;
1020
- isOptional: true;
1021
- };
1022
- periodType: {
1023
- type: _contractspec_lib_schema0.FieldType<string, string>;
1024
- isOptional: false;
1025
- };
1026
- action: {
1027
- type: _contractspec_lib_schema0.FieldType<string, string>;
1028
- isOptional: false;
1029
- };
1030
- currentValue: {
1031
- type: _contractspec_lib_schema0.FieldType<number, number>;
1032
- isOptional: false;
1033
- };
1034
- isActive: {
1035
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
1036
- isOptional: false;
1037
- };
1038
- createdAt: {
1039
- type: _contractspec_lib_schema0.FieldType<Date, string>;
1040
- isOptional: false;
1041
- };
956
+ export declare const UpdateThresholdContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
957
+ thresholdId: {
958
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
959
+ isOptional: false;
960
+ };
961
+ name: {
962
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
963
+ isOptional: true;
964
+ };
965
+ threshold: {
966
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
967
+ isOptional: true;
968
+ };
969
+ warnThreshold: {
970
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
971
+ isOptional: true;
972
+ };
973
+ action: {
974
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
975
+ isOptional: true;
976
+ };
977
+ notifyEmails: {
978
+ type: import("@contractspec/lib.schema").FieldType<unknown, unknown>;
979
+ isOptional: true;
980
+ };
981
+ notifyWebhook: {
982
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
983
+ isOptional: true;
984
+ };
985
+ isActive: {
986
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
987
+ isOptional: true;
988
+ };
989
+ }>, import("@contractspec/lib.schema").SchemaModel<{
990
+ id: {
991
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
992
+ isOptional: false;
993
+ };
994
+ metricKey: {
995
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
996
+ isOptional: false;
997
+ };
998
+ subjectType: {
999
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1000
+ isOptional: true;
1001
+ };
1002
+ subjectId: {
1003
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1004
+ isOptional: true;
1005
+ };
1006
+ name: {
1007
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1008
+ isOptional: false;
1009
+ };
1010
+ threshold: {
1011
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
1012
+ isOptional: false;
1013
+ };
1014
+ warnThreshold: {
1015
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
1016
+ isOptional: true;
1017
+ };
1018
+ periodType: {
1019
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1020
+ isOptional: false;
1021
+ };
1022
+ action: {
1023
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1024
+ isOptional: false;
1025
+ };
1026
+ currentValue: {
1027
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
1028
+ isOptional: false;
1029
+ };
1030
+ isActive: {
1031
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
1032
+ isOptional: false;
1033
+ };
1034
+ createdAt: {
1035
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
1036
+ isOptional: false;
1037
+ };
1042
1038
  }>, undefined>;
1043
1039
  /**
1044
1040
  * Delete a threshold.
1045
1041
  */
1046
- declare const DeleteThresholdContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
1047
- thresholdId: {
1048
- type: _contractspec_lib_schema0.FieldType<string, string>;
1049
- isOptional: false;
1050
- };
1051
- }>, _contractspec_lib_schema0.SchemaModel<{
1052
- success: {
1053
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
1054
- isOptional: false;
1055
- };
1042
+ export declare const DeleteThresholdContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
1043
+ thresholdId: {
1044
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1045
+ isOptional: false;
1046
+ };
1047
+ }>, import("@contractspec/lib.schema").SchemaModel<{
1048
+ success: {
1049
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
1050
+ isOptional: false;
1051
+ };
1056
1052
  }>, undefined>;
1057
1053
  /**
1058
1054
  * List thresholds.
1059
1055
  */
1060
- declare const ListThresholdsContract: _contractspec_lib_contracts0.OperationSpec<_contractspec_lib_schema0.SchemaModel<{
1061
- metricKey: {
1062
- type: _contractspec_lib_schema0.FieldType<string, string>;
1063
- isOptional: true;
1064
- };
1065
- subjectType: {
1066
- type: _contractspec_lib_schema0.FieldType<string, string>;
1067
- isOptional: true;
1068
- };
1069
- subjectId: {
1070
- type: _contractspec_lib_schema0.FieldType<string, string>;
1071
- isOptional: true;
1072
- };
1073
- isActive: {
1074
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
1075
- isOptional: true;
1076
- };
1077
- }>, _contractspec_lib_schema0.SchemaModel<{
1078
- thresholds: {
1079
- type: _contractspec_lib_schema0.SchemaModel<{
1080
- id: {
1081
- type: _contractspec_lib_schema0.FieldType<string, string>;
1082
- isOptional: false;
1083
- };
1084
- metricKey: {
1085
- type: _contractspec_lib_schema0.FieldType<string, string>;
1086
- isOptional: false;
1087
- };
1088
- subjectType: {
1089
- type: _contractspec_lib_schema0.FieldType<string, string>;
1090
- isOptional: true;
1091
- };
1092
- subjectId: {
1093
- type: _contractspec_lib_schema0.FieldType<string, string>;
1094
- isOptional: true;
1095
- };
1096
- name: {
1097
- type: _contractspec_lib_schema0.FieldType<string, string>;
1098
- isOptional: false;
1099
- };
1100
- threshold: {
1101
- type: _contractspec_lib_schema0.FieldType<number, number>;
1102
- isOptional: false;
1103
- };
1104
- warnThreshold: {
1105
- type: _contractspec_lib_schema0.FieldType<number, number>;
1106
- isOptional: true;
1107
- };
1108
- periodType: {
1109
- type: _contractspec_lib_schema0.FieldType<string, string>;
1110
- isOptional: false;
1111
- };
1112
- action: {
1113
- type: _contractspec_lib_schema0.FieldType<string, string>;
1114
- isOptional: false;
1115
- };
1116
- currentValue: {
1117
- type: _contractspec_lib_schema0.FieldType<number, number>;
1118
- isOptional: false;
1119
- };
1120
- isActive: {
1121
- type: _contractspec_lib_schema0.FieldType<boolean, boolean>;
1122
- isOptional: false;
1123
- };
1124
- createdAt: {
1125
- type: _contractspec_lib_schema0.FieldType<Date, string>;
1126
- isOptional: false;
1127
- };
1128
- }>;
1129
- isArray: true;
1130
- isOptional: false;
1131
- };
1132
- total: {
1133
- type: _contractspec_lib_schema0.FieldType<number, number>;
1134
- isOptional: false;
1135
- };
1056
+ export declare const ListThresholdsContract: import("@contractspec/lib.contracts").OperationSpec<import("@contractspec/lib.schema").SchemaModel<{
1057
+ metricKey: {
1058
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1059
+ isOptional: true;
1060
+ };
1061
+ subjectType: {
1062
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1063
+ isOptional: true;
1064
+ };
1065
+ subjectId: {
1066
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1067
+ isOptional: true;
1068
+ };
1069
+ isActive: {
1070
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
1071
+ isOptional: true;
1072
+ };
1073
+ }>, import("@contractspec/lib.schema").SchemaModel<{
1074
+ thresholds: {
1075
+ type: import("@contractspec/lib.schema").SchemaModel<{
1076
+ id: {
1077
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1078
+ isOptional: false;
1079
+ };
1080
+ metricKey: {
1081
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1082
+ isOptional: false;
1083
+ };
1084
+ subjectType: {
1085
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1086
+ isOptional: true;
1087
+ };
1088
+ subjectId: {
1089
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1090
+ isOptional: true;
1091
+ };
1092
+ name: {
1093
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1094
+ isOptional: false;
1095
+ };
1096
+ threshold: {
1097
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
1098
+ isOptional: false;
1099
+ };
1100
+ warnThreshold: {
1101
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
1102
+ isOptional: true;
1103
+ };
1104
+ periodType: {
1105
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1106
+ isOptional: false;
1107
+ };
1108
+ action: {
1109
+ type: import("@contractspec/lib.schema").FieldType<string, string>;
1110
+ isOptional: false;
1111
+ };
1112
+ currentValue: {
1113
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
1114
+ isOptional: false;
1115
+ };
1116
+ isActive: {
1117
+ type: import("@contractspec/lib.schema").FieldType<boolean, boolean>;
1118
+ isOptional: false;
1119
+ };
1120
+ createdAt: {
1121
+ type: import("@contractspec/lib.schema").FieldType<Date, string>;
1122
+ isOptional: false;
1123
+ };
1124
+ }>;
1125
+ isArray: true;
1126
+ isOptional: false;
1127
+ };
1128
+ total: {
1129
+ type: import("@contractspec/lib.schema").FieldType<number, number>;
1130
+ isOptional: false;
1131
+ };
1136
1132
  }>, undefined>;
1137
- //#endregion
1138
- export { CreateThresholdContract, DefineMetricContract, DeleteMetricContract, DeleteThresholdContract, GetMetricContract, GetUsageContract, GetUsageSummaryContract, ListMetricsContract, ListThresholdsContract, MetricDefinitionModel, RecordBatchUsageContract, RecordUsageContract, UpdateMetricContract, UpdateThresholdContract, UsageRecordModel, UsageSummaryModel, UsageThresholdModel };
1139
1133
  //# sourceMappingURL=index.d.ts.map