Build with Micro.blog logo
Build with Micro.blog
API Documentation

Posting and Micropub

View .md

Endpoints for publishing, replying, uploading media, and querying Micropub resources.

BASE URL https://micro.blog
GET /micropub

Handles Micropub configuration, source, category, contact, and syndication queries.

Example Request

curl -X GET "https://micro.blog/micropub" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"

Query Parameters

Name Type Required Description
q string Required Search query or Micropub query type.
Example: source
mp-destination string Optional Micropub destination site URL or hostname.
Example: vincent-test.micro.blog
mp-channel string Optional Micropub source channel, for example pages.
Example: pages
filter string Optional Text filter for Micropub source or contact queries.
Example: Vincent

Header Parameters

Name Type Required Description
Authorization string Required Bearer token for authentication. Format: Bearer {token}.

Response

200 OK application/json

Returns a JSON response for the requested resource.

Example Response

{
  "media-endpoint": "https://micro.blog/micropub/media",
  "destination": [
    {
      "uid": "https://vincent.micro.blog/",
      "name": "vincent.micro.blog",
      "microblog-audio": true,
      "microblog-default": true,
      "microblog-title": "Vincent's Blog"
    }
  ],
  "post-types": [
    {
      "type": "note",
      "name": "Post",
      "properties": [
        "content",
        "published",
        "post-status",
        "category"
      ]
    }
  ],
  "channels": [
    {
      "uid": "default",
      "name": "Posts"
    }
  ],
  "syndicate-to": []
}
POST /micropub

Creates, updates, or deletes content through Micropub.

Example Request

curl -X POST "https://micro.blog/micropub" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"

Query Parameters

Name Type Required Description
action string Optional Micropub action, for example delete.
Example: delete
url string Optional URL to look up or modify.
Example: http://gluon.micro.blog/2019/12/16/hello-world.html
h string Optional Micropub object type. Use entry for posts.
Example: entry
content string Optional Reply text.
Example: @vincent Thanks for the update.
name string Optional Title or notebook name, depending on the endpoint.
Example: This is a title
photo string Optional Photo URL for a Micropub post.
Example: https://gluon.micro.blog/uploads/2019/9931898b67.jpg
bookmark-of string Optional URL being bookmarked.
Example: https://micro.blog/rom/21700756
mp-destination string Optional Micropub destination site URL or hostname.
Example: https://example.micro.blog/
mp-channel string Optional Micropub source channel, for example pages.
Example: pages
site_id string Optional Site URL or identifier for the destination site.
Example: https://gluon-the-second.micro.blog/

Header Parameters

Name Type Required Description
Authorization string Required Bearer token for authentication. Format: Bearer {token}.

Response

200 OK application/json

Returns an empty JSON object on success.

Example Response

{}
GET /micropub/media

Returns Micropub media endpoint configuration or uploaded media.

Example Request

curl -X GET "https://micro.blog/micropub/media" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"

Query Parameters

Name Type Required Description
q string Required Search query or Micropub query type.
Example: config
mp-destination string Optional Micropub destination site URL or hostname.
Example: https://vincent.micro.blog/

Header Parameters

Name Type Required Description
Authorization string Required Bearer token for authentication. Format: Bearer {token}.

Response

200 OK application/json

Returns a JSON response for the requested resource.

Example Response

{
  "items": [
    {
      "url": "https://vincent.micro.blog/uploads/2026/photo.jpg",
      "published": "2026-04-26T12:00:00+00:00",
      "alt": "Photo description",
      "microblog-ai": false,
      "microblog-id": 12345,
      "sizes": {
        "large": "https://vincent.micro.blog/uploads/2026/photo.jpg"
      },
      "cdn": {
        "large": "https://cdn.uploads.micro.blog/12345/photo.jpg"
      }
    }
  ]
}
POST /micropub/media

Uploads media or deletes an uploaded media file through the Micropub media endpoint.

Example Request

curl -X POST "https://micro.blog/micropub/media" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93" \
  --header "Content-Type: multipart/form-data" \
  --form "file=@/path/to/file.jpg"

