> For the complete documentation index, see [llms.txt](https://docs.validator247.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.validator247.com/testnet/autonity.md).

# Autonity

### Get setup to access your CAX account

Install

```
sudo apt install snapd
sudo apt install python3-pip
pip install httpie==3.2.2
http --version
```

Get API KEY

```
MESSAGE=$(jq -nc --arg nonce "$(date +%s%N)" '$ARGS.named')
aut account sign-message $MESSAGE message.sig -k $HOME/.autonity/keystore/tresure.key > message.sig
echo -n $MESSAGE | https https://cax.piccadilly.autonity.org/api/apikeys api-sig:@message.sig
```

```
KEY=API_KEY
```

View your tresure.key wallet balance

```
aut account info -k $HOME/.autonity/keystore/tresure.key
```

## View off-chain CAX balance

```
https GET https://cax.piccadilly.autonity.org/api/balances/ API-Key:$KEY
```

## Deposit USDC to CAX

```
aut token transfer --token 0x3a60C03a86eEAe30501ce1af04a6C04Cf0188700 0x11F62c273dD23dbe4D1713C5629fc35713Aa5a94 USDC_AMOUNT | aut tx sign - | aut tx send -
```

## View orderbooks

```
https GET https://cax.piccadilly.autonity.org/api/orderbooks/ API-Key:$KEY
```

## Getting current price of NTN-USDC

```
https GET https://cax.piccadilly.autonity.org/api/orderbooks/NTN-USDC/quote API-Key:$KEY
```

## Buy NTN with limit-order

```
https POST https://cax.piccadilly.autonity.org/api/orders/ API-Key:$KEY pair=NTN-USDC side=bid price=NTN_PRICE amount=NTN_AMOUNT
```

## Check order (Enter order ID from previous step)

```
https GET https://cax.piccadilly.autonity.org/api/orders/ORDER_ID API-Key:$KEY
```

## Cancel open order

```
https DELETE https://cax.piccadilly.autonity.org/api/orders/ORDER_ID API-Key:$KEY
```

## Withdraw

```
https POST https://cax.piccadilly.autonity.org/api/withdraws API-Key:$KEY symbol=NTN  amount=NTN_AMOUNT
```

## Bond NTN to validator

```
aut validator bond --validator VALIDATOR_ADDRESS NTN AMOUNT | aut tx sign - | aut tx send -
```

Or&#x20;

```
aut validator bond <Amount> | aut tx sign - | aut tx send -
```

## Unbond&#x20;

```
aut validator unbond --validator <VALIDATOR_IDENTIFIER_ADDRESS> <AMOUNT> | aut tx sign - | aut tx send -
```

Transfer USDC&#x20;

```
aut token transfer --token 0x3a60C03a86eEAe30501ce1af04a6C04Cf0188700 0x799af677770d436b265af0b851ad38f04f2b167a 999996 | aut tx sign - | aut tx send -
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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.validator247.com/testnet/autonity.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.
