1import * as neptunegraph from "@distilled.cloud/aws/neptune-graph";
2import * as Layer from "effect/Layer";
3import { makeNeptuneGraphGraphHttpBinding } from "./BindingHttp.ts";
4import { ExecuteQuery } from "./ExecuteQuery.ts";
5
6/**
7 * HTTP implementation of the {@link ExecuteQuery} binding — signs
8 * `neptune-graph:ExecuteQuery` data-plane requests against the graph's HTTPS
9 * endpoint and, at deploy time, grants the query IAM actions
10 * (`ReadDataViaQuery`, `WriteDataViaQuery`, `DeleteDataViaQuery`) on the
11 * bound graph to the host function.
12 */
13export const ExecuteQueryHttp = Layer.effect(
14 ExecuteQuery,
15 makeNeptuneGraphGraphHttpBinding({
16 tag: "AWS.NeptuneGraph.ExecuteQuery",
17 operation: neptunegraph.executeQuery,
18 actions: [
19 "neptune-graph:ReadDataViaQuery",
20 "neptune-graph:WriteDataViaQuery",
21 "neptune-graph:DeleteDataViaQuery",
22 ],
23 }),
24);