Siwa Private Key

Raw private key signer using viem LocalAccount for SIWA authentication.

43 stars 12 forksOther

Install

skills CLI (Claude Code, Cursor, Codex and more)
npx skills add builders-garden/siwa --skill siwa-private-key
Manual install
git clone --depth 1 https://github.com/builders-garden/siwa.git /tmp/siwa
mkdir -p ~/.claude/skills
cp -r /tmp/siwa/packages/siwa-skill/private-key ~/.claude/skills/siwa-private-key

Personal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.

From the SKILL.md

# SIWA Private Key Signer

Sign SIWA messages using a raw private key via viem's LocalAccount.

## Install

```bash
npm install @buildersgarden/siwa viem
```

## Create Signer

```typescript
import { createLocalAccountSigner } from "@buildersgarden/siwa/signer";
import { privateKeyToAccount } from "viem/accounts";

const account = privateKeyToAccount(process.env.PRIVATE_KEY as `0x${string}`);
const signer = createLocalAccountSigner(account);
```

## Register as ERC-8004 Agent

If your agent doesn't have an ERC-8004 identity yet, register onchain first:

```typescript
import { registerAgent } from "@buildersgarden/siwa/registry";

const result = await registerAgent({
  agentURI: "data:application/json;base64,...",  // or ipfs://...
  chainId: 84532,  // Base Sepolia
  signer,
});

console.log("Agent ID:", result.agentId);
console.log("Registry:", result.agentRegistry);
console.log("Tx Hash:", result.txHash);
```

The `agentURI` contains your agent's metadata (name, description, capabilities). You can use a base64 data URI or IPFS.

---

## SIWA Authentication Flow

The authentication flow consists of two steps:

> **Note:** The URLs below (`api.example.com`) are placeholders. Replace them with your own server that implements the SIWA verification endpoints. See the [Server-Side Verification](https://siwa.id/skills/server-side/skill.md) skill for implementation details.

1. **Get a nonce** from the server's `/siwa/nonce` endpoint
Read the full skill on GitHub

Details

Skill name
siwa-private-key
Path
packages/siwa-skill/private-key/SKILL.md
License
MIT
Repo updated
29 April 2026

FAQ

What does the Siwa Private Key skill do?

Raw private key signer using viem LocalAccount for SIWA authentication.

How do I install the Siwa Private Key skill?

skills CLI (Claude Code, Cursor, Codex and more): npx skills add builders-garden/siwa --skill siwa-private-key. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.

Is Siwa Private Key popular?

It lives in builders-garden/siwa, which has 43 GitHub stars and 12 forks.

Related skills

Browse the most popular Claude skills, all other skills, or write your own with the skills generator.