Arbitrum One
¿Listo para usar esto en producción?
El plan gratuito cubre proyectos personales. El pago por uso escala sin necesidad de tarjeta.
Arbitrum One
El plan gratuito cubre proyectos personales. El pago por uso escala sin necesidad de tarjeta.
Every request to the Arbitrum One API on TheRPC must include an API key — it authenticates you and links each call to your plan's quotas and usage metrics. This guide walks through obtaining a key from the dashboard, passing it correctly in the Authorization header on calls to arbitrum.therpc.io, securing it with environment variables and rotation, and recognizing the error responses you get when authentication fails.
https://arbitrum.therpc.io/YOUR_API_KEYYour key travels in the Authorization header using the Bearer scheme — Authorization: Bearer YOUR_API_KEY. Every single request to the Arbitrum One endpoint must include this header; a call without it, or with a malformed value, is rejected before it reaches chain 42161.
When authentication fails, the Arbitrum One API returns a JSON-RPC error object with a negative code and a descriptive message instead of a result (see the example below). The most common causes are a missing Authorization header, an invalid or malformed key, a key that has expired or been revoked from the dashboard, and exceeding your plan's rate limit. Check the error.message to tell these apart quickly.
The recommended setup is to load your Arbitrum One API key from an environment variable rather than hardcoding it in source. Keep the key in a .env file that is excluded from version control, and read it at runtime — the Node.js and Python snippets below show the pattern for pointing your client at arbitrum.therpc.io safely.