How to use where clause in Knex
Create refunds with Stripe
Load HTML with Cheerio
How to send POST request with Axios
Find intersection of array in Lodash
Powered by Official white Bloop logo with a period

Terms / Privacy / Search / Support

  • const rawBucket = new s3.CfnBucket(this, "Bucket", {
      /* ... */
    });
    // -or-
    const rawBucketAlt = myBucket.node
      .defaultChild as s3.CfnBucket;
    
    // then
    rawBucket.cfnOptions.condition = new CfnCondition(
      this,
      "EnableBucket",
      {
        /* ... */
      }
    );
    rawBucket.cfnOptions.metadata = {
      metadataKey: "MetadataValue",
    };
    
    Docs
    0
  • // Extracts the function name out of an AWS Lambda Function ARN
    const arnComponents = stack.parseArn(arn, ":");
    const functionName = arnComponents.resourceName;
    
    Docs
    0
  • // Builds "arn::lambda:::function:MyFunction"
    stack.formatArn({
      service: "lambda",
      resource: "function",
      sep: ":",
      resourceName: "MyFunction",
    });
    
    Docs
    0
  • exports.handler = function (event, context) {
      const sns = AWS.SNS();
      const dynamoDb = AWS.DynamoDB();
      someAsyncFunction(() => {
        // do something with the services e.g. sns.publish
      });
    };
    
    Docs
    0
  • exports.handler = function (event, context) {
      someAsyncFunction(() => {
        const sns = AWS.SNS();
        const dynamoDb = AWS.DynamoDB();
        // do something with the services e.g. sns.publish
      });
    };
    
    Docs
    0
  • const { DynamoDB } = require("@aws-sdk/client-dynamodb");
    const {
      marshall,
      unmarshall,
    } = require("@aws-sdk/util-dynamodb");
    
    const client = new DynamoDB(clientParams);
    const params = {
      TableName: "Table",
      Key: marshall({
        HashKey: "hashKey",
      }),
    };
    
    const { Item } = await client.getItem(params);
    unmarshall(Item);
    
    Docs
    0
  • const { DynamoDB } = require("@aws-sdk/client-dynamodb");
    const { marshall } = require("@aws-sdk/util-dynamodb");
    
    const client = new DynamoDB(clientParams);
    const params = {
      TableName: "Table",
      Item: marshall({
        HashKey: "hashKey",
        NumAttribute: 1,
        BoolAttribute: true,
        ListAttribute: [1, "two", false],
        MapAttribute: { foo: "bar" },
        NullAttribute: null,
      }),
    };
    
    await client.putItem(params);
    
    Docs
    0
  • const { DynamoDB } = require("@aws-sdk/client-dynamodb");
    const { marshall } = require("@aws-sdk/util-dynamodb");
    
    const client = new DynamoDB(clientParams);
    const params = {
      TableName: "Table",
      Item: marshall({
        HashKey: "hashKey",
        NumAttribute: 1,
        BoolAttribute: true,
        ListAttribute: [1, "two", false],
        MapAttribute: { foo: "bar" },
        NullAttribute: null,
      }),
    };
    
    await client.putItem(params);
    
    Docs
    0
  • const { DynamoDB } = require("@aws-sdk/client-dynamodb");
    const {
      marshall,
      unmarshall,
    } = require("@aws-sdk/util-dynamodb");
    
    const client = new DynamoDB(clientParams);
    const params = {
      TableName: "Table",
      Key: marshall({
        HashKey: "hashKey",
      }),
    };
    
    const { Item } = await client.getItem(params);
    unmarshall(Item);
    
    Docs
    0
  • Powered by Official black Bloop logo with a period
    download the IDE extension

    View other examples