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

main
ts 33 lines 1.17 KB
Raw
1 import type * as SVC from "@distilled.cloud/aws/finspace";
2 import * as Binding from "alchemy/Binding";
3 import type * as Effect from "effect/Effect";
4 import type { KxEnvironment } from "./KxEnvironment.ts";
5
6 /**
7 * Runtime binding for `finspace:GetKxDatabase` — reads one kdb database of the bound environment — including `lastCompletedChangesetId`, the anchor ingestion pipelines use to advance dataviews.
8 * Provide the implementation with
9 * `Effect.provide(AWS.FinSpace.GetKxDatabaseHttp)`.
10 * ### Reading Databases
11 * **Example:** Read the Latest Changeset Id
12 * ```typescript
13 * const getDatabase = yield* AWS.FinSpace.GetKxDatabase(kdb);
14 *
15 * const { lastCompletedChangesetId } = yield* getDatabase({
16 * databaseName: "ticks",
17 * });
18 * ```
19 *
20 * @binding
21 */
22 export interface GetKxDatabase extends Binding.Service<
23 GetKxDatabase,
24 "AWS.FinSpace.GetKxDatabase",
25 <K extends KxEnvironment>(
26 environment: K,
27 ) => Effect.Effect<
28 (
29 request: Omit<SVC.GetKxDatabaseRequest, "environmentId">,
30 ) => Effect.Effect<SVC.GetKxDatabaseResponse, SVC.GetKxDatabaseError>
31 >
32 > {}
33 export const GetKxDatabase = Binding.Service<GetKxDatabase>("AWS.FinSpace.GetKxDatabase");