> ## Documentation Index
> Fetch the complete documentation index at: https://docs.dolphinclaw.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Deploy your first AI agent on Dolphinclaw platform

> Create your account, fund your BNB wallet, write your first agent, and deploy it to the Dolphinclaw platform in under two minutes.

This guide walks you through the full flow from creating an account to having a running agent on Dolphinclaw. By the end, you will have a deployed agent that logs output to your dashboard and, optionally, appears in the marketplace.

<Steps>
  <Step title="Sign up at dolphinclaw.io">
    Go to [dolphinclaw.io](https://dolphinclaw.io) and create an account. As soon as your account is created, Dolphinclaw generates a secure BNB wallet for you automatically. You do not need MetaMask or any external wallet extension to get started.
  </Step>

  <Step title="Deposit BNB">
    Open the **Wallet** section of your dashboard and copy your wallet address. Send BNB to that address to fund your account. You need a positive BNB balance to run agents — either your own or ones you rent from the marketplace.
  </Step>

  <Step title="Create an agent">
    In the dashboard, click **New Agent** and fill in:

    * **Name** — a unique identifier for your agent.
    * **Hourly price** — the amount in BNB charged per hour of execution. Set this to `0` if you are building a private agent.
    * **Entry file** — the file Dolphinclaw will run. Defaults to `index.js`.

    Dolphinclaw creates a private Git repository for your agent as part of this step.
  </Step>

  <Step title="Write your agent code">
    A Dolphinclaw agent is a standard Node.js script. Install `@dolphinclaw/sdk` in your project and use it to send logs and results to the dashboard.

    ```bash theme={null}
    npm install @dolphinclaw/sdk
    ```

    Here is a minimal working agent you can use as a starting point:

    ```javascript theme={null}
    const sdk = require('@dolphinclaw/sdk');

    sdk.log('Agent started successfully');

    // Main agent logic
    setInterval(() => {
      sdk.log('Scanning market data...');

      if (Math.random() > 0.7) {
        sdk.success('Arbitrage opportunity found!', {
          profit: "0.05 ETH",
          pair: "WETH/USDC"
        });
      }
    }, 5000);

    // Handle graceful shutdown (SIGTERM)
    process.on('SIGTERM', () => {
      sdk.log('SIGTERM received. Cleaning up...');
      process.exit(0);
    });
    ```

    Make sure your repository has a `package.json` at the root and that `@dolphinclaw/sdk` is listed as a dependency. Dolphinclaw runs `npm install` automatically before launching your agent.

    <Tip>
      Handle `SIGTERM` in long-running agents. When you stop an agent from the dashboard, Dolphinclaw sends a `SIGTERM` signal and waits up to 10 seconds for a clean exit. Use this window to flush state, close connections, or log a final status before the container is terminated.
    </Tip>
  </Step>

  <Step title="Deploy your agent">
    Push your code using one of two methods:

    * **Dashboard editor** — write and commit code directly in the browser using Dolphinclaw Deployed Tools.
    * **GitHub import** — connect a GitHub repository and import it into your agent's private repository.

    Once your code is pushed, click **Deploy** in the dashboard. Dolphinclaw installs your dependencies, starts the container, and begins streaming logs to your terminal view.
  </Step>

  <Step title="Go public (optional)">
    To make your agent available in the marketplace, toggle **Publicly Visible** on your agent's settings page. This submits your agent to the curation queue. Once approved, your agent appears in the marketplace and other users can rent it at the hourly rate you set.
  </Step>
</Steps>

For a full reference on SDK methods including `log`, `success`, `warn`, `error`, and `reportResult`, see the [SDK reference](/building/sdk).
