# Posts

Page: https://microblog.dev/api/posts/
API base URL: https://micro.blog

Endpoints for timeline posts, user posts, replies, media, conversations, search, and post deletion.

## Endpoints
### GET /posts/all

URL: `https://micro.blog/posts/all`

Retrieves the user's timeline feed. Returns posts in JSON Feed format with Micro.blog extensions. Supports pagination via query parameters.




Query parameters:
- `count` (integer, optional): Maximum number of items to return.
  Example: `150`
- `since_id` (integer, optional): Only return posts newer than this post ID.
  Example: `1`
- `before_id` (integer, optional): Only return posts older than this post ID.
  Example: `117`



Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

```sh
curl -X GET "https://micro.blog/posts/all" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed object containing an array of posts with Micro.blog extensions.
Response properties:

- `version` (string): JSON Feed version identifier.
  Example: `https://jsonfeed.org/version/1`
- `title` (string): Title of the feed.
  Example: `Micro.blog - Timeline`
- `home_page_url` (string): URL of the home page for this feed.
  Example: `https://micro.blog`
- `feed_url` (string): URL of this feed.
  Example: `https://micro.blog/posts/all`
- `_microblog` (object): Micro.blog-specific extensions to the JSON Feed format.
  Properties:

  - `about` (string): URL to API documentation.
    Example: `https://micro.blog/about/api`

- `items` (array of object): Array of post items.
  Item properties:

  - `id` (string): Unique post identifier (64-bit).
    Example: `77494371`
  - `content_html` (string): HTML content of the post.
    Example: `<p>Post content...</p>`
  - `summary` (string): Summary or excerpt of the post.
  - `url` (string): URL to the post.
    Example: `https://www.manton.org/2025/11/07/if-you-are-on-the.html`
  - `date_published` (string): ISO 8601 timestamp of when the post was published.
    Example: `2025-11-07T18:00:00+00:00`
  - `author` (object): Author information.
    Properties:

    - `name` (string): Author's display name.
      Example: `Manton Reece`
    - `url` (string): URL to author's profile or website.
      Example: `https://manton.org`
    - `avatar` (string): URL to author's avatar image.
      Example: `https://avatars.micro.blog/avatars/2025/22/3.jpg`
    - `_microblog` (object): Micro.blog-specific author fields.
      Properties:

      - `username` (string): Author's Micro.blog username.
        Example: `manton`


  - `_microblog` (object): Micro.blog-specific post fields.
    Properties:

    - `date_relative` (string): Human-readable relative date/time.
      Example: `19:00`
    - `date_timestamp` (integer): Unix timestamp of the post.
      Example: `1762538400`
    - `is_favorite` (boolean): Whether the post is favorited by the authenticated user.
    - `is_bookmark` (boolean): Whether the post is bookmarked by the authenticated user.
    - `is_deletable` (boolean): Whether the authenticated user can delete this post.
    - `is_conversation` (boolean): Whether this post is part of a conversation thread.
    - `is_linkpost` (boolean): Whether this post is a link post.
    - `is_mention` (boolean): Whether this post mentions the authenticated user.
    - `note` (string): Additional note or context for the post.
    - `syndication` (array of string): Array of syndication URLs where this post was shared.
      Example: `[https://example.com/syndication/url]`



Example response:

```json
{
  "version": "https://jsonfeed.org/version/1",
  "title": "Micro.blog - Timeline",
  "home_page_url": "https://micro.blog",
  "feed_url": "https://micro.blog/posts/all",
  "_microblog": {
    "about": "https://micro.blog/about/api"
  },
  "items": [
    {
      "id": "77494371",
      "content_html": "<p>If you are on the TestFlight beta for Micro.blog iOS, you will have seen our experiments to enable Liquid Glass. I'm admitting defeat today, going to opt out of the new UI for the next version. There are too many little glitches.</p>\n",
      "summary": "",
      "url": "https://www.manton.org/2025/11/07/if-you-are-on-the.html",
      "date_published": "2025-11-07T18:00:00+00:00",
      "author": {
        "name": "Manton Reece",
        "url": "https://manton.org",
        "avatar": "https://avatars.micro.blog/avatars/2025/22/3.jpg",
        "_microblog": {
          "username": "manton"
        }
      },
      "_microblog": {
        "date_relative": "19:00",
        "date_timestamp": 1762538400,
        "is_favorite": false,
        "is_bookmark": false,
        "is_deletable": false,
        "is_conversation": false,
        "is_linkpost": false,
        "is_mention": false,
        "note": "",
        "syndication": [
          "https://example.com/syndication/url"
        ]
      }
    }
  ]
}

```

### GET /posts/all/by_id

URL: `https://micro.blog/posts/all/by_id`

Returns one timeline post by query ID.




Query parameters:
- `id` (integer, required): Resource identifier.
  Example: `12345`



Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

```sh
curl -X GET "https://micro.blog/posts/all/by_id?id=12345" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a single timeline post object.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "items": []
}
```

### GET /posts/conversation

URL: `https://micro.blog/posts/conversation`

Returns the conversation thread for a post, mention, favourite, or thread ID.




Query parameters:
- `id` (integer, required): Identifier for the resource.
  Example: `88924898`



Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

```sh
curl -X GET "https://micro.blog/posts/conversation?id=88924898" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "title": "Micro.blog",
  "home_page_url": "https://micro.blog",
  "feed_url": "https://micro.blog/posts/conversation",
  "items": []
}
```

### GET /posts/links/search

URL: `https://micro.blog/posts/links/search`

Searches indexed links and returns JSON Feed.




