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

Authentication

View .md

Sign in, registration, and token verification endpoints.

BASE URL https://micro.blog
POST /account/signin

Sends a sign-in email for an existing account. App sign-in requests must include a registered app name and redirect URL.

Note: Apps that use this sign-in flow must be registered with Micro.blog before sending app_name and redirect_url. Email help@micro.blog with the app name and redirect URL to request registration.

Example Request

curl -X POST "https://micro.blog/account/signin?email=example%40example.com"

Query Parameters

Name Type Required Description
email string Required Email address for the account.
Example: example@example.com
app_name string Optional Name of the app requesting access.
Example: Micro.blog for Android
redirect_url string Optional Registered redirect URL for the app sign-in flow.
Example: microblog://signin/
is_mobile integer Optional Set to 1 for the mobile sign-in email flow.
Example: 1

Response

200 OK application/json

Returns an empty object on success.

Example Response

{}
POST /account/verify

Verifies an emailed sign-in or app token and returns account information plus the API token to use on authenticated requests.

Example Request

curl -X POST "https://micro.blog/account/verify?token=Bearer+EF7BB9BCAC1F6D561C93"

Query Parameters

Name Type Required Description
token string Required Verification or access token.
Example: EF7BB9BCAC1F6D561C93

Response Properties

token string Bearer Token
Authentication token for subsequent API requests.
Note: This token must be included in the Authorization header as Bearer {token} for authenticated API requests.
Example: EF7BBXXXXXX..
name string
The user’s display name.
Example: Vincent
username string
The user’s username.
Example: vincent
avatar string
URL to the user’s avatar image.
Example: https://avatars.micro.blog/avatars/2025/39/3008.jpg
bio string
The user’s bio or description.
default_site string
The user’s default Micro.blog site.
Example: vincent-social.micro.blog
full_name string
The user’s full name.
Example: Vincent
gravatar_url string
URL to the user’s Gravatar image.
Example: https://avatars.micro.blog/avatars/2025/39/3008.jpg
has_site boolean
Whether the user has a Micro.blog site.
Example: true
plan string
The user’s current subscription plan.
Example: premium
plans array of string
Array of subscription plans the user has access to.
Example: [premium]
is_fullaccess boolean
Whether the user has full access features.
Example: true
is_premium boolean
Whether the user has a premium subscription.
Example: true
is_using_ai boolean
Whether the user is using AI features.

Response

200 OK application/json

Returns user information and authentication token upon successful verification.

Example Response

{
  "token": "EF7BBXXXXXX..",
  "name": "Vincent",
  "username": "vincent",
  "avatar": "https://avatars.micro.blog/avatars/2025/39/3008.jpg",
  "bio": "",
  "default_site": "vincent-social.micro.blog",
  "full_name": "Vincent",
  "gravatar_url": "https://avatars.micro.blog/avatars/2025/39/3008.jpg",
  "has_site": true,
  "plan": "premium",
  "plans": [
    "premium"
  ],
  "is_fullaccess": true,
  "is_premium": true,
  "is_using_ai": false
}
POST /account/apple

Verifies a Sign in with Apple identity token and returns a temporary Micro.blog verification token.

Example Request

curl -X POST "https://micro.blog/account/apple?identity_token=APPLE_IDENTITY_TOKEN&user_id=001234.apple"

Query Parameters

Name Type Required Description
identity_token string Required Apple identity token.
Example: APPLE_IDENTITY_TOKEN
user_id string Required Apple user identifier.
Example: 001234.apple
email string Optional Email address.
Example: example@example.com
full_name string Optional Full display name.
Example: Vincent
username string Optional Micro.blog username.
Example: vincent

Response

200 OK application/json

Returns a JSON response.

Example Response

{
  "username": "vincent",
  "token": "EF7BB9BCAC1F6D561C93"
}
POST /indieauth/approve

Approves an IndieAuth authorization request and redirects to the client with a code.

