Sengi-Windows-MacOS-Linux/src/app/services/models/mastodon.interfaces.ts

137 lines
2.3 KiB
TypeScript
Raw Normal View History

2018-09-08 05:17:19 +02:00
export interface AppData {
client_id: string;
client_secret: string;
id: string;
name: string;
redirect_uri: string;
website: string;
}
2018-03-17 05:30:43 +01:00
export interface TokenData {
access_token: string;
token_type: string;
scope: string;
created_at: string;
}
export interface Account {
id: number;
username: string;
acct: string;
display_name: string;
locked: string;
created_at: string;
followers_count: number;
following_count: number;
statuses_count: number;
note: string;
url: string;
avatar: string;
avatar_static: string;
header: string;
header_static: string;
}
export interface Application {
name: string;
website: string;
}
export interface Attachment {
id: string;
type: 'image' | 'video' | 'gifv';
url: string;
remote_url: string;
preview_url: string;
text_url: string;
}
export interface Card {
url: string;
title: string;
description: string;
image: string;
}
export interface Context {
ancestors: Status[];
descendants: Status[];
}
export interface Error {
error: string;
}
export interface Instance {
uri: string;
title: string;
description: string;
email: string;
}
export interface Mention {
url: string;
username: string;
acct: string;
id: string;
}
export interface Notification {
id: string;
type: 'mention' | 'reblog' | 'favourite' | 'follow';
created_at: string;
account: Account;
status?: Status;
}
export interface Relationship {
2019-02-23 05:35:12 +01:00
id: number;
following: boolean;
followed_by: boolean;
blocking: boolean;
muting: boolean;
requested: boolean;
2018-03-17 05:30:43 +01:00
}
export interface Report {
id: string;
action_taken: boolean;
}
export interface Results {
accounts: Account[];
statuses: Status[];
hashtags: string[];
}
export interface Status {
id: string;
uri: string;
url: string;
account: Account;
2018-03-17 05:30:43 +01:00
in_reply_to_id: string;
in_reply_to_account_id: string;
2018-09-21 04:51:18 +02:00
reblog: Status;
2018-03-17 05:30:43 +01:00
content: string;
created_at: string;
reblogs_count: string;
favourites_count: string;
reblogged: boolean;
favourited: boolean;
sensitive: boolean;
2018-03-17 05:30:43 +01:00
spoiler_text: string;
visibility: string;
2018-09-21 04:51:18 +02:00
media_attachments: Attachment[];
2018-10-13 17:38:23 +02:00
mentions: Mention[];
tags: Tag[];
2018-03-17 05:30:43 +01:00
application: Application;
emojis: any[];
2018-10-13 17:38:23 +02:00
language: string;
pinned: boolean;
2018-03-17 05:30:43 +01:00
}
export interface Tag {
name: string;
url: string;
}