api-docs-mirror/amino/docs.yml

655 lines
36 KiB
YAML

globals:
responses:
"*":
"200:0":
title: api:ok
description: The request was successful. This is not a separate response, but included in every 200 response's json
body: $api_codes.api:0
400:104:
title: Missing NDCDEVICEID
description: The NDCDEVICEID header was not included, or did not compute on amino servers
body: $api_codes.api:104
headers:
"*":
- name: NDCDEVICEID
description: The device id generated by the app. See
required: true
- name: NDC-MSG-SIG
description: Message signature (?) generated by the app
required: false
- name: SMDEVICEID
description: I don't know, seems to be a non-string hex number
required: false
- name: AUID
description: The auid (UUIDv4) generated on amino servers for this client, retrieved with GET /g/s/auid
required: false
vars:
query-strings:
all:
pageToken:
name: pageToken
description: page token for paginated requests
required: false
start:
name: start
description: paginated data index offset. Difference to
required: false
size:
name: size
description: max number of items to get for paginated requests
required: false
language:
name: language
description: Content language to be returned
required: false
pagingType:
name: pagingType
description: Seems to have no effect, default value is `t`
required: false
v:
name: v
description: Likely a verson number. Changing to numbers or strings, or omission, seems to have no effect
required: false
topic:
categoryKey:
name: categoryKey
description: Likely has to do with what type of items are returned. Logged out values seen include [`recommendation`, `fresh`]
required: false
moduleID:
name: moduleID
description: Unknown. Seems to be a UUIDv4 by default, changing this (even to invalid UUIDv4 strings) seems to have no effect
required: false
type:
name: type
description: the type of communities to get, observed include [`discover`, `discovery-list`]. Omission or arbitrary values will not fail the request, but will return zero values.
required: false
url-args:
topic:
variant:
name: variant
description: The variant of this topic item. Nonzero values seem to have no effect
required: false
request:
device:
POST:
lang: JSON
content:
{
"deviceID": "... <device id generated by the app>",
"bundleID": "com.narvii.amino.master <android app package?>",
"clientType": "100 <always 100>",
"timezone": "-300 <timezone number code>",
"systemPushEnabled": "true <true by default on new install>",
"locale": "en_US <locale string>",
"deviceToken": "... <device token generated by the app>",
"deviceTokenType": "1 <always 1?>",
"timestamp": "1579580530965 <request time in ms>"
}
client-config:
POST:
lang: JSON
content:
{
"packageName": "com.narvii.amino.master <android app package?>",
"versionCode": "00000 <likely app version, also sent in user-agent header next to package name>",
"androidAPI": "21 <Android api version. This example is 21, or android 5.0>",
"model": "SCH-R530U <Phone device model. This example is a US Cellular Galaxy S3>",
"device": "d2usc <Another way to identify the phone model>",
"timestamp": "1579580222209 <request time in ms>"
}
login:
POST:
lang: JSON
content:
{
"email": "... <account email address>",
"v": "2 <Unknown use, probably verson number. All integer values seem to work>",
"secret": "... <Login secret. Can be server supplied secret, or in the format \"0 <password>\"",
"deviceID": "... <NDCDEVICEID of this client>",
"clientType": "100 <Unknown meaning, always seems to be 100>",
"action": "normal <Unknown use>",
"timestamp": "1579754764781 <Login timestamp"
}
response:
device:
POST:
ok:
lang: JSON
content:
{
"devOptions": "null <?>"
}
client-config:
POST:
ok:
lang: JSON
content:
{
"clientConfig": {
"<->": "<Unknown, was empty in api calls made by my client>"
}
}
auid:
GET:
ok:
lang: JSON
content:
{
"auid": "... <UUIDv4>"
}
auth-config:
GET:
ok:
lang: JSON
content: {
"mobileSignUpProviderList": [8]
}
eventlog-profile:
GET:
ok:
lang: JSON
content:
{
"globalStrategyInfo": "{...} <json string literal with unknown meaning>",
"uid": "None <Unknown. Probably another UUIDv4>",
"contentLanguage": "en <Primary app language>",
"signUpStrategy": "2 <Signup method. Variants unknown>",
"landingOption": "4 <Landing option. Variants unknown>",
"interestPickerStyle": "3 <Style for the interest picker. Variants unknown>",
"auid": "... <This device's auid>",
"needTriggerInterestPicker": "true <unknown meaning>",
"participatedExperiments": {
"userVectorCommunitySimilarityChannel": 1,
"retentionSrPush": 2,
"landingOptionExp": 2,
"communitySearchExp": 2,
"communitySearchRerankExp": 1,
"<->": " <various AB experiment values>"
}
}
content-language-settings:
GET:
ok:
lang: JSON
content:
{
"contentLanguageSettings": {
"language": "en <The language preference>"
}
}
appearance-settings:
GET:
ok:
lang: JSON
content:
{
"backgroundMediaList": [
[
"100 <Media, always 100?>",
"... <URL to an image>",
"null <unknown purpose>"
]
]
}
community-configuration:
GET:
ok:
lang: JSON
content:
{
"configuration": {
"appearance": {},
"page": {},
"module": {
"post": {
"enabled": true,
"postType": {
"screeningRoom": {
"privilege": {
"type": "5 <Unknown use>",
"minLevel": "100 <Unknown use>"
},
"enabled": true
},
"story": "{...} <Same privilege format",
"liveMode": "{...} <Same privilege format",
"publicChatRooms": "{...} <Same privilege format"
}
},
"chat": {
"enabled": true,
"spamProtectionEnabled": true,
"avChat": {
"screeningRoomEnabled": true,
"audioEnabled": "true <Probably in-chat voice>",
"videoEnabled": "false <Probably in-chat video>",
"audio2Enabled": "true <Probably in-chat voice>"
},
"publicChat": "{...} <Same privilege format>"
}
},
"general": {
"videoUploadPolicy": 1
}
}
}
content-modules:
GET:
ok:
lang: JSON
content:
{
"contentModuleList": [
{
"-": "community cards",
"contentObjectType": "16 <Unknown, probably content type id>",
"contentPoolId": "en <Unknown, probably content language>",
"contentVariety": "1 <Unknown, appears to be related to dataUrl path>",
"createdTime": "2019-12-31T08:38:32Z <Likely content created at>",
"customizable": "false <Amino stuff seems to be false, ads seem true>",
"dataUrl": "/topic/0/feed/community?... <URL to this content, see GET /g/s/topic/0/feed...>",
"displayName": "Recommended Communities <Name to put on the header of this section",
"ext": {
"<->": " <Ads seem to have field `adUnitId`>"
},
"extensions": "null <Always seems to be null>",
"isVirtual": "false <Only discover topics button seems to be true>",
"moduleId": "... <UUIDv4 of this item>",
"moduleName": "Recommended Communities <Name of this module>",
"moduleType": "RecommendedCommunities <Type of this module. Related to contentObjectType?>",
"status": "0 <Appears to always be zero>",
"style": "GeneralCommunityCard <Style of this item>",
"topicLocked": "false <Unknown use of `locked` in this context",
"uid": "... <UUIDv4 of... something>",
"userRemovable": "false <Unknown, probably related to frontpage stuff being not remuvable>",
"visibility": "1 <Likely a visibility bool>"
},
{
"-": "an ad",
"contentObjectType": "151 <Unknown, probably content type id>",
"contentPoolId": " <Unknown, probably content language>",
"contentVariety": "0 <Unknown, appears to be related to dataUrl path>",
"createdTime": "2019-12-31T08:38:32Z <Likely content created at>",
"customizable": "true <Amino stuff seems to be false, ads seem true>",
"dataUrl": "/topic/0/feed/banner-ads?... <URL to this content, see GET /g/s/topic/0/feed...>",
"displayName": "Recommended Communities <Name to put on the header of this section",
"ext": {
"adUnitId": "703300 <ID to look up this ad. Used in GET `dataUrl`"
},
"extensions": "null <Always seems to be null>",
"isVirtual": "false <Only discover topics button seems to be true>",
"moduleId": "... <UUIDv4 of this item>",
"moduleName": "Little Red series for all EN users <Name of this module>",
"moduleType": "CustomizedBannerAds <Type of this module. Related to contentObjectType>",
"status": "0 <Appears to always be zero>",
"style": "BannerSizeMedium <Style of this item>",
"topicLocked": "false <Unknown use of `locked` in this context",
"uid": "... <UUIDv4 of... something>",
"userRemovable": "false <Unknown, probably related to frontpage stuff being not remuvable>",
"visibility": "1 <Likely a visibility bool>"
}
]
}
topic-banner-ads:
GET:
ok:
lang: JSON
content:
{
"allItemCount": "1 <Total returnable item count>",
"itemList": [
{
"adCampaignId": "803326 <Likely related to ad grouping by campaign, use unknown>",
"deepLink": "ndc://topic/1390058 <Likely a hard link to this item, root URL unknown>",
"imageUrl": "... <A URL to the image used, seems to be background images?>",
"objectId": "803326 <Seems to be the same as adCampaignId>",
"objectType": "153 <Type of this object. Matches those in GET /g/s/home/discover/content-modules/>",
"strategyInfo": {
"<->": "<This is a raw JSON string. It has been reformatted as JSON>",
"adUnitId": "703323 <Matches the adUnitId query string>",
"imageUrl": "... <A URL to the used image, seesm to be the same as parent object>",
"landingUrl": "... <Seems to match parent object>",
"objectId": "803326 <Seems to match parent object>",
"objectType": "ad_campaign <Unknown use>",
"reqId": "... <A UUIDv4, use unknown>",
"scenarioType": "banner-703323 <Seems to match banner-adUnitId, use unknown>",
"uiPos": "0 <Likely related to desired render position"
}
}
],
"paging": "{...} <Paging info>"
}
topic-story:
GET:
ok:
lang: JSON
content:
{
"allItemCount": "400 <Total returnable item count>",
"blogList": [
"{...} <full `blog` object>"
],
"communityInfoMapping": {
"<->": "<community id (ndcId) -> short info",
"192258706": {
"<->": " <Short amino community description>",
"endpoint": "Tik <Endpoint pointing to this community>",
"icon": "... <URL to the icon of this community",
"name": "-TikTok Amino- <Name of this community>",
"ndcId": "192258706 <Number ID of this community>",
"status": "0 <Unknown>"
}
},
"paging": "{...} <Paging info>"
}
topic-communities:
GET:
ok:
lang: JSON
content:
{
"allItemCount": "100 <Total returnable item count>",
"communityList": [
"{...} <Community object>"
],
"paging": "{...} <Paging info>"
}
live-layer:
GET:
ok:
lang: JSON
content:
{
"communityInfoMapping": {
"<ndcId>": "{...} <Community object>"
},
"paging": "{...} <Paging info>",
"playlistInThreadList": {
"<->": " <Info about videos playing in chat threads>",
"<UUIDv4 thread id>": {
"currentItemIndex": "14 <Playlist length>",
"currentItemStatus": "2 <Likely playlist current index>",
"items": [
"{...} <Youtube video object>"
]
}
},
"threadList": [
"{...} <Chat thread object>"
],
"userInfoInThread": {
"<->": " <Info about users in chat threads>",
"<UUIDv4 thread id>": {
"userProfileCount": 2,
"userProfileList": [
"{...} <User object>"
]
}
}
}
announcement:
GET:
ok:
lang: JSON
content:
{
"blogList": [
"{...} <Blog object. Always by System (UUIDv4 all 0's)>"
]
}
login:
POST:
ok:
lang: JSON
content:
{
"account": {
"<->": " <This differs from regular profile info in that it is privileged information>",
"activation": "1 <Unknown use>",
"phoneNumber": "null <Account linked phone number>",
"phoneNumberActivation": "0 <Likely related to phone verification, in the same way as with email",
"email": "... <User email>",
"emailActivation": "1 <Email activation, 1 / 0 bool>",
"username": "null <Unknown>",
"uid": "... <UUIDv4 of this user>",
"aminoIdEditable": "true <May the aminoId be changed? (I believe that one lifetime change is allowed)>",
"membership": "null <Probably related to paid membership>",
"aminoId": "BooruBot <Unique aminoId that points to this user>",
"mediaList": "null <Unknown use, probably a list of media objects>",
"icon": "... <Link to this user's profile image>",
"nickname": "BooruBot <Non-unique account global (non-community) nickname>",
"role": "0 <Unknown. Probably related to admin / curator roles in communities, N / A globally (unless amino admin?)>",
"securityLevel": "3 <Unknown use. Probably related to admin / moderator only visibility stuff>",
"status": "0 <Unknown, probably also related to admin / moderator. Could also be ban / mute status>",
"dateOfBirth": "null <User birthdate>",
"address": "null <Likely related to physical city / street address>",
"latitude": "null <Physical latitude>",
"longitude": "null <Physical longitude>",
"facebookID": "null <Linked facebook profile>",
"googleID": "null <Linked google profile>",
"twitterID": "null <Linked twitter profile>",
"gender": "null <User gender>",
"createdTime": "2019-05-16T03:47:29Z <Account creation time>",
"modifiedTime": "2019-08-15T06:39:15Z <Account last modified time>",
"advancedSettings": "{...} <Unknown settings>",
"extensions": {
"adsEnabled": "true <Are ads enabled? Probably related to amino paid membership. Useable for adblock?>",
"adsFlags": "11 <Unknown, probably has to do with ad selection>",
"adsLevel": "1 <Unknown, probably has to do with ad frequency>",
"contentLanguage": "en <Primary app language>",
"deviceInfo": {
"lastClientType": "100 <Client type used before this. Always 100? All mobile 100?>"
}
},
},
"auid": "... <UUIDv4 of this device>",
"secret": "... <Secret that may be used for logging in. Appears to contain device auid, ipv4 address, and other stuff>",
"sid": "... <session ID>",
"userProfile": "{...} <User object>"
}
incorrect-info:
lang: JSON
content:
{
"api:message": "Account or password is incorrect! If you forget your password, please reset it.",
"api:timestamp": "2020-01-23T04:44:36Z <API timestamp>",
"api:statuscode": "200 <Statuscode 200 represents bad credentials>",
"api:duration": "0.016s <Processing time>"
}
api_codes:
api:104:
lang: JSON
content:
{
"api:message": "Invalid Request. Please update to the latest version. If the problem continues, please contact us.",
"api:timestamp": "2020-01-22T22:11:28Z <API timestamp>",
"api:statuscode": "104 <Statuscode 104 represents a bad NDCDEVICEID header>",
"api:duration": "0.000s <Processing time>"
}
api:0:
lang: JSON
content:
{
"api:message": "OK",
"api:timestamp": "2020-01-22T23:49:13Z <API timestamp>",
"api:statuscode": "0 <Statuscode 0 is ok>",
"api:duration": "0.010s <Processing time>"
}
routes:
# Does not require auth
/g/s/device/:
POST:
description: POST a device configuration
body: $request.device.POST
responses:
"200":
title: Device Configured
description: The device config was accepted
body: $response.device.POST.ok
/g/s/auid/:
GET:
description: GET an auid for this device
query strings:
- name: deviceId
description: Same as NDCDEVICEID
required: true
responses:
"200":
title: auid Generated
description: An auid was generated and returned by the server. It may now be used in request headers
body: $response.auid.GET.ok
/g/s/client-config/:
POST:
description: POST device information for configuration. Likely related to analytics / telemetry
body: $request.client-config.POST
responses:
"200":
title: Client Configured
description: The client config was accepted
body: $response.client-config.POST.ok
/g/s/client-config/content-language-settings/:
GET:
description: GET the app content language settings
responses:
"200":
title: Language Settings
description: The language settings were retrieved
body: $response.content-language-settings.GET.ok
/g/s/client-config/appearance-settings:
GET:
description: GET the app appearance settings
responses:
"200":
title: Appearance Settings
description: The appearance objects to use was retrieved
body: $response.appearance-settings.GET.ok
/g/s/auth/config-v2/:
GET:
description: GET auth config data (unknown use)
responses:
"200":
title: Config Recieved
description: Data with an unknown purpose is recieved
body: $response.auth-config.GET.ok
/g/s/eventlog/profile/:
GET:
description: GET the eventlog for the current profile (appears to be device profile by auid, not necessarily amino profile)
query strings:
- name: language
description: language code used, example being `en`. Affects experiments
required: false
responses:
"200":
title: Eventlog Retrieved
description: The eventlog for this device profile. This data appears to be related to AB experiments
body: $response.eventlog-profile.GET.ok
/g/s/community/configuration/:
GET:
description: GET community config info
responses:
"200":
title: Community Config
description: Community config was retrieved
body: $response.community-configuration.GET.ok
/g/s/home/discover/content-modules/:
GET:
description: GET content modules for homepage discovery. This includes community info, stories, ads, ect
query strings:
- $query-strings.all.v
responses:
"200":
title: Content Modules
description: discovery content modules were retrieved
body: $response.content-modules.GET.ok
/g/s/topic/:variant/feed/banner-ads/:
GET:
description: GET a piece of media for a topic. Usually seems to be used in homepage exploration
url arguments:
- $url-args.topic.variant
query strings:
- name: adUnitId
description: The id of this add, which is a number
required: true
- $query-strings.all.pagingType
- $query-strings.all.size
- $query-strings.topic.categoryKey
responses:
"200":
title: Banner Ads Retrieved
description: The banner ads matching this id were retrieved
body: $response.topic-banner-ads.GET.ok
/g/s/topic/:variant/feed/story/:
GET:
description: GET a list of blogs for a topic. Usually for homepage display
url arguments:
- $url-args.topic.variant
query strings:
- $query-strings.all.v
- $query-strings.topic.type
- $query-strings.topic.categoryKey
- $query-strings.all.size
- $query-strings.all.pageToken
- $query-strings.all.pagingType
responses:
"200":
title: Blogs Retrieved
description: The blogs for frontpage display were retrieved
body: $response.topic-story.GET.ok
/g/s/topic/:variant/feed/community/:
GET:
description: GET a list of communities. Usually for homepage display
url arguments:
- $url-args.topic.variant
query strings:
- $query-strings.topic.type
- $query-strings.topic.categoryKey
- $query-strings.all.size
- $query-strings.all.pageToken
- $query-strings.all.pagingType
responses:
"200":
title: Communities Retrieved
description: The communities for frontpage display were retrieved
body: $response.topic-communities.GET.ok
/g/s/live-layer/public-chats/:
GET:
description: GET the active public chats and information about who is in them.
query strings:
- $query-strings.all.pageToken
- $query-strings.all.size
responses:
"200":
title: Chats Retrieved
description: Chat info and users were retrieved
body: $response.live-layer.GET.ok
/g/s/announcement/:
GET:
description: GET the announcement blog list
query string:
- $query-strings.all.language
- $query-strings.all.start
- $query-strings.all.size
responses:
"200":
title: Announcements Retrieved
description: Current announcement blogs were retrieved
body: $response.announcement.GET.ok
# On login
/g/s/auth/login/:
POST:
description: Log in with credentials
body: $request.login.POST
responses:
"200":
title: Login Successful
description: The login was successful and account information was sent
body: $response.login.POST.ok
400:200:
title: Login Unsuccessful
description: The supplied credentials were not correct
body: $response.login.POST.incorrect-info