Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ src/pages.gen.ts
.env
.vercel
.vocs

.env*.local
src/pages/protocol/tips/tip-*

# Playwright
Expand Down
27 changes: 24 additions & 3 deletions biome.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
{
"$schema": "https://biomejs.dev/schemas/2.3.11/schema.json",
"assist": { "actions": { "source": { "organizeImports": "on" } } },
"assist": {
"actions": {
"source": {
"organizeImports": "on"
}
}
},
"formatter": {
"enabled": true,
"indentStyle": "space",
Expand All @@ -15,7 +21,9 @@
}
},
"css": {
"parser": { "tailwindDirectives": true },
"parser": {
"tailwindDirectives": true
},
"formatter": {
"enabled": true
},
Expand All @@ -41,5 +49,18 @@
"files": {
"ignoreUnknown": false,
"includes": ["**", "!dist", "!node_modules", "!specs/lib", "!src/snippets/unformatted"]
}
},
"overrides": [
{
"includes": ["env.d.ts"],
"linter": {
"rules": {
"recommended": true,
"correctness": {
"noUnusedVariables": "off"
}
}
}
}
]
}
26 changes: 26 additions & 0 deletions env.d.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
interface EnvironmentVariables {
readonly NODE_ENV: 'development' | 'production' | 'test'

readonly VITE_BASE_URL: string
readonly VITE_POSTHOG_KEY: string
readonly VITE_POSTHOG_HOST: string
readonly VITE_TEMPO_ENV: 'localnet' | 'devnet' | 'moderato'

readonly INDEXSUPPLY_API_KEY: string
readonly SLACK_FEEDBACK_WEBHOOK: string

readonly VERCEL_URL: string
readonly VERCEL_BRANCH_URL: string
readonly VERCEL_PROJECT_PRODUCTION_URL: string
readonly VERCEL_ENV: 'development' | 'production' | 'preview'
}

declare namespace NodeJS {
interface ProcessEnv extends EnvironmentVariables {}
}

interface ImportMetaEnv extends EnvironmentVariables {}

interface ImportMeta {
readonly env: ImportMetaEnv
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@
"@vitejs/plugin-react": "^5.1.2",
"anser": "^2.3.5",
"tsx": "^4.21.0",
"typescript": "~5.9.3",
"typescript": "^5.9.3",
"use-sync-external-store": "^1.6.0",
"vite": "^7.3.1"
},
Expand Down
71 changes: 36 additions & 35 deletions pnpm-lock.yaml

Large diffs are not rendered by default.

7 changes: 5 additions & 2 deletions src/pages/guide/node/installation.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,11 @@ The versions across networks may not be compatible, as such, please consult the

| Network | Version |
|----------|---------|
| Andantino | v0.8.2 |
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Andantino still exists on v0.8.2 with --chain andantino

| Moderato | v1.0.0-rc.1 |
| Moderato (Testnet) | v1.1.0 |

:::warning
The `andantino` chainspec has been removed as of v1.1.0. Testnet nodes must use `--chain moderato`.
:::

## Pre-built Binary

Expand Down
10 changes: 10 additions & 0 deletions src/pages/guide/node/operate-validator.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,16 @@ The old validator identity must be deactivated before the new one is activated
If you lose your signing share (stored on the database in `<datadir>/consensus/`), you will need to rotate to a new validator identity. This requires coordinating with the Tempo team to deactivate your old identity and register a new one.
We're planning to release a high-availability feature that allows storing consensus data in an external database, which will enable signing share recovery without the need for key rotation.

### Deleting Signing Shares

:::warning[Breaking Change in v1.1.0]
`--delete-signing-share` now requires the `--force` flag to prevent accidental deletion of validator signing keys. **Update any automation scripts that manage validator key lifecycle.**
:::

```bash
tempo consensus --delete-signing-share --force
```

## Log Management

### Parsing Logs
Expand Down
8 changes: 6 additions & 2 deletions src/pages/guide/node/validator.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -38,19 +38,23 @@ The public key should match the output of the `generate-private-key` command.

