API reference

Lemmy has two, intertwined APIs:

This page describes concepts that are common to both.

Basic usage

Request and response strings are in JSON format.

Data types

Lemmy types

Lower-level types

  • ? designates an option which may be omitted in requests and not be present in responses. It will be of type SomeType.
  • [SomeType] is a list which contains objects of type SomeType.
  • Times and dates are timestamp strings in ISO 8601 format. Timestamps will be UTC, your client must do the UTC to local conversion.

Default rate limits

These can be edited in your lemmy.hjson file, by copying the relevant section from defaults.hjson.

  • 3 per hour for signups and community creation.
  • 6 per hour for image posting.
  • 6 per 10 minutes for post creation.
  • 180 actions per minute for post voting and comment creation.

Everything else is not rate-limited.

See also: rate limiting for custom front-ends.