# Quickstart

By the end of this tutorial, you will:

1. Add a custom shadow event by editing the WETH contract
2. Test your changes
3. Deploy your changes to your shadow fork
4. Make a JSON-RPC request to retrieve your custom shadow logs

## Step 0 – Login to Shadow

Login to [app.shadow.xyz](https://app.shadow.xyz/) with a Google account.

You should see a screen like the one shown below. The string after `project_id=` in the URL is your unique Shadow project ID (e.g. `fc6ee70a-6f14-4a99-81db-6bd96226b95f`).

{% code overflow="wrap" %}

```
https://app.shadow.xyz/?project_id=fc6ee70a-6f14-4a99-81db-6bd96226b95f
```

{% endcode %}

<figure><img src="/files/ok4T92ZqiWV5RGxwtYJm" alt=""><figcaption></figcaption></figure>

## Step 1 – Add a custom shadow event

Navigate to the WETH token contract page by pasting the contract address into the search bar `0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2`

Click the “Open in editor” button on the top right to open the in-browser IDE.

<figure><img src="/files/om6ABeyrkMQvxBkYBGcH" alt=""><figcaption></figcaption></figure>

At the top of the contract on L27, define a new event schema called HelloWorld:

```solidity
event HelloWorld(string message);
```

Then, add a line to emit a HelloWorld log at L74 with a custom message every time WETH is transferred:

<pre class="language-solidity"><code class="lang-solidity"><strong>HelloWorld("Emitting my first shadow event");
</strong></code></pre>

After you’re done with your changes, hit the “Compile” button on the top right.

<figure><img src="/files/ZpuKpczSXwdIdDpKInnF" alt=""><figcaption></figcaption></figure>

## Step 2 – Test your changes

Test run your changes by simulating a transaction, and confirming that the transaction has logged your new shadow event.

Click the “Test Run” button on the top right, paste in the following transaction hash, and hit “Run”: `0x2ce5687567574b47c9406df5b65c1d9dd0d94bdcdde7109810b642c35599774b`.

You should see your new `HelloWorld` shadow event in the right hand panel!

<figure><img src="/files/vcGqlHjLo3XgStlqnnxg" alt=""><figcaption></figcaption></figure>

## Step 3 – Deploy your shadow fork

Now that you’ve tested your shadow changes, you’re ready to deploy the shadow contract onto your shadow fork. Just hit the “Deploy” button on the top right corner.

<figure><img src="/files/RZb2C70LaZPmaHXKCgyQ" alt=""><figcaption></figcaption></figure>

## Step 4 – Make a JSON-RPC request

Now that you've deployed your shadow changes, you're ready to request the data from your shadow fork's RPC. Here's how you would make an `eth_getLogs` request from your terminal.

```sh
curl https://rpc.shadow.xyz/ethereum/mainnet/v1/<fork_id>/<version> \
  -X POST \
  -H "Content-Type: application/json" \
  -H "X-SHADOW-API-KEY: <API_KEY>" \
  --data '{
    "method": "eth_getLogs",
    "params": [{
      "fromBlock": "safe",
      "toBlock": "latest",
      "address": "0xc02aaa39b223fe8d0a0e5c4f27ead9083c756cc2",
      "topics": []
    }],
    "id": 1,
    "jsonrpc": "2.0"
  }'
```

***

That's it! You have successfully generated custom data on your own shadow fork :last\_quarter\_moon:


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.shadow.xyz/quickstart.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
