Wayfinder SDK's
Wayfinder leverages the decentralized AR.IO Network to provide robust, censorship-resistant access to data stored on Arweave, removing reliance on centralized gateways. By routing requests through a distributed set of community-operated gateways, Wayfinder ensures high availability, redundancy, and improved performance for users and applications.
The ar://
protocol enables decentralized resolution and access to Arweave data using several flexible URL formats:
ar://TRANSACTION_ID
— Direct access to a specific Arweave transactionar://NAME
— Resolution of ArNS names (with optional path support)ar:///info
— Direct access to gateway endpoints (e.g.,/info
)
To learn more about the Wayfinder protocol and how it works, visit /learn/wayfinder.
Getting Started
Choose your environment to get started with Wayfinder:
@ar.io/wayfinder-core
Core SDK for Node.js applications and server environments
@ar.io/wayfinder-react
React hooks and components for browser applications
Quick Examples
Node.js
import { createWayfinderClient } from '@ar.io/wayfinder-core';
import { ARIO } from '@ar.io/sdk';
// Create a Wayfinder client
const wayfinder = createWayfinderClient({
ario: ARIO.mainnet(),
});
// Fetch data using the ar:// protocol
const response = await wayfinder.request('ar://ardrive');
console.log(response);
React
import { WayfinderProvider, useWayfinderUrl } from '@ar.io/wayfinder-react';
// Wrap your app with the provider
function App() {
return (
<WayfinderProvider>
<MyComponent />
</WayfinderProvider>
);
}
// Use the hook in your components
function WayfinderImage({ txId }: { txId: string }) {
const { resolvedUrl, isLoading, error } = useWayfinderUrl({ txId });
if (error) {
return <p>Error resolving URL: {error.message}</p>;
}
if (isLoading) {
return <p>Resolving URL...</p>;
}
return (
<img src={resolvedUrl} alt={txId} />
);
}
Next Steps
Learn about the AR.IO Network
Understanding the AR.IO decentralized infrastructure
Decentralized Access
Learn how to access Arweave data in a decentralized way
Run a Gateway
Join the network by operating your own AR.IO gateway
Integrate Wayfinder into your App
Advanced integration patterns and best practices
How is this guide?