quick start

handle=yui.syui.ai
curl -sL "https://bsky.social/xrpc/com.atproto.repo.listRecords?repo=${handle}&collection=app.bsky.feed.post&limit=1"

Send the following mention to @yui.syui.ai.

# card account create
@yui.syui.ai /card

# get egg card
@yui.syui.ai /card egg

You will then receive an egg card. Anyone can perform this hidden command. If you already have one, it will be displayed.

This card can be grown by converting your did to base64 and sending it to @yui.syui.ai.

$ echo did:plc:4hqjfn7m6n5hno3doamuhgef|base64
ZGlkOnBsYzo0aHFqZm43bTZuNWhubzNkb2FtdWhnZWYK
@yui.syui.ai /egg ZGlkOnBsYzo0aHFqZm43bTZuNWhubzNkb2FtdWhnZWYK

Note that this will consume one day's battle points.

If you send this by command, it will look like this

env

data=`curl -sL -X POST -H "Content-Type: application/json" -d "{\"identifier\":\"$handle\",\"password\":\"$pass\"}" https://bsky.social/xrpc/com.atproto.server.createSession`
token=`echo $data|jq -r .accessJwt`
did=`echo $data|jq -r .did`
base=`echo $did|base64`

handle_m=yui.syui.ai
did_m=`curl -sL -X GET -H "Content-Type: application/json" -H "Authorization: Bearer $token" "https://bsky.social/xrpc/app.bsky.actor.getProfile?actor=${handle_m}"|jq -r .did`
at=@${handle_m}
s=0
e=`echo $at|wc -c`
text="$at /egg $base"
col=app.bsky.feed.post
created_at=`date --iso-8601=seconds`

json

json="{
        \"did\": \"$did\",
        \"repo\": \"$handle\",
        \"collection\": \"$col\",
        \"record\": {
            \"text\": \"$text\",
            \"\$type\": \"$col\",
            \"createdAt\": \"$created_at\",
            \"facets\": [
            {
                \"\$type\": \"app.bsky.richtext.facet\",
                \"index\": {
                    \"byteEnd\": $e,
                    \"byteStart\": $s
                },\"features\": [
                {
                    \"did\": \"$did_m\",
                    \"\$type\": \"app.bsky.richtext.facet#mention\"
                }
                ]
            }
            ]
        }
}"

post

curl -sL -X POST -H "Content-Type: application/json" \
         -H "Authorization: Bearer $token" \
         -d "$json" \
         https://bsky.social/xrpc/com.atproto.repo.createRecord

results matching ""

    No results matching ""