viem

Configure Viem clients for Celo mainnet and Sepolia testnet.

8|4|Updated Jan 27, 2026
One-click install
npx skills add https://github.com/celo-org/agent-skills --skill viem-celo-org
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: viem
Source: https://github.com/celo-org/agent-skills/tree/main/skills/viem
Command: npx skills add https://github.com/celo-org/agent-skills --skill viem-celo-org

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

Viem for Celo enables developers to build type-safe dApps and tooling that interact with the Celo blockchain using a modern TypeScript library.

Core Features & Use Cases

  • Type-safe chain configuration and client setup with Viem for Celo mainnet and Sepolia testnet.
  • Fee currency support and CIP-64 transaction handling for paying gas with USDC/USDT on Celo.
  • Read and write contract data, sign messages, and manage transactions within a TypeScript project.

Quick Start

Install Viem in your project with npm install viem and configure a public or wallet client for the Celo chain using Viem's chain definitions and a transport (e.g., http).

Frequently Asked Questions about viem

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I build type-safe dApps on Celo with TypeScript?

Viem for Celo provides type-safe chain configuration and client setup for Celo mainnet and Sepolia testnet. Install viem via npm, configure a public or wallet client using Viem's Celo chain definitions, and use TypeScript's type system to catch errors during development and contract interactions.

Can I pay gas fees with USDC or USDT on Celo?

Yes. Viem for Celo supports CIP-64 transaction handling and fee currency configuration, enabling you to pay gas with USDC or USDT instead of the native asset. Configure the fee currency in your transaction objects when signing and submitting transactions.

How do I read and write contract data on Celo using Viem?

Viem for Celo lets you read contract state and write data by setting up a public client for reads and a wallet client for writes. Use Viem's contract utilities with your contract ABI and address to call functions, sign messages, and manage transactions within your TypeScript project.

What's required to start using Viem for Celo development?

Install Viem via npm and integrate it into a TypeScript project. You need Viem's Celo chain definitions and a transport layer (e.g., http endpoint). No additional blockchain tools are required; Viem handles type-safe interactions with mainnet and testnets.

Does Viem work with both Celo mainnet and testnet?

Yes. Viem for Celo supports both Celo mainnet and Sepolia testnet through built-in chain definitions. Switch between networks by selecting the appropriate chain configuration when instantiating your public or wallet client.

Why use Viem instead of web3.js or ethers.js for Celo?

Viem for Celo provides modern TypeScript-first design with full type safety, native CIP-64 fee currency support, and optimized performance. It's purpose-built for type-safe Celo development and handles Celo-specific features like alternate fee currencies automatically.