| 1 | import * as GCP from "@/GCP"; |
| 2 | import * as Effect from "effect/Effect"; |
| 3 | import * as HttpServerResponse from "effect/http/HttpServerResponse"; |
| 4 | |
| 5 | /** |
| 6 | * Minimal Effect-native Cloud Function the Cloud Functions bindings are |
| 7 | * granted on. Declared by {@link ./bindings-host.ts}. |
| 8 | */ |
| 9 | export default class TargetFunction extends GCP.CloudFunctions.Function<TargetFunction>()( |
| 10 | "TargetFunction", |
| 11 | { main: import.meta.url, location: "us-central1" }, |
| 12 | Effect.succeed({ fetch: Effect.succeed(HttpServerResponse.text("ok")) }), |
| 13 | ) {} |