diff --git a/.changeset/blue-hands-sing.md b/.changeset/blue-hands-sing.md
new file mode 100644
index 0000000000..a915680556
--- /dev/null
+++ b/.changeset/blue-hands-sing.md
@@ -0,0 +1,5 @@
+---
+"create-onchain": patch
+---
+
+Update @farcaster/frame-sdk dependency
diff --git a/.changeset/green-socks-call.md b/.changeset/green-socks-call.md
new file mode 100644
index 0000000000..a89078e3af
--- /dev/null
+++ b/.changeset/green-socks-call.md
@@ -0,0 +1,5 @@
+---
+"@coinbase/onchainkit": patch
+---
+
+Update @farcaster/frame-sdk dependency
diff --git a/examples/minikit-example/.env.example b/examples/minikit-example/.env.example
index 2975825dc5..2417b667d8 100644
--- a/examples/minikit-example/.env.example
+++ b/examples/minikit-example/.env.example
@@ -3,7 +3,7 @@
NEXT_PUBLIC_ONCHAINKIT_PROJECT_NAME=minikit-example
NEXT_PUBLIC_URL=
NEXT_PUBLIC_ICON_URL=$NEXT_PUBLIC_URL/logo.png
-NEXT_PUBLIC_ONCHAINKIT_API_KEY=""
+NEXT_PUBLIC_ONCHAINKIT_API_KEY=
# Frame metadata
@@ -23,6 +23,10 @@ NEXT_PUBLIC_APP_OG_TITLE=minikit-example
NEXT_PUBLIC_APP_OG_DESCRIPTION=
NEXT_PUBLIC_APP_OG_IMAGE=$NEXT_PUBLIC_URL/hero.png
+# Neynar
+
+NEYNAR_API_KEY=
+
# Redis config
REDIS_URL=
diff --git a/examples/minikit-example/app/api/me/route.ts b/examples/minikit-example/app/api/me/route.ts
new file mode 100644
index 0000000000..ccdadcaf07
--- /dev/null
+++ b/examples/minikit-example/app/api/me/route.ts
@@ -0,0 +1,73 @@
+import { Errors, createClient } from "@farcaster/quick-auth";
+import { NextRequest, NextResponse } from "next/server";
+
+const client = createClient();
+
+function getUrlHost() {
+ let urlValue: string;
+
+ if (process.env.VERCEL_ENV === "production") {
+ urlValue = process.env.NEXT_PUBLIC_URL!;
+ } else if (process.env.VERCEL_URL) {
+ urlValue = `https://${process.env.VERCEL_URL}`;
+ } else {
+ urlValue = "http://localhost:3000";
+ }
+
+ const url = new URL(urlValue);
+
+ return url.host;
+}
+
+export async function GET(request: NextRequest) {
+ // Because we're fetching this endpoint via `sdk.quickAuth.fetch`,
+ // if we're in a mini app, the request will include the necessary `Authorization` header.
+ const authorization = request.headers.get("Authorization");
+
+ // Here we ensure that we have a valid token.
+ if (!authorization || !authorization.startsWith("Bearer ")) {
+ return NextResponse.json({ message: "Missing token" }, { status: 401 });
+ }
+
+ try {
+ // Now we verify the token. `domain` must match the domain of the request.
+ // In our case, we're using the `getUrlHost` function to get the domain of the request
+ // based on the Vercel environment. This will vary depending on your hosting provider.
+ const payload = await client.verifyJwt({
+ token: authorization.split(" ")[1] as string,
+ domain: getUrlHost(),
+ });
+
+ // If the token was valid, `payload.sub` will be the user's Farcaster ID.
+ const userFid = payload.sub;
+
+ // And now we can use that FID to do whatever we want.
+ // In this example, we're going to get the user's info from Neynar and return it.
+ const userInfoResult = await fetch(
+ `https://api.neynar.com/v2/farcaster/user/bulk?fids=${userFid}`,
+ {
+ headers: {
+ "x-api-key": process.env.NEYNAR_API_KEY || "",
+ },
+ },
+ ).then((res) => res.json());
+
+ const userInfo = userInfoResult?.users?.[0];
+
+ if (!userInfo) {
+ return NextResponse.json({ message: "User not found" }, { status: 404 });
+ }
+
+ return NextResponse.json(userInfo);
+ } catch (e) {
+ if (e instanceof Errors.InvalidTokenError) {
+ return NextResponse.json({ message: "Invalid token" }, { status: 401 });
+ }
+
+ if (e instanceof Error) {
+ return NextResponse.json({ message: e.message }, { status: 500 });
+ }
+
+ throw e;
+ }
+}
diff --git a/examples/minikit-example/app/components/UserInfo.tsx b/examples/minikit-example/app/components/UserInfo.tsx
new file mode 100644
index 0000000000..d2430a6d9d
--- /dev/null
+++ b/examples/minikit-example/app/components/UserInfo.tsx
@@ -0,0 +1,105 @@
+import { useIsInMiniApp } from "@coinbase/onchainkit/minikit";
+import sdk from "@farcaster/frame-sdk";
+import { useQuery } from "@tanstack/react-query";
+
+function useUserInfo() {
+ const { isInMiniApp } = useIsInMiniApp();
+
+ return useQuery({
+ queryKey: ["useQuickAuth", isInMiniApp],
+ queryFn: async () => {
+ // If we're in a mini app context, all we have to do to make an authenticated
+ // request is to use `sdk.quickAuth.fetch`. This will automatically include the
+ // necessary `Authorization` header for the backend to verify.
+ const result = await sdk.quickAuth.fetch("/api/me");
+
+ const userInfo = await result.json();
+ return {
+ displayName: userInfo.display_name,
+ pfpUrl: userInfo.pfp_url,
+ bio: userInfo.profile?.bio?.text,
+ followerCount: userInfo.follower_count,
+ followingCount: userInfo.following_count,
+ };
+ },
+ enabled: isInMiniApp,
+ });
+}
+
+export function UserInfo() {
+ const { data, isLoading, error } = useUserInfo();
+
+ if (isLoading) {
+ return (
+
+ );
+ }
+
+ if (error || !data) {
+ return (
+
+
+ {error ? "Failed to load user info" : "No user info available"}
+
+
+ );
+ }
+
+ return (
+
+
+ {/* Profile Picture */}
+ {data.pfpUrl && (
+

+ )}
+
+ {/* User Info */}
+
+ {/* Display Name */}
+
+ {data.displayName}
+
+
+ {/* Bio */}
+ {data.bio && (
+
+ {data.bio}
+
+ )}
+
+ {/* Follower Stats */}
+
+
+
+ {data.followerCount?.toLocaleString() || "0"}
+
+
+ Followers
+
+
+
+
+ {data.followingCount?.toLocaleString() || "0"}
+
+
+ Following
+
+
+
+
+
+
+ );
+}
diff --git a/examples/minikit-example/app/page.tsx b/examples/minikit-example/app/page.tsx
index b4a528d320..a927736e76 100644
--- a/examples/minikit-example/app/page.tsx
+++ b/examples/minikit-example/app/page.tsx
@@ -20,6 +20,7 @@ import { AddFrame } from "./actions/AddFrame";
import { ComposeCast } from "./actions/ComposeCast";
import { ViewCast } from "./actions/ViewCast";
import { CloseFrame } from "./actions/CloseFrame";
+import { UserInfo } from "./components/UserInfo";
export default function App() {
const { setFrameReady, isFrameReady } = useMiniKit();
@@ -68,6 +69,7 @@ export default function App() {
+
diff --git a/examples/minikit-example/lib/notification-client.ts b/examples/minikit-example/lib/notification-client.ts
index faef584449..6226bcb823 100644
--- a/examples/minikit-example/lib/notification-client.ts
+++ b/examples/minikit-example/lib/notification-client.ts
@@ -1,5 +1,5 @@
import {
- FrameNotificationDetails,
+ MiniAppNotificationDetails,
type SendNotificationRequest,
sendNotificationResponseSchema,
} from "@farcaster/frame-sdk";
@@ -25,7 +25,7 @@ export async function sendFrameNotification({
fid: number;
title: string;
body: string;
- notificationDetails?: FrameNotificationDetails | null;
+ notificationDetails?: MiniAppNotificationDetails | null;
}): Promise
{
if (!notificationDetails) {
notificationDetails = await getUserNotificationDetails(fid);
@@ -37,7 +37,7 @@ export async function sendFrameNotification({
// Define a strict allowlist of full hostnames
const allowedHostnames = ["api.coinbase.com"];
const url = new URL(notificationDetails.url);
-
+
// Validate the URL scheme and hostname
if (url.protocol !== "https:" || !allowedHostnames.includes(url.hostname)) {
return { state: "error", error: "Invalid or unsafe notification URL" };
diff --git a/examples/minikit-example/lib/notification.ts b/examples/minikit-example/lib/notification.ts
index 569690c12d..29ad8723e9 100644
--- a/examples/minikit-example/lib/notification.ts
+++ b/examples/minikit-example/lib/notification.ts
@@ -1,4 +1,4 @@
-import type { FrameNotificationDetails } from "@farcaster/frame-sdk";
+import type { MiniAppNotificationDetails } from "@farcaster/frame-sdk";
import { redis } from "./redis";
const notificationServiceKey =
@@ -10,19 +10,19 @@ function getUserNotificationDetailsKey(fid: number): string {
export async function getUserNotificationDetails(
fid: number,
-): Promise {
+): Promise {
if (!redis) {
return null;
}
- return await redis.get(
+ return await redis.get(
getUserNotificationDetailsKey(fid),
);
}
export async function setUserNotificationDetails(
fid: number,
- notificationDetails: FrameNotificationDetails,
+ notificationDetails: MiniAppNotificationDetails,
): Promise {
if (!redis) {
return;
diff --git a/examples/minikit-example/package.json b/examples/minikit-example/package.json
index 256cf11e45..de429fbc21 100644
--- a/examples/minikit-example/package.json
+++ b/examples/minikit-example/package.json
@@ -11,16 +11,17 @@
},
"dependencies": {
"@coinbase/onchainkit": "workspace:*",
- "@farcaster/frame-sdk": "^0.0.60",
+ "@farcaster/frame-sdk": "^0.1.7",
+ "@tanstack/react-query": "^5",
"@upstash/redis": "^1.34.4",
"next": "^15.3.3",
"react": "^18",
"react-dom": "^18",
- "@tanstack/react-query": "^5",
"viem": "^2.27.2",
"wagmi": "^2.14.11"
},
"devDependencies": {
+ "@farcaster/quick-auth": "^0.0.7",
"@types/node": "^22",
"@types/react": "^18",
"@types/react-dom": "^18",
diff --git a/packages/create-onchain/templates/minikit-basic/lib/notification-client.ts b/packages/create-onchain/templates/minikit-basic/lib/notification-client.ts
index 74071566e8..23d5276228 100644
--- a/packages/create-onchain/templates/minikit-basic/lib/notification-client.ts
+++ b/packages/create-onchain/templates/minikit-basic/lib/notification-client.ts
@@ -1,5 +1,5 @@
import {
- FrameNotificationDetails,
+ MiniAppNotificationDetails,
type SendNotificationRequest,
sendNotificationResponseSchema,
} from "@farcaster/frame-sdk";
@@ -25,7 +25,7 @@ export async function sendFrameNotification({
fid: number;
title: string;
body: string;
- notificationDetails?: FrameNotificationDetails | null;
+ notificationDetails?: MiniAppNotificationDetails | null;
}): Promise {
if (!notificationDetails) {
notificationDetails = await getUserNotificationDetails(fid);
diff --git a/packages/create-onchain/templates/minikit-basic/lib/notification.ts b/packages/create-onchain/templates/minikit-basic/lib/notification.ts
index 569690c12d..29ad8723e9 100644
--- a/packages/create-onchain/templates/minikit-basic/lib/notification.ts
+++ b/packages/create-onchain/templates/minikit-basic/lib/notification.ts
@@ -1,4 +1,4 @@
-import type { FrameNotificationDetails } from "@farcaster/frame-sdk";
+import type { MiniAppNotificationDetails } from "@farcaster/frame-sdk";
import { redis } from "./redis";
const notificationServiceKey =
@@ -10,19 +10,19 @@ function getUserNotificationDetailsKey(fid: number): string {
export async function getUserNotificationDetails(
fid: number,
-): Promise {
+): Promise {
if (!redis) {
return null;
}
- return await redis.get(
+ return await redis.get(
getUserNotificationDetailsKey(fid),
);
}
export async function setUserNotificationDetails(
fid: number,
- notificationDetails: FrameNotificationDetails,
+ notificationDetails: MiniAppNotificationDetails,
): Promise {
if (!redis) {
return;
diff --git a/packages/create-onchain/templates/minikit-basic/package.json b/packages/create-onchain/templates/minikit-basic/package.json
index e95e544abf..7585e9ab88 100644
--- a/packages/create-onchain/templates/minikit-basic/package.json
+++ b/packages/create-onchain/templates/minikit-basic/package.json
@@ -10,7 +10,7 @@
},
"dependencies": {
"@coinbase/onchainkit": "latest",
- "@farcaster/frame-sdk": "^0.0.60",
+ "@farcaster/frame-sdk": "^0.1.7",
"@upstash/redis": "^1.34.4",
"next": "^15.3.3",
"react": "^18",
diff --git a/packages/create-onchain/templates/minikit-snake/lib/notification-client.ts b/packages/create-onchain/templates/minikit-snake/lib/notification-client.ts
index 74071566e8..23d5276228 100644
--- a/packages/create-onchain/templates/minikit-snake/lib/notification-client.ts
+++ b/packages/create-onchain/templates/minikit-snake/lib/notification-client.ts
@@ -1,5 +1,5 @@
import {
- FrameNotificationDetails,
+ MiniAppNotificationDetails,
type SendNotificationRequest,
sendNotificationResponseSchema,
} from "@farcaster/frame-sdk";
@@ -25,7 +25,7 @@ export async function sendFrameNotification({
fid: number;
title: string;
body: string;
- notificationDetails?: FrameNotificationDetails | null;
+ notificationDetails?: MiniAppNotificationDetails | null;
}): Promise {
if (!notificationDetails) {
notificationDetails = await getUserNotificationDetails(fid);
diff --git a/packages/create-onchain/templates/minikit-snake/lib/notification.ts b/packages/create-onchain/templates/minikit-snake/lib/notification.ts
index 569690c12d..29ad8723e9 100644
--- a/packages/create-onchain/templates/minikit-snake/lib/notification.ts
+++ b/packages/create-onchain/templates/minikit-snake/lib/notification.ts
@@ -1,4 +1,4 @@
-import type { FrameNotificationDetails } from "@farcaster/frame-sdk";
+import type { MiniAppNotificationDetails } from "@farcaster/frame-sdk";
import { redis } from "./redis";
const notificationServiceKey =
@@ -10,19 +10,19 @@ function getUserNotificationDetailsKey(fid: number): string {
export async function getUserNotificationDetails(
fid: number,
-): Promise {
+): Promise {
if (!redis) {
return null;
}
- return await redis.get(
+ return await redis.get(
getUserNotificationDetailsKey(fid),
);
}
export async function setUserNotificationDetails(
fid: number,
- notificationDetails: FrameNotificationDetails,
+ notificationDetails: MiniAppNotificationDetails,
): Promise {
if (!redis) {
return;
diff --git a/packages/create-onchain/templates/minikit-snake/package.json b/packages/create-onchain/templates/minikit-snake/package.json
index e95e544abf..7585e9ab88 100644
--- a/packages/create-onchain/templates/minikit-snake/package.json
+++ b/packages/create-onchain/templates/minikit-snake/package.json
@@ -10,7 +10,7 @@
},
"dependencies": {
"@coinbase/onchainkit": "latest",
- "@farcaster/frame-sdk": "^0.0.60",
+ "@farcaster/frame-sdk": "^0.1.7",
"@upstash/redis": "^1.34.4",
"next": "^15.3.3",
"react": "^18",
diff --git a/packages/onchainkit/package.json b/packages/onchainkit/package.json
index 6ac94f6f45..51d208b93f 100644
--- a/packages/onchainkit/package.json
+++ b/packages/onchainkit/package.json
@@ -31,7 +31,7 @@
"react-dom": "^18 || ^19"
},
"dependencies": {
- "@farcaster/frame-sdk": "^0.0.60",
+ "@farcaster/frame-sdk": "^0.1.7",
"@farcaster/frame-wagmi-connector": "^0.0.53",
"@tanstack/react-query": "^5",
"@wagmi/core": "^2.16.7",
diff --git a/packages/onchainkit/src/minikit/MiniKitProvider.test.tsx b/packages/onchainkit/src/minikit/MiniKitProvider.test.tsx
index 6097d2be8c..250c09ca00 100644
--- a/packages/onchainkit/src/minikit/MiniKitProvider.test.tsx
+++ b/packages/onchainkit/src/minikit/MiniKitProvider.test.tsx
@@ -54,7 +54,7 @@ describe('MiniKitProvider', () => {
added: false,
safeAreaInsets: { top: 0, bottom: 0, left: 0, right: 0 },
},
- }) as unknown as Promise;
+ }) as unknown as Promise;
});
afterEach(() => {
@@ -161,8 +161,12 @@ describe('MiniKitProvider', () => {
await act(() => Promise.resolve());
- expect(sdk.on).toHaveBeenCalledWith('frameAdded', expect.any(Function));
- expect(sdk.on).toHaveBeenCalledWith('frameRemoved', expect.any(Function));
+ expect(sdk.on).toHaveBeenCalledWith('miniAppAdded', expect.any(Function));
+ expect(sdk.on).toHaveBeenCalledWith(
+ 'miniAppAddRejected',
+ expect.any(Function),
+ );
+ expect(sdk.on).toHaveBeenCalledWith('miniAppRemoved', expect.any(Function));
expect(sdk.on).toHaveBeenCalledWith(
'notificationsEnabled',
expect.any(Function),
@@ -217,7 +221,7 @@ describe('MiniKitProvider', () => {
};
act(() => {
- sdk.emit('frameAdded', {
+ sdk.emit('miniAppAdded', {
notificationDetails,
});
});
@@ -228,7 +232,7 @@ describe('MiniKitProvider', () => {
expect(contextValue?.context?.client.added).toBe(true);
act(() => {
- sdk.emit('frameRemoved');
+ sdk.emit('miniAppRemoved');
});
expect(contextValue?.context?.client.notificationDetails).toBeUndefined();
@@ -252,12 +256,12 @@ describe('MiniKitProvider', () => {
await act(() => Promise.resolve());
- sdk.emit('frameAddRejected', {
+ sdk.emit('miniAppAddRejected', {
reason: 'invalid_domain_manifest',
});
expect(consoleErrorSpy).toHaveBeenCalledWith(
- 'Frame add rejected',
+ 'Mini app add rejected',
'invalid_domain_manifest',
);
});
diff --git a/packages/onchainkit/src/minikit/MiniKitProvider.tsx b/packages/onchainkit/src/minikit/MiniKitProvider.tsx
index 332776c182..03ed73fb70 100644
--- a/packages/onchainkit/src/minikit/MiniKitProvider.tsx
+++ b/packages/onchainkit/src/minikit/MiniKitProvider.tsx
@@ -32,10 +32,10 @@ export function MiniKitProvider({
autoConnect = true,
...onchainKitProps
}: MiniKitProviderReact & OnchainKitProviderReact) {
- const [context, setContext] = useState(null);
+ const [context, setContext] = useState(null);
useEffect(() => {
- sdk.on('frameAdded', ({ notificationDetails }) => {
+ sdk.on('miniAppAdded', ({ notificationDetails }) => {
if (notificationDetails) {
updateClientContext({
details: notificationDetails,
@@ -44,11 +44,11 @@ export function MiniKitProvider({
}
});
- sdk.on('frameAddRejected', ({ reason }) => {
- console.error('Frame add rejected', reason);
+ sdk.on('miniAppAddRejected', ({ reason }) => {
+ console.error('Mini app add rejected', reason);
});
- sdk.on('frameRemoved', () => {
+ sdk.on('miniAppRemoved', () => {
updateClientContext({
details: undefined,
frameAdded: false,
diff --git a/packages/onchainkit/src/minikit/types.ts b/packages/onchainkit/src/minikit/types.ts
index 6a477a0532..d0d24aea54 100644
--- a/packages/onchainkit/src/minikit/types.ts
+++ b/packages/onchainkit/src/minikit/types.ts
@@ -1,7 +1,7 @@
-import type { Context, FrameNotificationDetails } from '@farcaster/frame-sdk';
+import type { Context, MiniAppNotificationDetails } from '@farcaster/frame-sdk';
export type UpdateClientContextParams = {
- details?: FrameNotificationDetails | null;
+ details?: MiniAppNotificationDetails | null;
frameAdded?: boolean;
};
@@ -28,7 +28,7 @@ export type MiniKitProviderReact = {
};
export type MiniKitContextType = {
- context: Context.FrameContext | null;
+ context: Context.MiniAppContext | null;
updateClientContext: (params: UpdateClientContextParams) => void;
notificationProxyUrl: string;
__isMiniKit: boolean;
diff --git a/packages/playground/lib/notification-client.ts b/packages/playground/lib/notification-client.ts
index 24a9f43413..1ef6323b8f 100644
--- a/packages/playground/lib/notification-client.ts
+++ b/packages/playground/lib/notification-client.ts
@@ -1,20 +1,20 @@
import {
- FrameNotificationDetails,
+ MiniAppNotificationDetails,
type SendNotificationRequest,
sendNotificationResponseSchema,
-} from "@farcaster/frame-sdk";
-import { getUserNotificationDetails } from "@/lib/notification";
+} from '@farcaster/frame-sdk';
+import { getUserNotificationDetails } from '@/lib/notification';
-const appUrl = process.env.NEXT_PUBLIC_URL || "";
+const appUrl = process.env.NEXT_PUBLIC_URL || '';
type SendFrameNotificationResult =
| {
- state: "error";
+ state: 'error';
error: unknown;
}
- | { state: "no_token" }
- | { state: "rate_limit" }
- | { state: "success" };
+ | { state: 'no_token' }
+ | { state: 'rate_limit' }
+ | { state: 'success' };
export async function sendFrameNotification({
fid,
@@ -25,19 +25,19 @@ export async function sendFrameNotification({
fid: number;
title: string;
body: string;
- notificationDetails?: FrameNotificationDetails | null;
+ notificationDetails?: MiniAppNotificationDetails | null;
}): Promise {
if (!notificationDetails) {
notificationDetails = await getUserNotificationDetails(fid);
}
if (!notificationDetails) {
- return { state: "no_token" };
+ return { state: 'no_token' };
}
const response = await fetch(notificationDetails.url, {
- method: "POST",
+ method: 'POST',
headers: {
- "Content-Type": "application/json",
+ 'Content-Type': 'application/json',
},
body: JSON.stringify({
notificationId: crypto.randomUUID(),
@@ -53,15 +53,15 @@ export async function sendFrameNotification({
if (response.status === 200) {
const responseBody = sendNotificationResponseSchema.safeParse(responseJson);
if (responseBody.success === false) {
- return { state: "error", error: responseBody.error.errors };
+ return { state: 'error', error: responseBody.error.errors };
}
if (responseBody.data.result.rateLimitedTokens.length) {
- return { state: "rate_limit" };
+ return { state: 'rate_limit' };
}
- return { state: "success" };
+ return { state: 'success' };
}
- return { state: "error", error: responseJson };
-}
\ No newline at end of file
+ return { state: 'error', error: responseJson };
+}
diff --git a/packages/playground/lib/notification.ts b/packages/playground/lib/notification.ts
index 569690c12d..f80e58b50c 100644
--- a/packages/playground/lib/notification.ts
+++ b/packages/playground/lib/notification.ts
@@ -1,8 +1,8 @@
-import type { FrameNotificationDetails } from "@farcaster/frame-sdk";
-import { redis } from "./redis";
+import type { MiniAppNotificationDetails } from '@farcaster/frame-sdk';
+import { redis } from './redis';
const notificationServiceKey =
- process.env.NEXT_PUBLIC_ONCHAINKIT_PROJECT_NAME ?? "minikit";
+ process.env.NEXT_PUBLIC_ONCHAINKIT_PROJECT_NAME ?? 'minikit';
function getUserNotificationDetailsKey(fid: number): string {
return `${notificationServiceKey}:user:${fid}`;
@@ -10,19 +10,19 @@ function getUserNotificationDetailsKey(fid: number): string {
export async function getUserNotificationDetails(
fid: number,
-): Promise {
+): Promise {
if (!redis) {
return null;
}
- return await redis.get(
+ return await redis.get(
getUserNotificationDetailsKey(fid),
);
}
export async function setUserNotificationDetails(
fid: number,
- notificationDetails: FrameNotificationDetails,
+ notificationDetails: MiniAppNotificationDetails,
): Promise {
if (!redis) {
return;
diff --git a/packages/playground/package.json b/packages/playground/package.json
index 81d394f1ea..27c2bf52b7 100644
--- a/packages/playground/package.json
+++ b/packages/playground/package.json
@@ -10,6 +10,7 @@
},
"dependencies": {
"@coinbase/onchainkit": "workspace:*",
+ "@farcaster/frame-sdk": "^0.1.7",
"@radix-ui/react-dropdown-menu": "^2.1.1",
"@radix-ui/react-icons": "^1.3.0",
"@radix-ui/react-label": "^2.1.0",
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 4e8f483fc2..c378976aa9 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -51,8 +51,8 @@ importers:
specifier: workspace:*
version: link:../../packages/onchainkit
'@farcaster/frame-sdk':
- specifier: ^0.0.60
- version: 0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
+ specifier: ^0.1.7
+ version: 0.1.7(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
'@tanstack/react-query':
specifier: ^5
version: 5.69.0(react@18.3.1)
@@ -75,6 +75,9 @@ importers:
specifier: ^2.14.11
version: 2.14.15(@tanstack/query-core@5.69.0)(@tanstack/react-query@5.69.0(react@18.3.1))(@types/react@18.3.19)(@upstash/redis@1.35.0)(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.3)(utf-8-validate@5.0.10)(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(zod@3.25.42)
devDependencies:
+ '@farcaster/quick-auth':
+ specifier: ^0.0.7
+ version: 0.0.7(typescript@5.8.3)
'@types/node':
specifier: ^22
version: 22.13.10
@@ -147,7 +150,7 @@ importers:
dependencies:
'@coinbase/onchainkit':
specifier: latest
- version: 0.38.14(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(@upstash/redis@1.35.0)(bufferutil@4.0.9)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(utf-8-validate@5.0.10)(zod@3.25.42)
+ version: 0.38.17(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(bufferutil@4.0.9)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
buffer:
specifier: ^6.0.3
version: 6.0.3
@@ -225,11 +228,11 @@ importers:
packages/onchainkit:
dependencies:
'@farcaster/frame-sdk':
- specifier: ^0.0.60
- version: 0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
+ specifier: ^0.1.7
+ version: 0.1.7(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
'@farcaster/frame-wagmi-connector':
specifier: ^0.0.53
- version: 0.0.53(@farcaster/frame-sdk@0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))
+ version: 0.0.53(@farcaster/frame-sdk@0.1.7(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))
'@tanstack/react-query':
specifier: ^5
version: 5.69.0(react@18.3.1)
@@ -384,6 +387,9 @@ importers:
'@coinbase/onchainkit':
specifier: workspace:*
version: link:../onchainkit
+ '@farcaster/frame-sdk':
+ specifier: ^0.1.7
+ version: 0.1.7(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
'@radix-ui/react-dropdown-menu':
specifier: ^2.1.1
version: 2.1.6(@types/react-dom@18.3.5(@types/react@18.3.19))(@types/react@18.3.19)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)
@@ -1289,8 +1295,8 @@ packages:
'@changesets/write@0.4.0':
resolution: {integrity: sha512-CdTLvIOPiCNuH71pyDu3rA+Q0n65cmAbXnwWH84rKGiFumFzkmHNT8KHTMEchcxN+Kl8I54xGUhJ7l3E7X396Q==}
- '@coinbase/onchainkit@0.38.14':
- resolution: {integrity: sha512-pTSK1SHjIKFIJFI7PWQSK0MKkzZe47w/6SZ21gUmxBKpRF1+cyaH7msm74iZgjGsZBYoxsYzQ2FwqrA06wupTw==}
+ '@coinbase/onchainkit@0.38.17':
+ resolution: {integrity: sha512-TMZwdsSzzOcswIKnPolCMJJlmTYrSV+cx/T2UV3LTRWPvvACvCV5TTKQx7ELs34Fqtp7QA7Kcn4unio4En2PaQ==}
peerDependencies:
react: ^18 || ^19
react-dom: ^18 || ^19
@@ -1695,12 +1701,9 @@ packages:
'@farcaster/frame-sdk@0.0.60':
resolution: {integrity: sha512-MHQwdFT1VPe3kS0NvnORBPb/DQXr8qpdSDgIgfrdVCB8byQ5uFELlr3gQMuFYFyLFQVXgbMl75z8O6+hvorqow==}
- '@farcaster/frame-wagmi-connector@0.0.42':
- resolution: {integrity: sha512-KI6/Jai7TVOz1B166E86Pf+ehNFyknn0AzSXJ7RTeSX/Uvh1jna+DgISNpRJjV08YJHBxkynAi+kQI4dlbqJoQ==}
- peerDependencies:
- '@farcaster/frame-sdk': ^0.0.53
- '@wagmi/core': ^2.14.1
- viem: ^2.21.55
+ '@farcaster/frame-sdk@0.1.7':
+ resolution: {integrity: sha512-NcHBOn8mERDRDyHfHT8IMwKNOOMI+n/5WpOAYEZGteEDcYp8zRKmZEunmMXVvmHXd9Q7/8aQvwxngQMkSZ7/ww==}
+ engines: {node: '>=22.11.0'}
'@farcaster/frame-wagmi-connector@0.0.53':
resolution: {integrity: sha512-+fonXzzj3KxTeUHbtt7lZUC4v/MhC2Y2KpQw7WcVamiDwedm+jTMqBIdrMrWRej/HSWrBQ1rDIOlsWxnv9CDng==}
@@ -1709,11 +1712,27 @@ packages:
'@wagmi/core': ^2.14.1
viem: ^2.21.55
+ '@farcaster/miniapp-core@0.3.6':
+ resolution: {integrity: sha512-PKQmDKVf/ljoscYHUgUiRgsQCrJ+etgdyFOLUlhDKWI5Rw9AyG43PKrSmee0RduvV4S9w4LAPoUcx3YwWmAsrw==}
+
+ '@farcaster/miniapp-sdk@0.1.7':
+ resolution: {integrity: sha512-6Ph/mlGCOYLVm1+3ORHW3rIVEceWxvJIHWfHp2NbKAeobna11lAV1zx2fpEXu+HIKJ614fg+UjmlK9JORCRgEw==}
+
'@farcaster/quick-auth@0.0.5':
resolution: {integrity: sha512-Z8hWz/7c33zlmII2AJHja/Wz0C03mm2o+CEBtBylmiun1wC4FMgx1Fal699VQvBUG1lpcJ662WxuRNxKogktDw==}
peerDependencies:
typescript: 5.8.3
+ '@farcaster/quick-auth@0.0.6':
+ resolution: {integrity: sha512-tiZndhpfDtEhaKlkmS5cVDuS+A/tafqZT3y9I44rC69m3beJok6e8dIH2JhxVy3EvOWTyTBnrmNn6GOOh+qK6A==}
+ peerDependencies:
+ typescript: 5.8.3
+
+ '@farcaster/quick-auth@0.0.7':
+ resolution: {integrity: sha512-FNHlizdwjLmX7MQjsArGuj7SVfrQ9UCqk9JIiMaBt/J9WtIEZQxFtilKYjaIDyd4gZiZ9EImKVvR2bVyd8ExeQ==}
+ peerDependencies:
+ typescript: 5.8.3
+
'@floating-ui/core@1.6.9':
resolution: {integrity: sha512-uMXCuQ3BItDUbAMhIXw7UPXRfAlOAvZzdK9BWpE60MCn+Svt3aLn9jsPTi/WNGlRUu2uI0v5S7JiIUsbsvh3fw==}
@@ -9778,10 +9797,10 @@ snapshots:
human-id: 4.1.1
prettier: 2.8.8
- '@coinbase/onchainkit@0.38.14(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(@upstash/redis@1.35.0)(bufferutil@4.0.9)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(utf-8-validate@5.0.10)(zod@3.25.42)':
+ '@coinbase/onchainkit@0.38.17(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(bufferutil@4.0.9)(react-dom@18.3.1(react@18.3.1))(react@18.3.1)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)':
dependencies:
'@farcaster/frame-sdk': 0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
- '@farcaster/frame-wagmi-connector': 0.0.42(@farcaster/frame-sdk@0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))
+ '@farcaster/frame-wagmi-connector': 0.0.53(@farcaster/frame-sdk@0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))
'@tanstack/react-query': 5.69.0(react@18.3.1)
'@wagmi/core': 2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))
clsx: 2.1.1
@@ -10122,24 +10141,75 @@ snapshots:
- utf-8-validate
- zod
- '@farcaster/frame-wagmi-connector@0.0.42(@farcaster/frame-sdk@0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))':
+ '@farcaster/frame-sdk@0.1.7(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)':
+ dependencies:
+ '@farcaster/miniapp-sdk': 0.1.7(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
+ '@farcaster/quick-auth': 0.0.6(typescript@5.8.3)
+ comlink: 4.4.2
+ eventemitter3: 5.0.1
+ ox: 0.4.4(typescript@5.8.3)(zod@3.25.42)
+ transitivePeerDependencies:
+ - bufferutil
+ - encoding
+ - typescript
+ - utf-8-validate
+ - zod
+
+ '@farcaster/frame-wagmi-connector@0.0.53(@farcaster/frame-sdk@0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))':
dependencies:
'@farcaster/frame-sdk': 0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
'@wagmi/core': 2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))
viem: 2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
- '@farcaster/frame-wagmi-connector@0.0.53(@farcaster/frame-sdk@0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))':
+ '@farcaster/frame-wagmi-connector@0.0.53(@farcaster/frame-sdk@0.1.7(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))':
dependencies:
- '@farcaster/frame-sdk': 0.0.60(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
+ '@farcaster/frame-sdk': 0.1.7(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
'@wagmi/core': 2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))
viem: 2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)
+ '@farcaster/miniapp-core@0.3.6(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)':
+ dependencies:
+ '@solana/web3.js': 1.98.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)
+ ox: 0.4.4(typescript@5.8.3)(zod@3.25.42)
+ zod: 3.25.42
+ transitivePeerDependencies:
+ - bufferutil
+ - encoding
+ - typescript
+ - utf-8-validate
+
+ '@farcaster/miniapp-sdk@0.1.7(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)':
+ dependencies:
+ '@farcaster/miniapp-core': 0.3.6(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)
+ '@farcaster/quick-auth': 0.0.6(typescript@5.8.3)
+ comlink: 4.4.2
+ eventemitter3: 5.0.1
+ ox: 0.4.4(typescript@5.8.3)(zod@3.25.42)
+ transitivePeerDependencies:
+ - bufferutil
+ - encoding
+ - typescript
+ - utf-8-validate
+ - zod
+
'@farcaster/quick-auth@0.0.5(typescript@5.8.3)':
dependencies:
jose: 5.10.0
typescript: 5.8.3
zod: 3.25.42
+ '@farcaster/quick-auth@0.0.6(typescript@5.8.3)':
+ dependencies:
+ jose: 5.10.0
+ typescript: 5.8.3
+ zod: 3.25.42
+
+ '@farcaster/quick-auth@0.0.7(typescript@5.8.3)':
+ dependencies:
+ jose: 5.10.0
+ typescript: 5.8.3
+ zod: 3.25.42
+
'@floating-ui/core@1.6.9':
dependencies:
'@floating-ui/utils': 0.2.9
@@ -12363,7 +12433,7 @@ snapshots:
'@vue/shared@3.5.13': {}
- '@wagmi/connectors@5.7.11(@types/react@18.3.19)(@upstash/redis@1.35.0)(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.3)(utf-8-validate@5.0.10)(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(zod@3.25.42)':
+ '@wagmi/connectors@5.7.11(@types/react@18.3.19)(@upstash/redis@1.35.0)(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.3)(utf-8-validate@5.0.10)(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(zod@3.25.42)':
dependencies:
'@coinbase/wallet-sdk': 4.3.0
'@metamask/sdk': 0.32.0(bufferutil@4.0.9)(utf-8-validate@5.0.10)
@@ -18179,7 +18249,7 @@ snapshots:
wagmi@2.14.15(@tanstack/query-core@5.69.0)(@tanstack/react-query@5.69.0(react@18.3.1))(@types/react@18.3.19)(@upstash/redis@1.35.0)(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.3)(utf-8-validate@5.0.10)(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(zod@3.25.42):
dependencies:
'@tanstack/react-query': 5.69.0(react@18.3.1)
- '@wagmi/connectors': 5.7.11(@types/react@18.3.19)(@upstash/redis@1.35.0)(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.3)(utf-8-validate@5.0.10)(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(zod@3.25.42)
+ '@wagmi/connectors': 5.7.11(@types/react@18.3.19)(@upstash/redis@1.35.0)(@wagmi/core@2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42)))(bufferutil@4.0.9)(react@18.3.1)(typescript@5.8.3)(utf-8-validate@5.0.10)(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))(zod@3.25.42)
'@wagmi/core': 2.16.7(@tanstack/query-core@5.69.0)(@types/react@18.3.19)(react@18.3.1)(typescript@5.8.3)(use-sync-external-store@1.4.0(react@18.3.1))(viem@2.27.2(bufferutil@4.0.9)(typescript@5.8.3)(utf-8-validate@5.0.10)(zod@3.25.42))
react: 18.3.1
use-sync-external-store: 1.4.0(react@18.3.1)