The process for running a validator node is very similar to [running a full node](/guide/node/rpc).

You should start by downloading the latest snapshot using `tempo download --chain <moderato|mainnet>`. Downloading the snapshot allows your validator to start participating in consensus much faster.
You should start by downloading the latest snapshot using `tempo download --chain <moderato|mainnet|devnet>`. Downloading the snapshot allows your validator to start participating in consensus much faster.
Once you've downloaded the snapshot and have been whitelisted on-chain, you can proceed to run the validator node as such:

```bash
tempo node --datadir <datadir> \
--chain <moderato|mainnet> \
--chain moderato \
--port 30303 \
--discovery.addr 0.0.0.0 \
--discovery.port 30303 \
--consensus.signing-key <path> \
--consensus.fee-recipient <validator_wallet_address> \
```

:::warning[Testnet Chain Name Change]
As of v1.1.0, testnet nodes must use `--chain moderato`. The previous `andantino` chainspec has been removed.
:::

The notable difference between RPC nodes and validator nodes is the omission of the `--follow` argument and the addition of the `--consensus.signing-key` and `--consensus.fee-recipient` arguments. The fee recipient is the address that will receive transaction fees in your validators' proposed blocks.

Once your node is up, it may not start syncing immediately. This is because your node might not be part of the active set. In most cases, your validator will enter the active set in under 6 hours after the on-chain addition of the validator identity.
Expand Down
46 changes: 42 additions & 4 deletions src/pages/guide/payments/send-parallel-transactions.mdx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
description: Submit multiple transactions concurrently using Tempo's 2D nonce system. Use nonce keys to avoid waiting for sequential confirmations.
description: Submit multiple transactions concurrently using Tempo's nonce system. Choose between 2D nonces for ordered sequences or expiring nonces for fire-and-forget.
---

import * as Demo from '../../../components/guides/Demo.tsx'
Expand All @@ -9,11 +9,49 @@ import { Cards, Card } from 'vocs'

# Send Parallel Transactions

Submit multiple transactions in parallel using Tempo's [2D nonces](/protocol/transactions/spec-tempo-transaction). The `nonceKey` property allow you to send concurrent transactions without waiting for each one to confirm sequentially.
Submit multiple transactions in parallel using Tempo's flexible nonce system. Choose between:

## Understanding nonce keys
- **[2D nonces](/protocol/transactions/spec-tempo-transaction)**: Independent nonce sequences for ordered transaction groups
- **[Expiring nonces](/protocol/tips/tip-1009)**: Time-bounded replay protection for fire-and-forget transactions *(recommended for most use cases)*

Tempo uses a **2D nonce system** that enables parallel transaction execution:
## Expiring Nonces (Recommended)

[TIP-1009](/protocol/tips/tip-1009) introduces expiring nonces: transactions specify a `validBefore` timestamp (max 30s in the future) instead of tracking sequential nonces. This is the simplest approach for parallel submission.

To use expiring nonces, set `nonceKey` to `UINT256_MAX` (`0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff`). This signals to the protocol that the transaction uses time-based replay protection instead of sequential nonces.

:::code-group

```typescript [TypeScript]
const tx = await Actions.token.transfer(config, {
amount: parseUnits('100', 6),
to: recipient,
token: alphaUsd,
nonceKey: BigInt('0xffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff'),
validBefore: Math.floor(Date.now() / 1000) + 30,
})
```

```rust [Rust]
let pending = provider
.send_transaction(TempoTransactionRequest {
nonce_key: Some(U256::MAX),
valid_before: Some(SystemTime::now().duration_since(UNIX_EPOCH).as_secs() + 30),
..Default::default(),
})
.await?;
```

:::code-group

Benefits:
- No nonce tracking required
- Automatic replay protection via circular buffer
- No permanent state bloat from unused nonce keys

## 2D Nonces

For cases requiring ordered sequences within a key, Tempo's **2D nonce system** enables parallel transaction execution:

