checkly 8.23.2 → 9.0.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 (55) hide show
  1. package/dist/ai-context/skills-command/references/configure-supporting-constructs.md +44 -0
  2. package/dist/ai-context/skills-command/references/initialize.md +1 -1
  3. package/dist/commands/deploy.js +3 -1
  4. package/dist/commands/deploy.js.map +1 -1
  5. package/dist/commands/import/plan.js +10 -0
  6. package/dist/commands/import/plan.js.map +1 -1
  7. package/dist/constructs/construct-codegen.d.ts +5 -1
  8. package/dist/constructs/construct-codegen.js +11 -0
  9. package/dist/constructs/construct-codegen.js.map +1 -1
  10. package/dist/constructs/index.d.ts +3 -0
  11. package/dist/constructs/index.js +3 -0
  12. package/dist/constructs/index.js.map +1 -1
  13. package/dist/constructs/internal/codegen/context.d.ts +8 -0
  14. package/dist/constructs/internal/codegen/context.js +58 -0
  15. package/dist/constructs/internal/codegen/context.js.map +1 -1
  16. package/dist/constructs/project-bundle.js +5 -0
  17. package/dist/constructs/project-bundle.js.map +1 -1
  18. package/dist/constructs/project.d.ts +4 -2
  19. package/dist/constructs/project.js +2 -0
  20. package/dist/constructs/project.js.map +1 -1
  21. package/dist/constructs/status-page-codegen.d.ts +8 -1
  22. package/dist/constructs/status-page-codegen.js +21 -0
  23. package/dist/constructs/status-page-codegen.js.map +1 -1
  24. package/dist/constructs/status-page-service.d.ts +9 -1
  25. package/dist/constructs/status-page-service.js +9 -1
  26. package/dist/constructs/status-page-service.js.map +1 -1
  27. package/dist/constructs/status-page-v3-automation-rule-codegen.d.ts +22 -0
  28. package/dist/constructs/status-page-v3-automation-rule-codegen.js +51 -0
  29. package/dist/constructs/status-page-v3-automation-rule-codegen.js.map +1 -0
  30. package/dist/constructs/status-page-v3-automation-rule.d.ts +90 -0
  31. package/dist/constructs/status-page-v3-automation-rule.js +87 -0
  32. package/dist/constructs/status-page-v3-automation-rule.js.map +1 -0
  33. package/dist/constructs/status-page-v3-codegen.d.ts +36 -0
  34. package/dist/constructs/status-page-v3-codegen.js +100 -0
  35. package/dist/constructs/status-page-v3-codegen.js.map +1 -0
  36. package/dist/constructs/status-page-v3-component-codegen.d.ts +24 -0
  37. package/dist/constructs/status-page-v3-component-codegen.js +74 -0
  38. package/dist/constructs/status-page-v3-component-codegen.js.map +1 -0
  39. package/dist/constructs/status-page-v3-component.d.ts +78 -0
  40. package/dist/constructs/status-page-v3-component.js +105 -0
  41. package/dist/constructs/status-page-v3-component.js.map +1 -0
  42. package/dist/constructs/status-page-v3.d.ts +118 -0
  43. package/dist/constructs/status-page-v3.js +112 -0
  44. package/dist/constructs/status-page-v3.js.map +1 -0
  45. package/dist/constructs/status-page.d.ts +12 -1
  46. package/dist/constructs/status-page.js +18 -1
  47. package/dist/constructs/status-page.js.map +1 -1
  48. package/dist/rest/projects.d.ts +11 -1
  49. package/dist/rest/projects.js.map +1 -1
  50. package/dist/services/check-parser/lockfile-pruner.js +3 -3
  51. package/dist/services/check-parser/lockfile-pruner.js.map +1 -1
  52. package/dist/services/check-parser/package-files/package-manager.js +23 -15
  53. package/dist/services/check-parser/package-files/package-manager.js.map +1 -1
  54. package/oclif.manifest.json +410 -410
  55. package/package.json +12 -12
