@anvil-cloud/sdk 0.0.14 → 0.0.15
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.
- package/aws/cognitoAuth.ts +70 -0
- package/aws/cognitoUserPool.ts +132 -0
- package/aws/dynamoDB.ts +176 -0
- package/aws/eventBus.ts +91 -0
- package/aws/httpApi.ts +108 -0
- package/aws/index.ts +49 -0
- package/aws/lambda.ts +1 -1
- package/aws/oauthAuthorizer.ts +70 -0
- package/aws/queue.ts +156 -0
- package/aws/svelteKitSite.ts +14 -0
- package/aws/vpcEndpoint.ts +9 -4
- package/bin/aws/cognitoAuth.d.ts +36 -0
- package/bin/aws/cognitoAuth.js +53 -0
- package/bin/aws/cognitoAuth.js.map +1 -0
- package/bin/aws/cognitoUserPool.d.ts +82 -0
- package/bin/aws/cognitoUserPool.js +65 -0
- package/bin/aws/cognitoUserPool.js.map +1 -0
- package/bin/aws/dynamoDB.d.ts +115 -0
- package/bin/aws/dynamoDB.js +121 -0
- package/bin/aws/dynamoDB.js.map +1 -0
- package/bin/aws/eventBus.d.ts +47 -0
- package/bin/aws/eventBus.js +63 -0
- package/bin/aws/eventBus.js.map +1 -0
- package/bin/aws/httpApi.d.ts +66 -0
- package/bin/aws/httpApi.js +60 -0
- package/bin/aws/httpApi.js.map +1 -0
- package/bin/aws/index.d.ts +21 -0
- package/bin/aws/index.js +29 -1
- package/bin/aws/index.js.map +1 -1
- package/bin/aws/lambda.d.ts +1 -1
- package/bin/aws/oauthAuthorizer.d.ts +36 -0
- package/bin/aws/oauthAuthorizer.js +53 -0
- package/bin/aws/oauthAuthorizer.js.map +1 -0
- package/bin/aws/queue.d.ts +83 -0
- package/bin/aws/queue.js +103 -0
- package/bin/aws/queue.js.map +1 -0
- package/bin/aws/svelteKitSite.d.ts +9 -0
- package/bin/aws/svelteKitSite.js +3 -0
- package/bin/aws/svelteKitSite.js.map +1 -1
- package/bin/aws/vpcEndpoint.d.ts +9 -5
- package/bin/aws/vpcEndpoint.js +2 -1
- package/bin/aws/vpcEndpoint.js.map +1 -1
- package/bin/grants.js +4 -0
- package/bin/grants.js.map +1 -1
- package/bin/package.json +1 -1
- package/bin/types/enums/aws/index.d.ts +164 -36
- package/bin/types/enums/aws/index.js +149 -35
- package/bin/types/enums/aws/index.js.map +1 -1
- package/bin/types/input.d.ts +962 -10
- package/bin/types/output.d.ts +13 -0
- package/grants.ts +6 -1
- package/package.json +1 -1
- package/tsconfig.json +7 -0
- package/types/enums/aws/index.ts +186 -36
- package/types/input.ts +994 -10
- package/types/output.ts +14 -0
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
2
|
+
import * as inputs from "../types/input";
|
|
3
|
+
import * as grants from "../grants";
|
|
4
|
+
/**
|
|
5
|
+
* Serverless key-value and document store. Secure-by-default DynamoDB table with GSI support, optional streams, and Lambda/EventBridge consumers. First data layer component — pairs naturally with anvil.aws.Lambda.
|
|
6
|
+
*/
|
|
7
|
+
export declare class DynamoDB extends pulumi.ComponentResource {
|
|
8
|
+
/**
|
|
9
|
+
* Returns true if the given object is an instance of DynamoDB. This is designed to work even
|
|
10
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
11
|
+
*/
|
|
12
|
+
static isInstance(obj: any): obj is DynamoDB;
|
|
13
|
+
/**
|
|
14
|
+
* The ARN of the DynamoDB stream. Only present when stream is enabled.
|
|
15
|
+
*/
|
|
16
|
+
readonly streamArn: pulumi.Output<string | undefined>;
|
|
17
|
+
/**
|
|
18
|
+
* The ARN of the DynamoDB table.
|
|
19
|
+
*/
|
|
20
|
+
readonly tableArn: pulumi.Output<string>;
|
|
21
|
+
/**
|
|
22
|
+
* The physical DynamoDB table name. Scoped as {name}-{stage}.
|
|
23
|
+
*/
|
|
24
|
+
readonly tableName: pulumi.Output<string>;
|
|
25
|
+
/**
|
|
26
|
+
* Create a DynamoDB resource with the given unique name, arguments, and options.
|
|
27
|
+
*
|
|
28
|
+
* @param name The _unique_ name of the resource.
|
|
29
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
30
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
31
|
+
*/
|
|
32
|
+
constructor(name: string, args: DynamoDBArgs, opts?: pulumi.ComponentResourceOptions);
|
|
33
|
+
/**
|
|
34
|
+
* Grants read access (dynamodb:GetItem, dynamodb:BatchGetItem, dynamodb:Query, dynamodb:Scan) on this dynamodb
|
|
35
|
+
* to the target compute resource's execution role.
|
|
36
|
+
*
|
|
37
|
+
* @param target - The compute resource to grant access to.
|
|
38
|
+
* @param opts - Optional. indexes: scope to specific GSI names only.
|
|
39
|
+
* If omitted, grants table access only — no index access.
|
|
40
|
+
* @param opts.justification - Optional audit trail note.
|
|
41
|
+
*/
|
|
42
|
+
grantRead(target: grants.GrantTarget, opts?: {
|
|
43
|
+
indexes?: string[];
|
|
44
|
+
justification?: string;
|
|
45
|
+
}): void;
|
|
46
|
+
/**
|
|
47
|
+
* Grants write access (dynamodb:PutItem, dynamodb:UpdateItem, dynamodb:BatchWriteItem) on this dynamodb
|
|
48
|
+
* to the target compute resource's execution role.
|
|
49
|
+
*
|
|
50
|
+
* @param target - The compute resource to grant access to.
|
|
51
|
+
* @param opts - Optional. indexes: scope to specific GSI names only.
|
|
52
|
+
* If omitted, grants table access only — no index access.
|
|
53
|
+
* @param opts.justification - Optional audit trail note.
|
|
54
|
+
*/
|
|
55
|
+
grantWrite(target: grants.GrantTarget, opts?: {
|
|
56
|
+
indexes?: string[];
|
|
57
|
+
justification?: string;
|
|
58
|
+
}): void;
|
|
59
|
+
/**
|
|
60
|
+
* Grants readwrite access (dynamodb:GetItem, dynamodb:BatchGetItem, dynamodb:Query, dynamodb:Scan, dynamodb:PutItem, dynamodb:UpdateItem, dynamodb:BatchWriteItem) on this dynamodb
|
|
61
|
+
* to the target compute resource's execution role.
|
|
62
|
+
*
|
|
63
|
+
* @param target - The compute resource to grant access to.
|
|
64
|
+
* @param opts - Optional. indexes: scope to specific GSI names only.
|
|
65
|
+
* If omitted, grants table access only — no index access.
|
|
66
|
+
* @param opts.justification - Optional audit trail note.
|
|
67
|
+
*/
|
|
68
|
+
grantReadWrite(target: grants.GrantTarget, opts?: {
|
|
69
|
+
indexes?: string[];
|
|
70
|
+
justification?: string;
|
|
71
|
+
}): void;
|
|
72
|
+
/**
|
|
73
|
+
* Grants delete access (dynamodb:DeleteItem) on this dynamodb
|
|
74
|
+
* to the target compute resource's execution role.
|
|
75
|
+
*
|
|
76
|
+
* @param target - The compute resource to grant access to.
|
|
77
|
+
* @param opts - Optional. indexes: scope to specific GSI names only.
|
|
78
|
+
* If omitted, grants table access only — no index access.
|
|
79
|
+
* @param opts.justification - Optional audit trail note.
|
|
80
|
+
*/
|
|
81
|
+
grantDelete(target: grants.GrantTarget, opts?: {
|
|
82
|
+
indexes?: string[];
|
|
83
|
+
justification?: string;
|
|
84
|
+
}): void;
|
|
85
|
+
}
|
|
86
|
+
/**
|
|
87
|
+
* The set of arguments for constructing a DynamoDB resource.
|
|
88
|
+
*/
|
|
89
|
+
export interface DynamoDBArgs {
|
|
90
|
+
/**
|
|
91
|
+
* Global Secondary Indexes. All GSI key types must be explicitly declared — Anvil derives attributeDefinitions automatically from all declared keys.
|
|
92
|
+
*/
|
|
93
|
+
globalSecondaryIndexes?: pulumi.Input<pulumi.Input<inputs.aws.DynamoDBGlobalSecondaryIndexArgs>[]>;
|
|
94
|
+
/**
|
|
95
|
+
* Primary hash (partition) key. Required.
|
|
96
|
+
*/
|
|
97
|
+
hashKey: pulumi.Input<inputs.aws.DynamoDBKeyAttributeArgs>;
|
|
98
|
+
/**
|
|
99
|
+
* Tier 2 opt-in. ARN of a KMS CMK for encryption at rest. If omitted, AWS_OWNED_KMS is used (Tier 1 default — always on, zero cost). Use this for compliance workloads requiring key rotation control, audit trail, or the ability to revoke access by disabling the key.
|
|
100
|
+
*/
|
|
101
|
+
kmsKeyArn?: pulumi.Input<string>;
|
|
102
|
+
/**
|
|
103
|
+
* Primary range (sort) key. Optional.
|
|
104
|
+
*/
|
|
105
|
+
rangeKey?: pulumi.Input<inputs.aws.DynamoDBKeyAttributeArgs>;
|
|
106
|
+
/**
|
|
107
|
+
* DynamoDB Streams configuration. Opt-in. Enables change data capture on the table.
|
|
108
|
+
*/
|
|
109
|
+
stream?: pulumi.Input<inputs.aws.DynamoDBStreamArgs>;
|
|
110
|
+
transform?: pulumi.Input<inputs.aws.DynamoTransformArgsArgs>;
|
|
111
|
+
/**
|
|
112
|
+
* Name of the attribute used for TTL (time-to-live). Items with this attribute set to a past Unix timestamp are automatically deleted by DynamoDB.
|
|
113
|
+
*/
|
|
114
|
+
ttlAttribute?: pulumi.Input<string>;
|
|
115
|
+
}
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
3
|
+
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.DynamoDB = void 0;
|
|
6
|
+
const pulumi = require("@pulumi/pulumi");
|
|
7
|
+
const utilities = require("../utilities");
|
|
8
|
+
const grants = require("../grants");
|
|
9
|
+
/**
|
|
10
|
+
* Serverless key-value and document store. Secure-by-default DynamoDB table with GSI support, optional streams, and Lambda/EventBridge consumers. First data layer component — pairs naturally with anvil.aws.Lambda.
|
|
11
|
+
*/
|
|
12
|
+
class DynamoDB extends pulumi.ComponentResource {
|
|
13
|
+
/**
|
|
14
|
+
* Returns true if the given object is an instance of DynamoDB. This is designed to work even
|
|
15
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
16
|
+
*/
|
|
17
|
+
static isInstance(obj) {
|
|
18
|
+
if (obj === undefined || obj === null) {
|
|
19
|
+
return false;
|
|
20
|
+
}
|
|
21
|
+
return obj['__pulumiType'] === DynamoDB.__pulumiType;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Create a DynamoDB resource with the given unique name, arguments, and options.
|
|
25
|
+
*
|
|
26
|
+
* @param name The _unique_ name of the resource.
|
|
27
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
28
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
29
|
+
*/
|
|
30
|
+
constructor(name, args, opts) {
|
|
31
|
+
let resourceInputs = {};
|
|
32
|
+
opts = opts || {};
|
|
33
|
+
if (!opts.id) {
|
|
34
|
+
if (args?.hashKey === undefined && !opts.urn) {
|
|
35
|
+
throw new Error("Missing required property 'hashKey'");
|
|
36
|
+
}
|
|
37
|
+
resourceInputs["globalSecondaryIndexes"] = args?.globalSecondaryIndexes;
|
|
38
|
+
resourceInputs["hashKey"] = args?.hashKey;
|
|
39
|
+
resourceInputs["kmsKeyArn"] = args?.kmsKeyArn;
|
|
40
|
+
resourceInputs["rangeKey"] = args?.rangeKey;
|
|
41
|
+
resourceInputs["stream"] = args?.stream;
|
|
42
|
+
resourceInputs["transform"] = args?.transform;
|
|
43
|
+
resourceInputs["ttlAttribute"] = args?.ttlAttribute;
|
|
44
|
+
resourceInputs["streamArn"] = undefined /*out*/;
|
|
45
|
+
resourceInputs["tableArn"] = undefined /*out*/;
|
|
46
|
+
resourceInputs["tableName"] = undefined /*out*/;
|
|
47
|
+
}
|
|
48
|
+
else {
|
|
49
|
+
resourceInputs["streamArn"] = undefined /*out*/;
|
|
50
|
+
resourceInputs["tableArn"] = undefined /*out*/;
|
|
51
|
+
resourceInputs["tableName"] = undefined /*out*/;
|
|
52
|
+
}
|
|
53
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
54
|
+
super(DynamoDB.__pulumiType, name, resourceInputs, opts, true /*remote*/);
|
|
55
|
+
this.__name = name;
|
|
56
|
+
}
|
|
57
|
+
/**
|
|
58
|
+
* Grants read access (dynamodb:GetItem, dynamodb:BatchGetItem, dynamodb:Query, dynamodb:Scan) on this dynamodb
|
|
59
|
+
* to the target compute resource's execution role.
|
|
60
|
+
*
|
|
61
|
+
* @param target - The compute resource to grant access to.
|
|
62
|
+
* @param opts - Optional. indexes: scope to specific GSI names only.
|
|
63
|
+
* If omitted, grants table access only — no index access.
|
|
64
|
+
* @param opts.justification - Optional audit trail note.
|
|
65
|
+
*/
|
|
66
|
+
grantRead(target, opts) {
|
|
67
|
+
const name = `${this.__name}-${target.grantName()}-read`;
|
|
68
|
+
const indexPaths = opts?.indexes?.map(i => `index/${i}`) ?? null;
|
|
69
|
+
const arns = grants.buildResourceArns(this.tableArn, indexPaths);
|
|
70
|
+
grants.createGrant(this, name, target, ["dynamodb:GetItem", "dynamodb:BatchGetItem", "dynamodb:Query", "dynamodb:Scan"], arns, { justification: opts?.justification });
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Grants write access (dynamodb:PutItem, dynamodb:UpdateItem, dynamodb:BatchWriteItem) on this dynamodb
|
|
74
|
+
* to the target compute resource's execution role.
|
|
75
|
+
*
|
|
76
|
+
* @param target - The compute resource to grant access to.
|
|
77
|
+
* @param opts - Optional. indexes: scope to specific GSI names only.
|
|
78
|
+
* If omitted, grants table access only — no index access.
|
|
79
|
+
* @param opts.justification - Optional audit trail note.
|
|
80
|
+
*/
|
|
81
|
+
grantWrite(target, opts) {
|
|
82
|
+
const name = `${this.__name}-${target.grantName()}-write`;
|
|
83
|
+
const indexPaths = opts?.indexes?.map(i => `index/${i}`) ?? null;
|
|
84
|
+
const arns = grants.buildResourceArns(this.tableArn, indexPaths);
|
|
85
|
+
grants.createGrant(this, name, target, ["dynamodb:PutItem", "dynamodb:UpdateItem", "dynamodb:BatchWriteItem"], arns, { justification: opts?.justification });
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Grants readwrite access (dynamodb:GetItem, dynamodb:BatchGetItem, dynamodb:Query, dynamodb:Scan, dynamodb:PutItem, dynamodb:UpdateItem, dynamodb:BatchWriteItem) on this dynamodb
|
|
89
|
+
* to the target compute resource's execution role.
|
|
90
|
+
*
|
|
91
|
+
* @param target - The compute resource to grant access to.
|
|
92
|
+
* @param opts - Optional. indexes: scope to specific GSI names only.
|
|
93
|
+
* If omitted, grants table access only — no index access.
|
|
94
|
+
* @param opts.justification - Optional audit trail note.
|
|
95
|
+
*/
|
|
96
|
+
grantReadWrite(target, opts) {
|
|
97
|
+
const name = `${this.__name}-${target.grantName()}-readwrite`;
|
|
98
|
+
const indexPaths = opts?.indexes?.map(i => `index/${i}`) ?? null;
|
|
99
|
+
const arns = grants.buildResourceArns(this.tableArn, indexPaths);
|
|
100
|
+
grants.createGrant(this, name, target, ["dynamodb:GetItem", "dynamodb:BatchGetItem", "dynamodb:Query", "dynamodb:Scan", "dynamodb:PutItem", "dynamodb:UpdateItem", "dynamodb:BatchWriteItem"], arns, { justification: opts?.justification });
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* Grants delete access (dynamodb:DeleteItem) on this dynamodb
|
|
104
|
+
* to the target compute resource's execution role.
|
|
105
|
+
*
|
|
106
|
+
* @param target - The compute resource to grant access to.
|
|
107
|
+
* @param opts - Optional. indexes: scope to specific GSI names only.
|
|
108
|
+
* If omitted, grants table access only — no index access.
|
|
109
|
+
* @param opts.justification - Optional audit trail note.
|
|
110
|
+
*/
|
|
111
|
+
grantDelete(target, opts) {
|
|
112
|
+
const name = `${this.__name}-${target.grantName()}-delete`;
|
|
113
|
+
const indexPaths = opts?.indexes?.map(i => `index/${i}`) ?? null;
|
|
114
|
+
const arns = grants.buildResourceArns(this.tableArn, indexPaths);
|
|
115
|
+
grants.createGrant(this, name, target, ["dynamodb:DeleteItem"], arns, { justification: opts?.justification });
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
exports.DynamoDB = DynamoDB;
|
|
119
|
+
/** @internal */
|
|
120
|
+
DynamoDB.__pulumiType = 'anvil:aws:DynamoDB';
|
|
121
|
+
//# sourceMappingURL=dynamoDB.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dynamoDB.js","sourceRoot":"","s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AS,CAAC;QAC3D,MAAM,UAAU,GAAG,IAAI,EAAE,OAAO,EAAE,GAAG,CAAC,CAAC,CAAC,EAAE,CAAC,SAAS,CAAC,EAAE,CAAC,IAAI,IAAI,CAAC;QACjE,MAAM,IAAI,GAAG,MAAM,CAAC,iBAAiB,CAAC,IAAI,CAAC,QAAQ,EAAE,UAAU,CAAC,CAAC;QACjE,MAAM,CAAC,WAAW,CAAC,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC,qBAAqB,CAAC,EAAE,IAAI,EAAE,EAAE,aAAa,EAAE,IAAI,EAAE,aAAa,EAAE,CAAC,CAAC;IAClH,CAAC;;AA/HP,4BAiIC;AAhIG,gBAAgB;AACO,qBAAY,GAAG,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
2
|
+
import * as inputs from "../types/input";
|
|
3
|
+
import * as grants from "../grants";
|
|
4
|
+
/**
|
|
5
|
+
* An Anvil-managed EventBridge event bus. Archives events for 7 days by default for replay and debugging. Rules route matching events to Lambda targets.
|
|
6
|
+
*/
|
|
7
|
+
export declare class EventBus extends pulumi.ComponentResource {
|
|
8
|
+
/**
|
|
9
|
+
* Returns true if the given object is an instance of EventBus. This is designed to work even
|
|
10
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
11
|
+
*/
|
|
12
|
+
static isInstance(obj: any): obj is EventBus;
|
|
13
|
+
/**
|
|
14
|
+
* The ARN of the EventBridge event bus.
|
|
15
|
+
*/
|
|
16
|
+
readonly arn: pulumi.Output<string>;
|
|
17
|
+
/**
|
|
18
|
+
* The name of the EventBridge event bus. Pass to HttpApi consumer: { eventBridge: { name: bus.name } }
|
|
19
|
+
*/
|
|
20
|
+
readonly name: pulumi.Output<string>;
|
|
21
|
+
/**
|
|
22
|
+
* Create a EventBus resource with the given unique name, arguments, and options.
|
|
23
|
+
*
|
|
24
|
+
* @param name The _unique_ name of the resource.
|
|
25
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
26
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
27
|
+
*/
|
|
28
|
+
constructor(name: string, args?: EventBusArgs, opts?: pulumi.ComponentResourceOptions);
|
|
29
|
+
/**
|
|
30
|
+
* Grants putevents access (events:PutEvents) on this eventbus
|
|
31
|
+
* to the target compute resource's execution role.
|
|
32
|
+
*
|
|
33
|
+
* @param target - The compute resource to grant access to.
|
|
34
|
+
* @param opts - Optional grant options (justification for audit trail).
|
|
35
|
+
*/
|
|
36
|
+
grantPutEvents(target: grants.GrantTarget, opts?: grants.GrantOptions): void;
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* The set of arguments for constructing a EventBus resource.
|
|
40
|
+
*/
|
|
41
|
+
export interface EventBusArgs {
|
|
42
|
+
/**
|
|
43
|
+
* EventBridge rules on this bus. Each rule matches events by pattern and routes them to a target.
|
|
44
|
+
*/
|
|
45
|
+
rules?: pulumi.Input<pulumi.Input<inputs.aws.EventBusRuleArgs>[]>;
|
|
46
|
+
transform?: pulumi.Input<inputs.aws.EventBridgeTransformArgsArgs>;
|
|
47
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
3
|
+
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.EventBus = void 0;
|
|
6
|
+
const pulumi = require("@pulumi/pulumi");
|
|
7
|
+
const utilities = require("../utilities");
|
|
8
|
+
const grants = require("../grants");
|
|
9
|
+
/**
|
|
10
|
+
* An Anvil-managed EventBridge event bus. Archives events for 7 days by default for replay and debugging. Rules route matching events to Lambda targets.
|
|
11
|
+
*/
|
|
12
|
+
class EventBus extends pulumi.ComponentResource {
|
|
13
|
+
/**
|
|
14
|
+
* Returns true if the given object is an instance of EventBus. This is designed to work even
|
|
15
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
16
|
+
*/
|
|
17
|
+
static isInstance(obj) {
|
|
18
|
+
if (obj === undefined || obj === null) {
|
|
19
|
+
return false;
|
|
20
|
+
}
|
|
21
|
+
return obj['__pulumiType'] === EventBus.__pulumiType;
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Create a EventBus resource with the given unique name, arguments, and options.
|
|
25
|
+
*
|
|
26
|
+
* @param name The _unique_ name of the resource.
|
|
27
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
28
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
29
|
+
*/
|
|
30
|
+
constructor(name, args, opts) {
|
|
31
|
+
let resourceInputs = {};
|
|
32
|
+
opts = opts || {};
|
|
33
|
+
if (!opts.id) {
|
|
34
|
+
resourceInputs["rules"] = args?.rules;
|
|
35
|
+
resourceInputs["transform"] = args?.transform;
|
|
36
|
+
resourceInputs["arn"] = undefined /*out*/;
|
|
37
|
+
resourceInputs["name"] = undefined /*out*/;
|
|
38
|
+
}
|
|
39
|
+
else {
|
|
40
|
+
resourceInputs["arn"] = undefined /*out*/;
|
|
41
|
+
resourceInputs["name"] = undefined /*out*/;
|
|
42
|
+
}
|
|
43
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
44
|
+
super(EventBus.__pulumiType, name, resourceInputs, opts, true /*remote*/);
|
|
45
|
+
this.__name = name;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Grants putevents access (events:PutEvents) on this eventbus
|
|
49
|
+
* to the target compute resource's execution role.
|
|
50
|
+
*
|
|
51
|
+
* @param target - The compute resource to grant access to.
|
|
52
|
+
* @param opts - Optional grant options (justification for audit trail).
|
|
53
|
+
*/
|
|
54
|
+
grantPutEvents(target, opts) {
|
|
55
|
+
const name = `${this.__name}-${target.grantName()}-putevents`;
|
|
56
|
+
const arns = grants.buildResourceArns(this.arn, undefined);
|
|
57
|
+
grants.createGrant(this, name, target, ["events:PutEvents"], arns, opts);
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
exports.EventBus = EventBus;
|
|
61
|
+
/** @internal */
|
|
62
|
+
EventBus.__pulumiType = 'anvil:aws:EventBus';
|
|
63
|
+
//# sourceMappingURL=eventBus.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"eventBus.js","sourceRoot":"","sources":["../../aws/eventBus.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AAIzC,0CAA0C;AAG1C,oCAAoC;AAEpC;;GAEG;AACH,MAAa,QAAS,SAAQ,MAAM,CAAC,iBAAiB;IAOlD;;;OAGG;IACI,MAAM,CAAC,UAAU,CAAC,GAAQ;QAC7B,IAAI,GAAG,KAAK,SAAS,IAAI,GAAG,KAAK,IAAI,EAAE;YACnC,OAAO,KAAK,CAAC;SAChB;QACD,OAAO,GAAG,CAAC,cAAc,CAAC,KAAK,QAAQ,CAAC,YAAY,CAAC;IACzD,CAAC;IAWD;;;;;;OAMG;IACH,YAAY,IAAY,EAAE,IAAmB,EAAE,IAAsC;QACjF,IAAI,cAAc,GAAkB,EAAE,CAAC;QACvC,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC;QAClB,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE;YACV,cAAc,CAAC,OAAO,CAAC,GAAG,IAAI,EAAE,KAAK,CAAC;YACtC,cAAc,CAAC,WAAW,CAAC,GAAG,IAAI,EAAE,SAAS,CAAC;YAC9C,cAAc,CAAC,KAAK,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC1C,cAAc,CAAC,MAAM,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;SAC9C;aAAM;YACH,cAAc,CAAC,KAAK,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;YAC1C,cAAc,CAAC,MAAM,CAAC,GAAG,SAAS,CAAC,OAAO,CAAC;SAC9C;QACD,IAAI,GAAG,MAAM,CAAC,YAAY,CAAC,SAAS,CAAC,oBAAoB,EAAE,EAAE,IAAI,CAAC,CAAC;QACnE,KAAK,CAAC,QAAQ,CAAC,YAAY,EAAE,IAAI,EAAE,cAAc,EAAE,IAAI,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;QAC1E,IAAI,CAAC,MAAM,GAAG,IAAI,CAAC;IACvB,CAAC;IAED;;;;;;OAMG;IACI,cAAc,CAAC,MAA0B,EAAE,IAA0B;QACxE,MAAM,IAAI,GAAG,GAAG,IAAI,CAAC,MAAM,IAAI,MAAM,CAAC,SAAS,EAAE,YAAY,CAAC;QAC9D,MAAM,IAAI,GAAG,MAAM,CAAC,iBAAiB,CAAC,IAAI,CAAC,GAAG,EAAE,SAAS,CAAC,CAAC;QAC3D,MAAM,CAAC,WAAW,CAAC,IAAI,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC,kBAAkB,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC;IAC7E,CAAC;;AA9DL,4BAgEC;AA/DG,gBAAgB;AACO,qBAAY,GAAG,oBAAoB,CAAC"}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
2
|
+
import * as inputs from "../types/input";
|
|
3
|
+
import * as outputs from "../types/output";
|
|
4
|
+
/**
|
|
5
|
+
* An Anvil-managed AWS HTTP API Gateway (API Gateway v2). Route-level consumers support Lambda, SQS, EventBridge, Step Functions, and HTTP proxy integrations. Secure by default: TLS 1.2 minimum enforced on custom domains, execute-api endpoint disabled when a custom domain is set, conservative throttling defaults (1000 rps / 500 burst), CORS opt-in with wildcard origin blocked, per-consumer least-privilege IAM roles, access logs on by default.
|
|
6
|
+
*/
|
|
7
|
+
export declare class HttpApi extends pulumi.ComponentResource {
|
|
8
|
+
/**
|
|
9
|
+
* Returns true if the given object is an instance of HttpApi. This is designed to work even
|
|
10
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
11
|
+
*/
|
|
12
|
+
static isInstance(obj: any): obj is HttpApi;
|
|
13
|
+
/**
|
|
14
|
+
* The default execute-api endpoint URL. Empty string when a custom domain is set and the execute-api endpoint is disabled.
|
|
15
|
+
*/
|
|
16
|
+
readonly apiEndpoint: pulumi.Output<string>;
|
|
17
|
+
/**
|
|
18
|
+
* The API Gateway HTTP API ID.
|
|
19
|
+
*/
|
|
20
|
+
readonly apiId: pulumi.Output<string>;
|
|
21
|
+
/**
|
|
22
|
+
* ACM cert validation CNAME. Only populated when domain.dns: false and domain.certificateArn is omitted. Add this record in Cloudflare (or your DNS provider) then re-run deploy — Anvil blocks until ACM confirms validation.
|
|
23
|
+
*/
|
|
24
|
+
readonly certValidationCname: pulumi.Output<outputs.aws.HttpApiCertValidationCname>;
|
|
25
|
+
/**
|
|
26
|
+
* The primary URL for the API. When a custom domain is configured this is the custom domain URL. Otherwise it is the execute-api endpoint URL.
|
|
27
|
+
*/
|
|
28
|
+
readonly url: pulumi.Output<string>;
|
|
29
|
+
/**
|
|
30
|
+
* Create a HttpApi resource with the given unique name, arguments, and options.
|
|
31
|
+
*
|
|
32
|
+
* @param name The _unique_ name of the resource.
|
|
33
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
34
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
35
|
+
*/
|
|
36
|
+
constructor(name: string, args: HttpApiArgs, opts?: pulumi.ComponentResourceOptions);
|
|
37
|
+
}
|
|
38
|
+
/**
|
|
39
|
+
* The set of arguments for constructing a HttpApi resource.
|
|
40
|
+
*/
|
|
41
|
+
export interface HttpApiArgs {
|
|
42
|
+
/**
|
|
43
|
+
* Optional CORS configuration. Opt-in — omit to disable CORS entirely. When enabled, allowOrigins is required and wildcard '*' is blocked as a security measure.
|
|
44
|
+
*/
|
|
45
|
+
cors?: pulumi.Input<inputs.aws.HttpApiCorsArgs>;
|
|
46
|
+
/**
|
|
47
|
+
* The API Gateway authorizer ID to apply to all routes. Pass auth.authorizerId from an OAuthAuthorizer or CognitoAuth component. All routes inherit this authorizer unless skipAuth: true is set on the route. Omit to leave all routes public.
|
|
48
|
+
*/
|
|
49
|
+
defaultAuthorizerId?: any;
|
|
50
|
+
/**
|
|
51
|
+
* Optional custom domain for the API. When set, Anvil provisions the ACM certificate, API Gateway domain name, and Route 53 DNS record automatically. The raw execute-api endpoint is disabled — all traffic must flow through the custom domain.
|
|
52
|
+
*/
|
|
53
|
+
domain?: pulumi.Input<inputs.aws.HttpApiDomainArgs>;
|
|
54
|
+
/**
|
|
55
|
+
* CloudWatch access log retention period. Presets: '7d' | '30d' | '90d' | '1y' | '3y' | '6y' | '7y'. Default: '1y' — satisfies SOC 2, ISO 27001, and PCI DSS baseline retention requirements.
|
|
56
|
+
*/
|
|
57
|
+
logRetention?: pulumi.Input<string>;
|
|
58
|
+
/**
|
|
59
|
+
* The API routes. Each route maps a method and path to a consumer. At least one route is required.
|
|
60
|
+
*/
|
|
61
|
+
routes: pulumi.Input<pulumi.Input<inputs.aws.HttpApiRouteArgs>[]>;
|
|
62
|
+
/**
|
|
63
|
+
* Optional throttling configuration. Defaults to rateLimit: 1000 rps and burstLimit: 500 concurrent requests when omitted. Without throttling a single route can exhaust the account-level limit shared across all APIs.
|
|
64
|
+
*/
|
|
65
|
+
throttling?: pulumi.Input<inputs.aws.HttpApiThrottlingArgs>;
|
|
66
|
+
}
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
// *** WARNING: this file was generated by pulumi-language-nodejs. ***
|
|
3
|
+
// *** Do not edit by hand unless you're certain you know what you are doing! ***
|
|
4
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5
|
+
exports.HttpApi = void 0;
|
|
6
|
+
const pulumi = require("@pulumi/pulumi");
|
|
7
|
+
const utilities = require("../utilities");
|
|
8
|
+
/**
|
|
9
|
+
* An Anvil-managed AWS HTTP API Gateway (API Gateway v2). Route-level consumers support Lambda, SQS, EventBridge, Step Functions, and HTTP proxy integrations. Secure by default: TLS 1.2 minimum enforced on custom domains, execute-api endpoint disabled when a custom domain is set, conservative throttling defaults (1000 rps / 500 burst), CORS opt-in with wildcard origin blocked, per-consumer least-privilege IAM roles, access logs on by default.
|
|
10
|
+
*/
|
|
11
|
+
class HttpApi extends pulumi.ComponentResource {
|
|
12
|
+
/**
|
|
13
|
+
* Returns true if the given object is an instance of HttpApi. This is designed to work even
|
|
14
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
15
|
+
*/
|
|
16
|
+
static isInstance(obj) {
|
|
17
|
+
if (obj === undefined || obj === null) {
|
|
18
|
+
return false;
|
|
19
|
+
}
|
|
20
|
+
return obj['__pulumiType'] === HttpApi.__pulumiType;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* Create a HttpApi resource with the given unique name, arguments, and options.
|
|
24
|
+
*
|
|
25
|
+
* @param name The _unique_ name of the resource.
|
|
26
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
27
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
28
|
+
*/
|
|
29
|
+
constructor(name, args, opts) {
|
|
30
|
+
let resourceInputs = {};
|
|
31
|
+
opts = opts || {};
|
|
32
|
+
if (!opts.id) {
|
|
33
|
+
if (args?.routes === undefined && !opts.urn) {
|
|
34
|
+
throw new Error("Missing required property 'routes'");
|
|
35
|
+
}
|
|
36
|
+
resourceInputs["cors"] = args?.cors;
|
|
37
|
+
resourceInputs["defaultAuthorizerId"] = args?.defaultAuthorizerId;
|
|
38
|
+
resourceInputs["domain"] = args?.domain;
|
|
39
|
+
resourceInputs["logRetention"] = args?.logRetention;
|
|
40
|
+
resourceInputs["routes"] = args?.routes;
|
|
41
|
+
resourceInputs["throttling"] = args?.throttling;
|
|
42
|
+
resourceInputs["apiEndpoint"] = undefined /*out*/;
|
|
43
|
+
resourceInputs["apiId"] = undefined /*out*/;
|
|
44
|
+
resourceInputs["certValidationCname"] = undefined /*out*/;
|
|
45
|
+
resourceInputs["url"] = undefined /*out*/;
|
|
46
|
+
}
|
|
47
|
+
else {
|
|
48
|
+
resourceInputs["apiEndpoint"] = undefined /*out*/;
|
|
49
|
+
resourceInputs["apiId"] = undefined /*out*/;
|
|
50
|
+
resourceInputs["certValidationCname"] = undefined /*out*/;
|
|
51
|
+
resourceInputs["url"] = undefined /*out*/;
|
|
52
|
+
}
|
|
53
|
+
opts = pulumi.mergeOptions(utilities.resourceOptsDefaults(), opts);
|
|
54
|
+
super(HttpApi.__pulumiType, name, resourceInputs, opts, true /*remote*/);
|
|
55
|
+
}
|
|
56
|
+
}
|
|
57
|
+
exports.HttpApi = HttpApi;
|
|
58
|
+
/** @internal */
|
|
59
|
+
HttpApi.__pulumiType = 'anvil:aws:HttpApi';
|
|
60
|
+
//# sourceMappingURL=httpApi.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"httpApi.js","sourceRoot":"","sources":["../../aws/httpApi.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;AAEjF,yCAAyC;AAIzC,0CAA0C;AAE1C;;GAEG;AACH,MAAa,OAAQ,SAAQ,MAAM,CAAC,iBAAiB;IAIjD;;;OAGG;IACI,MAAM,CAAC,UAAU,CAAC,GAAQ;QAC7B,IAAI,GAAG,KAAK,SAAS,IAAI,GAAG,KAAK,IAAI,EAAE;YACnC,OAAO,KAAK,CAAC;SAChB;QACD,OAAO,GAAG,CAAC,cAAc,CAAC,KAAK,OAAO,CAAC,YAAY,CAAC;IACxD,CAAC;IAmBD;;;;;;OAMG;IACH,YAAY,IAAY,EAAE,IAAiB,EAAE,IAAsC;QAC/E,IAAI,cAAc,GAAkB,EAAE,CAAC;QACvC,IAAI,GAAG,IAAI,IAAI,EAAE,CAAC;QAClB,IAAI,CAAC,IAAI,CAAC,EAAE,EAAE;YACV,IAAI,IAAI,EAAE,MAAM,KAAK,SAAS,IAAI,CAAC,IAAI,CAAC,GAAG,EAAE;gBACzC,MAAM,IAAI,KAAK,CAAC,oCAAoC,CAAC,CAAC;aACzD;YACD,cAAc,CAAC,MA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|
export type Bucket = import("./bucket").Bucket;
|
|
3
3
|
export declare const Bucket: typeof import("./bucket").Bucket;
|
|
4
|
+
export { CognitoAuthArgs } from "./cognitoAuth";
|
|
5
|
+
export type CognitoAuth = import("./cognitoAuth").CognitoAuth;
|
|
6
|
+
export declare const CognitoAuth: typeof import("./cognitoAuth").CognitoAuth;
|
|
7
|
+
export { CognitoUserPoolArgs } from "./cognitoUserPool";
|
|
8
|
+
export type CognitoUserPool = import("./cognitoUserPool").CognitoUserPool;
|
|
9
|
+
export declare const CognitoUserPool: typeof import("./cognitoUserPool").CognitoUserPool;
|
|
10
|
+
export { DynamoDBArgs } from "./dynamoDB";
|
|
11
|
+
export type DynamoDB = import("./dynamoDB").DynamoDB;
|
|
12
|
+
export declare const DynamoDB: typeof import("./dynamoDB").DynamoDB;
|
|
13
|
+
export { EventBusArgs } from "./eventBus";
|
|
14
|
+
export type EventBus = import("./eventBus").EventBus;
|
|
15
|
+
export declare const EventBus: typeof import("./eventBus").EventBus;
|
|
16
|
+
export { HttpApiArgs } from "./httpApi";
|
|
17
|
+
export type HttpApi = import("./httpApi").HttpApi;
|
|
18
|
+
export declare const HttpApi: typeof import("./httpApi").HttpApi;
|
|
4
19
|
export { LambdaArgs } from "./lambda";
|
|
5
20
|
export type Lambda = import("./lambda").Lambda;
|
|
6
21
|
export declare const Lambda: typeof import("./lambda").Lambda;
|
|
22
|
+
export { OAuthAuthorizerArgs } from "./oauthAuthorizer";
|
|
23
|
+
export type OAuthAuthorizer = import("./oauthAuthorizer").OAuthAuthorizer;
|
|
24
|
+
export declare const OAuthAuthorizer: typeof import("./oauthAuthorizer").OAuthAuthorizer;
|
|
25
|
+
export { QueueArgs } from "./queue";
|
|
26
|
+
export type Queue = import("./queue").Queue;
|
|
27
|
+
export declare const Queue: typeof import("./queue").Queue;
|
|
7
28
|
export { SvelteKitSiteArgs } from "./svelteKitSite";
|
|
8
29
|
export type SvelteKitSite = import("./svelteKitSite").SvelteKitSite;
|
|
9
30
|
export declare const SvelteKitSite: typeof import("./svelteKitSite").SvelteKitSite;
|
package/bin/aws/index.js
CHANGED
|
@@ -16,13 +16,27 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
|
16
16
|
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
17
17
|
};
|
|
18
18
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
19
|
-
exports.VpcEndpoint = exports.Vpc = exports.SvelteKitSite = exports.Lambda = exports.Bucket = void 0;
|
|
19
|
+
exports.VpcEndpoint = exports.Vpc = exports.SvelteKitSite = exports.Queue = exports.OAuthAuthorizer = exports.Lambda = exports.HttpApi = exports.EventBus = exports.DynamoDB = exports.CognitoUserPool = exports.CognitoAuth = exports.Bucket = void 0;
|
|
20
20
|
const pulumi = require("@pulumi/pulumi");
|
|
21
21
|
const utilities = require("../utilities");
|
|
22
22
|
exports.Bucket = null;
|
|
23
23
|
utilities.lazyLoad(exports, ["Bucket"], () => require("./bucket"));
|
|
24
|
+
exports.CognitoAuth = null;
|
|
25
|
+
utilities.lazyLoad(exports, ["CognitoAuth"], () => require("./cognitoAuth"));
|
|
26
|
+
exports.CognitoUserPool = null;
|
|
27
|
+
utilities.lazyLoad(exports, ["CognitoUserPool"], () => require("./cognitoUserPool"));
|
|
28
|
+
exports.DynamoDB = null;
|
|
29
|
+
utilities.lazyLoad(exports, ["DynamoDB"], () => require("./dynamoDB"));
|
|
30
|
+
exports.EventBus = null;
|
|
31
|
+
utilities.lazyLoad(exports, ["EventBus"], () => require("./eventBus"));
|
|
32
|
+
exports.HttpApi = null;
|
|
33
|
+
utilities.lazyLoad(exports, ["HttpApi"], () => require("./httpApi"));
|
|
24
34
|
exports.Lambda = null;
|
|
25
35
|
utilities.lazyLoad(exports, ["Lambda"], () => require("./lambda"));
|
|
36
|
+
exports.OAuthAuthorizer = null;
|
|
37
|
+
utilities.lazyLoad(exports, ["OAuthAuthorizer"], () => require("./oauthAuthorizer"));
|
|
38
|
+
exports.Queue = null;
|
|
39
|
+
utilities.lazyLoad(exports, ["Queue"], () => require("./queue"));
|
|
26
40
|
exports.SvelteKitSite = null;
|
|
27
41
|
utilities.lazyLoad(exports, ["SvelteKitSite"], () => require("./svelteKitSite"));
|
|
28
42
|
exports.Vpc = null;
|
|
@@ -37,8 +51,22 @@ const _module = {
|
|
|
37
51
|
switch (type) {
|
|
38
52
|
case "anvil:aws:Bucket":
|
|
39
53
|
return new exports.Bucket(name, undefined, { urn });
|
|
54
|
+
case "anvil:aws:CognitoAuth":
|
|
55
|
+
return new exports.CognitoAuth(name, undefined, { urn });
|
|
56
|
+
case "anvil:aws:CognitoUserPool":
|
|
57
|
+
return new exports.CognitoUserPool(name, undefined, { urn });
|
|
58
|
+
case "anvil:aws:DynamoDB":
|
|
59
|
+
return new exports.DynamoDB(name, undefined, { urn });
|
|
60
|
+
case "anvil:aws:EventBus":
|
|
61
|
+
return new exports.EventBus(name, undefined, { urn });
|
|
62
|
+
case "anvil:aws:HttpApi":
|
|
63
|
+
return new exports.HttpApi(name, undefined, { urn });
|
|
40
64
|
case "anvil:aws:Lambda":
|
|
41
65
|
return new exports.Lambda(name, undefined, { urn });
|
|
66
|
+
case "anvil:aws:OAuthAuthorizer":
|
|
67
|
+
return new exports.OAuthAuthorizer(name, undefined, { urn });
|
|
68
|
+
case "anvil:aws:Queue":
|
|
69
|
+
return new exports.Queue(name, undefined, { urn });
|
|
42
70
|
case "anvil:aws:SvelteKitSite":
|
|
43
71
|
return new exports.SvelteKitSite(name, undefined, { urn });
|
|
44
72
|
case "anvil:aws:Vpc":
|
package/bin/aws/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../aws/index.ts"],"names":[],"mappings":";AAAA,sEAAsE;AACtE,iFAAiF;;;;;;;;;;;;;;;;;AAEjF,yCAAyC;AACzC,0CAA0C;AAK7B,QAAA,MAAM,GAAqC,IAAW,CAAC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AK,yBAAyB;gBAC1B,OAAO,IAAI,qBAAa,CAAC,IAAI,EAAO,SAAS,EAAE,EAAE,GAAG,EAAE,CAAC,CAAA;YAC3D,KAAK,eAAe;gBAChB,OAAO,IAAI,WAAG,CAAC,IAAI,EAAO,SAAS,EAAE,EAAE,GAAG,EAAE,CAAC,CAAA;YACjD,KAAK,uBAAuB;gBACxB,OAAO,IAAI,mBAAW,CAAC,IAAI,EAAO,SAAS,EAAE,EAAE,GAAG,EAAE,CAAC,CAAA;YACzD;gBACI,MAAM,IAAI,KAAK,CAAC,yBAAyB,IAAI,EAAE,CAAC,CAAC;SACxD;IACL,CAAC;CACJ,CAAC;AACF,MAAM,CAAC,OAAO,CAAC,sBAAsB,CAAC,OAAO,EAAE,KAAK,EAAE,OAAO,CAAC,CAAA"}
|
package/bin/aws/lambda.d.ts
CHANGED
|
@@ -101,7 +101,7 @@ export interface LambdaArgs {
|
|
|
101
101
|
tracing?: pulumi.Input<boolean>;
|
|
102
102
|
transform?: pulumi.Input<inputs.aws.LambdaTransformArgsArgs>;
|
|
103
103
|
/**
|
|
104
|
-
* Enable a direct HTTPS endpoint for the function. Auth mode is AWS_IAM
|
|
104
|
+
* Enable a direct HTTPS endpoint for the function. Auth mode is AWS_IAM - never public. Default: false.
|
|
105
105
|
*/
|
|
106
106
|
url?: pulumi.Input<boolean>;
|
|
107
107
|
/**
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import * as pulumi from "@pulumi/pulumi";
|
|
2
|
+
/**
|
|
3
|
+
* An Anvil-managed JWT authorizer for HTTP API Gateway. Works with any OIDC-compliant identity provider — Auth0, Clerk, Google, Okta, Cognito. API Gateway verifies the JWT signature, issuer, audience, and expiry on every request natively — no Lambda or custom code required. Pass authorizerId to HttpApi defaultAuthorizerId to protect your routes.
|
|
4
|
+
*/
|
|
5
|
+
export declare class OAuthAuthorizer extends pulumi.ComponentResource {
|
|
6
|
+
/**
|
|
7
|
+
* Returns true if the given object is an instance of OAuthAuthorizer. This is designed to work even
|
|
8
|
+
* when multiple copies of the Pulumi SDK have been loaded into the same process.
|
|
9
|
+
*/
|
|
10
|
+
static isInstance(obj: any): obj is OAuthAuthorizer;
|
|
11
|
+
/**
|
|
12
|
+
* The API Gateway authorizer ID. Pass this to HttpApi defaultAuthorizerId to protect your API routes.
|
|
13
|
+
*/
|
|
14
|
+
readonly authorizerId: pulumi.Output<string>;
|
|
15
|
+
/**
|
|
16
|
+
* Create a OAuthAuthorizer resource with the given unique name, arguments, and options.
|
|
17
|
+
*
|
|
18
|
+
* @param name The _unique_ name of the resource.
|
|
19
|
+
* @param args The arguments to use to populate this resource's properties.
|
|
20
|
+
* @param opts A bag of options that control this resource's behavior.
|
|
21
|
+
*/
|
|
22
|
+
constructor(name: string, args: OAuthAuthorizerArgs, opts?: pulumi.ComponentResourceOptions);
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* The set of arguments for constructing a OAuthAuthorizer resource.
|
|
26
|
+
*/
|
|
27
|
+
export interface OAuthAuthorizerArgs {
|
|
28
|
+
/**
|
|
29
|
+
* The intended recipients of the JWT. API Gateway rejects tokens whose 'aud' claim does not match one of these values. Typically your API's client ID registered with the identity provider.
|
|
30
|
+
*/
|
|
31
|
+
audience: pulumi.Input<pulumi.Input<string>[]>;
|
|
32
|
+
/**
|
|
33
|
+
* The OIDC issuer URL of your identity provider. API Gateway fetches public signing keys from {issuer}/.well-known/jwks.json to verify token signatures. Examples: Auth0: 'https://your-tenant.auth0.com/', Clerk: 'https://your-instance.clerk.accounts.dev', Google: 'https://accounts.google.com'.
|
|
34
|
+
*/
|
|
35
|
+
issuer: pulumi.Input<string>;
|
|
36
|
+
}
|