Help needed: Posting to Bluesky with an attached image

nope, that step is right here:

what was wrong is the JSON structure. i finally made it work yesterday using this structure:

{
  "repo": "BLUESKY_HANDLE",
  "record": {
    "text": "Just a test post via API",
    "createdAt": "2024-05-13T14:52:21.422Z",
    "embed": {
      "$type": "app.bsky.embed.images",
      "images": [
        {
          "alt": "brief alt text description of the first image",
          "image": {
            "$type": "blob",
            "ref": {
              "$link": "bafkreibabalobzn6cd366ukcsjycp4yymjymgfxcv6xczmlgpemzkz3cfa"
            },
            "mimeType": "image/webp",
            "size": 760898
          }
        },
        {
          "alt": "brief alt text description of the second image",
          "image": {
            "$type": "blob",
            "ref": {
              "$link": "bafkreif3fouono2i3fmm5moqypwskh3yjtp7snd5hfq5pr453oggygyrte"
            },
            "mimeType": "image/png",
            "size": 13208
          }
        }
      ]
    }
  },
  "collection": "app.bsky.feed.post"
}
2 Likes