@devries-cameron20 / t3code Mirror · read-only
Fork 0

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

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 06:00 UTC

main
ts 43 lines 1.3 KB
Raw
1 import type * as personalizeevents from "@distilled.cloud/aws/personalize-events";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { Dataset } from "./Dataset.ts";
5
6 /**
7 * `PutActions` request with `datasetArn` injected from the bound dataset.
8 */
9 export interface PutActionsRequest extends Omit<
10 personalizeevents.PutActionsRequest,
11 "datasetArn"
12 > {}
13
14 /**
15 * Runtime binding for `personalize:PutActions`, scoped to one {@link Dataset} —
16 * Adds or updates actions incrementally in the bound Actions
17 * {@link Dataset} for the NEXT_BEST_ACTION recipe.
18 * Provide the implementation with
19 * `Effect.provide(AWS.Personalize.PutActionsHttp)`.
20 *
21 * ### Incremental Imports
22 * **Example:** Upsert an Action
23 * ```typescript
24 * // init
25 * const putActions = yield* Personalize.PutActions(actionsDataset);
26 *
27 * yield* putActions({ actions: [{ actionId: "action-1" }] });
28 * ```
29 *
30 * @binding
31 */
32 export interface PutActions extends Binding.Service<
33 PutActions,
34 "AWS.Personalize.PutActions",
35 (
36 dataset: Dataset,
37 ) => Effect.Effect<
38 (
39 request: PutActionsRequest,
40 ) => Effect.Effect<personalizeevents.PutActionsResponse, personalizeevents.PutActionsError>
41 >
42 > {}
43 export const PutActions = Binding.Service<PutActions>("AWS.Personalize.PutActions");