sailfork / t3code-github / .repos/ alchemy-effect/ packages/ aws/ src/ Amplify/ StartDeploymentHttp.ts

import * as amplify from "@distilled.cloud/aws/amplify";
import * as Output from "alchemy/Output";
import * as Layer from "effect/Layer";
import { makeAmplifyHttpBinding } from "./BindingHttp.ts";
import { StartDeployment } from "./StartDeployment.ts";

export const StartDeploymentHttp = Layer.effect(
  StartDeployment,
  makeAmplifyHttpBinding({
    name: "StartDeployment",
    operation: amplify.startDeployment,
    actions: ["amplify:StartDeployment"],
    resources: (app) => [Output.interpolate`${app.appArn}/branches/*`],
  }),
);