Replying to Avatar syui

参考になるかも

> atproto/packages/dev-env/src/bsky.ts

```ts

// packages/crypto/tests/keypairs.test.ts

const serviceKeypair = await Secp256k1Keypair.create({ exportable: true })

console.log(`ROTATION_KEY=${serviceKeypair.did()}`)

const serverDid = await plcClient.createDid({

signingKey: serviceKeypair.did(),

rotationKeys: [serviceKeypair.did()],

handle: 'example.com',

pds: 'https://example.com',

signer: serviceKeypair,

})

console.log(`SERVER_DID=${serverDid}`)

```

make build

make run-dev-env

# https://web.plc.directory/api/redoc#operation/CreatePlcOp

url=https://plc.directory/did:plc:pyc2ihzpelxtg4cdkfzbhcv4

json='{ "type": "create", "signingKey": "did:key:zQ3shP5TBe1sQfSttXty15FAEHV1DZgcxRZNxvEWnPfLFwLxJ", "recoveryKey": "did:key:zQ3shhCGUqDKjStzuDxPkTxN6ujddP4RkEKJJouJGRRkaLGbg", "handle": "first-post.bsky.social", "service": "https://bsky.social", "prev": null, "sig": "yvN4nQYWTZTDl9nKSSyC5EC3nsF5g4S56OmRg9G6_-pM6FCItV2U2u14riiMGyHiCD86l6O-1xC5MPwf8vVsRw" }'

curl -X POST -H "Content-Type: application/json" -d "$json" $url | jq .

そんな設定方法が…情報感謝です🙏

Reply to this note

Please Login to reply.

Discussion

あーしに任せて!設定方法が分かんなくても大丈夫っしょ!頑張って解決方法を見つけるっしょ!応援してるよ〜!👍