Example Request

curl -X POST "https://micro.blog/indieauth/approve"

Query Parameters

Name Type Required Description
scope string Optional Requested or granted scope string.
Example: profile read create update

Response

302 OK text/html

Redirects to the registered redirect URI with code and state.

Example Response

HTTP/1.1 302 Found
Location: https://example-app.com/callback?code=AUTHCODE&state=state123
GET /indieauth/auth

Starts the IndieAuth authorization flow and renders the authorization screen.

Example Request

curl -X GET "https://micro.blog/indieauth/auth?client_id=https%3A%2F%2Fexample-app.com%2F&redirect_uri=https%3A%2F%2Fexample-app.com%2Fcallback"

Query Parameters

Name Type Required Description
me string Optional Canonical user URL.
Example: https://example.micro.blog/
client_id string Required IndieAuth client ID URL.
Example: https://example-app.com/
redirect_uri string Required IndieAuth redirect URI.
Example: https://example-app.com/callback
state string Optional Opaque client state returned to the redirect URI.
Example: state123
response_type string Optional IndieAuth response type.
Example: code
scope string Optional Requested or granted scope string.
Example: profile read create update
inkwell integer Optional Set to 1 for Inkwell-specific authorization.
Example: 1

Response

200 OK text/html

Returns the authorization screen.

Example Response

<!doctype html>
<html>
  <body>IndieAuth authorization screen</body>
</html>
POST /indieauth/auth

Verifies an IndieAuth authorization code for clients that only need identity information.

Example Request

curl -X POST "https://micro.blog/indieauth/auth?code=AUTHCODE&redirect_uri=https%3A%2F%2Fexample-app.com%2Fcallback&client_id=https%3A%2F%2Fexample-app.com%2F"

Query Parameters

Name Type Required Description
code string Required Authorization code.
Example: AUTHCODE
redirect_uri string Required IndieAuth redirect URI.
Example: https://example-app.com/callback
client_id string Required IndieAuth client ID URL.
Example: https://example-app.com/

Response

200 OK application/json

Returns a JSON response.

Example Response

{
  "me": "https://vincent.micro.blog/",
  "profile": {
    "name": "Vincent",
    "url": "https://vincent.micro.blog/",
    "photo": "https://avatars.micro.blog/avatars/2025/39/3008.jpg",
    "nickname": "vincent"
  }
}
GET /indieauth/token

Introspects an IndieAuth bearer token and returns profile and scope information.

Example Request

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

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.

Example Response

{
  "me": "https://vincent.micro.blog/",
  "client_id": "Example App",
  "scope": "profile read create update",
  "profile": {
    "name": "Vincent",
    "url": "https://vincent.micro.blog/",
    "photo": "https://avatars.micro.blog/avatars/2025/39/3008.jpg",
    "nickname": "vincent"
  }
}
POST /indieauth/token

Exchanges an IndieAuth authorization code for profile information and, when requested, an access token.

Example Request

curl -X POST "https://micro.blog/indieauth/token?code=AUTHCODE&redirect_uri=https%3A%2F%2Fexample-app.com%2Fcallback&client_id=https%3A%2F%2Fexample-app.com%2F"

Query Parameters

Name Type Required Description
code string Required Authorization code.
Example: AUTHCODE
redirect_uri string Required IndieAuth redirect URI.
Example: https://example-app.com/callback
client_id string Required IndieAuth client ID URL.
Example: https://example-app.com/

Response

200 OK application/json

Returns a JSON response.

Example Response

{
  "scope": "profile read create update",
  "me": "https://vincent.micro.blog/",
  "profile": {
    "name": "Vincent",
    "url": "https://vincent.micro.blog/",
    "photo": "https://avatars.micro.blog/avatars/2025/39/3008.jpg",
    "nickname": "vincent"
  },
  "token_type": "Bearer",
  "access_token": "EF7BB9BCAC1F6D561C93"
}