Skip to content

Commit 7347047

Browse files
committed
documentation
1 parent b076b0e commit 7347047

File tree

1 file changed

+42
-0
lines changed

1 file changed

+42
-0
lines changed
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
# Immutable connector for Sequence Web-SDK
2+
3+
## Installation
4+
5+
To install this package:
6+
7+
```bash
8+
npm install @0xsequence/immutable-connector @imtbl/config @imtbl/sdk
9+
# or
10+
11+
pnpm install @0xsequence/immutable-connector @imtbl/config @imtbl/sdk
12+
# or
13+
yarn add @0xsequence/immutable-connector @imtbl/config @imtbl/sdk
14+
```
15+
16+
## Adding the connect
17+
18+
First, an Immutable Passport instance must be created with valid and correctly configured Immutable keys.
19+
20+
Note, that the application will need a callback route configured similarly to this example: https://github.com/immutable/ts-immutable-sdk/blob/main/examples/passport/login-with-nextjs/src/app/redirect/page.tsx
21+
22+
```js
23+
export const passportInstance = new passport.Passport({
24+
baseConfig: {
25+
environment: Environment.SANDBOX,
26+
publishableKey: 'my_publisheable_key'
27+
},
28+
clientId: 'my_client_id',
29+
redirectUri: `${window.location.origin}/auth/callback`,
30+
audience: 'platform_api',
31+
scope: 'openid offline_access email transact'
32+
})
33+
```
34+
35+
Finally, the wallet can be passed down to the web-sdk configuration similarly to other wallets,
36+
37+
```js
38+
immutable({
39+
passportInstance,
40+
environment: Environment.SANDBOX
41+
})
42+
```

0 commit comments

Comments
 (0)