Query parameters:
- `q` (string, required): Search query.
  Example: `search term`






Example request:

```sh
curl -X GET "https://micro.blog/posts/links/search?q=search+term"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "items": []
}
```

### GET /posts/links/{prefix}

URL: `https://micro.blog/posts/links/{prefix}`

Returns indexed links matching a host/path prefix in JSON Feed format.


Path parameters:
- `prefix` (string, required): Hostname and optional path prefix.
  Example: `example.com/path`








Example request:

```sh
curl -X GET "https://micro.blog/posts/links/{prefix}"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "items": []
}
```

### GET /posts/media

URL: `https://micro.blog/posts/media`

Retrieves media posts from the authenticated user timeline in JSON Feed format.




Query parameters:
- `count` (integer, optional): Maximum number of items to return.
  Example: `25`
- `since_id` (integer, optional): Only return posts newer than this post ID.
  Example: `77479242`
- `before_id` (integer, optional): Only return posts older than this post ID.
  Example: `9853826`



Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

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

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "title": "Micro.blog",
  "home_page_url": "https://micro.blog",
  "feed_url": "https://micro.blog/posts/media",
  "items": []
}
```

### GET /posts/photos

URL: `https://micro.blog/posts/photos`

Retrieves photo posts from the authenticated user timeline in JSON Feed format.




Query parameters:
- `count` (integer, optional): Maximum number of items to return.
  Example: `25`
- `since_id` (integer, optional): Only return posts newer than this post ID.
  Example: `77479242`
- `before_id` (integer, optional): Only return posts older than this post ID.
  Example: `9853826`



Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

```sh
curl -X GET "https://micro.blog/posts/photos" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "title": "Micro.blog",
  "home_page_url": "https://micro.blog",
  "feed_url": "https://micro.blog/posts/photos",
  "items": []
}
```

### GET /posts/replies

URL: `https://micro.blog/posts/replies`

Returns replies for the authenticated user.




Query parameters:
- `count` (integer, optional): Maximum number of items to return.
  Example: `25`
- `q` (string, optional): Search query or Micropub query type.
  Example: `search term`



Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

```sh
curl -X GET "https://micro.blog/posts/replies" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "title": "Micro.blog",
  "home_page_url": "https://micro.blog",
  "feed_url": "https://micro.blog/posts/replies",
  "items": []
}
```

### GET /posts/search

URL: `https://micro.blog/posts/search`

Searches posts visible to the authenticated user.




Query parameters:
- `q` (string, required): Search query or Micropub query type.
  Example: `vincent`
- `count` (integer, optional): Maximum number of items to return.
  Example: `25`



Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

```sh
curl -X GET "https://micro.blog/posts/search?q=vincent" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "title": "Micro.blog",
  "home_page_url": "https://micro.blog",
  "feed_url": "https://micro.blog/posts/search",
  "items": []
}
```

### GET /posts/timeline

URL: `https://micro.blog/posts/timeline`

Retrieves the authenticated user timeline in JSON Feed format.




Query parameters:
- `count` (integer, optional): count parameter.
  Example: `example`
- `since_id` (string, optional): Only return posts newer than this post ID.
  Example: `77479242`
- `before_id` (string, optional): Only return posts older than this post ID.
  Example: `9853826`



Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

```sh
curl -X GET "https://micro.blog/posts/timeline" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "items": []
}
```

### GET /posts/timeline/{id}

URL: `https://micro.blog/posts/timeline/{id}`

Returns one timeline post by ID.


Path parameters:
- `id` (integer, required): Identifier for the resource.
  Example: `12345`





Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

```sh
curl -X GET "https://micro.blog/posts/timeline/{id}?id=2" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "title": "Micro.blog",
  "home_page_url": "https://micro.blog",
  "feed_url": "https://micro.blog/posts/timeline/{id}",
  "items": []
}
```

### DELETE /posts/{id}

URL: `https://micro.blog/posts/{id}`

Deletes one of the authenticated user's posts by ID.


Path parameters:
- `id` (integer, required): Identifier for the resource.
  Example: `12345`





Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

```sh
curl -X DELETE "https://micro.blog/posts/{id}" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns an empty JSON object on success.
Example response:

```json
{}
```

### GET /posts/{username}

URL: `https://micro.blog/posts/{username}`

Returns a user profile and recent posts for the given username.


Path parameters:
- `username` (string, required): Micro.blog username.
  Example: `vincent`



Query parameters:
- `count` (integer, optional): Maximum number of items to return.
  Example: `0`



Header parameters:
- `Authorization` (string, required): Bearer token for authentication. Format: `Bearer {token}`.
  Example: `Bearer EF7BB9BCAC1F6D561C93`




Example request:

```sh
curl -X GET "https://micro.blog/posts/{username}" \
  --header "Authorization: Bearer EF7BB9BCAC1F6D561C93"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "title": "Micro.blog",
  "home_page_url": "https://micro.blog",
  "feed_url": "https://micro.blog/posts/{username}",
  "items": []
}
```

### GET /posts/{username}/photos

URL: `https://micro.blog/posts/{username}/photos`

Returns public photo posts for a user in JSON Feed format.


Path parameters:
- `username` (string, required): Micro.blog username.
  Example: `vincent`



Query parameters:
- `count` (integer, optional): count parameter.
  Example: `example`






Example request:

```sh
curl -X GET "https://micro.blog/posts/{username}/photos"
```

Response:
- Status: 200
- Content-Type: `application/json`
- Description: Returns a JSON Feed response.
Example response:

```json
{
  "version": "https://jsonfeed.org/version/1.1",
  "items": []
}
```

