@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 46 lines 1.5 KB
Raw
1 import type * as featurestore from "@distilled.cloud/aws/sagemaker-featurestore-runtime";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { FeatureGroup } from "./FeatureGroup.ts";
5
6 export interface DeleteRecordRequest extends Omit<
7 featurestore.DeleteRecordRequest,
8 "FeatureGroupName"
9 > {}
10
11 /**
12 * Runtime binding for `sagemaker:DeleteRecord` — delete a record from a
13 * `FeatureGroup`'s online store.
14 *
15 * Bind this operation to a `FeatureGroup` inside a function runtime to get a
16 * callable that automatically injects the feature group name. The default
17 * `SoftDelete` mode nulls the feature columns; `HardDelete` removes the
18 * record entirely. `EventTime` must be later than the stored record's event
19 * time for the deletion to take effect.
20 * ### Deleting Records
21 * **Example:** Soft-Delete a Record
22 * ```typescript
23 * // init
24 * const deleteRecord = yield* AWS.SageMaker.DeleteRecord(featureGroup);
25 *
26 * // runtime
27 * yield* deleteRecord({
28 * RecordIdentifierValueAsString: "user-123",
29 * EventTime: new Date().toISOString(),
30 * });
31 * ```
32 *
33 * @binding
34 */
35 export interface DeleteRecord extends Binding.Service<
36 DeleteRecord,
37 "AWS.SageMaker.DeleteRecord",
38 <F extends FeatureGroup>(
39 featureGroup: F,
40 ) => Effect.Effect<
41 (
42 request: DeleteRecordRequest,
43 ) => Effect.Effect<featurestore.DeleteRecordResponse, featurestore.DeleteRecordError>
44 >
45 > {}
46 export const DeleteRecord = Binding.Service<DeleteRecord>("AWS.SageMaker.DeleteRecord");