Spike — tenant + identity context
Resolved tenant (from middleware headers)
{
"id": "00000000-0000-0000-0000-000000000001",
"slug": "vippharmacy",
"surface": "storefront",
"displayName": "VIP Pharmacy",
"resolvedVia": "subdomain"
}Clerk identity (from auth() + currentUser())
{
"userId": null,
"sessionId": null,
"email": null,
"firstName": null,
"role": "anonymous"
}Next: pipe { tenantId, userId, role } into withTenantContext() from @greggvios/database in a Node-runtime API route to prove RLS narrows queries correctly.