- **Protocol nonce (key 0)**: The default sequential nonce. Transactions must be processed in order.
- **User nonces (keys 1+)**: Independent nonce sequences that allow concurrent transaction submission.
Expand Down
12 changes: 12 additions & 0 deletions src/pages/protocol/fees/spec-fee.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,18 @@ On the Moderato testnet, validators currently expect alphaUSD (one of the tokens

If validators have not specified a fee token preference, the protocol falls back to expecting pathUSD as their fee token.

## Gas Parameters

As of [TIP-1010](/protocol/tips/tip-1010), Tempo uses the following mainnet gas parameters:

| Parameter | Value |
|-----------|-------|
| Base fee | 20 gwei |
| Total block gas limit | 500M gas |
| General gas limit | 30M gas/block |

A standard TIP-20 transfer costs approximately 0.1 cent at the base fee.

### Removing validator preference

To remove a validator token preference, set it to the zero address:
Expand Down
4 changes: 2 additions & 2 deletions src/pages/protocol/transactions/AccountKeychain.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ The Tempo Transaction type unlocks a number of new signature schemes, including

Access Keys are secondary signing keys authorized by an account's Root Key. They can sign transactions on behalf of the account with the following restrictions:

- **Expiry**: Unix timestamp when the key becomes invalid (0 = never expires)
- **Expiry**: Unix timestamp when the key becomes invalid (0 = never expires, non-zero values must be > current timestamp)
- **Spending Limits**: Per-TIP20 token limits that deplete as tokens are spent
- Limits deplete as tokens are spent and can be updated by the Root Key via `updateSpendingLimit()`
- Spending limits only apply to TIP20 `transfer()`, `transferWithMemo()`, `approve()`, and `startReward()` calls
Expand Down Expand Up @@ -136,7 +136,7 @@ interface IAccountKeychain {
* The protocol enforces this restriction by checking transactionKey[msg.sender]
* @param keyId The key identifier (address) to authorize
* @param signatureType Signature type of the key (0: Secp256k1, 1: P256, 2: WebAuthn)
* @param expiry Unix timestamp when key expires (0 = never expires)
* @param expiry Unix timestamp when key expires (MUST be > current_timestamp, or 0 for never expires)
* @param enforceLimits Whether to enforce spending limits for this key
* @param limits Initial spending limits for tokens (only used if enforceLimits is true)
*/
Expand Down
13 changes: 13 additions & 0 deletions src/pages/quickstart/evm-compatibility.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,19 @@ If a wallet wants to submit a non-TIP20 transaction without having to submit the

At the VM layer, all opcodes are supported out of the box. Due to the lack of a native token, native token balance is always returning zero balances.

### State Creation Costs

Tempo uses higher gas costs for state-creating operations to prevent state growth attacks ([TIP-1000](/protocol/tips/tip-1000)):

| Operation | Tempo | Ethereum |
|-----------|-------|----------|
| New storage slot (SSTORE 0→non-zero) | 250,000 gas | 20,000 gas |
| Account creation | 250,000 gas | 0 gas |
| Contract creation per byte | 1,000 gas | 200 gas |
| Transaction gas cap | 30M gas | 30M gas |

This means transfers to new addresses cost ~300k gas, and contract deployments cost 5-10x more than on Ethereum. Update your `gas_limit` estimates accordingly.

### Balance Opcodes and RPC Methods

| Feature | Behavior on Tempo | Alternatives |
Expand Down
5 changes: 4 additions & 1 deletion src/pages/quickstart/verify-contracts.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,13 @@ View the full API documentation at [contracts.tempo.xyz/docs](https://contracts.
| Network | Chain ID |
|---------|----------|
| Tempo Mainnet | `4217` |
| Tempo Testnet (Andantino) | `42429` |
| Tempo Testnet (Moderato) | `42431` |
| Tempo Devnet | `31318` |

:::info
The `andantino` testnet (chain ID `42429`) has been deprecated. Use `moderato` (chain ID `42431`) for testnet development.
:::

## Troubleshooting

:::tip
Expand Down
Loading