sailfork / t3code-github / .repos/ alchemy-effect/ packages/ aws/ src/ DataExchange/ DeleteAsset.ts

import type * as dataexchange from "@distilled.cloud/aws/dataexchange";
import * as Binding from "alchemy/Binding";
import type * as Effect from "effect/Effect";
import type { Revision } from "./Revision.ts";

/**
 * Runtime binding for `dataexchange:DeleteAsset`.
 *
 * Deletes an asset from the bound (not-yet-finalized) revision. The
 * data set and revision ids are injected from the binding.
 * Provide the implementation with
 * `Effect.provide(AWS.DataExchange.DeleteAssetHttp)`.
 * ### Managing Assets
 * **Example:** Remove A Bad Import
 * ```typescript
 * const deleteAsset = yield* AWS.DataExchange.DeleteAsset(revision);
 *
 * // runtime
 * yield* deleteAsset({ AssetId: assetId });
 * ```
 *
 * @binding
 */
export interface DeleteAsset extends Binding.Service<
  DeleteAsset,
  "AWS.DataExchange.DeleteAsset",
  (
    revision: Revision,
  ) => Effect.Effect<
    (
      request: Omit<dataexchange.DeleteAssetRequest, "DataSetId" | "RevisionId">,
    ) => Effect.Effect<dataexchange.DeleteAssetResponse, dataexchange.DeleteAssetError>
  >
> {}
export const DeleteAsset = Binding.Service<DeleteAsset>("AWS.DataExchange.DeleteAsset");