# Simple Node

Every domain name will store data in GUN as per the following schema:

```js
const gun = Gun({
    peers: ['gun-seed-1.auti.sm/gun'],
});

gun.user().auth({
    pub: 'my-public-key',
    priv: 'my-private-key',
});

user.put({  
    message: {  
    	[messageHash]: Message  
    }  
});  
```

Anyone can run a client and observe the AutismRegister contract to get all names with a valid `pubkey` record, and then observe and store all updates from the public key associated with the identity to provide reliable data duplication for the network:

```
const contractABI = [
    {
        "anonymous": false,
        "inputs": [
            {
                "indexed": true,
                "internalType": "address",
                "name": "account",
                "type": "address"
            },
            {
                "indexed": false,
                "internalType": "bytes",
                "name": "value",
                "type": "bytes"
            },
            {
                "indexed": false,
                "internalType": "bytes",
                "name": "proof",
                "type": "bytes"
            },
            {
                "indexed": false,
                "internalType": "address",
                "name": "relayer",
                "type": "address"
            }
        ],
        "name": "RecordUpdatedFor",
        "type": "event"
    }
];

const contractAddress = "0x6b0a11F9aA5aa275f16e44e1D479A59dd00abE58";

const registrar = new new Web3().eth.Contract(
    contractABI,
    contractAddress,
);

const gun = Gun({
    peers: ['gun-seed-1.auti.sm/gun'],
});

registrar
    .getPastEvents('RecordUpdatedFor', {
        fromBlock: 2193241,
    })
    .forEach(event => {
        const pubkeyBytes = event.returnValues.value;
        const account = event.returnValues.account;
        const pubkey = Web3.utils.hexToUtf8(pubkeyBytes);
        const user = gun.user(ecdsaPubKey);
        
        user.get('message')
            .map((data, messageId) => {
                // data = Message
                // messageId = "<creator>/<messageHash>"
            });
    });
    


```

By default, we will run 2 full nodes in North America, 2 in Asia, and 2 in Europe to provide reliable global coverage. These 6 nodes will become the bootstrap peers for anyone trying to connect to Autism.


---

# 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.zkitter.com/developers/data/simple-node.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.
