Home

Ethereum method - eth_chainId

POST
https://eth-sepolia.nownodes.io/

Authorizations

ApiKeyAuthApiKeyAuth

api-key string

NOWNodes API key passed in the api-key header.

Returns the hexadecimal string of the current chain ID.

Body

application/json

Returns the hexadecimal string of the current chain ID.

Request payload for Returns the hexadecimal string of the current chain ID..

jsonrpcstringrequired

JSON-RPC protocol version

methodstringrequired

Name of the method to call

paramsarrayrequired

This method does not require parameters. Use an empty array.

idintegerrequired

Unique identifier for the request

Response

200OK

Chain ID response

401Unauthorized

Unauthorized: API key is present but rejected by the NOWNodes gateway.

405Method Not Allowed

Method Not Allowed. Returned by the NOWNodes gateway for malformed or unsupported gateway-level requests.

422Unprocessable Entity

Missing API key. The NOWNodes gateway returns plain text for this error.

500Internal Server Error

Upstream node or gateway error.