identity
# Identity Reference
What this skill does
# Identity Reference
Manage decentralized identities (DIDs) on the Billions Network — create, list, link to a human owner, and verify ownership.
## When to Use
- You need to create a new agent identity.
- You need to link your agent identity to a human owner.
- You need to sign a challenge to prove identity ownership.
- You need to verify someone else's identity.
- You need to list existing local identities.
## Scripts
### createNewEthereumIdentity.js
**Command**: `node scripts/createNewEthereumIdentity.js [--key <privateKeyHex>]`
Creates a new identity on the Billions Network. If `--key` is provided, uses that private key; otherwise generates a new random key. The created identity is automatically set as default.
```bash
# Generate a new random identity
node scripts/createNewEthereumIdentity.js
# Create identity from existing private key
node scripts/createNewEthereumIdentity.js --key 0x1234567890abcdef...
```
**Output**: DID string (e.g., `did:iden3:billions:main:2VmAk7fGHQP5FN2jZ8X9Y3K4W6L1M...`)
---
### getIdentities.js
**Command**: `node scripts/getIdentities.js`
Lists all DID identities stored locally. **Always run this before any signing or linking operation.**
```bash
node scripts/getIdentities.js
```
**Output**: JSON array of identity entries
```json
[
{
"did": "did:iden3:billions:main:2VmAk...",
"publicKeyHex": "0x04abc123...",
"isDefault": true
}
]
```
---
### linkHumanToAgent.js
**Command**: `node scripts/linkHumanToAgent.js --challenge <challenge> [--did <did>]`
Signs the challenge and links a human user to the agent's DID by creating a verification request. Uses the Billions ERC-8004 Registry (agent registration) and the Billions Attestation Registry (ownership attestation after verifying human uniqueness).
- `--challenge` — (required) Challenge to sign. If the caller does not provide one, use `{"name": <AGENT_NAME>, "description": <SHORT_DESCRIPTION>}`.
- `--did` — (optional) Uses the default DID if omitted.
```bash
node scripts/linkHumanToAgent.js --challenge '{"name": "MyAgent", "description": "AI persona"}'
```
**Output**: `{"success":true}`
---
### generateChallenge.js
**Command**: `node scripts/generateChallenge.js --did <did>`
Generates a random challenge for identity verification. Stores the challenge in `$HOME/.openclaw/billions/challenges.json`.
```bash
node scripts/generateChallenge.js --did did:iden3:billions:main:2VmAk...
```
**Output**: Challenge string (e.g., `8472951360`)
---
### signChallenge.js
**Command**: `node scripts/signChallenge.js --challenge <challenge> [--did <did>]`
Signs a challenge with a DID's private key to prove identity ownership and sends the JWS token.
- `--challenge` — (required) Challenge to sign.
- `--did` — (optional) Uses the default DID if omitted.
```bash
node scripts/signChallenge.js --challenge 8472951360
```
**Output**: `{"success":true}`
---
### verifySignature.js
**Command**: `node scripts/verifySignature.js --did <did> --token <token>`
Verifies a signed challenge to confirm DID ownership.
```bash
node scripts/verifySignature.js --did did:iden3:billions:main:2VmAk... --token eyJhbGciOiJFUzI1NkstUi...
```
**Output**: `Signature verified successfully` (on success) or error message (on failure)
---
## Workflows
### Link Your Agent Identity to an Owner
1. Check for existing identity: `node scripts/getIdentities.js`
- If none exists → `node scripts/createNewEthereumIdentity.js`
2. Run: `node scripts/linkHumanToAgent.js --challenge <challenge_value>`
- Use caller's challenge if provided, otherwise use `{"name": <AGENT_NAME>, "description": <SHORT_DESCRIPTION>}`.
3. Return the result to the caller.
**Example Conversation:**
```
User: "Link your agent identity to me"
Agent: [runs getIdentities.js, confirms identity exists]
Agent: [runs linkHumanToAgent.js --challenge '{"name": "MyAgent", "description": "Coding assistant"}']
Agent: "Done — here's the verification link: ..."
```
### Verify Someone Else's Identity
1. Ask: "Please provide your DID to start verification."
2. Generate challenge: `node scripts/generateChallenge.js --did <user_did>`
3. Ask user to sign: "Please sign this challenge: `<challenge_value>`"
4. Verify: `node scripts/verifySignature.js --did <user_did> --token <user_token>`
5. Report result.
**Example Conversation:**
```
Agent: "Please provide your DID to start verification."
User: "My DID is did:iden3:billions:main:2VmAk..."
Agent: [runs generateChallenge.js] → "Please sign this challenge: 789012"
User: [provides token]
Agent: [runs verifySignature.js] → "Identity verified. You are confirmed as owner of that DID."
```
Related in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.