| 1 | import * as kendra from "@distilled.cloud/aws/kendra"; |
| 2 | import * as Layer from "effect/Layer"; |
| 3 | import { toWireDays } from "../../Util/Duration.ts"; |
| 4 | import type { UpdateQuerySuggestionsConfigRequest } from "./UpdateQuerySuggestionsConfig.ts"; |
| 5 | import { makeKendraIndexHttpBinding } from "./BindingHttp.ts"; |
| 6 | import { UpdateQuerySuggestionsConfig } from "./UpdateQuerySuggestionsConfig.ts"; |
| 7 | |
| 8 | export const UpdateQuerySuggestionsConfigHttp = Layer.effect( |
| 9 | UpdateQuerySuggestionsConfig, |
| 10 | makeKendraIndexHttpBinding({ |
| 11 | tag: "AWS.Kendra.UpdateQuerySuggestionsConfig", |
| 12 | operation: kendra.updateQuerySuggestionsConfig, |
| 13 | actions: ["kendra:UpdateQuerySuggestionsConfig"], |
| 14 | prepare: ({ |
| 15 | queryLogLookBackWindow, |
| 16 | ...rest |
| 17 | }: UpdateQuerySuggestionsConfigRequest = {}) => ({ |
| 18 | ...rest, |
| 19 | QueryLogLookBackWindowInDays: toWireDays(queryLogLookBackWindow), |
| 20 | }), |
| 21 | }), |
| 22 | ); |