2023-05-20 15:30:12 -05:00
|
|
|
package structs
|
|
|
|
|
2023-05-20 21:18:10 -05:00
|
|
|
// API RESPONSE
|
|
|
|
|
|
|
|
// To save space and readability, i'm taking this approach
|
|
|
|
// to fit to any response from twitch, and then define the
|
|
|
|
// specific parts later, because we don't need every part
|
|
|
|
// of the request
|
2023-05-20 16:18:23 -05:00
|
|
|
type TwitchApiResponse struct {
|
|
|
|
Data map[string]interface{} `json:"data"`
|
|
|
|
Extensions Extensions `json:"extensions"`
|
2023-05-20 15:30:12 -05:00
|
|
|
}
|
|
|
|
type Extensions struct {
|
|
|
|
DurationMilliseconds int `json:"durationMilliseconds"`
|
|
|
|
OperationName string `json:"operationName"`
|
|
|
|
RequestID string `json:"requestID"`
|
|
|
|
}
|
2023-05-20 21:18:10 -05:00
|
|
|
|
|
|
|
// PARTS OF RESPONSE
|
|
|
|
|
|
|
|
type RawSocial struct {
|
|
|
|
Name string `json:"name"`
|
|
|
|
Title string `json:"title"`
|
|
|
|
Url string `json:"url"`
|
|
|
|
}
|