Single-page application (SPA) for SSI127 self-sovereign identity management. Built with vanilla JavaScript, styled with the 127crew dark theme.
This frontend provides a complete accounts/dashboard interface for managing DIDs (Decentralized Identifiers) and OAuth clients through the SSI127 backend API.
- DID-Based Authentication — Challenge/response signing flow
- Dashboard — User overview and quick actions
- DID Management — View and manage decentralized identifiers
- OAuth Client Registration — Register applications and retrieve credentials
- Profile Management — Account settings and API token access
- Responsive Design — Dark theme, mobile-friendly
- No Dependencies — Vanilla JS, no npm/build step required
-
Login (
/login)- DID input field
- Challenge-response authentication flow
- Demo DID button for testing
-
Dashboard (
/dashboard)- User welcome and quick stats
- Links to management pages
- Account overview
-
DIDs (
/dids)- View current DID
- Copy DID to clipboard
- Future: Create/import DIDs
-
Clients (
/clients)- Register OAuth applications
- Enter app name and redirect URIs
- Receive client ID and secret
-
Profile (
/profile)- Account information
- Session management
- View/copy JWT token for API access
- Router: Simple client-side SPA router (
js/lib/router.js) - Storage: LocalStorage wrapper for auth tokens and user data (
js/lib/storage.js) - API Client: Fetch-based API wrapper for SSI127 backend (
js/api.js) - Pages: Modular page components (
js/pages/*.js)
The app communicates with these SSI127 backend endpoints:
POST /auth/challenge— Get challenge noncePOST /auth/verify— Verify signature and get JWTGET /auth/jwks— Get JWT public keysPOST /clients/register— Register OAuth clientPOST /oauth/authorize— OAuth authorizationPOST /oauth/token— Exchange code for token
cd /mnt/Projects/127crew/SSI127-UI
python3 -m http.server 8000Visit http://localhost:8000
Note: If running locally, update the API base URL in js/api.js to point to your local SSI127 backend (default: http://localhost:8080)
-
Push to GitHub:
git add . git commit -m "Add SSI127 accounts UI" git push origin main
-
Enable GitHub Pages:
- Go to repo Settings → Pages
- Set source to
mainbranch // (root) - GitHub will auto-read the
CNAMEfile
-
DNS Setup:
- Add a CNAME record in your domain registrar:
- Name:
accounts - Target:
<your-github-username>.github.io
- Name:
- Wait 5-10 minutes for DNS propagation
- Add a CNAME record in your domain registrar:
-
Verify:
- Visit https://accounts.127crew.dev
- Should see the login page
Update the API base URL in js/api.js:
const API_CLIENT = new API(
window.location.hostname === 'localhost'
? 'http://localhost:8080'
: 'https://ssi.127crew.dev'
);Ensure your SSI127 backend has CORS enabled for accounts.127crew.dev domain.
- User enters their DID
- Frontend requests challenge nonce from
/auth/challenge - Frontend displays "awaiting signature" (mock signature in demo)
- Frontend sends signature to
/auth/verify - Backend returns JWT token
- Token stored in localStorage, user redirected to dashboard
SSI127-UI/
├── index.html # SPA entry point
├── css/
│ ├── style.css # Base/utility styles from 127crew.dev
│ └── auth.css # Auth and dashboard specific styles
├── js/
│ ├── app.js # Router setup and app bootstrap
│ ├── api.js # API client wrapper
│ ├── lib/
│ │ ├── router.js # Simple SPA router
│ │ └── storage.js # Auth token/user storage
│ └── pages/
│ ├── login.js # Login page component
│ ├── dashboard.js # Dashboard page
│ ├── dids.js # DIDs management page
│ ├── clients.js # OAuth clients page
│ └── profile.js # Profile/settings page
├── CNAME # GitHub Pages custom domain
└── README.md
- This is a static frontend with no build step required
- All authentication happens via the backend API
- JWT tokens are stored in localStorage (suitable for SPAs)
- For production, add HTTPS enforcement and consider secure cookie storage
- The demo uses a mock signature for testing; real implementations should use cryptographic signing
For issues or questions:
- Check SSI127 backend logs
- Ensure CORS is configured on backend
- Verify backend is running and accessible