@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, 04:45 UTC

main
ts 44 lines 1.31 KB
Raw
1 import type * as bigqueryconnection from "@distilled.cloud/gcp/bigqueryconnection_v1";
2 import * as Binding from "alchemy/Binding";
3 import type { RuntimeContext } from "alchemy/RuntimeContext";
4 import type * as Effect from "effect/Effect";
5 import type { Connection } from "./Connection.ts";
6
7 export interface GetConnectionRequest extends Omit<
8 bigqueryconnection.GetProjectsLocationsConnectionsRequest,
9 "name"
10 > {}
11
12 /**
13 * Runtime binding for BigQuery Connection `connections.get`.
14 *
15 * Bind this operation to a {@link Connection} in a Function/Action init
16 * phase. Provide {@link GetConnectionHttp}.
17 *
18 * ### Reading a Connection
19 * **Example:** Get the bound connection
20 * ```typescript
21 * const getConnection = yield* GCP.BigQueryConnection.GetConnection(gcs);
22 * const live = yield* getConnection();
23 * ```
24 *
25 * @binding
26 * @category BigQueryConnection
27 */
28 export interface GetConnection extends Binding.Service<
29 GetConnection,
30 "GCP.BigQueryConnection.GetConnection",
31 (
32 connection: Connection,
33 ) => Effect.Effect<
34 (
35 request?: GetConnectionRequest,
36 ) => Effect.Effect<
37 bigqueryconnection.Connection,
38 bigqueryconnection.GetProjectsLocationsConnectionsError,
39 RuntimeContext
40 >
41 >
42 > {}
43
44 export const GetConnection = Binding.Service<GetConnection>("GCP.BigQueryConnection.GetConnection");