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

main
ts 22 lines 586 Bytes
Raw
1 import { GetPlan } from "@distilled.cloud/stripe/stripe";
2 import * as Layer from "effect/Layer";
3 import { RetrievePlan } from "./RetrievePlan.ts";
4 import { makeHttpStripeIdBinding } from "./StripeHttp.ts";
5
6 /**
7 * HTTP implementation of {@link RetrievePlan}. Provide it on the
8 * Function or Worker Effect.
9 *
10 * @layer
11 * @product Product
12 * @provides Stripe.RetrievePlan
13 */
14 export const RetrievePlanHttp = Layer.effect(
15 RetrievePlan,
16 makeHttpStripeIdBinding({
17 tag: "Stripe.RetrievePlan",
18 operation: GetPlan,
19 idField: "plan",
20 permissions: ["plans_read"],
21 }),
22 );