diff --git a/astro.config.mjs b/astro.config.mjs index 52019db..9d7835f 100644 --- a/astro.config.mjs +++ b/astro.config.mjs @@ -37,13 +37,16 @@ export default defineConfig({ { label: "v0.5", items: [ - // { label: "Network Overview", slug: "concepts/network-overview" }, - { label: "Control Space", slug: "v05/control-space" }, - { label: "Permission System", slug: "v05/permissions" }, - { label: "Capability Permissions", slug: "v05/capability-permissions" }, - { label: "Emission Permissions", slug: "v05/emission-permissions" }, - { label: "Tokenomics", slug: "concepts/tokenomics" }, - { label: "Governance & DAO", slug: "concepts/governance-dao" }, + // { label: "Network Overview", slug: "concepts/network-overview" }, + { label: "Control Space", slug: "v05/control-space" }, + { label: "Permission System", slug: "v05/permissions" }, + { + label: "Capability Permissions", + slug: "v05/capability-permissions", + }, + { label: "Emission Permissions", slug: "v05/emission-permissions" }, + { label: "Tokenomics", slug: "concepts/tokenomics" }, + { label: "Governance & DAO", slug: "concepts/governance-dao" }, ], }, { @@ -96,6 +99,16 @@ export default defineConfig({ }, ], }, + { + label: "How-to Guides", + items: [ + { label: "Setup a wallet", slug: "how-to-guides/setup-a-wallet" }, + // { + // label: "Setup a wallet", + // slug: "how-to-guides/setup-a-wallet", + // }, + ], + }, ], customCss: ["./src/tailwind.css"], }), diff --git a/public/images/how-to-guide/setup-wallet/subwallet-created-successfully.png b/public/images/how-to-guide/setup-wallet/subwallet-created-successfully.png new file mode 100644 index 0000000..b2e1460 Binary files /dev/null and b/public/images/how-to-guide/setup-wallet/subwallet-created-successfully.png differ diff --git a/public/images/how-to-guide/setup-wallet/subwallet-done-torus-setup.png b/public/images/how-to-guide/setup-wallet/subwallet-done-torus-setup.png new file mode 100644 index 0000000..4108c61 Binary files /dev/null and b/public/images/how-to-guide/setup-wallet/subwallet-done-torus-setup.png differ diff --git a/public/images/how-to-guide/setup-wallet/subwallet-extension-activated.png b/public/images/how-to-guide/setup-wallet/subwallet-extension-activated.png new file mode 100644 index 0000000..174a299 Binary files /dev/null and b/public/images/how-to-guide/setup-wallet/subwallet-extension-activated.png differ diff --git a/public/images/how-to-guide/setup-wallet/subwallet-open-setup.png b/public/images/how-to-guide/setup-wallet/subwallet-open-setup.png new file mode 100644 index 0000000..29244cf Binary files /dev/null and b/public/images/how-to-guide/setup-wallet/subwallet-open-setup.png differ diff --git a/public/images/how-to-guide/setup-wallet/subwallet-search-torus-network.png b/public/images/how-to-guide/setup-wallet/subwallet-search-torus-network.png new file mode 100644 index 0000000..446f1c4 Binary files /dev/null and b/public/images/how-to-guide/setup-wallet/subwallet-search-torus-network.png differ diff --git a/public/images/how-to-guide/setup-wallet/subwallet-select-config-to-add-network.png b/public/images/how-to-guide/setup-wallet/subwallet-select-config-to-add-network.png new file mode 100644 index 0000000..9a35275 Binary files /dev/null and b/public/images/how-to-guide/setup-wallet/subwallet-select-config-to-add-network.png differ diff --git a/src/content/docs/agents/client.mdx b/src/content/docs/agents/client.mdx index 577402d..1657f47 100644 --- a/src/content/docs/agents/client.mdx +++ b/src/content/docs/agents/client.mdx @@ -25,13 +25,13 @@ The AgentClient simplifies communication with Agent APIs by: ## Installation ```sh -npm install @torus-network/torus-ts-sdk +npm install @@torus-network/sdk ``` ## Basic Usage ```ts -import { AgentClient, Keypair } from "@torus-network/torus-ts-sdk"; +import { AgentClient, Keypair } from "@@torus-network/sdk"; // Create a keypair from your mnemonic const keypair = new Keypair( @@ -75,7 +75,7 @@ interface AgentClientOptions { The `Keypair` class handles SR25519 key generation and JWT token creation: ```ts -import { Keypair } from "@torus-network/torus-ts-sdk"; +import { Keypair } from "@@torus-network/sdk"; // Create from mnemonic const keypair = new Keypair( @@ -301,7 +301,7 @@ if (response.success) { ### Memory Agent Client ```ts -import { AgentClient, Keypair } from "@torus-network/torus-ts-sdk"; +import { AgentClient, Keypair } from "@@torus-network/sdk"; class MemoryAgentClient { private client: AgentClient; @@ -414,7 +414,7 @@ if (searchResult.success) { ### Environment-based Configuration ```ts -import { AgentClient, Keypair } from "@torus-network/torus-ts-sdk"; +import { AgentClient, Keypair } from "@@torus-network/sdk"; // Environment configuration const config = { diff --git a/src/content/docs/agents/server-setup.mdx b/src/content/docs/agents/server-setup.mdx index 514c06e..a1445ea 100644 --- a/src/content/docs/agents/server-setup.mdx +++ b/src/content/docs/agents/server-setup.mdx @@ -28,13 +28,13 @@ The AgentServer uses **Hono** for HTTP routing and **Zod** for input validation, ## Installation ```sh -npm install @torus-network/torus-ts-sdk +npm install @@torus-network/sdk ``` ## Basic Usage ```ts -import { AgentServer } from "@torus-network/torus-ts-sdk"; +import { AgentServer } from "@@torus-network/sdk"; import { z } from "zod"; const agent = new AgentServer({ @@ -443,7 +443,7 @@ Visit `http://localhost:3000/docs` to view the interactive API documentation. Multi method agent is an agent that defines more than 1 method. ```ts -import { AgentServer } from "@torus-network/torus-ts-sdk"; +import { AgentServer } from "@@torus-network/sdk"; import { z } from "zod"; const memoryAgent = new AgentServer({ diff --git a/src/content/docs/how-to-guides/how-to-guides.mdx b/src/content/docs/how-to-guides/how-to-guides.mdx new file mode 100644 index 0000000..8c22d0c --- /dev/null +++ b/src/content/docs/how-to-guides/how-to-guides.mdx @@ -0,0 +1,91 @@ +--- +title: How to be a builder on Torus +description: A practical guide to getting involved in the Torus Network, from permissions to integration. +--- + +## Overview + +Participating in the Torus Network means becoming an **agent** that contributes value through **signals** and **integrations**. This guide walks you through each step β€” from setting up your wallet to delivering a fully working agent. + +--- + +## 🧭 Step-by-Step Path + +### 1. Set up your wallet + +Every agent begins with a wallet that can sign transactions. + +πŸ‘‰ [How to create a wallet](/how-to-guides/set-up-wallet) + +--- + +### 2. Register your agent + +To act on-chain, your wallet must be registered or whitelisted. + +πŸ‘‰ [How to register an agent](/how-to-guides/register-agent) +πŸ‘‰ [How to apply to be whitelisted](/how-to-guides/apply-to-be-whitelisted) + +--- + +### 3. Create a permission namespace + +Define your agent’s capabilities by creating a permission. + +πŸ‘‰ [How to create a permission](/how-to-guides/create-permission) +πŸ‘‰ [How to edit a permission](/how-to-guides/edit-permission) + +--- + +### 4. Grant or manage capabilities + +Give specific agents (including yourself) the ability to act. + +πŸ‘‰ [How to create capabilities](/how-to-guides/create-capabilities) +πŸ‘‰ [How to delete capabilities](/how-to-guides/delete-capabilities) + +--- + +### 5. Create a signal + +Agents produce **signals** to announce work, ideas, or needs. To emit signals, you must have emissions permissions. + +πŸ‘‰ [How to create a signal](/how-to-guides/create-signal) +πŸ‘‰ [How to receive emissions](/how-to-guides/receive-emissions) + +--- + +### 6. Interact with the API + +To read/write from the network, learn how to use the API. + +πŸ‘‰ [How to interact with the Agent API](/how-to-guides/agent-api) + +--- + +### 7. Integrate it all + +Bring everything together into a working, running agent. + +πŸ‘‰ [How to host an agent](/how-to-guides/host-agent) +πŸ‘‰ [How to connect to the chain](/how-to-guides/connect-to-chain) + +--- + +## πŸ§‘β€πŸ’» Participating in Signals (as a developer) + +Once a signal is live, others can collaborate: + +1. **Find** a relevant signal +2. **Talk** to the issuer +3. **Develop** based on the signal’s namespace + permissions +4. **Deliver** your work + +πŸ‘‰ [How to find and respond to a signal](/how-to-guides/respond-to-signal) +πŸ‘‰ [How to host an agent](/how-to-guides/host-agent) + +--- + +## πŸ”„ Ready to start? + +Start from the top or jump into the step you need. Each how-to guide is standalone, but together they form the full path to participation. diff --git a/src/content/docs/how-to-guides/how-to-take-part.mdx b/src/content/docs/how-to-guides/how-to-take-part.mdx new file mode 100644 index 0000000..8c22d0c --- /dev/null +++ b/src/content/docs/how-to-guides/how-to-take-part.mdx @@ -0,0 +1,91 @@ +--- +title: How to be a builder on Torus +description: A practical guide to getting involved in the Torus Network, from permissions to integration. +--- + +## Overview + +Participating in the Torus Network means becoming an **agent** that contributes value through **signals** and **integrations**. This guide walks you through each step β€” from setting up your wallet to delivering a fully working agent. + +--- + +## 🧭 Step-by-Step Path + +### 1. Set up your wallet + +Every agent begins with a wallet that can sign transactions. + +πŸ‘‰ [How to create a wallet](/how-to-guides/set-up-wallet) + +--- + +### 2. Register your agent + +To act on-chain, your wallet must be registered or whitelisted. + +πŸ‘‰ [How to register an agent](/how-to-guides/register-agent) +πŸ‘‰ [How to apply to be whitelisted](/how-to-guides/apply-to-be-whitelisted) + +--- + +### 3. Create a permission namespace + +Define your agent’s capabilities by creating a permission. + +πŸ‘‰ [How to create a permission](/how-to-guides/create-permission) +πŸ‘‰ [How to edit a permission](/how-to-guides/edit-permission) + +--- + +### 4. Grant or manage capabilities + +Give specific agents (including yourself) the ability to act. + +πŸ‘‰ [How to create capabilities](/how-to-guides/create-capabilities) +πŸ‘‰ [How to delete capabilities](/how-to-guides/delete-capabilities) + +--- + +### 5. Create a signal + +Agents produce **signals** to announce work, ideas, or needs. To emit signals, you must have emissions permissions. + +πŸ‘‰ [How to create a signal](/how-to-guides/create-signal) +πŸ‘‰ [How to receive emissions](/how-to-guides/receive-emissions) + +--- + +### 6. Interact with the API + +To read/write from the network, learn how to use the API. + +πŸ‘‰ [How to interact with the Agent API](/how-to-guides/agent-api) + +--- + +### 7. Integrate it all + +Bring everything together into a working, running agent. + +πŸ‘‰ [How to host an agent](/how-to-guides/host-agent) +πŸ‘‰ [How to connect to the chain](/how-to-guides/connect-to-chain) + +--- + +## πŸ§‘β€πŸ’» Participating in Signals (as a developer) + +Once a signal is live, others can collaborate: + +1. **Find** a relevant signal +2. **Talk** to the issuer +3. **Develop** based on the signal’s namespace + permissions +4. **Deliver** your work + +πŸ‘‰ [How to find and respond to a signal](/how-to-guides/respond-to-signal) +πŸ‘‰ [How to host an agent](/how-to-guides/host-agent) + +--- + +## πŸ”„ Ready to start? + +Start from the top or jump into the step you need. Each how-to guide is standalone, but together they form the full path to participation. diff --git a/src/content/docs/how-to-guides/setup-a-wallet.mdx b/src/content/docs/how-to-guides/setup-a-wallet.mdx new file mode 100644 index 0000000..a257d71 --- /dev/null +++ b/src/content/docs/how-to-guides/setup-a-wallet.mdx @@ -0,0 +1,150 @@ +--- +title: Setup a Wallet +description: Learn how to set up a wallet to manage your assets on Torus. +--- + +import { + Steps, + Aside, + CardGrid, + LinkCard, +} from "@astrojs/starlight/components"; + +In this guide, we’ll walk through setting up a wallet with the **SubWallet** browser extension, a popular non-custodial wallet for managing assets across multiple blockchains. +If you prefer a different extension, scroll to the bottom for a list of other wallets that work with Torus. +For simplicity’s sake, though, we’ll focus on SubWallet. + +#### What we will accomplish + +- Install the SubWallet extension +- Create a new wallet (master password + seed phrase) +- Connect SubWallet to Torus + +## Steps to connect your SubWallet to Torus. + +### 1. Installing the SubWallet Extension + + + +1. **Download the Extension** + Visit the [SubWallet download page](https://www.subwallet.app/download.html) and download the appropriate version of the extension for your browser (Chrome, Brave, Firefox, or Microsoft Edge). + +3. **Activate/Pin the Extension** + In some cases, you may need to activate the extension manually. Refer to the [SubWallet documentation](https://docs.subwallet.app/main) for instructions. + + If everything is correct, the SubWallet icon should appear in the top-right corner of your browser. You are ready to move to the next step and create a new wallet. + + + + Below is a reference image of the SubWallet extension activated/pinned in + the Brave browser: + + + + ![SubWallet extension activated in Brave browser](/images/how-to-guide/setup-wallet/subwallet-extension-activated.png) + + + +### 2. Creating a New Account + + + +1. **Open the SubWallet extension in you browser**: + Click on the SubWallet icon in your browser’s extension area to open the wallet. + +2. **Click Create a New Account**: + You will be prompted between three options: + + - Create new account + - Import account + - Connect existing account + + Select **Create new account** option. + + +3. **Create a Master Password**: + You will be prompted to create a master password. This password is crucial as it encrypts your wallet data on your device for security. + +4. **Backup Your Seed Phrase**: + After setting your password and accepting all the seed phrase terms, you will receive a seed phrase. **Write this down and store it in a secure location. This seed phrase is essential for recovering your wallet if you forget your password or lose access to your device.** + [Here's a video for you to watch later about methods to keep your seed phrase safe](https://www.youtube.com/watch?v=fdtx0MG0Xgo). + + + +5. **Create an account name**: + Choose an account name, this does not impact on anything, so feel free to choose any name you like. If you want to change it later, you can do so from the account settings. + + + + Below is a reference image of a successfull account created in the + SubWallet extension: + + + + ![SubWallet account succesfully created](/images/how-to-guide/setup-wallet/subwallet-created-successfully.png) + + + +### 3. Adding Torus to the Subwallet + + +1. **Open the Subwallet Setup**: + Click in the three bars(**☰**) on the top left corner of the subwallet extension. + ![SubWallet setup button](/images/how-to-guide/setup-wallet/subwallet-open-setup.png) + +2. **Select Manage Networks**: + Under the **Assets & Addresses** tab, click on **Manage Networks**. + ![SubWallet manage networks button](/images/how-to-guide/setup-wallet/subwallet-select-config-to-add-network.png) + +3. **Search for Torus and activate it**: + Click on the search bar, type Torus, and select it from the list. Make sure to enable it so it appears in your list of active tokens. + ![SubWallet search for Torus button](/images/how-to-guide/setup-wallet/subwallet-search-torus-network.png) + +4. **Confirm Torus is active**: + Once enabled, **Torus** will appear in your list of active networks. + You mihgt have to scroll down to find Torus in the list. + You're now ready to interact with the Torus ecosystem using your SubWallet. + ![SubWallet network list with torus](/images/how-to-guide/setup-wallet/subwallet-done-torus-setup.png) + + + + + +## Support and Resources + +For further assistance, you can access detailed tutorials and user guides on the [SubWallet Documentation page](https://docs.subwallet.app/main). Additionally, community support is available through channels like Telegram, Discord, and YouTube. + +By following these steps, you can effectively set up and start using your SubWallet to manage, receive, and send assets across multiple blockchain networks, ensuring a secure and efficient digital asset management experience. + + + +## Other Supported Wallets + +While this guide uses SubWallet, other wallets are also compatible with the Torus Network. +The list below includes some of the most known and tested options, but it may not cover every possible wallet. + +These wallets are not officially endorsed, and while they are known to work with Substrate networks, we recommend using them only if you're already familiar or willing to explore. + +- [Polkadot.js Extension](https://polkadot.js.org/extension/). + The official extension for Substrate-based networks. Well-supported and reliable for Torus. +- [Talisman](https://talisman.xyz/). + A modern wallet for the Polkadot ecosystem with a user-friendly interface and Torus compatibility. +- [Nova Wallet](https://novawallet.io/). + Mobile-only (iOS/Android), good for monitoring and mobile usage. Not recommended for browser dApps. +- [Ledger (via Polkadot.js)](https://wiki.polkadot.network/docs/learn-ledger). + For advanced users, hardware wallet support via Polkadot.js ensures enhanced security.