Manual Staff Access Grant (Via Clerk Dashboard)
If the automated script doesn't work, you can grant staff access manually through the Clerk Dashboard.
Steps
1. Go to Clerk Dashboard
Visit: https://dashboard.clerk.com
2. Select Your Application
Choose the homepage.dev application
3. Navigate to Users
Click on "Users" in the left sidebar
4. Find the User
Search for the user by email: tim@do.dev
5. Open User Details
Click on the user to open their details page
6. Edit Private Metadata
- Scroll down to the "Metadata" section
- Click on the "Private metadata" tab
- Click "Edit" or the pencil icon
7. Add Staff Access Flag
Add this JSON to the private metadata:
{
"staffDashboardAccess": true
}If there's already other metadata, just add the staffDashboardAccess field:
{
"existingField": "value",
"staffDashboardAccess": true
}8. Save Changes
Click "Save" to apply the changes
9. Sign Out and Back In
The user needs to:
- Sign out completely from homepage.dev
- Sign back in
- This refreshes the JWT token with the new claim
10. Test Access
Navigate to: http://localhost:3017/staff
You should see the staff dashboard!
Troubleshooting
Still getting 404?
-
Check email domain:
- Email must end with
@do.dev - Check your Clerk account settings
- Email must end with
-
Check JWT template:
- Go to Clerk Dashboard → JWT Templates
- Edit the "convex" template
- Make sure it includes:
{ "staffDashboardAccess": "{{user.private_metadata.staffDashboardAccess}}" }
-
Clear browser cache:
- Hard refresh (Cmd+Shift+R or Ctrl+Shift+R)
- Or open in incognito mode
-
Check dev server:
- Make sure
pnpm devis running - Restart if needed
- Make sure
Verify It Worked
After signing back in, check your JWT token at: https://jwt.io
Decode your token and look for:
{
"staffDashboardAccess": true
}If you see this, you're good to go!