Skip to content

UpdateApiKey

Source: src/AWS/ApiGateway/UpdateApiKey.ts

Runtime binding for patching an API Gateway API key (apigateway:PATCH on /apikeys/{id}). Account-scoped — takes no resource.

Provide ApiGateway.UpdateApiKeyHttp on the Function effect to implement the binding.

// init
const updateApiKey = yield* ApiGateway.UpdateApiKey();
// runtime
yield* updateApiKey({
apiKey: keyId,
patchOperations: [{ op: "replace", path: "/enabled", value: "false" }],
});