I was following these steps
and this code
import { CeramicClient } from '@ceramicnetwork/http-client'
import { readEncodedComposite } from '@composedb/devtools-node'
import { DID } from 'dids'
import { Ed25519Provider } from 'key-did-provider-ed25519'
import { getResolver } from 'key-did-resolver'
import { fromString } from 'uint8arrays/from-string'
// Hexadecimal-encoded private key for a DID having admin access to the target Ceramic node
// Replace the example key here by your admin private key
const privateKey = fromString('b0cb[...]515f')
const did = new DID({
resolver: getResolver(),
provider: new Ed25519Provider(privateKey),
})
await did.authenticate()
// Replace by the URL of the Ceramic node you want to deploy the Models to
const ceramic = new CeramicClient('http://localhost:7007')
// An authenticated DID with admin access must be set on the Ceramic instance
ceramic.did = did
// Replace by the path to the local encoded composite file
const composite = await readEncodedComposite(ceramic, 'my-first-composite.json')
// Notify the Ceramic node to index the models present in the composite
await composite.startIndexingOn(ceramic)
only worked with this change
const privateKey = fromString('b0cb[...]515f', "base16")
NOTE: the key I was using was
b982fe675a206d5654b7548834174f0fa091c3258879f08afcec9d2a890e397b
of course I have changed it now.
I hope this helps the docs, otherwise I’d love to know where I went wrong.
Thanks