Created
April 4, 2020 08:50
-
-
Save hajipy/6364c153e2050832cf1ef9609d6df650 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export interface Tweet { | |
created_at: string; | |
id: number; | |
id_str: string; | |
full_text: string; | |
source: string; | |
truncated: boolean; | |
in_reply_to_status_id?: number; | |
in_reply_to_status_id_str?: string; | |
in_reply_to_user_id?: number; | |
in_reply_to_user_id_str?: string; | |
in_reply_to_screen_name?: string; | |
user: TwitterUser; | |
coordinates?: TwitterCoordinates; | |
place?: TwitterPlace; | |
quoted_status_id?: number; | |
quoted_status_id_str?: string; | |
is_quote_status: boolean; | |
quoted_status?: Tweet; | |
retweeted_status?: Tweet; | |
quote_count?: number; | |
reply_count: number; | |
retweet_count: number; | |
favorite_count?: number; | |
entities: TwitterEntities; | |
extended_entities: TwitterExtendedEntities; | |
favorited?: boolean; | |
retweeted: boolean; | |
possibly_sensitive?: boolean; | |
filter_level: string; | |
lang?: string; | |
matching_rules: TwitterRule[]; | |
} | |
export interface TwitterUser { | |
id: number; | |
id_str: string; | |
name: string; | |
screen_name: string; | |
location?: string; | |
url?: string; | |
description?: string; | |
derived: object[]; // Note:よくわからなかったので、objectで誤魔化しておく | |
protected: boolean; | |
verified: boolean; | |
followers_count: number; | |
friends_count: number; | |
listed_count: number; | |
favourites_count: number; | |
statuses_count: number; | |
created_at: string; | |
utc_offset: null; | |
time_zone: null; | |
geo_enabled: boolean; | |
lang: string; | |
contributors_enabled: boolean; | |
profile_background_color: string; | |
profile_background_image_url: string; | |
profile_background_image_url_https: string; | |
profile_background_tile: boolean; | |
profile_banner_url: string; | |
profile_image_url: string; | |
profile_image_url_https: string; | |
profile_link_color: string; | |
profile_sidebar_border_color: string; | |
profile_sidebar_fill_color: string; | |
profile_text_color: string; | |
profile_use_background_image: boolean; | |
default_profile: boolean; | |
default_profile_image: boolean; | |
withheld_in_countries: string[]; | |
withheld_scope: string; | |
} | |
export interface TwitterCoordinates { | |
coordinates: number[]; | |
type: string; | |
} | |
export interface TwitterPlace { | |
id: string; | |
url: string; | |
place_type: string; | |
name: string; | |
full_name: string; | |
country_code: string; | |
country: string; | |
bounding_box: object; | |
attributes: object; | |
} | |
export interface TwitterEntities { | |
hashtags: TwitterHashtag[]; | |
media: TwitterMedia[]; | |
urls: TwitterUrl[]; | |
user_mentions: TwitterUserMention[]; | |
symbols: TwitterSymbol[]; | |
polls?: TwitterPoll[]; | |
} | |
export interface TwitterExtendedEntities { | |
media: TwitterMedia[]; | |
} | |
export interface TwitterRule { | |
tag: string; | |
id: number; | |
id_str: string; | |
} | |
export interface TwitterHashtag { | |
indices: number[]; | |
text: string; | |
} | |
export interface TwitterMedia { | |
display_url: string; | |
expanded_url: string; | |
id: number; | |
id_str: string; | |
indices: number[]; | |
media_url: string; | |
media_url_https: string; | |
sizes: TwitterMediaSizes; | |
source_status_id: number; | |
source_status_id_str: string; | |
type: string; | |
url: string; | |
} | |
export interface TwitterUrl { | |
display_url: string; | |
expanded_url: string; | |
indices: number[]; | |
url: string; | |
unwound?: { | |
url: string; | |
status: number; | |
title: string; | |
description: string; | |
}; | |
} | |
export interface TwitterUserMention { | |
id: number; | |
id_str: string; | |
indices: number[]; | |
name: string; | |
screen_name: string; | |
} | |
export interface TwitterSymbol { | |
indices: number[]; | |
text: string; | |
} | |
export interface TwitterPoll { | |
options: { | |
position: number; | |
text: string; | |
}[]; | |
end_datetime: string; | |
duration_minutes: number; | |
} | |
export interface TwitterMediaSizes { | |
thumb: TwitterSize; | |
large: TwitterSize; | |
medium: TwitterSize; | |
small: TwitterSize; | |
[key: string]: TwitterSize; | |
} | |
export interface TwitterSize { | |
w: number; | |
h: number; | |
resize: string; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment