checkly 8.14.1 → 8.15.0-prerelease-cdf176f

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 (148) hide show
  1. package/dist/ai-context/context.d.ts +18 -0
  2. package/dist/ai-context/context.js +89 -0
  3. package/dist/ai-context/context.js.map +1 -1
  4. package/dist/ai-context/skills-command/references/configure-grpc-monitors.md +37 -0
  5. package/dist/ai-context/skills-command/references/configure-playwright-checks.md +5 -5
  6. package/dist/ai-context/skills-command/references/configure-ssl-monitors.md +39 -0
  7. package/dist/ai-context/skills-command/references/configure-traceroute-monitors.md +36 -0
  8. package/dist/ai-context/skills-command/references/configure.md +9 -0
  9. package/dist/commands/checks/stats.js +1 -0
  10. package/dist/commands/checks/stats.js.map +1 -1
  11. package/dist/commands/deploy.js +25 -16
  12. package/dist/commands/deploy.js.map +1 -1
  13. package/dist/constants.d.ts +4 -1
  14. package/dist/constants.js +3 -0
  15. package/dist/constants.js.map +1 -1
  16. package/dist/constructs/api-assertion-codegen.js +2 -2
  17. package/dist/constructs/api-assertion-codegen.js.map +1 -1
  18. package/dist/constructs/api-assertion.d.ts +3 -3
  19. package/dist/constructs/check-codegen.d.ts +6 -0
  20. package/dist/constructs/check-codegen.js +24 -0
  21. package/dist/constructs/check-codegen.js.map +1 -1
  22. package/dist/constructs/dns-assertion-codegen.js +2 -2
  23. package/dist/constructs/dns-assertion-codegen.js.map +1 -1
  24. package/dist/constructs/dns-assertion.d.ts +3 -3
  25. package/dist/constructs/dns-request.d.ts +2 -2
  26. package/dist/constructs/grpc-assertion-codegen.d.ts +3 -0
  27. package/dist/constructs/grpc-assertion-codegen.js +33 -0
  28. package/dist/constructs/grpc-assertion-codegen.js.map +1 -0
  29. package/dist/constructs/grpc-assertion-validation.d.ts +13 -0
  30. package/dist/constructs/grpc-assertion-validation.js +53 -0
  31. package/dist/constructs/grpc-assertion-validation.js.map +1 -0
  32. package/dist/constructs/grpc-assertion.d.ts +61 -0
  33. package/dist/constructs/grpc-assertion.js +71 -0
  34. package/dist/constructs/grpc-assertion.js.map +1 -0
  35. package/dist/constructs/grpc-monitor-codegen.d.ts +13 -0
  36. package/dist/constructs/grpc-monitor-codegen.js +34 -0
  37. package/dist/constructs/grpc-monitor-codegen.js.map +1 -0
  38. package/dist/constructs/grpc-monitor.d.ts +83 -0
  39. package/dist/constructs/grpc-monitor.js +56 -0
  40. package/dist/constructs/grpc-monitor.js.map +1 -0
  41. package/dist/constructs/grpc-request-codegen.d.ts +4 -0
  42. package/dist/constructs/grpc-request-codegen.js +68 -0
  43. package/dist/constructs/grpc-request-codegen.js.map +1 -0
  44. package/dist/constructs/grpc-request.d.ts +137 -0
  45. package/dist/constructs/grpc-request.js +2 -0
  46. package/dist/constructs/grpc-request.js.map +1 -0
  47. package/dist/constructs/icmp-assertion-codegen.js +2 -2
  48. package/dist/constructs/icmp-assertion-codegen.js.map +1 -1
  49. package/dist/constructs/icmp-assertion.d.ts +1 -1
  50. package/dist/constructs/icmp-request.d.ts +2 -2
  51. package/dist/constructs/index.d.ts +9 -0
  52. package/dist/constructs/index.js +9 -0
  53. package/dist/constructs/index.js.map +1 -1
  54. package/dist/constructs/internal/assertion-codegen.d.ts +11 -0
  55. package/dist/constructs/internal/assertion-codegen.js +39 -0
  56. package/dist/constructs/internal/assertion-codegen.js.map +1 -1
  57. package/dist/constructs/internal/assertion-validation.d.ts +3 -0
  58. package/dist/constructs/internal/assertion-validation.js +17 -0
  59. package/dist/constructs/internal/assertion-validation.js.map +1 -0
  60. package/dist/constructs/internal/assertion.d.ts +17 -11
  61. package/dist/constructs/internal/assertion.js +39 -38
  62. package/dist/constructs/internal/assertion.js.map +1 -1
  63. package/dist/constructs/internal/common-diagnostics.d.ts +1 -0
  64. package/dist/constructs/internal/common-diagnostics.js +14 -0
  65. package/dist/constructs/internal/common-diagnostics.js.map +1 -1
  66. package/dist/constructs/ssl-assertion-codegen.d.ts +3 -0
  67. package/dist/constructs/ssl-assertion-codegen.js +36 -0
  68. package/dist/constructs/ssl-assertion-codegen.js.map +1 -0
  69. package/dist/constructs/ssl-assertion-validation.d.ts +13 -0
  70. package/dist/constructs/ssl-assertion-validation.js +49 -0
  71. package/dist/constructs/ssl-assertion-validation.js.map +1 -0
  72. package/dist/constructs/ssl-assertion.d.ts +197 -0
  73. package/dist/constructs/ssl-assertion.js +267 -0
  74. package/dist/constructs/ssl-assertion.js.map +1 -0
  75. package/dist/constructs/ssl-monitor-codegen.d.ts +36 -0
  76. package/dist/constructs/ssl-monitor-codegen.js +51 -0
  77. package/dist/constructs/ssl-monitor-codegen.js.map +1 -0
  78. package/dist/constructs/ssl-monitor.d.ts +89 -0
  79. package/dist/constructs/ssl-monitor.js +73 -0
  80. package/dist/constructs/ssl-monitor.js.map +1 -0
  81. package/dist/constructs/ssl-request-codegen.d.ts +4 -0
  82. package/dist/constructs/ssl-request-codegen.js +48 -0
  83. package/dist/constructs/ssl-request-codegen.js.map +1 -0
  84. package/dist/constructs/ssl-request.d.ts +143 -0
  85. package/dist/constructs/ssl-request.js +2 -0
  86. package/dist/constructs/ssl-request.js.map +1 -0
  87. package/dist/constructs/tcp-monitor-codegen.js +2 -2
  88. package/dist/constructs/tcp-monitor-codegen.js.map +1 -1
  89. package/dist/constructs/tcp-monitor.d.ts +1 -1
  90. package/dist/constructs/traceroute-assertion-codegen.d.ts +3 -0
  91. package/dist/constructs/traceroute-assertion-codegen.js +17 -0
  92. package/dist/constructs/traceroute-assertion-codegen.js.map +1 -0
  93. package/dist/constructs/traceroute-assertion-validation.d.ts +11 -0
  94. package/dist/constructs/traceroute-assertion-validation.js +77 -0
  95. package/dist/constructs/traceroute-assertion-validation.js.map +1 -0
  96. package/dist/constructs/traceroute-assertion.d.ts +67 -0
  97. package/dist/constructs/traceroute-assertion.js +96 -0
  98. package/dist/constructs/traceroute-assertion.js.map +1 -0
  99. package/dist/constructs/traceroute-monitor-codegen.d.ts +13 -0
  100. package/dist/constructs/traceroute-monitor-codegen.js +34 -0
  101. package/dist/constructs/traceroute-monitor-codegen.js.map +1 -0
  102. package/dist/constructs/traceroute-monitor.d.ts +83 -0
  103. package/dist/constructs/traceroute-monitor.js +54 -0
  104. package/dist/constructs/traceroute-monitor.js.map +1 -0
  105. package/dist/constructs/traceroute-request-codegen.d.ts +4 -0
  106. package/dist/constructs/traceroute-request-codegen.js +41 -0
  107. package/dist/constructs/traceroute-request-codegen.js.map +1 -0
  108. package/dist/constructs/traceroute-request.d.ts +81 -0
  109. package/dist/constructs/traceroute-request.js +2 -0
  110. package/dist/constructs/traceroute-request.js.map +1 -0
  111. package/dist/constructs/url-assertion-codegen.js +2 -2
  112. package/dist/constructs/url-assertion-codegen.js.map +1 -1
  113. package/dist/formatters/assertion-line.d.ts +27 -0
  114. package/dist/formatters/assertion-line.js +126 -0
  115. package/dist/formatters/assertion-line.js.map +1 -0
  116. package/dist/formatters/batch-stats.js +20 -1
  117. package/dist/formatters/batch-stats.js.map +1 -1
  118. package/dist/formatters/check-result-detail.js +604 -1
  119. package/dist/formatters/check-result-detail.js.map +1 -1
  120. package/dist/helpers/cli-mode.d.ts +2 -2
  121. package/dist/helpers/cli-mode.js +103 -11
  122. package/dist/helpers/cli-mode.js.map +1 -1
  123. package/dist/reporters/json.d.ts +1 -0
  124. package/dist/reporters/json.js +58 -0
  125. package/dist/reporters/json.js.map +1 -1
  126. package/dist/reporters/util.js +192 -89
  127. package/dist/reporters/util.js.map +1 -1
  128. package/dist/rest/analytics.js +6 -0
  129. package/dist/rest/analytics.js.map +1 -1
  130. package/dist/rest/batch-analytics.d.ts +1 -0
  131. package/dist/rest/batch-analytics.js.map +1 -1
  132. package/dist/rest/check-results.d.ts +75 -1
  133. package/dist/rest/check-results.js.map +1 -1
  134. package/dist/rest/projects.d.ts +1 -1
  135. package/dist/services/check-parser/bundler.d.ts +6 -0
  136. package/dist/services/check-parser/bundler.js +8 -0
  137. package/dist/services/check-parser/bundler.js.map +1 -1
  138. package/dist/services/check-parser/cache-hash.d.ts +24 -2
  139. package/dist/services/check-parser/cache-hash.js +45 -3
  140. package/dist/services/check-parser/cache-hash.js.map +1 -1
  141. package/dist/services/check-parser/package-files/resolver.d.ts +6 -1
  142. package/dist/services/check-parser/package-files/resolver.js +19 -0
  143. package/dist/services/check-parser/package-files/resolver.js.map +1 -1
  144. package/dist/services/util.d.ts +4 -0
  145. package/dist/services/util.js +4 -0
  146. package/dist/services/util.js.map +1 -1
  147. package/oclif.manifest.json +214 -208
  148. package/package.json +1 -1
@@ -14,6 +14,9 @@ import { TcpMonitorCodegen } from './tcp-monitor-codegen.js';
14
14
  import { UrlMonitorCodegen } from './url-monitor-codegen.js';
15
15
  import { DnsMonitorCodegen } from './dns-monitor-codegen.js';
16
16
  import { IcmpMonitorCodegen } from './icmp-monitor-codegen.js';
17
+ import { GrpcMonitorCodegen } from './grpc-monitor-codegen.js';
18
+ import { SslMonitorCodegen } from './ssl-monitor-codegen.js';
19
+ import { TracerouteMonitorCodegen } from './traceroute-monitor-codegen.js';
17
20
  export interface CheckResource {
18
21
  id: string;
19
22
  checkType: string;
@@ -68,6 +71,9 @@ export declare class CheckCodegen extends Codegen<CheckResource> {
68
71
  urlMonitorCodegen: UrlMonitorCodegen;
69
72
  dnsMonitorCodegen: DnsMonitorCodegen;
70
73
  icmpMonitorCodegen: IcmpMonitorCodegen;
74
+ grpcMonitorCodegen: GrpcMonitorCodegen;
75
+ sslMonitorCodegen: SslMonitorCodegen;
76
+ tracerouteMonitorCodegen: TracerouteMonitorCodegen;
71
77
  constructor(program: Program);
72
78
  describe(resource: CheckResource): string;
73
79
  gencode(logicalId: string, resource: CheckResource, context: Context): void;
@@ -15,6 +15,9 @@ import { valueForPrivateLocationFromId } from './private-location-codegen.js';
15
15
  import { valueForAlertChannelFromId } from './alert-channel-codegen.js';
16
16
  import { DnsMonitorCodegen } from './dns-monitor-codegen.js';
17
17
  import { IcmpMonitorCodegen } from './icmp-monitor-codegen.js';
18
+ import { GrpcMonitorCodegen } from './grpc-monitor-codegen.js';
19
+ import { SslMonitorCodegen } from './ssl-monitor-codegen.js';
20
+ import { TracerouteMonitorCodegen } from './traceroute-monitor-codegen.js';
18
21
  export function buildCheckProps(program, genfile, builder, resource, context, options = {}) {
19
22
  builder.string('name', resource.name, { order: -1000 });
20
23
  if (resource.description != null) {
@@ -175,6 +178,9 @@ export class CheckCodegen extends Codegen {
175
178
  urlMonitorCodegen;
176
179
  dnsMonitorCodegen;
177
180
  icmpMonitorCodegen;
181
+ grpcMonitorCodegen;
182
+ sslMonitorCodegen;
183
+ tracerouteMonitorCodegen;
178
184
  constructor(program) {
179
185
  super(program);
180
186
  this.agenticCheckCodegen = new AgenticCheckCodegen(program);
@@ -187,6 +193,9 @@ export class CheckCodegen extends Codegen {
187
193
  this.urlMonitorCodegen = new UrlMonitorCodegen(program);
188
194
  this.dnsMonitorCodegen = new DnsMonitorCodegen(program);
189
195
  this.icmpMonitorCodegen = new IcmpMonitorCodegen(program);
196
+ this.grpcMonitorCodegen = new GrpcMonitorCodegen(program);
197
+ this.sslMonitorCodegen = new SslMonitorCodegen(program);
198
+ this.tracerouteMonitorCodegen = new TracerouteMonitorCodegen(program);
190
199
  }
191
200
  describe(resource) {
192
201
  const { checkType } = resource;
@@ -209,6 +218,12 @@ export class CheckCodegen extends Codegen {
209
218
  return this.dnsMonitorCodegen.describe(resource);
210
219
  case 'ICMP':
211
220
  return this.icmpMonitorCodegen.describe(resource);
221
+ case 'GRPC':
222
+ return this.grpcMonitorCodegen.describe(resource);
223
+ case 'SSL':
224
+ return this.sslMonitorCodegen.describe(resource);
225
+ case 'TRACEROUTE':
226
+ return this.tracerouteMonitorCodegen.describe(resource);
212
227
  default:
213
228
  throw new Error(`Unable to describe unsupported check type '${checkType}'.`);
214
229
  }
@@ -243,6 +258,15 @@ export class CheckCodegen extends Codegen {
243
258
  case 'ICMP':
244
259
  this.icmpMonitorCodegen.gencode(logicalId, resource, context);
245
260
  return;
261
+ case 'GRPC':
262
+ this.grpcMonitorCodegen.gencode(logicalId, resource, context);
263
+ return;
264
+ case 'SSL':
265
+ this.sslMonitorCodegen.gencode(logicalId, resource, context);
266
+ return;
267
+ case 'TRACEROUTE':
268
+ this.tracerouteMonitorCodegen.gencode(logicalId, resource, context);
269
+ return;
246
270
  default:
247
271
  throw new Error(`Unable to generate code for unsupported check type '${checkType}'.`);
248
272
  }
@@ -1 +1 @@
1
- {"version":3,"file":"check-codegen.js","sourceRoot":"","sources":["../../src/constructs/check-codegen.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAW,MAAM,6BAA6B,CAAA;AAE9D,OAAO,EAAE,mBAAmB,EAAwB,MAAM,4BAA4B,CAAA;AACtF,OAAO,EAA2B,uBAAuB,EAAE,MAAM,sCAAsC,CAAA;AACvG,OAAO,EAAE,eAAe,EAAoB,MAAM,wBAAwB,CAAA;AAC1E,OAAO,EAAE,mBAAmB,EAAwB,MAAM,4BAA4B,CAAA;AACtF,OAAO,EAAE,iBAAiB,EAAE,wBAAwB,EAAE,MAAM,0BAA0B,CAAA;AAEtF,OAAO,EAAqB,iBAAiB,EAAE,MAAM,wBAAwB,CAAA;AAC7E,OAAO,EAAE,uBAAuB,EAA4B,MAAM,gCAAgC,CAAA;AAClG,OAAO,EAAE,oBAAoB,EAAE,MAAM,6BAA6B,CAAA;AAClE,OAAO,EAAE,qBAAqB,EAA0B,MAAM,+BAA+B,CAAA;AAC7F,OAAO,EAAyB,qBAAqB,EAAE,MAAM,6BAA6B,CAAA;AAC1F,OAAO,EAAE,iBAAiB,EAAsB,MAAM,0BAA0B,CAAA;AAChF,OAAO,EAAE,iBAAiB,EAAsB,MAAM,0BAA0B,CAAA;AAChF,OAAO,EAAE,6BAA6B,EAAE,MAAM,+BAA+B,CAAA;AAC7E,OAAO,EAAE,0BAA0B,EAAE,MAAM,4BAA4B,CAAA;AACvE,OAAO,EAAE,iBAAiB,EAAsB,MAAM,0BAA0B,CAAA;AAChF,OAAO,EAAE,kBAAkB,EAAuB,MAAM,2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EAAE,QAA+B,EAAE,OAAO,CAAC,CAAA;gBACpF,OAAM;YACR,KAAK,KAAK;gBACR,IAAI,CAAC,iBAAiB,CAAC,OAAO,CAAC,SAAS,EAAE,QAA8B,EAAE,OAAO,CAAC,CAAA;gBAClF,OAAM;YACR,KAAK,YAAY;gBACf,IAAI,CAAC,wBAAwB,CAAC,OAAO,CAAC,SAAS,EAAE,QAAqC,EAAE,OAAO,CAAC,CAAA;gBAChG,OAAM;YACR;gBACE,MAAM,IAAI,KAAK,CAAC,uDAAuD,SAAS,IAAI,CAAC,CAAA;QACzF,CAAC;IACH,CAAC;CACF"}
@@ -1,4 +1,4 @@
1
- import { valueForGeneralAssertion, valueForNumericAssertion } from './internal/assertion-codegen.js';
1
+ import { unsupportedAssertionSource, valueForGeneralAssertion, valueForNumericAssertion } from './internal/assertion-codegen.js';
2
2
  export function valueForDnsAssertion(genfile, assertion) {
3
3
  genfile.namedImport('DnsAssertionBuilder', 'checkly/constructs');
4
4
  switch (assertion.source) {
@@ -20,7 +20,7 @@ export function valueForDnsAssertion(genfile, assertion) {
20
20
  hasRegex: false,
21
21
  });
22
22
  default:
23
- throw new Error(`Unsupported DNS assertion source ${assertion.source}`);
23
+ return unsupportedAssertionSource(assertion.source, 'DNS');
24
24
  }
25
25
  }
26
26
  //# sourceMappingURL=dns-assertion-codegen.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"dns-assertion-codegen.js","sourceRoot":"","sources":["../../src/constructs/dns-assertion-codegen.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,wBAAwB,EAAE,wBAAwB,EAAE,MAAM,iCAAiC,CAAA;AAGpG,MAAM,UAAU,oBAAoB,CAAE,OAAsB,EAAE,SAAuB;IACnF,OAAO,CAAC,WAAW,CAAC,qBAAqB,EAAE,oBAAoB,CAAC,CAAA;IAEhE,QAAQ,SAAS,CAAC,MAAM,EAAE,CAAC;QACzB,KAAK,eAAe;YAClB,OAAO,wBAAwB,CAAC,qBAAqB,EAAE,cAAc,E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AE,SAAS,EAAE;gBAC9E,WAAW,EAAE,IAAI;gBACjB,QAAQ,EAAE,KAAK;aAChB,CAAC,CAAA;QACJ,KAAK,aAAa;YAChB,OAAO,wBAAwB,CAAC,qBAAqB,EAAE,YAAY,EAAE,SAAS,EAAE;gBAC9E,WAAW,EAAE,IAAI;gBACjB,QAAQ,EAAE,KAAK;aAChB,CAAC,CAAA;QACJ;YACE,OAAO,0BAA0B,CAAC,SAAS,CAAC,MAAM,EAAE,KAAK,CAAC,CAAA;IAC9D,CAAC;AACH,CAAC"}
@@ -25,7 +25,7 @@ export declare class DnsAssertionBuilder {
25
25
  * Creates an assertion builder for DNS response codes.
26
26
  * @returns A general assertion builder for the response code.
27
27
  */
28
- static responseCode(): GeneralAssertionBuilder<DnsAssertionSource>;
28
+ static responseCode(): GeneralAssertionBuilder<DnsAssertionSource, string | number | boolean>;
29
29
  /**
30
30
  * Creates an assertion builder for DNS response time.
31
31
  * @returns A numeric assertion builder for response time in milliseconds.
@@ -38,12 +38,12 @@ export declare class DnsAssertionBuilder {
38
38
  * first capture group instead of the entire answer.
39
39
  * @returns A general assertion builder for the answer.
40
40
  */
41
- static textAnswer(regex?: string): GeneralAssertionBuilder<DnsAssertionSource>;
41
+ static textAnswer(regex?: string): GeneralAssertionBuilder<DnsAssertionSource, string | number | boolean>;
42
42
  /**
43
43
  * Creates an assertion builder for the JSON formatted answer.
44
44
  * @param property Optional JSON path to specific property (e.g., '$.Answer[0].data')
45
45
  * @returns A general assertion builder for the JSON formatted answer.
46
46
  */
47
- static jsonAnswer(property?: string): GeneralAssertionBuilder<DnsAssertionSource>;
47
+ static jsonAnswer(property?: string): GeneralAssertionBuilder<DnsAssertionSource, string | number | boolean>;
48
48
  }
49
49
  export {};
@@ -36,7 +36,7 @@ export interface DnsRequest {
36
36
  * @minimum 1
37
37
  * @maximum 65535
38
38
  * @example 53
39
- * @default 53
39
+ * @defaultValue 53
40
40
  */
41
41
  port?: number;
42
42
  /**
@@ -44,7 +44,7 @@ export interface DnsRequest {
44
44
  *
45
45
  * @example "UDP"
46
46
  * @example "TCP"
47
- * @default "UDP"
47
+ * @defaultValue "UDP"
48
48
  */
49
49
  protocol?: DnsProtocol;
50
50
  /**
@@ -0,0 +1,3 @@
1
+ import { GeneratedFile, Value } from '../sourcegen/index.js';
2
+ import { GrpcAssertion } from './grpc-assertion.js';
3
+ export declare function valueForGrpcAssertion(genfile: GeneratedFile, assertion: GrpcAssertion): Value;
@@ -0,0 +1,33 @@
1
+ import { unsupportedAssertionSource, valueForGeneralAssertion, valueForNumericAssertion } from './internal/assertion-codegen.js';
2
+ export function valueForGrpcAssertion(genfile, assertion) {
3
+ genfile.namedImport('GrpcAssertionBuilder', 'checkly/constructs');
4
+ switch (assertion.source) {
5
+ case 'RESPONSE_TIME':
6
+ return valueForNumericAssertion('GrpcAssertionBuilder', 'responseTime', assertion);
7
+ case 'GRPC_STATUS_CODE':
8
+ return valueForNumericAssertion('GrpcAssertionBuilder', 'statusCode', assertion);
9
+ case 'GRPC_HEALTHCHECK_STATUS':
10
+ return valueForGeneralAssertion('GrpcAssertionBuilder', 'healthCheckStatus', assertion, {
11
+ hasProperty: false,
12
+ hasRegex: false,
13
+ });
14
+ case 'GRPC_RESPONSE':
15
+ return valueForGeneralAssertion('GrpcAssertionBuilder', 'responseMessage', assertion, {
16
+ hasProperty: true,
17
+ hasRegex: false,
18
+ });
19
+ case 'TEXT_BODY':
20
+ return valueForGeneralAssertion('GrpcAssertionBuilder', 'textBody', assertion, {
21
+ hasProperty: true,
22
+ hasRegex: false,
23
+ });
24
+ case 'GRPC_METADATA':
25
+ return valueForGeneralAssertion('GrpcAssertionBuilder', 'responseMetadata', assertion, {
26
+ hasProperty: true,
27
+ hasRegex: false,
28
+ });
29
+ default:
30
+ return unsupportedAssertionSource(assertion.source, 'gRPC');
31
+ }
32
+ }
33
+ //# sourceMappingURL=grpc-assertion-codegen.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"grpc-assertion-codegen.js","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diagnostics } from './diagnostics.js';
2
+ import { GrpcAssertion } from './grpc-assertion.js';
3
+ /**
4
+ * Reports gRPC assertions whose source or comparison the backend does not accept.
5
+ *
6
+ * gRPC places no constraint on `property` — any string is valid for every source —
7
+ * so only the source and comparison are checked. Assertions written as plain object
8
+ * literals bypass GrpcAssertionBuilder and are type-legal because the fields are
9
+ * declared as plain strings; the backend rejects an unknown source or comparison
10
+ * with a 400. Source and comparison are independent (the accepted comparison does
11
+ * not depend on the source), so both are always checked.
12
+ */
13
+ export declare function validateGrpcAssertion(diagnostics: Diagnostics, assertion: GrpcAssertion, index: number): void;
@@ -0,0 +1,53 @@
1
+ import { addAssertionDiagnostic, quotedKeys } from './internal/assertion-validation.js';
2
+ // Keyed by the source union so a member added to GrpcAssertion['source'] without a
3
+ // matching entry here is a compile-time error.
4
+ const assertionSources = {
5
+ RESPONSE_TIME: true,
6
+ GRPC_RESPONSE: true,
7
+ TEXT_BODY: true,
8
+ GRPC_METADATA: true,
9
+ GRPC_HEALTHCHECK_STATUS: true,
10
+ GRPC_STATUS_CODE: true,
11
+ };
12
+ // The comparisons the backend accepts for gRPC assertions. Unlike traceroute, the
13
+ // backend does not couple the comparison to the source — it is the shared
14
+ // 14-operator list. Keep in sync with the backend's accepted comparison set.
15
+ const assertionComparisons = {
16
+ EQUALS: true,
17
+ NOT_EQUALS: true,
18
+ HAS_KEY: true,
19
+ NOT_HAS_KEY: true,
20
+ HAS_VALUE: true,
21
+ NOT_HAS_VALUE: true,
22
+ IS_EMPTY: true,
23
+ NOT_EMPTY: true,
24
+ GREATER_THAN: true,
25
+ LESS_THAN: true,
26
+ CONTAINS: true,
27
+ NOT_CONTAINS: true,
28
+ IS_NULL: true,
29
+ NOT_NULL: true,
30
+ };
31
+ /**
32
+ * Reports gRPC assertions whose source or comparison the backend does not accept.
33
+ *
34
+ * gRPC places no constraint on `property` — any string is valid for every source —
35
+ * so only the source and comparison are checked. Assertions written as plain object
36
+ * literals bypass GrpcAssertionBuilder and are type-legal because the fields are
37
+ * declared as plain strings; the backend rejects an unknown source or comparison
38
+ * with a 400. Source and comparison are independent (the accepted comparison does
39
+ * not depend on the source), so both are always checked.
40
+ */
41
+ export function validateGrpcAssertion(diagnostics, assertion, index) {
42
+ const location = `request.assertions[${index}]`;
43
+ if (!Object.hasOwn(assertionSources, assertion.source)) {
44
+ addAssertionDiagnostic(diagnostics, `The assertion at "${location}" has an unknown source "${assertion.source}". `
45
+ + `Expected one of ${quotedKeys(assertionSources)}.`);
46
+ }
47
+ if (!Object.hasOwn(assertionComparisons, assertion.comparison)) {
48
+ addAssertionDiagnostic(diagnostics, `The assertion at "${location}" has an unsupported comparison `
49
+ + `${assertion.comparison === '' ? '(none)' : `"${assertion.comparison}"`}. `
50
+ + `Expected one of ${quotedKeys(assertionComparisons)}.`);
51
+ }
52
+ }
53
+ //# sourceMappingURL=grpc-assertion-validation.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"grpc-assertion-validation.js","sourceRoot":"","sources":["../../src/constructs/grpc-assertion-validation.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,sBAAsB,EAAE,UAAU,EAAE,MAAM,oCAAoC,CAAA;AAEvF,mFAAmF;AACnF,+CAA+C;AAC/C,MAAM,gBAAgB,GAA0C;IAC9D,aAAa,EAAE,IAAI;IACnB,aAAa,EAAE,IAAI;IACnB,SAAS,EAAE,IAAI;IACf,aAAa,EAAE,IAAI;IACnB,uBAAuB,EAAE,IAAI;IAC7B,gBAAgB,EAAE,IAAI;CACvB,CAAA;AAED,kFAAkF;AAClF,0EAA0E;AAC1E,6EAA6E;AAC7E,MAAM,oBAAoB,GAAyB;IACjD,MAAM,EAAE,IAAI;IACZ,UAAU,EAAE,IAAI;IAChB,OAAO,EAAE,IAAI;IACb,WAAW,EAAE,IAAI;IACjB,SAAS,EAAE,IAAI;IACf,aAAa,EAAE,IAAI;IACnB,QAAQ,EAAE,IAAI;IACd,SAAS,EAAE,IAAI;IACf,YAAY,EAAE,IAAI;IAClB,SAAS,EAAE,IAAI;IACf,QAAQ,EAAE,IAAI;IACd,YAAY,EAAE,IAAI;IAClB,OAAO,EAAE,IAAI;IACb,QAAQ,EAAE,IAAI;CACf,CAAA;AAED;;;;;;;;;GASG;AACH,MAAM,UAAU,qBAAqB,CACnC,WAAwB,EACxB,SAAwB,EACxB,KAAa;IAEb,MAAM,QAAQ,GAAG,sBAAsB,KAAK,GAAG,CAAA;IAE/C,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,gBAAgB,EAAE,SAAS,CAAC,MAAM,CAAC,EAAE,CAAC;QACvD,sBAAsB,CAAC,WAAW,EAChC,qBAAqB,QAAQ,4BAA4B,SAAS,CAAC,MAAM,KAAK;cAC5E,mBAAmB,UAAU,CAAC,gBAAgB,CAAC,GAAG,CAAC,CAAA;IACzD,CAAC;IAED,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,oBAAoB,EAAE,SAAS,CAAC,UAAU,CAAC,EAAE,CAAC;QAC/D,sBAAsB,CAAC,WAAW,EAChC,qBAAqB,QAAQ,kCAAkC;cAC7D,GAAG,SAAS,CAAC,UAAU,KAAK,EAAE,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,IAAI,SAAS,CAAC,UAAU,GAAG,IAAI;cAC3E,mBAAmB,UAAU,CAAC,oBAAoB,CAAC,GAAG,CAAC,CAAA;IAC7D,CAAC;AACH,CAAC"}
@@ -0,0 +1,61 @@
1
+ import { Assertion as CoreAssertion, NumericAssertionBuilder, GeneralAssertionBuilder } from './internal/assertion.js';
2
+ type GrpcAssertionSource = 'RESPONSE_TIME' | 'GRPC_STATUS_CODE' | 'GRPC_HEALTHCHECK_STATUS' | 'GRPC_RESPONSE' | 'TEXT_BODY' | 'GRPC_METADATA';
3
+ export type GrpcAssertion = CoreAssertion<GrpcAssertionSource>;
4
+ /**
5
+ * Builder class for creating gRPC monitor assertions.
6
+ * Provides methods to create assertions for gRPC call responses.
7
+ *
8
+ * @example
9
+ * ```typescript
10
+ * // Response time assertions
11
+ * GrpcAssertionBuilder.responseTime().lessThan(1000)
12
+ *
13
+ * // gRPC status code assertions (e.g. 0 = OK)
14
+ * GrpcAssertionBuilder.statusCode().equals(0)
15
+ *
16
+ * // Health-check status assertions (HEALTH mode)
17
+ * GrpcAssertionBuilder.healthCheckStatus().equals('SERVING')
18
+ *
19
+ * // Response message assertions (BEHAVIOR mode)
20
+ * GrpcAssertionBuilder.responseMessage('$.status').equals('ok')
21
+ *
22
+ * // Response metadata (header) assertions
23
+ * GrpcAssertionBuilder.responseMetadata('content-type').contains('grpc')
24
+ * ```
25
+ */
26
+ export declare class GrpcAssertionBuilder {
27
+ /**
28
+ * Creates an assertion builder for gRPC response time.
29
+ * @returns A numeric assertion builder for response time in milliseconds.
30
+ */
31
+ static responseTime(): NumericAssertionBuilder<GrpcAssertionSource, string>;
32
+ /**
33
+ * Creates an assertion builder for the gRPC status code.
34
+ * @returns A numeric assertion builder for the gRPC status code.
35
+ */
36
+ static statusCode(): NumericAssertionBuilder<GrpcAssertionSource, string>;
37
+ /**
38
+ * Creates an assertion builder for the gRPC health-check status (HEALTH mode).
39
+ * @returns A general assertion builder for the health-check status.
40
+ */
41
+ static healthCheckStatus(): GeneralAssertionBuilder<GrpcAssertionSource, string | number | boolean>;
42
+ /**
43
+ * Creates an assertion builder for the gRPC response message (BEHAVIOR mode).
44
+ * @param property Optional JSON path to a specific property (e.g., '$.status').
45
+ * @returns A general assertion builder for the response message.
46
+ */
47
+ static responseMessage(property?: string): GeneralAssertionBuilder<GrpcAssertionSource, string | number | boolean>;
48
+ /**
49
+ * Creates an assertion builder for the raw gRPC response body as text (BEHAVIOR mode).
50
+ * @param property Optional property path for text content.
51
+ * @returns A general assertion builder for the text response body.
52
+ */
53
+ static textBody(property?: string): GeneralAssertionBuilder<GrpcAssertionSource, string | number | boolean>;
54
+ /**
55
+ * Creates an assertion builder for gRPC response metadata (headers).
56
+ * @param property Optional metadata key to assert against.
57
+ * @returns A general assertion builder for the response metadata.
58
+ */
59
+ static responseMetadata(property?: string): GeneralAssertionBuilder<GrpcAssertionSource, string | number | boolean>;
60
+ }
61
+ export {};
@@ -0,0 +1,71 @@
1
+ import { NumericAssertionBuilder, GeneralAssertionBuilder } from './internal/assertion.js';
2
+ /**
3
+ * Builder class for creating gRPC monitor assertions.
4
+ * Provides methods to create assertions for gRPC call responses.
5
+ *
6
+ * @example
7
+ * ```typescript
8
+ * // Response time assertions
9
+ * GrpcAssertionBuilder.responseTime().lessThan(1000)
10
+ *
11
+ * // gRPC status code assertions (e.g. 0 = OK)
12
+ * GrpcAssertionBuilder.statusCode().equals(0)
13
+ *
14
+ * // Health-check status assertions (HEALTH mode)
15
+ * GrpcAssertionBuilder.healthCheckStatus().equals('SERVING')
16
+ *
17
+ * // Response message assertions (BEHAVIOR mode)
18
+ * GrpcAssertionBuilder.responseMessage('$.status').equals('ok')
19
+ *
20
+ * // Response metadata (header) assertions
21
+ * GrpcAssertionBuilder.responseMetadata('content-type').contains('grpc')
22
+ * ```
23
+ */
24
+ export class GrpcAssertionBuilder {
25
+ /**
26
+ * Creates an assertion builder for gRPC response time.
27
+ * @returns A numeric assertion builder for response time in milliseconds.
28
+ */
29
+ static responseTime() {
30
+ return new NumericAssertionBuilder('RESPONSE_TIME');
31
+ }
32
+ /**
33
+ * Creates an assertion builder for the gRPC status code.
34
+ * @returns A numeric assertion builder for the gRPC status code.
35
+ */
36
+ static statusCode() {
37
+ return new NumericAssertionBuilder('GRPC_STATUS_CODE');
38
+ }
39
+ /**
40
+ * Creates an assertion builder for the gRPC health-check status (HEALTH mode).
41
+ * @returns A general assertion builder for the health-check status.
42
+ */
43
+ static healthCheckStatus() {
44
+ return new GeneralAssertionBuilder('GRPC_HEALTHCHECK_STATUS');
45
+ }
46
+ /**
47
+ * Creates an assertion builder for the gRPC response message (BEHAVIOR mode).
48
+ * @param property Optional JSON path to a specific property (e.g., '$.status').
49
+ * @returns A general assertion builder for the response message.
50
+ */
51
+ static responseMessage(property) {
52
+ return new GeneralAssertionBuilder('GRPC_RESPONSE', property);
53
+ }
54
+ /**
55
+ * Creates an assertion builder for the raw gRPC response body as text (BEHAVIOR mode).
56
+ * @param property Optional property path for text content.
57
+ * @returns A general assertion builder for the text response body.
58
+ */
59
+ static textBody(property) {
60
+ return new GeneralAssertionBuilder('TEXT_BODY', property);
61
+ }
62
+ /**
63
+ * Creates an assertion builder for gRPC response metadata (headers).
64
+ * @param property Optional metadata key to assert against.
65
+ * @returns A general assertion builder for the response metadata.
66
+ */
67
+ static responseMetadata(property) {
68
+ return new GeneralAssertionBuilder('GRPC_METADATA', property);
69
+ }
70
+ }
71
+ //# sourceMappingURL=grpc-assertion.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"grpc-assertion.js","sourceRoot":"","sources":["../../src/constructs/grpc-assertion.ts"],"names":[],"mappings":"AAAA,OAAO,EAA8B,uBAAuB,EAAE,uBAAuB,EAAE,MAAM,yBAAyB,CAAA;AAYtH;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,MAAM,OAAO,oBAAoB;IAC/B;;;OAGG;IACH,MAAM,CAAC,YAAY;QACjB,OAAO,IAAI,uBAAuB,CAAsB,eAAe,CAAC,CAAA;IAC1E,CAAC;IAED;;;OAGG;IACH,MAAM,CAAC,UAAU;QACf,OAAO,IAAI,uBAAuB,CAAsB,kBAAkB,CAAC,CAAA;IAC7E,CAAC;IAED;;;OAGG;IACH,MAAM,CAAC,iBAAiB;QACtB,OAAO,IAAI,uBAAuB,CAAsB,yBAAyB,CAAC,CAAA;IACpF,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,eAAe,CAAE,QAAiB;QACvC,OAAO,IAAI,uBAAuB,CAAsB,eAAe,EAAE,QAAQ,CAAC,CAAA;IACpF,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,QAAQ,CAAE,QAAiB;QAChC,OAAO,IAAI,uBAAuB,CAAsB,WAAW,EAAE,QAAQ,CAAC,CAAA;IAChF,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,gBAAgB,CAAE,QAAiB;QACxC,OAAO,IAAI,uBAAuB,CAAsB,eAAe,EAAE,QAAQ,CAAC,CAAA;IACpF,CAAC;CACF"}
@@ -0,0 +1,13 @@
1
+ import { Codegen, Context } from './internal/codegen/index.js';
2
+ import { MonitorResource } from './monitor-codegen.js';
3
+ import { GrpcRequest } from './grpc-request.js';
4
+ export interface GrpcMonitorResource extends MonitorResource {
5
+ checkType: 'GRPC';
6
+ request: GrpcRequest;
7
+ degradedResponseTime?: number;
8
+ maxResponseTime?: number;
9
+ }
10
+ export declare class GrpcMonitorCodegen extends Codegen<GrpcMonitorResource> {
11
+ describe(resource: GrpcMonitorResource): string;
12
+ gencode(logicalId: string, resource: GrpcMonitorResource, context: Context): void;
13
+ }
@@ -0,0 +1,34 @@
1
+ import { Codegen } from './internal/codegen/index.js';
2
+ import { expr, ident } from '../sourcegen/index.js';
3
+ import { buildMonitorProps } from './monitor-codegen.js';
4
+ import { valueForGrpcRequest } from './grpc-request-codegen.js';
5
+ const construct = 'GrpcMonitor';
6
+ export class GrpcMonitorCodegen extends Codegen {
7
+ describe(resource) {
8
+ return `gRPC Monitor: ${resource.name}`;
9
+ }
10
+ gencode(logicalId, resource, context) {
11
+ const filePath = context.filePath('resources/grpc-monitors', resource.name, {
12
+ tags: resource.tags,
13
+ unique: true,
14
+ });
15
+ const file = this.program.generatedConstructFile(filePath.fullPath);
16
+ file.namedImport(construct, 'checkly/constructs');
17
+ file.section(expr(ident(construct), builder => {
18
+ builder.new(builder => {
19
+ builder.string(logicalId);
20
+ builder.object(builder => {
21
+ if (resource.degradedResponseTime !== undefined) {
22
+ builder.number('degradedResponseTime', resource.degradedResponseTime);
23
+ }
24
+ if (resource.maxResponseTime !== undefined) {
25
+ builder.number('maxResponseTime', resource.maxResponseTime);
26
+ }
27
+ buildMonitorProps(this.program, file, builder, resource, context);
28
+ builder.value('request', valueForGrpcRequest(this.program, file, context, resource.request));
29
+ });
30
+ });
31
+ }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wBAChD,OAAO,CAAC,MAAM,CAAC,sBAAsB,EAAE,QAAQ,CAAC,oBAAoB,CAAC,CAAA;oBACvE,CAAC;oBAED,IAAI,QAAQ,CAAC,eAAe,KAAK,SAAS,EAAE,CAAC;wBAC3C,OAAO,CAAC,MAAM,CAAC,iBAAiB,EAAE,QAAQ,CAAC,eAAe,CAAC,CAAA;oBAC7D,CAAC;oBAED,iBAAiB,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,OAAO,CAAC,CAAA;oBAEjE,OAAO,CAAC,KAAK,CAAC,SAAS,EAAE,mBAAmB,CAAC,IAAI,CAAC,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,QAAQ,CAAC,OAAO,CAAC,CAAC,CAAA;gBAC9F,CAAC,CAAC,CAAA;YACJ,CAAC,CAAC,CAAA;QACJ,CAAC,CAAC,CAAC,CAAA;IACL,CAAC;CACF"}
@@ -0,0 +1,83 @@
1
+ import { Monitor, MonitorProps } from './monitor.js';
2
+ import { Diagnostics } from './diagnostics.js';
3
+ import { GrpcRequest } from './grpc-request.js';
4
+ export interface GrpcMonitorProps extends MonitorProps {
5
+ /**
6
+ * Determines the request that the monitor is going to run.
7
+ */
8
+ request: GrpcRequest;
9
+ /**
10
+ * The response time in milliseconds where the monitor should be considered
11
+ * degraded.
12
+ *
13
+ * @defaultValue 10000
14
+ * @minimum 0
15
+ * @maximum 180000
16
+ * @example
17
+ * ```typescript
18
+ * degradedResponseTime: 3000 // Alert when the gRPC call takes longer than 3 seconds
19
+ * ```
20
+ */
21
+ degradedResponseTime?: number;
22
+ /**
23
+ * The response time in milliseconds where the monitor should be considered
24
+ * failing.
25
+ *
26
+ * @defaultValue 20000
27
+ * @minimum 0
28
+ * @maximum 180000
29
+ * @example
30
+ * ```typescript
31
+ * maxResponseTime: 10000 // Fail if the gRPC call takes longer than 10 seconds
32
+ * ```
33
+ */
34
+ maxResponseTime?: number;
35
+ }
36
+ /**
37
+ * Creates a gRPC Monitor
38
+ */
39
+ export declare class GrpcMonitor extends Monitor {
40
+ request: GrpcRequest;
41
+ degradedResponseTime?: number;
42
+ maxResponseTime?: number;
43
+ /**
44
+ * Constructs the gRPC Monitor instance
45
+ *
46
+ * @param logicalId unique project-scoped resource name identification
47
+ * @param props configuration properties
48
+ *
49
+ * {@link https://www.checklyhq.com/docs/constructs/grpc-monitor/ Read more in the docs}
50
+ */
51
+ constructor(logicalId: string, props: GrpcMonitorProps);
52
+ describe(): string;
53
+ validate(diagnostics: Diagnostics): Promise<void>;
54
+ synthesize(): {
55
+ checkType: string;
56
+ request: GrpcRequest;
57
+ degradedResponseTime: number | undefined;
58
+ maxResponseTime: number | undefined;
59
+ doubleCheck: boolean;
60
+ activated: boolean | undefined;
61
+ muted: boolean | undefined;
62
+ shouldFail: boolean | undefined;
63
+ locations: (keyof import("../index.js").Region)[] | undefined;
64
+ privateLocations: undefined;
65
+ tags: string[] | undefined;
66
+ frequency: number | undefined;
67
+ frequencyOffset: number | undefined;
68
+ groupId: import("./ref.js").Ref | null;
69
+ retryStrategy: import("./retry-strategy.js").LinearRetryStrategy | import("./retry-strategy.js").ExponentialRetryStrategy | import("./retry-strategy.js").FixedRetryStrategy | import("./retry-strategy.js").SingleRetryRetryStrategy | null | undefined;
70
+ alertSettings: import("./alert-escalation-policy.js").AlertEscalation | undefined;
71
+ useGlobalAlertSettings: boolean | undefined;
72
+ runParallel: boolean | undefined;
73
+ triggerIncident: {
74
+ serviceId: import("./ref.js").Ref;
75
+ severity: "MINOR" | "MEDIUM" | "MAJOR" | "CRITICAL";
76
+ name: string;
77
+ description: string;
78
+ notifySubscribers: boolean;
79
+ } | undefined;
80
+ description?: string | undefined;
81
+ name: string;
82
+ };
83
+ }
@@ -0,0 +1,56 @@
1
+ import { Monitor } from './monitor.js';
2
+ import { Session } from './session.js';
3
+ import { validateResponseTimes } from './internal/common-diagnostics.js';
4
+ import { validateGrpcAssertion } from './grpc-assertion-validation.js';
5
+ /**
6
+ * Creates a gRPC Monitor
7
+ */
8
+ export class GrpcMonitor extends Monitor {
9
+ request;
10
+ degradedResponseTime;
11
+ maxResponseTime;
12
+ /**
13
+ * Constructs the gRPC Monitor instance
14
+ *
15
+ * @param logicalId unique project-scoped resource name identification
16
+ * @param props configuration properties
17
+ *
18
+ * {@link https://www.checklyhq.com/docs/constructs/grpc-monitor/ Read more in the docs}
19
+ */
20
+ constructor(logicalId, props) {
21
+ super(logicalId, props);
22
+ this.request = props.request;
23
+ this.degradedResponseTime = props.degradedResponseTime;
24
+ this.maxResponseTime = props.maxResponseTime;
25
+ Session.registerConstruct(this);
26
+ this.addSubscriptions();
27
+ this.addPrivateLocationCheckAssignments();
28
+ }
29
+ describe() {
30
+ return `GrpcMonitor:${this.logicalId}`;
31
+ }
32
+ async validate(diagnostics) {
33
+ await super.validate(diagnostics);
34
+ await validateResponseTimes(diagnostics, this, {
35
+ // gRPC allows thresholds up to 180s (calls can run to the 180s timeout),
36
+ // matching the backend's gRPC response-time limits.
37
+ degradedResponseTime: 180_000,
38
+ maxResponseTime: 180_000,
39
+ // Backend default applied when maxResponseTime is omitted.
40
+ defaultMaxResponseTime: 20_000,
41
+ });
42
+ for (const [index, assertion] of (this.request.assertions ?? []).entries()) {
43
+ validateGrpcAssertion(diagnostics, assertion, index);
44
+ }
45
+ }
46
+ synthesize() {
47
+ return {
48
+ ...super.synthesize(),
49
+ checkType: 'GRPC',
50
+ request: this.request,
51
+ degradedResponseTime: this.degradedResponseTime,
52
+ maxResponseTime: this.maxResponseTime,
53
+ };
54
+ }
55
+ }
56
+ //# sourceMappingURL=grpc-monitor.js.map