requireTenantId
requireTenantId(
source,purpose):string
Defined in: packages/ddd-core/application/tenant-resolver.ts:90
Returns the tenant for a security-sensitive operation, or fails closed; see requireTenant, which it calls.
Parameters
Section titled “Parameters”source
Section titled “source”TenantSource | undefined
purpose
Section titled “purpose”string
Returns
Section titled “Returns”string
Example
Section titled “Example”requireTenantId(ctx, 'users.create idempotency key');// becomesrequireTenant('users.create idempotency key', ctx);