Mach API Endpoints
Get Gas Estimate
Estimates gas costs for a specific chain
GET
This endpoint provides an estimation of gas costs for a specific blockchain. It returns the gas estimate and gas price in the chain’s native format, which can be used to calculate the total gas cost for transactions on that chain.
Query Parameters
The chain identifier (e.g., “avalanche”, “ethereum”)
Response
Estimated gas units required for a typical transaction
Current gas price in the chain’s native format (e.g., wei)
Status Codes
| Status Code | Description |
|---|---|
| 200 | Success - Gas estimate returned successfully |
| 422 | Validation Error - Invalid chain parameter |
| 500 | Internal Server Error - Something went wrong on the server |