AuthServer
OIDC Social Login
Configure Google, Microsoft, Apple, GitHub, and custom social providers.
SqlOS supports social login via OpenID Connect providers and GitHub OAuth. Users click a provider button, authenticate with the provider, and are linked or created in SqlOS.
| Provider | Key | Notes |
|---|---|---|
google | Standard OAuth 2.0 | |
| Microsoft | microsoft | Entra ID (Azure AD) |
| Apple | apple | Web only, requires Apple Developer account |
| GitHub | github | OAuth profile/email lookup through GitHub's user APIs |
| Custom | any | Any OIDC-compliant provider via discovery or manual config |
Dashboard: Auth Server > OIDC > Create Connection
Admin API:
curl -X POST http://localhost:5062/sqlos/admin/auth/api/oidc-connections \
-H "Content-Type: application/json" \
-d '{
"providerType": "google",
"displayName": "Google",
"clientId": "your-google-client-id",
"clientSecret": "your-google-client-secret"
}'SqlOS owns the provider callback URI:
http://localhost:5062/sqlos/auth/oidc/callbackAdd the exact dashboard-provided URI to your provider's allowed redirect URIs.
If you build a custom headless callback with SqlOSOidcAuthService, register your app-owned callback route instead. The example API uses /api/v1/auth/oidc/callback/{connectionId} so the callback can complete the handoff before returning to the frontend.
curl -X POST http://localhost:5062/sqlos/admin/auth/api/oidc-connections/{id}/enableFrontend Backend Provider
│ │ │
├─ GET /oidc/providers ───►│ │
│◄── provider list ────────│ │
│ │ │
├─ POST /oidc/start ──────►│ │
│◄── authorizationUrl ─────│ │
│ │ │
├──── redirect to provider ────────────────────────────►│
│◄── callback with code ────────────────────────────────│
│ │ │
│ GET /oidc/callback ──►│── exchange code ──────────►│
│ │◄── user info ──────────────│
│◄── redirect with handoff │ │
│ │ │
├─ POST /oidc/complete ───►│ │
│◄── tokens ───────────────│ │// Start OIDC flow
app.MapPost("/api/v1/auth/oidc/start", async (
OidcStartRequest request,
SqlOSOidcAuthService oidcService,
SqlOSHomeRealmDiscoveryService discoveryService) =>
{
var discovery = await discoveryService.DiscoverAsync(
new SqlOSHomeRealmDiscoveryRequest(request.Email), ct);
if (discovery.Mode == "sso")
return Results.Ok(new { mode = "sso", discovery.SsoConnectionId });
var result = await oidcService.StartAuthorizationAsync(
new SqlOSStartOidcAuthorizationRequest
{
ConnectionId = request.ConnectionId,
RedirectUri = $"{origin}/api/v1/auth/oidc/callback/{request.ConnectionId}",
State = state
}, ipAddress, ct);
return Results.Ok(new { authorizationUrl = result.AuthorizationUrl });
});const { providers } = await apiGet("/api/v1/auth/oidc/providers");
// User clicks a provider
const { authorizationUrl } = await apiPost("/api/v1/auth/oidc/start", {
email,
connectionId: provider.connectionId,
});
window.location.href = authorizationUrl;http://localhost:5062/sqlos/auth/oidc/callbackproviderType: "google", your client ID and secretproviderType: "microsoft", your client ID and secretproviderType: "apple", your service ID and keyproviderType: "github", your GitHub client ID and secretread:user and user:emailSee GitHub OIDC for dashboard, API, and code-first setup.
For any OIDC-compliant provider, use discovery-based or manual configuration:
# Discovery-based (auto-fetches endpoints from .well-known)
curl -X POST http://localhost:5062/sqlos/admin/auth/api/oidc-connections \
-d '{
"providerType": "custom",
"displayName": "Okta",
"clientId": "...",
"clientSecret": "...",
"discoveryUrl": "https://your-org.okta.com/.well-known/openid-configuration"
}'