Model the Mastodon entities
{ acct : String
, avatar : String
, created_at : String
, display_name : String
, followers_count : Basics.Int
, following_count : Basics.Int
, header : String
, id : AccountId
, locked : Basics.Bool
, note : String
, statuses_count : Basics.Int
, url : String
, username : String
}
Mastodon account
{ server : Server
, accessToken : Token
}
Server token
{ account : Account
, created_at : String
}
AccountNotificationDate
{ server : Server
, scope : String
, client_id : ClientId
, client_secret : ClientSecret
, id : String
, redirect_uri : String
}
App registration
{ name : String
, website : Maybe String
}
Application
{ id : String
, type_ : String
, url : String
, remote_url : String
, preview_url : Maybe String
, text_url : Maybe String
, description : Maybe String
}
Attachment can be an image, a video, an audio or a gifv
{ server : Server
, token : Token
, account : Maybe Account
}
Web Client
{ ancestors : List Status
, descendants : List Status
}
Context of a status
Contains ancestors statuses and descendants statuses
Mastodon error types
{ name : String
, url : String
, history : List HashtagHistory
}
Tag with history
{ day : String
, uses : String
, accounts : String
}
HashtagHistory
{ description : String }
Update a media
{ id : AccountId
, url : String
, username : String
, acct : String
}
Mention
{ id : String
, type_ : String
, created_at : String
, account : Account
, status : Maybe Status
}
Notification
- id: The notification ID
- type_: One of: "mention", "reblog", "favourite", "follow"
- created_at: The time the notification was created
- account: The Account sending the notification to the user
- status: The Status associated with the notification, if applicable
{ id : String
, type_ : String
, status : Maybe Status
, accounts : List AccountNotificationDate
, created_at : String
}
NotificationAggregate
Group multiple notification together
Reblog of a Status
{ id : String
, blocking : Basics.Bool
, followed_by : Basics.Bool
, following : Basics.Bool
, muting : Basics.Bool
, requested : Basics.Bool
}
Relationship between followers
{ accounts : List Account
, statuses : List Status
, hashtags : List Hashtag
}
SearchResults
{ account : Account
, application : Maybe Application
, content : String
, created_at : String
, edited_at : Maybe String
, favourited : Maybe Basics.Bool
, favourites_count : Basics.Int
, id : StatusId
, in_reply_to_account_id : Maybe String
, in_reply_to_id : Maybe StatusId
, media_attachments : List Attachment
, mentions : List Mention
, reblog : Maybe Reblog
, reblogged : Maybe Basics.Bool
, reblogs_count : Basics.Int
, sensitive : Maybe Basics.Bool
, spoiler_text : String
, tags : List Tag
, uri : String
, url : Maybe String
, visibility : String
}
Status
{ status : Status
, text : Maybe String
, spoiler_text : Maybe String
}
Used when editing a status
{ status : String
, spoiler_text : Maybe String
, sensitive : Basics.Bool
, media_ids : List String
}
Edit a status
Status id
{ id : StatusId
, text : String
, spoiler_text : String
}
Used to get the original content of a status
{ status : String
, in_reply_to_id : Maybe StatusId
, spoiler_text : Maybe String
, sensitive : Basics.Bool
, visibility : String
, media_ids : List String
}
Submit a status
{ name : String
, url : String
}
tags
#hashtag