Skip to main content
ConnectFor teamsSign inDashboard
SDK · Developer integration

One line, every framework.

SvelteKit, Astro, SolidStart, Qwik, Nuxt, Next.js, Hono. Framework adapters make sign-in integration a one-liner. Standard sign-in endpoints, webhook events, and AI-agent delegation.

01Quickstart

Live in 3 minutes.

Install the SDK, create the Auth object, wire the routes. Done in 3 steps on one framework.

01

Install SDK

bun add @modfolio/connect-sdk@^7.0.0
02

Configure Auth

import { createSvelteKitAuth } from "@modfolio/connect-sdk/sveltekit";

export const auth = createSvelteKitAuth({ clientId: "my-app" });
export const handle = auth.handle;
03

Wire routes

// src/routes/auth/login/+server.ts
export const GET = auth.loginHandler;

// src/routes/auth/callback/+server.ts
export const GET = auth.callbackHandler;

// src/routes/auth/logout/+server.ts
export const GET = auth.logoutHandler;
02Frameworks

7 adapters, same API.

Adapters tailored to each framework's middleware pattern. All share the same ConnectAuth interface, the same handler pattern.

SvelteKit

auth.ts
import { createSvelteKitAuth } from "@modfolio/connect-sdk/sveltekit";

export const auth = createSvelteKitAuth({ clientId: "my-app" });
export const handle = auth.handle;

Astro

auth.ts
import { createAstroAuth } from "@modfolio/connect-sdk/astro";

export const auth = createAstroAuth({ clientId: "my-app" });
export const onRequest = auth.middleware;

Nuxt

auth.ts
import { createNuxtAuth } from "@modfolio/connect-sdk/nuxt";

export const auth = createNuxtAuth({ clientId: "my-app" });
export default auth.eventHandler;

SolidStart

auth.ts
import { createSolidStartAuth } from "@modfolio/connect-sdk/solidstart";

export const auth = createSolidStartAuth({ clientId: "my-app" });
export const middleware = auth.middleware;

Qwik

auth.ts
import { createQwikAuth } from "@modfolio/connect-sdk/qwik";

export const auth = createQwikAuth({ clientId: "my-app" });
export const onRequest = auth.onRequest;

Next.js

auth.ts
import { createNextAuth } from "@modfolio/connect-sdk/nextjs";

export const auth = createNextAuth({ clientId: "my-app" });
export const middleware = auth.middleware;

Hono

auth.ts
import { createHonoAuth } from "@modfolio/connect-sdk/hono";

export const auth = createHonoAuth({ clientId: "my-app" });
app.use("/*", auth.middleware);
03API

13 endpoints, four groups.

OIDC Core, Discovery, FedCM, SCIM. Each endpoint maps to a published standard (RFC).

OIDC Core

GET/sso/authorizeAuthorization (prompt=none/login/consent)
POST/sso/tokenCode/Refresh/Credentials → JWT
POST/sso/parPushed Authorization Request
POST/sso/verifyJWT signature verification (DPoP supported)
POST/sso/introspectToken introspection
POST/sso/revokeToken revocation

Discovery

GET/.well-known/openid-configurationOIDC Discovery
GET/.well-known/ssf-configurationSSF Transmitter
GET/.well-known/web-identityFedCM Provider

FedCM

GET/fedcm/accountsFedCM accounts list
POST/fedcm/tokenFedCM token issuance

SCIM

GET/scim/v2/UsersUser provisioning
GET/scim/v2/GroupsGroup sync
04Events

Webhook events, eight categories.

Propagate every activity in real time with webhooks and real-time security signals (SSF). Each event has a defined, typed shape, so the SDK handles it directly.

Authentication12
login.success, login.failure, login.social, logout
Token8
token.issued, token.refreshed, token.revoked
User9
user.created, user.updated, user.locked
Organization8
org.created, org.member_added, org.invitation_sent
Security7
security.mfa_enabled, security.risk_detected
Admin6
admin.client_created, admin.policy_updated
SCIM5
scim.user_provisioned, scim.group_updated
System2
system.key_rotated, system.cleanup
05FAQ

Frequently asked questions.

For further questions, use GitHub Issues or sdk@modfolio.io.

Which frameworks do you support?

We provide adapters for SvelteKit, Astro, SolidStart, Qwik, Nuxt, Next.js, and Hono.

Where is authentication data stored?

It is stored in Modfolio's own PostgreSQL database, which Cloudflare Workers reach over an authenticated private tunnel. It is backed up every day.

Can I migrate existing users?

You can sync with an existing directory through automatic employee-account provisioning (SCIM 2.0), or do a bulk import through the Better Auth sign-up API.

Can I start for free?

Yes — the standard sign-in features you use by signing up directly are free. Enterprise compliance, an SLA, and a data processing agreement (DPA) are arranged separately.

Commission

Install now.

bun add @modfolio/connect-sdk — 5 minutes is all it takes.