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

main
ts 38 lines 1.07 KB
Raw
1 import type {
2 Account as StripeAccount,
3 GetAccountByAccountError,
4 GetAccountByAccountRequest,
5 } from "@distilled.cloud/stripe/stripe";
6 import * as Binding from "alchemy/Binding";
7 import type { RuntimeContext } from "alchemy/RuntimeContext";
8 import type * as Effect from "effect/Effect";
9 import type { Account } from "./Account.ts";
10
11 export interface RetrieveAccountRequest extends Omit<GetAccountByAccountRequest, "account"> {}
12
13 /**
14 * Retrieve a bound Stripe Connect Account over HTTP.
15 *
16 * ### Reading an Account
17 * **Example:** Bind and retrieve
18 * ```typescript
19 * const retrieve = yield* Stripe.RetrieveAccount(merchant);
20 * const live = yield* retrieve();
21 * ```
22 *
23 * @binding
24 * @product Account
25 */
26 export interface RetrieveAccount extends Binding.Service<
27 RetrieveAccount,
28 "Stripe.RetrieveAccount",
29 (
30 account: Account,
31 ) => Effect.Effect<
32 (
33 request?: RetrieveAccountRequest,
34 ) => Effect.Effect<StripeAccount, GetAccountByAccountError, RuntimeContext>
35 >
36 > {}
37
38 export const RetrieveAccount = Binding.Service<RetrieveAccount>("Stripe.RetrieveAccount");