Document and expose new clicks/shares analytics metrics

Requires https://github.com/WorldWideTelescope/wwt-constellations-backend/pull/37 .
This commit is contained in:
Peter Williams 2023-10-25 15:12:27 -04:00
Родитель 58fef25856
Коммит 21ca491deb
4 изменённых файлов: 14 добавлений и 2 удалений

Просмотреть файл

@ -46,6 +46,8 @@ The response is as follows:
"creation_date": $string[iso8601], // the creation date of this scene in ISO8601 format
"impressions": $int, // the number of impressions this scene has received
"likes": $int, // the number of likes this scene has received
"clicks": $int?, // the number of user clicks on the outgoing URL
"shares": $int?, // the number of times users have activated the share-link flow for this scene
}
]
}

Просмотреть файл

@ -38,5 +38,7 @@ The response is as follows:
"count": $int, // the number of scenes owned by this handle
"impressions": $int, // the total number of impressions received by this handle's scenes
"likes": $int, // the total number of likes received by this handle's scenes
"clicks": $int?, // the total number of outgoing-URL user clicks for this handle's scenes
"shares": $int?, // the total number of link-share clicks for this handle's scenes
},
}

Просмотреть файл

@ -30,9 +30,11 @@ The structure of the response is:
"display_name": $string, // the handle's display name
},
"creation_date": $string(iso8601), // the date this scene was created
"likes": $number, // the number of likes this scene has received
"likes": $int, // the number of likes this scene has received
"liked": $bool, // whether the logged-in user has "liked" this scene
"impressions": $number, // the number of impressions this scene has received
"impressions": $int, // the number of impressions this scene has received
"clicks": $int?, // the number of user clicks on the outgoing URL
"shares": $int?, // the number of times users have activated the share-link flow for this scene
"place": { // WWT camera information associated with this scene
// See "POST /handle/:handle/scene" docs for descriptions:
"ra_rad": $number,

Просмотреть файл

@ -118,6 +118,8 @@ class HandleSceneStats:
count: int
impressions: int
likes: int
clicks: Optional[int]
shares: Optional[int]
@dataclass_json(undefined="EXCLUDE")
@ -278,6 +280,8 @@ class SceneHydrated:
likes: int
liked: bool
impressions: int
clicks: Optional[int]
shares: Optional[int]
place: ScenePlace
content: SceneContentHydrated
text: str
@ -291,6 +295,8 @@ class SceneInfo:
creation_date: str
impressions: int
likes: int
clicks: Optional[int]
shares: Optional[int]
@dataclass_json(undefined="EXCLUDE")