Query Parameters

Name Type Required Description
action string Optional Micropub action, for example delete.
Example: delete
mp-destination string Optional Micropub destination site URL or hostname.
Example: https://vincent.micro.blog/
url string Optional URL to look up or modify.
Example: https://vincent.micro.blog/uploads/2023/dd2f2731d0.jpg

Header Parameters

Name Type Required Description
Authorization string Required Bearer token for authentication. Format: Bearer {token}.
Content-Type string Required Request content type.

Request Body

Name Type Required Description
file string Optional File upload field for media uploads.
Example: @/path/to/file.jpg

Response

200 OK application/json

Returns a JSON response for the requested resource.

Example Response

{
  "url": "https://vincent.micro.blog/uploads/2026/photo.jpg",
  "poster": ""
}
POST /micropub/media/append

Appends a base64-encoded chunk to a large media upload. Micro.blog clients use this before marking the upload as finished.

Example Request

curl -X POST "https://micro.blog/micropub/media/append" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93" \
  --form "file_id=12345" \
  --form "file_name=video.mov" \
  --form "file_type=video/quicktime" \
  --form "file_data=data:;base64,AAAA"

Header Parameters

Name Type Required Description
Authorization string Required Bearer token for authentication. Format: Bearer {token}.
Content-Type string Required Request content type.

Request Body

Name Type Required Description
file_id integer Required Client-generated upload identifier shared by all chunks for the same file.
Example: 12345
file_name string Optional Original file name. The Micro.blog app includes this with chunk requests.
Example: video.mov
file_type string Optional MIME type for the uploaded file.
Example: video/quicktime
file_data string Required Base64-encoded chunk data, optionally prefixed with a data URL header.
Example: data:;base64,AAAA
mp-destination string Optional Micropub destination site URL or hostname.
Example: https://example.micro.blog/

Response

200 OK application/json

Returns an empty JSON object on success.

Example Response

{}
POST /micropub/media/finished

Marks a chunked media upload as finished and queues server-side processing.

Example Request

curl -X POST "https://micro.blog/micropub/media/finished" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93" \
  --form "file_id=12345" \
  --form "file_name=video.mov"

Header Parameters

Name Type Required Description
Authorization string Required Bearer token for authentication. Format: Bearer {token}.
Content-Type string Required Request content type.

Request Body

Name Type Required Description
file_id integer Required Client-generated upload identifier used for the appended chunks.
Example: 12345
file_name string Required Original file name.
Example: video.mov
mp-destination string Optional Micropub destination site URL or hostname.
Example: https://example.micro.blog/

Response

200 OK application/json

Returns an empty JSON object on success.

Example Response

{}
GET /micropub/media/waiting

Returns processing state and the final URL for a chunked media upload.

Example Request

curl -X GET "https://micro.blog/micropub/media/waiting?file_id=12345" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"

Query Parameters

Name Type Required Description
file_id integer Required Upload file identifier.
Example: 12345

Header Parameters

Name Type Required Description
Authorization string Required Bearer token for authentication. Format: Bearer {token}.

Response

200 OK application/json

Returns whether processing is still running and, when available, the uploaded media URL.

Example Response

{
  "is_processing": false,
  "url": "https://vincent.micro.blog/uploads/2026/video.mp4"
}
POST /posts/reply

Creates a reply to a Micro.blog post or mention.

Example Request

curl -X POST "https://micro.blog/posts/reply?id=28150987&content=%40vincent+testing+a+reply+with+a+%5Blink%5D%28https%3A%2F%2Fgluon.app%29" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"

Query Parameters

Name Type Required Description
id integer Required Identifier for the resource.
Example: 28150987
content string Required Reply text.
Example: @vincent testing a reply with a [link](https://gluon.app)
text string Optional Text content.
Example: Draft note text

Header Parameters

Name Type Required Description
Authorization string Required Bearer token for authentication. Format: Bearer {token}.

Response

200 OK application/json

Returns an empty JSON object on success.

Example Response

{}