Skip to content

PutPrincipalMapping

Source: src/AWS/Kendra/PutPrincipalMapping.ts

Runtime binding for the PutPrincipalMapping operation (IAM action kendra:PutPrincipalMapping), scoped to one Index.

Maps users to groups (optionally per data source) so queries filtered on the user’s context only return documents that user’s groups may access. Provide the implementation with Effect.provide(AWS.Kendra.PutPrincipalMappingHttp).

const putPrincipalMapping = yield* AWS.Kendra.PutPrincipalMapping(index);
yield* putPrincipalMapping({
GroupId: "engineering",
GroupMembers: {
MemberUsers: [{ UserId: "user@example.com" }],
},
});