import {
  jsonOk,
  routeWrap
} from "./chunk-KKJ5D3II.js";

// src/handlers/whoami.ts
function handleWhoami(request) {
  return routeWrap(request, async ({ auth }) => {
    return jsonOk({
      name: auth.name,
      tenant_id: auth.tenantId,
      is_global_admin: auth.isGlobalAdmin,
      permissions: auth.permissions
    });
  });
}

export {
  handleWhoami
};
