Skip to content

bifravst/cloudformation-helpers

Folders and files

NameName
Last commit message
Last commit date
Nov 8, 2024
Jan 30, 2024
Jul 12, 2024
Aug 12, 2024
Jul 12, 2024
May 6, 2020
Apr 3, 2024
Apr 3, 2024
Jan 6, 2025
Jul 12, 2024
Oct 17, 2023
Feb 19, 2024
Apr 1, 2025
Apr 1, 2025
Apr 22, 2024
Mar 18, 2024

CloudFormation Helpers npm version

GitHub Actions semantic-release Renovate @commitlint/config-conventional code style: prettier ESLint: TypeScript

Helper functions which simplify working with AWS CloudFormation stacks.

Installation

npm i --save-dev --save-exact @bifravst/cloudformation-helpers

Usage

cfnResponse

cfnResponse implements sending custom resource responses.

import { cfnResponse, ResponseStatus } from "@bifravst/cloudformation-helpers";
import { CloudFormationCustomResourceEvent } from "aws-lambda";

/**
 * Lambda creating a custom resource
 */
export const handler = async (
  event: CloudFormationCustomResourceEvent,
): Promise<void> => {
  // Create custom resource ...

  await cfnResponse({
    Status: ResponseStatus.SUCCESS,
    event,
    PhysicalResourceId: "MyCustomResource",
  });
};