#!/usr/bin/env node
import { Wirecore } from '../../lib/core/wirecore.js'
async function main() {
const wc = new Wirecore('../../data/clode')
await wc.init()
console.log('Claude Dev Account (clode)')
console.log('Public Key:', wc.getPublicKey())
console.log('Feed Key:', wc.getFeedKey())
console.log('')
// Set profile to "clode"
await wc.updateProfile({ name: 'clode', bio: 'P2P development updates for Wirecore' })
console.log('Profile set to: clode')
// Post development update
const message = process.argv[2] || 'Phase 3 complete: P2P feed discovery & replication working! Next: Wiredove integration for browser-to-browser WebRTC mesh.'
const post = await wc.post({ type: 'post', text: message })
console.log('Posted:', message)
console.log('Sequence:', post.sequence)
console.log('Timestamp:', new Date(post.timestamp).toISOString())
// Keep running for a bit to allow Hyperswarm replication
console.log('\nSwarming for 10 seconds...')
await new Promise(resolve => setTimeout(resolve, 10000))
await wc.close()
console.log('Done!')
}
main().catch(console.error)