create_order
Buy energy or bandwidth at the Merx market quote. Confirmed Merx funds and API key required; no commission.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"resource_type": "<resource_type>",
"amount": "<amount>",
"duration_sec": "<duration_sec>",
"target_address": "<target_address>",
"idempotency_key": "<idempotency_key>"
},
"name": "create_order"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| amount | Yes | Amount of resource units (min 65000 for ENERGY, 1000 for BANDWIDTH). | |
| duration_sec | Yes | Rental duration in seconds on the fixed market grid, from 2 minutes through 24 hours. | |
| max_price_sun | No | Optional offered price in SUN/unit. Below-current offers fail; equal or higher offers execute at the submitted price. Omit to use the current best price. | |
| resource_type | Yes | Resource type to purchase. | |
| target_address | Yes | TRON address to receive delegated resources. | |
| idempotency_key | Yes | Unique operation ID (1–200 characters). Reuse this exact value when retrying after a timeout or lost response. |