@bounded-sh/server 0.0.20 → 0.0.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -21
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -71,39 +71,24 @@ await init({ apiKey: 'your-api-key', appId: 'your-app-id' });
|
|
|
71
71
|
const wallet = await createWalletClient({ keypair: secretKeyString });
|
|
72
72
|
```
|
|
73
73
|
|
|
74
|
-
###
|
|
74
|
+
### Signing And Transactions
|
|
75
75
|
|
|
76
76
|
```typescript
|
|
77
|
-
import { init,
|
|
78
|
-
import { Keypair } from '@solana/web3.js';
|
|
77
|
+
import { init, createWalletClient } from '@tarobase/server';
|
|
79
78
|
|
|
80
|
-
// Initialize the SDK
|
|
81
79
|
await init({
|
|
82
80
|
apiKey: 'your-api-key',
|
|
83
81
|
appId: 'your-app-id',
|
|
84
82
|
rpcUrl: process.env.SOLANA_MAINNET_RPC_URL
|
|
85
83
|
});
|
|
86
84
|
|
|
87
|
-
|
|
88
|
-
const provider = new SolanaKeypairProvider(
|
|
89
|
-
"https://your-solana-rpc.example",
|
|
90
|
-
Keypair.generate()
|
|
91
|
-
);
|
|
85
|
+
const wallet = await createWalletClient({ keypair: process.env.SERVER_WALLET_KEYPAIR! });
|
|
92
86
|
|
|
93
87
|
// Sign a message
|
|
94
|
-
const signature = await
|
|
88
|
+
const signature = await wallet.signMessage("Hello, world!");
|
|
95
89
|
|
|
96
|
-
//
|
|
97
|
-
const
|
|
98
|
-
appId: 'your-app-id',
|
|
99
|
-
network: 'solana_mainnet',
|
|
100
|
-
txArgs: [{
|
|
101
|
-
setDocumentData: [{ path: 'todos/123', data: { text: 'New todo' } }],
|
|
102
|
-
deletePaths: [],
|
|
103
|
-
remainingAccounts: [],
|
|
104
|
-
idl: {}
|
|
105
|
-
}]
|
|
106
|
-
});
|
|
90
|
+
// Submit a transaction you built explicitly with @solana/web3.js
|
|
91
|
+
// const signature = await wallet.signAndSubmitTransaction(transaction);
|
|
107
92
|
```
|
|
108
93
|
|
|
109
94
|
### Subscriptions
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@bounded-sh/server",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.22",
|
|
4
4
|
"description": "Server SDK for Poof API - Node.js/Backend implementation",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"module": "./dist/index.mjs",
|
|
@@ -46,7 +46,7 @@
|
|
|
46
46
|
"typescript": "5.9.3"
|
|
47
47
|
},
|
|
48
48
|
"dependencies": {
|
|
49
|
-
"@bounded-sh/core": "0.0.
|
|
49
|
+
"@bounded-sh/core": "0.0.22",
|
|
50
50
|
"@coral-xyz/anchor": "0.31.1",
|
|
51
51
|
"@solana/spl-token": "0.4.14",
|
|
52
52
|
"@solana/web3.js": "1.98.4",
|