Mastodon
  • What is Mastodon?
  • Using Mastodon
    • Signing up for an account
    • Setting up your profile
    • Posting toots
    • Using the network features
    • Dealing with unwanted content
    • Promoting yourself and others
    • Set your preferences
    • More settings
    • Using Mastodon externally
    • Moving or leaving accounts
    • Running your own server
  • Running Mastodon
    • Preparing your machine
    • Installing from source
    • Configuring your environment
    • Installing optional features
      • Full-text search
      • Hidden services
      • Single Sign On
    • Setting up your new instance
    • Using the admin CLI
    • Upgrading to a new release
    • Backing up your server
    • Migrating to a new machine
    • Scaling up your server
    • Moderation actions
    • Troubleshooting errors
      • Database index corruption
  • Developing Mastodon apps
    • Getting started with the API
    • Playing with public data
    • Obtaining client app access
    • Logging in with an account
    • Guidelines and best practices
    • Libraries and implementations
  • Contributing to Mastodon
    • Technical overview
    • Setting up a dev environment
    • Code structure
    • Routes
    • Bug bounties and responsible disclosure
  • Spec compliance
    • ActivityPub
    • WebFinger
    • Security
    • Microformats
    • OAuth
    • Bearcaps
  • REST API
    • OAuth Scopes
    • Rate limits
  • API Methods
    • apps
      • oauth
    • accounts
      • bookmarks
      • favourites
      • mutes
      • blocks
      • domain_blocks
      • filters
      • reports
      • follow_requests
      • endorsements
      • featured_tags
      • preferences
      • suggestions
    • statuses
      • media
      • polls
      • scheduled_statuses
    • timelines
      • conversations
      • lists
      • markers
      • streaming
    • notifications
      • push
    • search
    • instance
      • trends
      • directory
      • custom_emojis
    • admin
    • announcements
    • proofs
    • oembed
  • API Entities
    • Account
    • Activity
    • Admin::Account
    • Admin::Report
    • Announcement
    • AnnouncementReaction
    • Application
    • Attachment
    • Card
    • Context
    • Conversation
    • Emoji
    • Error
    • FeaturedTag
    • Field
    • Filter
    • History
    • IdentityProof
    • Instance
    • List
    • Marker
    • Mention
    • Notification
    • Poll
    • Preferences
    • PushSubscription
    • Relationship
    • Report
    • Results
    • ScheduledStatus
    • Source
    • Status
    • Tag
    • Token

OAuth Scopes

Defining what you have permission to do with the API

    • OAuth Scopes
    • List of scopes
    • Granular scopes

OAuth Scopes

The API is divided up into access scopes. The scopes are hierarchical, i.e. if you have access to read, you automatically have access to read:accounts. It is recommended that you request as little as possible for your application.

Multiple scopes can be requested at the same time: During app creation with the scopes param, and during the authorization phase with the scope query param (space-separate the scopes).

Mind the scope vs scopes difference. This is because scope is a standard OAuth parameter name, so it is used in the OAuth methods. Mastodon’s own REST API uses the more appropriate scopes.

If you do not specify a scope in your authorization request, or a scopes in your app creation request, the resulting access token / app will default to read access.

The set of scopes saved during app creation must include all the scopes that you will request in the authorization request, otherwise authorization will fail.

Version history

  • 0.9.0 - read, write, follow
  • 2.4.0 - push
  • 2.4.3 - granular scopes https://github.com/tootsuite/mastodon/pull/7929
  • 2.6.0 - read:reports deprecated (unused stub) https://github.com/tootsuite/mastodon/pull/8736/commits/adcf23f1d00c8ff6877ca2ee2af258f326ae4e1f
  • 2.6.0 - write:conversations added https://github.com/tootsuite/mastodon/pull/9009
  • 2.9.1 - Admin scopes added https://github.com/tootsuite/mastodon/pull/9387
  • 3.1.0 - Bookmark scopes added

List of scopes

read

Grants access to read data. Requesting read will also grant child scopes shown in the left column of the table below.

write

Grants access to write data. Requesting write will also grant child scopes shown in the right column of the table below.

follow

Grants access to manage relationships. Requesting follow will also grant the following child scopes, shown in bold in the table:

  • read:blocks, write:blocks
  • read:follows, write:follows
  • read:mutes, write:mutes

push

Grants access to Web Push API subscriptions. Added in Mastodon 2.4.0.

Admin scopes

Used for moderation API. Added in Mastodon 2.9.1. The following granular scopes are available (note that there is no singular admin scope):

  • admin:read
    • admin:read:accounts
    • admin:read:reports
  • admin:write
    • admin:write:accounts
    • admin:write:reports

Granular scopes

read write
read:accounts write:accounts
read:blocks write:blocks
read:bookmarks write:bookmarks
write:conversations
read:favourites write:favourites
read:filters write:filters
read:follows write:follows
read:lists write:lists
write:media
read:mutes write:mutes
read:notifications write:notifications
write:reports
read:search
read:statuses write:statuses
admin:read admin:write
admin:read:accounts admin:write:accounts
admin:read:reports admin:write:reports

Last updated January 12, 2020 · Improve this page

Sponsored by

Dotcom-Monitor LoadView Stephen Tures Swayable

Join Mastodon · Blog · ·

View source · CC BY-SA 4.0 · Imprint