Skip to content

CheckDocumentAccess

Source: src/AWS/QBusiness/CheckDocumentAccess.ts

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

Checks whether a specific user can access a document, returning the user’s groups/aliases and the document’s ACL evaluation. Provide the implementation with Effect.provide(AWS.QBusiness.CheckDocumentAccessHttp).

const checkAccess = yield* AWS.QBusiness.CheckDocumentAccess(index);
const { hasAccess } = yield* checkAccess({
userId: "user@example.com",
documentId: "welcome",
});