Skip to main content

Setup

1

Get credentials

Go to the Kakao Developers portal and create an application. Under Kakao Login, enable the feature and add your redirect URI:
https://your-app.com/api/kavach/auth/oauth/callback/kakao
2

Configure

lib/kavach.ts
import { createKavach } from 'kavachos';
import { oauth } from 'kavachos/auth';

const kavach = await createKavach({
  database: { provider: 'sqlite', url: 'kavach.db' },
  plugins: [
    oauth({
      providers: [
        {
          id: 'kakao',
          clientId: process.env.KAKAO_CLIENT_ID!,
          clientSecret: process.env.KAKAO_CLIENT_SECRET!,
        },
      ],
    }),
  ],
});
KAKAO_CLIENT_ID=...
KAKAO_CLIENT_SECRET=...

Scopes

Default scopes: profile_nickname, account_email
ScopeWhat it unlocks
profile_nicknameKakao nickname
profile_imageProfile image
account_emailEmail address (requires business verification)
Email access requires business verification in the Kakao Developer Console. Without it, only profile_nickname and profile_image are available.

Endpoints

MethodPathDescription
GET/auth/oauth/authorize/kakaoRedirect to Kakao
GET/auth/oauth/callback/kakaoHandle callback
Last modified on April 17, 2026