insforge-integrations

Use this skill when integrating a third-party auth provider (Clerk, Auth0, WorkOS, Kinde, Stytch) with InsForge for authentication and RLS. Covers JWT configuration, client setup, database RLS policies, and provider-specific gotchas for each supported integration.

Safety Notice

This listing is imported from skills.sh public index metadata. Review upstream SKILL.md and repository scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "insforge-integrations" with this command: npx skills add insforge/agent-skills/insforge-agent-skills-insforge-integrations

InsForge Integrations

This skill covers integrating third-party authentication providers with InsForge. Each provider has its own guide under this directory.

Supported Providers

ProviderGuideWhen to use
ClerkClerk JWT Templates + InsForge RLSClerk signs tokens directly via JWT Template — no server-side signing needed
Auth0Auth0 Actions + InsForge RLSAuth0 uses a post-login Action to embed claims into the access token
WorkOSWorkOS AuthKit + InsForge RLSWorkOS AuthKit middleware + server-side JWT signing with jsonwebtoken
KindeKinde + InsForge RLSKinde token customization for InsForge integration
StytchStytch + InsForge RLSStytch session tokens for InsForge integration

Common Pattern

All integrations follow the same core pattern:

  1. Auth provider signs or issues a JWT containing the user's ID
  2. JWT is passed to InsForge via edgeFunctionToken in createClient()
  3. InsForge extracts claims via request.jwt.claims in SQL
  4. RLS policies use a requesting_user_id() function to enforce row-level security

Choosing a Provider

  • Clerk — Simplest setup; JWT Template handles signing, no server code needed
  • Auth0 — Flexible; uses post-login Actions for claim injection
  • WorkOS — Enterprise-focused; AuthKit middleware + server-side JWT signing
  • Kinde — Developer-friendly; built-in token customization
  • Stytch — API-first; session-based token flow

Setup

  1. Identify which auth provider the project uses
  2. Read the corresponding reference guide from the table above
  3. Follow the provider-specific setup steps

Usage Examples

Each provider guide includes full code examples for:

  • Auth provider dashboard configuration
  • InsForge client utility with edgeFunctionToken
  • requesting_user_id() SQL function and RLS policies
  • Environment variable setup

Refer to the specific references/<provider>.md file for complete examples.

Best Practices

  • All provider user IDs are strings (not UUIDs) — always use TEXT columns for user_id
  • Use requesting_user_id() instead of auth.uid() for RLS policies
  • Set edgeFunctionToken as an async function (Clerk) or server-signed JWT (Auth0, WorkOS, Kinde, Stytch)
  • Always get the JWT secret via npx @insforge/cli secrets get JWT_SECRET

Common Mistakes

MistakeSolution
Using auth.uid() for RLSUse requesting_user_id() — third-party IDs are strings, not UUIDs
Using UUID columns for user_idUse TEXT — all supported providers use string-format IDs
Hardcoding the JWT secretAlways retrieve via npx @insforge/cli secrets get JWT_SECRET
Missing requesting_user_id() functionMust be created before RLS policies will work

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

Coding

insforge-cli

No summary provided by upstream source.

Repository SourceNeeds Review
Automation

insforge

No summary provided by upstream source.

Repository SourceNeeds Review
Automation

insforge-debug

No summary provided by upstream source.

Repository SourceNeeds Review
Coding

vercel-react-best-practices

React and Next.js performance optimization guidelines from Vercel Engineering. This skill should be used when writing, reviewing, or refactoring React/Next.js code to ensure optimal performance patterns. Triggers on tasks involving React components, Next.js pages, data fetching, bundle optimization, or performance improvements.

Repository Source
311.5K25Kvercel