@@ -0,0 +1,100 @@
1
+ import { Codegen } from './internal/codegen/index.js';
2
+ import { decl, expr, ident } from '../sourcegen/index.js';
3
+ const construct = 'StatusPageV3';
4
+ export function valueForStatusPageV3FromId(genfile, physicalId) {
5
+ genfile.namedImport(construct, 'checkly/constructs');
6
+ return expr(ident(construct), builder => {
7
+ builder.member(ident('fromId'));
8
+ builder.call(builder => {
9
+ builder.string(physicalId);
10
+ });
11
+ });
12
+ }
13
+ /**
14
+ * Resolves a reference to a v3 status page: an imported page, a page already
15
+ * declared in the project (friend), or a `fromId()` reference as fallback.
16
+ */
17
+ export function valueForStatusPageV3Ref(genfile, physicalId, context) {
18
+ try {
19
+ const variable = context.lookupStatusPage(physicalId);
20
+ return context.importVariable(variable, genfile);
21
+ }
22
+ catch {
23
+ try {
24
+ const variable = context.lookupFriendStatusPage(physicalId);
25
+ return context.importFriendVariable(variable, genfile);
26
+ }
27
+ catch {
28
+ return valueForStatusPageV3FromId(genfile, physicalId);
29
+ }
30
+ }
31
+ }
32
+ /**
33
+ * v2 and v3 pages share the `status-page` resource type. `StatusPageCodegen`
34
+ * dispatches here when the payload carries `version: 3`.
35
+ */
36
+ export class StatusPageV3Codegen extends Codegen {
37
+ describe(resource) {
38
+ return `Status Page (v3): ${resource.name}`;
39
+ }
40
+ prepare(logicalId, resource, context) {
41
+ const filePath = context.filePath('resources/status-pages', resource.name, {
42
+ unique: true,
43
+ });
44
+ context.registerStatusPage(resource.id, resource.name, this.program.generatedConstructFile(filePath.fullPath));
45
+ }
46
+ gencode(logicalId, resource, context) {
47
+ const { id, file } = context.lookupStatusPage(resource.id);
48
+ file.namedImport(construct, 'checkly/constructs');
49
+ file.section(decl(id, builder => {
50
+ builder.variable(expr(ident(construct), builder => {
51
+ builder.new(builder => {
52
+ builder.string(logicalId);
53
+ builder.object(builder => {
54
+ builder.string('name', resource.name);
55
+ builder.string('url', resource.url);
56
+ if (resource.customDomain) {
57
+ builder.string('customDomain', resource.customDomain);
58
+ }
59
+ if (resource.description) {
60
+ builder.string('description', resource.description);
61
+ }
62
+ if (resource.logo) {
63
+ builder.string('logo', resource.logo);
64
+ }
65
+ if (resource.logoDark) {
66
+ builder.string('logoDark', resource.logoDark);
67
+ }
68
+ if (resource.redirectTo) {
69
+ builder.string('redirectTo', resource.redirectTo);
70
+ }
71
+ if (resource.favicon) {
72
+ builder.string('favicon', resource.favicon);
73
+ }
74
+ if (resource.defaultTheme) {
75
+ builder.string('defaultTheme', resource.defaultTheme);
76
+ }
77
+ if (resource.privacyPolicyLink) {
78
+ builder.string('privacyPolicyLink', resource.privacyPolicyLink);
79
+ }
80
+ if (resource.termsOfServiceLink) {
81
+ builder.string('termsOfServiceLink', resource.termsOfServiceLink);
82
+ }
83
+ if (resource.footerText) {
84
+ builder.string('footerText', resource.footerText);
85
+ }
86
+ if (resource.googleAnalyticsTag) {
87
+ builder.string('googleAnalyticsTag', resource.googleAnalyticsTag);
88
+ }
89
+ // Indexing is on by default; only the opt-out is worth spelling out.
90
+ if (resource.allowIndexing === false) {
91
+ builder.boolean('allowIndexing', false);
92
+ }
93
+ });
94
+ });
95
+ }));
96
+ builder.export();
97
+ }));
98
+ }
99
+ }
100
+ //# sourceMappingURL=status-page-v3-codegen.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"status-page-v3-codegen.js","sourceRoot":"","sources":["../../src/constructs/status-page-v3-codegen.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAW,MAAM,6BAA6B,CAAA;AAC9D,OAAO,EAAE,IAAI,EAAE,IAAI,EAAiB,KAAK,EAAS,MAAM,uBAAuB,CAAA;AAsB/E,MAAM,SAAS,GAAG,cAAc,CAAA;AAEhC,MAAM,UAAU,0BAA0B,CAAE,OAAsB,EAAE,UAAkB;IACpF,OAAO,CAAC,WAAW,CAAC,SAAS,EAAE,oBAAoB,CAAC,CAAA;IAEpD,OAAO,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC,EAAE;QACtC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAA;QAC/B,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE;YACrB,OAAO,CAAC,MAAM,CAAC,UAAU,CAAC,CAAA;QAC5B,CAAC,CAAC,CAAA;IACJ,CAAC,CAAC,CAAA;AACJ,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,uBAAuB,CACrC,OAAsB,EACtB,UAAkB,EAClB,OAAgB;IAEhB,IAAI,CAAC;QACH,MAAM,QAAQ,GAAG,OAAO,CAAC,gBAAgB,CAAC,UAAU,CAAC,CAAA;QACrD,OAAO,OAAO,CAAC,cAAc,CAAC,QAAQ,EAAE,OAAO,CAAC,CAAA;IAClD,CAAC;IAAC,MAAM,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AC,mBAAmB,EAAE,QAAQ,CAAC,iBAAiB,CAAC,CAAA;wBACjE,CAAC;wBAED,IAAI,QAAQ,CAAC,kBAAkB,EAAE,CAAC;4BAChC,OAAO,CAAC,MAAM,CAAC,oBAAoB,EAAE,QAAQ,CAAC,kBAAkB,CAAC,CAAA;wBACnE,CAAC;wBAED,IAAI,QAAQ,CAAC,UAAU,EAAE,CAAC;4BACxB,OAAO,CAAC,MAAM,CAAC,YAAY,EAAE,QAAQ,CAAC,UAAU,CAAC,CAAA;wBACnD,CAAC;wBAED,IAAI,QAAQ,CAAC,kBAAkB,EAAE,CAAC;4BAChC,OAAO,CAAC,MAAM,CAAC,oBAAoB,EAAE,QAAQ,CAAC,kBAAkB,CAAC,CAAA;wBACnE,CAAC;wBAED,qEAAqE;wBACrE,IAAI,QAAQ,CAAC,aAAa,KAAK,KAAK,EAAE,CAAC;4BACrC,OAAO,CAAC,OAAO,CAAC,eAAe,EAAE,KAAK,CAAC,CAAA;wBACzC,CAAC;oBACH,CAAC,CAAC,CAAA;gBACJ,CAAC,CAAC,CAAA;YACJ,CAAC,CAAC,CAAC,CAAA;YAEH,OAAO,CAAC,MAAM,EAAE,CAAA;QAClB,CAAC,CAAC,CAAC,CAAA;IACL,CAAC;CACF"}
@@ -0,0 +1,24 @@
1
+ import { Codegen, Context } from './internal/codegen/index.js';
2
+ import { GeneratedFile, Value } from '../sourcegen/index.js';
3
+ import { StatusPageV3ComponentType } from './status-page-v3-component.js';
4
+ export interface StatusPageV3ComponentResource {
5
+ id: string;
6
+ statusPageId: string;
7
+ parentId?: string | null;
8
+ type: StatusPageV3ComponentType;
9
+ name: string;
10
+ description?: string | null;
11
+ hidden?: boolean | null;
12
+ displayOrder: number;
13
+ }
14
+ export declare function valueForStatusPageV3ComponentFromId(genfile: GeneratedFile, physicalId: string): Value;
15
+ /**
16
+ * Resolves a reference to a component: an imported component, one already
17
+ * declared in the project (friend), or a `fromId()` reference as fallback.
18
+ */
19
+ export declare function valueForStatusPageV3ComponentRef(genfile: GeneratedFile, physicalId: string, context: Context): Value;
20
+ export declare class StatusPageV3ComponentCodegen extends Codegen<StatusPageV3ComponentResource> {
21
+ describe(resource: StatusPageV3ComponentResource): string;
22
+ prepare(logicalId: string, resource: StatusPageV3ComponentResource, context: Context): void;
23
+ gencode(logicalId: string, resource: StatusPageV3ComponentResource, context: Context): void;
24
+ }
@@ -0,0 +1,74 @@
1
+ import { Codegen } from './internal/codegen/index.js';
2
+ import { decl, expr, ident } from '../sourcegen/index.js';
3
+ import { valueForStatusPageV3Ref } from './status-page-v3-codegen.js';
4
+ const construct = 'StatusPageV3Component';
5
+ export function valueForStatusPageV3ComponentFromId(genfile, physicalId) {
6
+ genfile.namedImport(construct, 'checkly/constructs');
7
+ return expr(ident(construct), builder => {
8
+ builder.member(ident('fromId'));
9
+ builder.call(builder => {
10
+ builder.string(physicalId);
11
+ });
12
+ });
13
+ }
14
+ /**
15
+ * Resolves a reference to a component: an imported component, one already
16
+ * declared in the project (friend), or a `fromId()` reference as fallback.
17
+ */
18
+ export function valueForStatusPageV3ComponentRef(genfile, physicalId, context) {
19
+ try {
20
+ const variable = context.lookupStatusPageComponent(physicalId);
21
+ return context.importVariable(variable, genfile);
22
+ }
23
+ catch {
24
+ try {
25
+ const variable = context.lookupFriendStatusPageComponent(physicalId);
26
+ return context.importFriendVariable(variable, genfile);
27
+ }
28
+ catch {
29
+ return valueForStatusPageV3ComponentFromId(genfile, physicalId);
30
+ }
31
+ }
32
+ }
33
+ export class StatusPageV3ComponentCodegen extends Codegen {
34
+ describe(resource) {
35
+ return `Status Page Component: ${resource.name}`;
36
+ }
37
+ prepare(logicalId, resource, context) {
38
+ const filePath = context.filePath('resources/status-pages/components', resource.name, {
39
+ unique: true,
40
+ });
41
+ context.registerStatusPageComponent(resource.id, resource.name, this.program.generatedConstructFile(filePath.fullPath));
42
+ }
43
+ gencode(logicalId, resource, context) {
44
+ const { id, file } = context.lookupStatusPageComponent(resource.id);
45
+ file.namedImport(construct, 'checkly/constructs');
46
+ file.section(decl(id, builder => {
47
+ builder.variable(expr(ident(construct), builder => {
48
+ builder.new(builder => {
49
+ builder.string(logicalId);
50
+ builder.object(builder => {
51
+ builder.value('statusPage', valueForStatusPageV3Ref(file, resource.statusPageId, context));
52
+ // SERVICE is the construct's default.
53
+ if (resource.type === 'GROUP') {
54
+ builder.string('type', resource.type);
55
+ }
56
+ builder.string('name', resource.name);
57
+ if (resource.description) {
58
+ builder.string('description', resource.description);
59
+ }
60
+ if (resource.hidden === true) {
61
+ builder.boolean('hidden', true);
62
+ }
63
+ builder.number('displayOrder', resource.displayOrder);
64
+ if (resource.parentId) {
65
+ builder.value('parent', valueForStatusPageV3ComponentRef(file, resource.parentId, context));
66
+ }
67
+ });
68
+ });
69
+ }));
70
+ builder.export();
71
+ }));
72
+ }
73
+ }
74
+ //# sourceMappingURL=status-page-v3-component-codegen.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"status-page-v3-component-codegen.js","sourceRoot":"","sources":["../../src/constructs/status-page-v3-component-codegen.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAW,MAAM,6BAA6B,CAAA;AAC9D,OAAO,EAAE,IAAI,EAAE,IAAI,EAAiB,KAAK,EAAS,MAAM,uBAAuB,CAAA;AAE/E,OAAO,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAA;AAarE,MAAM,SAAS,GAAG,uBAAuB,CAAA;AAEzC,MAAM,UAAU,mCAAmC,CAAE,OAAsB,EAAE,UAAkB;IAC7F,OAAO,CAAC,WAAW,CAAC,SAAS,EAAE,oBAAoB,CAAC,CAAA;IAEpD,OAAO,IAAI,CAAC,KAAK,CAAC,SAAS,CAAC,EAAE,OAAO,CAAC,EAAE;QACtC,OAAO,CAAC,MAAM,CAAC,KAAK,CAAC,QAAQ,CAAC,CAAC,CAAA;QAC/B,OAAO,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE;YACrB,OAAO,CAAC,MAAM,CAAC,UAAU,C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OAAO,CAAC,CAAC,CAAA;wBAC7F,CAAC;oBACH,CAAC,CAAC,CAAA;gBACJ,CAAC,CAAC,CAAA;YACJ,CAAC,CAAC,CAAC,CAAA;YAEH,OAAO,CAAC,MAAM,EAAE,CAAA;QAClB,CAAC,CAAC,CAAC,CAAA;IACL,CAAC;CACF"}
@@ -0,0 +1,78 @@
1
+ import { Construct } from './construct.js';
2
+ import { Diagnostics } from './diagnostics.js';
3
+ import { StatusPageV3, StatusPageV3Ref } from './status-page-v3.js';
4
+ export type StatusPageV3ComponentType = 'SERVICE' | 'GROUP';
5
+ export interface StatusPageV3ComponentProps {
6
+ /**
7
+ * The v3 status page this component belongs to. A component belongs to
8
+ * exactly one page and cannot be moved to another one later.
9
+ */
10
+ statusPage: StatusPageV3 | StatusPageV3Ref;
11
+ /**
12
+ * `SERVICE` (a monitored thing with its own status) or `GROUP` (a
13
+ * container for other components). Defaults to `SERVICE`.
14
+ */
15
+ type?: StatusPageV3ComponentType;
16
+ /**
17
+ * The name shown on the status page.
18
+ */
19
+ name: string;
20
+ /**
21
+ * An optional description shown next to the name.
22
+ */
23
+ description?: string;
24
+ /**
25
+ * Hide the component from the public page while keeping it available for
26
+ * incidents and automation. Defaults to false.
27
+ */
28
+ hidden?: boolean;
29
+ /**
30
+ * Position among its siblings; lower comes first.
31
+ */
32
+ displayOrder: number;
33
+ /**
34
+ * The GROUP component to nest this component under. Must be on the same
35
+ * status page.
36
+ */
37
+ parent?: StatusPageV3Component | StatusPageV3ComponentRef;
38
+ }
39
+ /**
40
+ * Creates a reference to an existing v3 Status Page Component.
41
+ *
42
+ * Use {@link StatusPageV3Component.fromId()} instead of instantiating this class directly.
43
+ */
44
+ export declare class StatusPageV3ComponentRef extends Construct {
45
+ constructor(logicalId: string, physicalId: string);
46
+ describe(): string;
47
+ validate(diagnostics: Diagnostics): Promise<void>;
48
+ synthesize(): null;
49
+ }
50
+ /**
51
+ * Creates a Component of a v3 Status Page
52
+ */
53
+ export declare class StatusPageV3Component extends Construct {
54
+ statusPage: StatusPageV3 | StatusPageV3Ref;
55
+ componentType: StatusPageV3ComponentType;
56
+ name: string;
57
+ description?: string;
58
+ hidden?: boolean;
59
+ displayOrder: number;
60
+ parent?: StatusPageV3Component | StatusPageV3ComponentRef;
61
+ static readonly __checklyType = "status-page-component";
62
+ /**
63
+ * Constructs the Status Page Component instance
64
+ *
65
+ * @param logicalId unique project-scoped resource name identification
66
+ * @param props component configuration properties
67
+ *
68
+ * {@link https://www.checklyhq.com/docs/constructs/status-page-v3-component/ Read more in the docs}
69
+ */
70
+ constructor(logicalId: string, props: StatusPageV3ComponentProps);
71
+ describe(): string;
72
+ /**
73
+ * @param id - The UUID of the existing status page component
74
+ */
75
+ static fromId(id: string): StatusPageV3ComponentRef;
76
+ validate(diagnostics: Diagnostics): Promise<void>;
77
+ synthesize(): any | null;
78
+ }
@@ -0,0 +1,105 @@
1
+ import { Construct } from './construct.js';
2
+ import { InvalidPropertyValueDiagnostic } from './construct-diagnostics.js';
3
+ import { validatePhysicalIdIsUuid } from './internal/common-diagnostics.js';
4
+ import { Ref } from './ref.js';
5
+ import { Session } from './session.js';
6
+ import { StatusPageV3, StatusPageV3Ref } from './status-page-v3.js';
7
+ /**
8
+ * Creates a reference to an existing v3 Status Page Component.
9
+ *
10
+ * Use {@link StatusPageV3Component.fromId()} instead of instantiating this class directly.
11
+ */
12
+ export class StatusPageV3ComponentRef extends Construct {
13
+ constructor(logicalId, physicalId) {
14
+ super(StatusPageV3Component.__checklyType, logicalId, physicalId, false);
15
+ Session.registerConstruct(this);
16
+ }
17
+ describe() {
18
+ return `StatusPageV3ComponentRef:${this.logicalId}`;
19
+ }
20
+ async validate(diagnostics) {
21
+ await super.validate(diagnostics);
22
+ await validatePhysicalIdIsUuid(diagnostics, 'StatusPageV3Component', this.physicalId);
23
+ }
24
+ synthesize() {
25
+ return null;
26
+ }
27
+ }
28
+ /**
29
+ * Creates a Component of a v3 Status Page
30
+ */
31
+ export class StatusPageV3Component extends Construct {
32
+ statusPage;
33
+ // Not `type`: that is the Construct's resource-type key.
34
+ componentType;
35
+ name;
36
+ description;
37
+ hidden;
38
+ displayOrder;
39
+ parent;
40
+ static __checklyType = 'status-page-component';
41
+ /**
42
+ * Constructs the Status Page Component instance
43
+ *
44
+ * @param logicalId unique project-scoped resource name identification
45
+ * @param props component configuration properties
46
+ *
47
+ * {@link https://www.checklyhq.com/docs/constructs/status-page-v3-component/ Read more in the docs}
48
+ */
49
+ constructor(logicalId, props) {
50
+ super(StatusPageV3Component.__checklyType, logicalId);
51
+ this.statusPage = props.statusPage;
52
+ this.componentType = props.type ?? 'SERVICE';
53
+ this.name = props.name;
54
+ this.description = props.description;
55
+ this.hidden = props.hidden;
56
+ this.displayOrder = props.displayOrder;
57
+ this.parent = props.parent;
58
+ Session.registerConstruct(this);
59
+ }
60
+ describe() {
61
+ return `StatusPageV3Component:${this.logicalId}`;
62
+ }
63
+ /**
64
+ * @param id - The UUID of the existing status page component
65
+ */
66
+ static fromId(id) {
67
+ return new StatusPageV3ComponentRef(`status-page-component-${id}`, id);
68
+ }
69
+ async validate(diagnostics) {
70
+ await super.validate(diagnostics);
71
+ if (!(this.statusPage instanceof StatusPageV3) && !(this.statusPage instanceof StatusPageV3Ref)) {
72
+ diagnostics.add(new InvalidPropertyValueDiagnostic('statusPage', new Error('Value must be a StatusPageV3 construct or StatusPageV3.fromId().')));
73
+ }
74
+ if (this.componentType !== 'SERVICE' && this.componentType !== 'GROUP') {
75
+ diagnostics.add(new InvalidPropertyValueDiagnostic('type', new Error(`Value must be "SERVICE" or "GROUP".`)));
76
+ }
77
+ if (this.hidden !== undefined && typeof this.hidden !== 'boolean') {
78
+ diagnostics.add(new InvalidPropertyValueDiagnostic('hidden', new Error('Value must be a boolean.')));
79
+ }
80
+ if (!Number.isInteger(this.displayOrder)) {
81
+ diagnostics.add(new InvalidPropertyValueDiagnostic('displayOrder', new Error('Value must be an integer.')));
82
+ }
83
+ // A referenced parent (fromId) can only be checked on the backend.
84
+ if (this.parent instanceof StatusPageV3Component) {
85
+ if (this.parent.componentType !== 'GROUP') {
86
+ diagnostics.add(new InvalidPropertyValueDiagnostic('parent', new Error(`Value must be a GROUP component ("${this.parent.logicalId}" is a ${this.parent.componentType}).`)));
87
+ }
88
+ if (this.parent.statusPage !== this.statusPage) {
89
+ diagnostics.add(new InvalidPropertyValueDiagnostic('parent', new Error(`Value must be a component of the same status page ("${this.parent.logicalId}" belongs to another page).`)));
90
+ }
91
+ }
92
+ }
93
+ synthesize() {
94
+ return {
95
+ statusPageId: Ref.from(this.statusPage.logicalId),
96
+ parentId: this.parent ? Ref.from(this.parent.logicalId) : null,
97
+ type: this.componentType,
98
+ name: this.name,
99
+ description: this.description,
100
+ hidden: this.hidden,
101
+ displayOrder: this.displayOrder,
102
+ };
103
+ }
104
+ }
105
+ //# sourceMappingURL=status-page-v3-component.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"status-page-v3-component.js","sourceRoot":"","sources":["../../src/constructs/status-page-v3-component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAC1C,OAAO,EAAE,8BAA8B,EAAE,MAAM,4BAA4B,CAAA;AAE3E,OAAO,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAA;AAC3E,OAAO,EAAE,GAAG,EAAE,MAAM,UAAU,CAAA;AAC9B,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AACtC,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,qBAAqB,CAAA;AAuCnE;;;;GAIG;AACH,MAAM,OAAO,wBAAyB,SAAQ,SAAS;IACrD,YAAa,SAAiB,EAAE,UAAkB;QAChD,KAAK,CAAC,qBAAqB,CAAC,aAAa,EAAE,SAAS,EAAE,UAAU,EAAE,KAAK,CAAC,CAAA;QACxE,OAAO,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAA;IACjC,CAAC;IAED,QAAQ;QACN,OAAO,4BAA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8BAA8B,CAChD,QAAQ,EACR,IAAI,KAAK,CAAC,qCAAqC,IAAI,CAAC,MAAM,CAAC,SAAS,UAAU,IAAI,CAAC,MAAM,CAAC,aAAa,IAAI,CAAC,CAC7G,CAAC,CAAA;YACJ,CAAC;YACD,IAAI,IAAI,CAAC,MAAM,CAAC,UAAU,KAAK,IAAI,CAAC,UAAU,EAAE,CAAC;gBAC/C,WAAW,CAAC,GAAG,CAAC,IAAI,8BAA8B,CAChD,QAAQ,EACR,IAAI,KAAK,CAAC,uDAAuD,IAAI,CAAC,MAAM,CAAC,SAAS,6BAA6B,CAAC,CACrH,CAAC,CAAA;YACJ,CAAC;QACH,CAAC;IACH,CAAC;IAED,UAAU;QACR,OAAO;YACL,YAAY,EAAE,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC;YACjD,QAAQ,EAAE,IAAI,CAAC,MAAM,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,CAAC,CAAC,CAAC,IAAI;YAC9D,IAAI,EAAE,IAAI,CAAC,aAAa;YACxB,IAAI,EAAE,IAAI,CAAC,IAAI;YACf,WAAW,EAAE,IAAI,CAAC,WAAW;YAC7B,MAAM,EAAE,IAAI,CAAC,MAAM;YACnB,YAAY,EAAE,IAAI,CAAC,YAAY;SAChC,CAAA;IACH,CAAC"}
@@ -0,0 +1,118 @@
1
+ import { Construct } from './construct.js';
2
+ import { Diagnostics } from './diagnostics.js';
3
+ import type { StatusPageTheme } from './status-page.js';
4
+ export interface StatusPageV3Props {
5
+ /**
6
+ * The name of the status page.
7
+ */
8
+ name: string;
9
+ /**
10
+ * The URL of the status page.
11
+ */
12
+ url: string;
13
+ /**
14
+ * A custom user domain, e.g. "status.example.com". See the docs on updating your DNS and SSL usage.
15
+ */
16
+ customDomain?: string;
17
+ /**
18
+ * A short description shown on the status page.
19
+ */
20
+ description?: string;
21
+ /**
22
+ * A URL pointing to an image file that serves as the logo for the status page.
23
+ */
24
+ logo?: string;
25
+ /**
26
+ * A URL pointing to an image file that serves as the logo in dark mode.
27
+ */
28
+ logoDark?: string;
29
+ /**
30
+ * The URL that clicking the logo should redirect the user to.
31
+ */
32
+ redirectTo?: string;
33
+ /**
34
+ * A URL pointing to an image file to be used as the favicon for the status page.
35
+ */
36
+ favicon?: string;
37
+ /**
38
+ * The default theme of the status page.
39
+ */
40
+ defaultTheme?: StatusPageTheme;
41
+ /**
42
+ * A link to your privacy policy, shown in the page footer.
43
+ */
44
+ privacyPolicyLink?: string;
45
+ /**
46
+ * A link to your terms of service, shown in the page footer.
47
+ */
48
+ termsOfServiceLink?: string;
49
+ /**
50
+ * Free-form footer text.
51
+ */
52
+ footerText?: string;
53
+ /**
54
+ * A Google Analytics tag ID (e.g. "G-XXXXXXXXXX") to embed on the public page.
55
+ */
56
+ googleAnalyticsTag?: string;
57
+ /**
58
+ * Whether search engines may index the public page. Defaults to true.
59
+ */
60
+ allowIndexing?: boolean;
61
+ }
62
+ /**
63
+ * Creates a reference to an existing v3 Status Page.
64
+ *
65
+ * References link existing resources to a project without managing them —
66
+ * typically so components and automation rules declared in code can attach
67
+ * to a page that was created in the UI.
68
+ *
69
+ * Use {@link StatusPageV3.fromId()} instead of instantiating this class directly.
70
+ */
71
+ export declare class StatusPageV3Ref extends Construct {
72
+ constructor(logicalId: string, physicalId: string);
73
+ describe(): string;
74
+ validate(diagnostics: Diagnostics): Promise<void>;
75
+ synthesize(): null;
76
+ }
77
+ /**
78
+ * Creates a v3 (components-based) Status Page.
79
+ *
80
+ * Unlike {@link StatusPage}, a v3 page has no cards or services. Its structure
81
+ * is declared with {@link StatusPageV3Component} constructs that point at the
82
+ * page, and incidents can be automated with {@link StatusPageV3AutomationRule}.
83
+ *
84
+ * A page's generation cannot change in place: a logical id that was deployed
85
+ * as a `StatusPage` cannot be redeployed as a `StatusPageV3` (or vice versa).
86
+ */
87
+ export declare class StatusPageV3 extends Construct {
88
+ name: string;
89
+ url: string;
90
+ customDomain?: string;
91
+ description?: string;
92
+ logo?: string;
93
+ logoDark?: string;
94
+ redirectTo?: string;
95
+ favicon?: string;
96
+ defaultTheme?: StatusPageTheme;
97
+ privacyPolicyLink?: string;
98
+ termsOfServiceLink?: string;
99
+ footerText?: string;
100
+ googleAnalyticsTag?: string;
101
+ allowIndexing?: boolean;
102
+ static readonly __checklyType = "status-page";
103
+ /**
104
+ * Constructs the v3 Status Page instance
105
+ *
106
+ * @param logicalId unique project-scoped resource name identification
107
+ * @param props status page configuration properties
108
+ *
109
+ * {@link https://www.checklyhq.com/docs/constructs/status-page-v3/ Read more in the docs}
110
+ */
111
+ constructor(logicalId: string, props: StatusPageV3Props);
112
+ describe(): string;
113
+ /**
114
+ * @param id - The UUID of the existing v3 status page
115
+ */
116
+ static fromId(id: string): StatusPageV3Ref;
117
+ synthesize(): any | null;
118
+ }
@@ -0,0 +1,112 @@
1
+ import { Construct } from './construct.js';
2
+ import { validatePhysicalIdIsUuid } from './internal/common-diagnostics.js';
3
+ import { Session } from './session.js';
4
+ /**
5
+ * Creates a reference to an existing v3 Status Page.
6
+ *
7
+ * References link existing resources to a project without managing them —
8
+ * typically so components and automation rules declared in code can attach
9
+ * to a page that was created in the UI.
10
+ *
11
+ * Use {@link StatusPageV3.fromId()} instead of instantiating this class directly.
12
+ */
13
+ export class StatusPageV3Ref extends Construct {
14
+ constructor(logicalId, physicalId) {
15
+ super(StatusPageV3.__checklyType, logicalId, physicalId, false);
16
+ Session.registerConstruct(this);
17
+ }
18
+ describe() {
19
+ return `StatusPageV3Ref:${this.logicalId}`;
20
+ }
21
+ async validate(diagnostics) {
22
+ await super.validate(diagnostics);
23
+ await validatePhysicalIdIsUuid(diagnostics, 'StatusPageV3', this.physicalId);
24
+ }
25
+ synthesize() {
26
+ return null;
27
+ }
28
+ }
29
+ /**
30
+ * Creates a v3 (components-based) Status Page.
31
+ *
32
+ * Unlike {@link StatusPage}, a v3 page has no cards or services. Its structure
33
+ * is declared with {@link StatusPageV3Component} constructs that point at the
34
+ * page, and incidents can be automated with {@link StatusPageV3AutomationRule}.
35
+ *
36
+ * A page's generation cannot change in place: a logical id that was deployed
37
+ * as a `StatusPage` cannot be redeployed as a `StatusPageV3` (or vice versa).
38
+ */
39
+ export class StatusPageV3 extends Construct {
40
+ name;
41
+ url;
42
+ customDomain;
43
+ description;
44
+ logo;
45
+ logoDark;
46
+ redirectTo;
47
+ favicon;
48
+ defaultTheme;
49
+ privacyPolicyLink;
50
+ termsOfServiceLink;
51
+ footerText;
52
+ googleAnalyticsTag;
53
+ allowIndexing;
54
+ // Same resource type as the v2 page: both live in one table and are told
55
+ // apart by the `version` discriminator synthesized below.
56
+ static __checklyType = 'status-page';
57
+ /**
58
+ * Constructs the v3 Status Page instance
59
+ *
60
+ * @param logicalId unique project-scoped resource name identification
61
+ * @param props status page configuration properties
62
+ *
63
+ * {@link https://www.checklyhq.com/docs/constructs/status-page-v3/ Read more in the docs}
64
+ */
65
+ constructor(logicalId, props) {
66
+ super(StatusPageV3.__checklyType, logicalId);
67
+ this.name = props.name;
68
+ this.url = props.url;
69
+ this.customDomain = props.customDomain;
70
+ this.description = props.description;
71
+ this.logo = props.logo;
72
+ this.logoDark = props.logoDark;
73
+ this.redirectTo = props.redirectTo;
74
+ this.favicon = props.favicon;
75
+ this.defaultTheme = props.defaultTheme;
76
+ this.privacyPolicyLink = props.privacyPolicyLink;
77
+ this.termsOfServiceLink = props.termsOfServiceLink;
78
+ this.footerText = props.footerText;
79
+ this.googleAnalyticsTag = props.googleAnalyticsTag;
80
+ this.allowIndexing = props.allowIndexing;
81
+ Session.registerConstruct(this);
82
+ }
83
+ describe() {
84
+ return `StatusPageV3:${this.logicalId}`;
85
+ }
86
+ /**
87
+ * @param id - The UUID of the existing v3 status page
88
+ */
89
+ static fromId(id) {
90
+ return new StatusPageV3Ref(`status-page-${id}`, id);
91
+ }
92
+ synthesize() {
93
+ return {
94
+ name: this.name,
95
+ url: this.url,
96
+ customDomain: this.customDomain,
97
+ description: this.description,
98
+ logo: this.logo,
99
+ logoDark: this.logoDark,
100
+ redirectTo: this.redirectTo,
101
+ favicon: this.favicon,
102
+ defaultTheme: this.defaultTheme,
103
+ privacyPolicyLink: this.privacyPolicyLink,
104
+ termsOfServiceLink: this.termsOfServiceLink,
105
+ footerText: this.footerText,
106
+ googleAnalyticsTag: this.googleAnalyticsTag,
107
+ allowIndexing: this.allowIndexing,
108
+ version: 3,
109
+ };
110
+ }
111
+ }
112
+ //# sourceMappingURL=status-page-v3.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"status-page-v3.js","sourceRoot":"","sources":["../../src/constructs/status-page-v3.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAE1C,OAAO,EAAE,wBAAwB,EAAE,MAAM,kCAAkC,CAAA;AAC3E,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA;AA8DtC;;;;;;;;GAQG;AACH,MAAM,OAAO,eAAgB,SAAQ,SAAS;IAC5C,YAAa,SAAiB,EAAE,UAAkB;QAChD,KAAK,CAAC,YAAY,CAAC,aAAa,EAAE,SAAS,EAAE,UAAU,EAAE,KAAK,CAAC,CAAA;QAC/D,OAAO,CAAC,iBAAiB,CAAC,IAAI,CAAC,CAAA;IACjC,CAAC;IAED,QAAQ;QACN,OAAO,mBAAmB,IAAI,CAAC,SAAS,EAAE,CAAA;IAC5C,CAAC;IAED,KAAK,CAAC,QAAQ,CAAE,WAAwB;QACtC,MAAM,KAAK,CAAC,QAAQ,CAAC,WAAW,CAAC,CAAA;QACjC,MAAM,wBAAwB,CAAC,WAAW,EAAE,cAAc,EAAE,IAAI,CAAC,UAAU,CAAC,CAAA;IAC9E,CAAC;IAED,UAAU;QACR,OAAO,IAAI,CAAA;IACb,CAAC;CACF;AAED;;;;;;;;;GASG;AACH,MAAM,OAAO,YAAa,SAAQ,SAAS;IACzC,IAAI,CAAQ;IACZ,GAAG,CAAQ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