From 9567447ca7c8819e5df049a1ec9c1d97698219de Mon Sep 17 00:00:00 2001 From: Spencer Stock Date: Thu, 19 Dec 2024 17:27:28 -0700 Subject: [PATCH 1/2] update docs for keysurl --- docs/pages/guides/spend-permissions/quick-start.mdx | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/docs/pages/guides/spend-permissions/quick-start.mdx b/docs/pages/guides/spend-permissions/quick-start.mdx index 9bf1b7c..86e1a4d 100644 --- a/docs/pages/guides/spend-permissions/quick-start.mdx +++ b/docs/pages/guides/spend-permissions/quick-start.mdx @@ -79,7 +79,13 @@ export async function getSpenderWalletClient() { ### Configure the Smart Wallet URL -In `app/providers.tsx`, update the chain configuration to use Base Sepolia testnet by replacing all instances of `base` with `baseSepolia` in this file (including the import). +In `app/providers.tsx`, update the value of `keysUrl` based on your environment: + +- For testnets: `"https://keys-dev.coinbase.com/connect"` +- For mainnets: Leave `keysUrl` undefined (defaults to keys.coinbase.com) + +We also want to point our chain id to Base Sepolia testnet by setting replacing all instances of `base` +with `baseSepolia` in this file (including the import). Your config in `app/providers.tsx` should now look like this: @@ -92,6 +98,8 @@ const config = createConfig({ preference: process.env.NEXT_PUBLIC_ONCHAINKIT_WALLET_CONFIG as | "smartWalletOnly" | "all", + // @ts-ignore + keysUrl: "https://keys-dev.coinbase.com/connect" }), ], storage: createStorage({ From d8f44c0a46756a218cda1dc5b948b0aafedfc4b5 Mon Sep 17 00:00:00 2001 From: Spencer Stock Date: Thu, 19 Dec 2024 17:33:54 -0700 Subject: [PATCH 2/2] give more details --- .../guides/spend-permissions/quick-start.mdx | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/docs/pages/guides/spend-permissions/quick-start.mdx b/docs/pages/guides/spend-permissions/quick-start.mdx index 86e1a4d..8fb622e 100644 --- a/docs/pages/guides/spend-permissions/quick-start.mdx +++ b/docs/pages/guides/spend-permissions/quick-start.mdx @@ -79,15 +79,16 @@ export async function getSpenderWalletClient() { ### Configure the Smart Wallet URL -In `app/providers.tsx`, update the value of `keysUrl` based on your environment: +In `app/providers.tsx`, update your configuration based on your environment: -- For testnets: `"https://keys-dev.coinbase.com/connect"` -- For mainnets: Leave `keysUrl` undefined (defaults to keys.coinbase.com) +- For testnets: + - Set `keysUrl: "https://keys-dev.coinbase.com/connect"` + - Replace all instances of `base` with `baseSepolia` (including the import) +- For mainnets: + - Leave `keysUrl` undefined (defaults to keys.coinbase.com) + - Keep the default `base` chain from the template -We also want to point our chain id to Base Sepolia testnet by setting replacing all instances of `base` -with `baseSepolia` in this file (including the import). - -Your config in `app/providers.tsx` should now look like this: +Your config in `app/providers.tsx` should look like this for testnet: ```ts const config = createConfig({