The best way to control Claude Code, Codex and more from any computer or phone

main
ts 41 lines 1.33 KB
Raw
1 import type * as datazone from "@distilled.cloud/aws/datazone";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { Domain } from "./Domain.ts";
5
6 export interface CreateAssetRequest extends Omit<datazone.CreateAssetInput, "domainIdentifier"> {}
7
8 /**
9 * Runtime binding for `datazone:CreateAsset`.
10 *
11 * Creates an asset in the bound domain's inventory, e.g. to register data produced by the function itself. The domain id is injected from the binding.
12 * Provide the implementation with
13 * `Effect.provide(AWS.DataZone.CreateAssetHttp)`.
14 * ### Publishing Assets
15 * **Example:** Register an Asset
16 * ```typescript
17 * // init — bind the operation to the domain
18 * const createAsset = yield* AWS.DataZone.CreateAsset(domain);
19 *
20 * // runtime
21 * const asset = yield* createAsset({
22 * name: "daily-orders",
23 * typeIdentifier: "amazon.datazone.S3ObjectCollectionAssetType",
24 * owningProjectIdentifier: projectId,
25 * });
26 * ```
27 *
28 * @binding
29 */
30 export interface CreateAsset extends Binding.Service<
31 CreateAsset,
32 "AWS.DataZone.CreateAsset",
33 (
34 domain: Domain,
35 ) => Effect.Effect<
36 (
37 request: CreateAssetRequest,
38 ) => Effect.Effect<datazone.CreateAssetOutput, datazone.CreateAssetError>
39 >
40 > {}
41 export const CreateAsset = Binding.Service<CreateAsset>("AWS.DataZone.CreateAsset");