Documentation
¶
Index ¶
- Constants
- func AccountPageUrl(page string, sortOrder AccountSortOrder, updated bool, hidden bool) *url.URL
- func AddTagUrl(productId, tagId string) *url.URL
- func AddToWishlist(httpClient *http.Client, ids ...string) error
- func AddToWishlistUrl(id string) *url.URL
- func ApiProductV1Url(id string) *url.URL
- func ApiProductV2Url(id string) *url.URL
- func AuthHostUrl() *url.URL
- func CatalogOrder(sortBy CatalogSortOrder, desc bool) string
- func CatalogPageUrl(page string, sortBy CatalogSortOrder, desc bool) *url.URL
- func CreateTagUrl(name string) *url.URL
- func DefaultAccountPageUrl(page string) *url.URL
- func DefaultCatalogPageUrl(page string) *url.URL
- func DefaultLicencesUrl(_ string) *url.URL
- func DefaultOrdersPageUrl(page string) *url.URL
- func DefaultUserWishlistUrl(_ string) *url.URL
- func DeleteTagUrl(tagId string) *url.URL
- func DetailsUrl(id string) *url.URL
- func ImageId(imageUrl string) string
- func ImageUrl(imageId, ext string) (*url.URL, error)
- func LicencesUrl() *url.URL
- func LoggedIn(client *http.Client) (bool, error)
- func Login(client *http.Client, username, password string, ...) error
- func LoginCheckUrl() *url.URL
- func LoginHostUrl() *url.URL
- func LoginTwoStepUrl() *url.URL
- func ManualDownloadUrl(manualDownload string) *url.URL
- func OnLoginSuccessUrl() *url.URL
- func OrdersPageUrl(page string, ...) *url.URL
- func ReCaptchaUrl() *url.URL
- func RemoveFromWishlist(httpClient *http.Client, ids ...string) error
- func RemoveFromWishlistUrl(id string) *url.URL
- func RemoveTagUrl(productId, tagId string) *url.URL
- func ScreenshotsJpgUrls(screenshots []string) ([]*url.URL, error)
- func UpdateTagsUrl(tagsJson string) *url.URL
- func UserDataUrl() *url.URL
- func UserWishlistUrl() *url.URL
- type AccountPage
- type AccountProduct
- func (ap *AccountProduct) GetGlobalRelease() string
- func (ap *AccountProduct) GetId() int
- func (ap *AccountProduct) GetImage() string
- func (ap *AccountProduct) GetOperatingSystems() []string
- func (ap *AccountProduct) GetRating() string
- func (ap *AccountProduct) GetSlug() string
- func (ap *AccountProduct) GetStoreUrl() string
- func (ap *AccountProduct) GetTagIds() []string
- func (ap *AccountProduct) GetTitle() string
- type AccountSortOrder
- type AddRemoveTagResp
- type AdditionalRequirementsGetter
- type AmountCurrency
- type ApiProductV1
- func (apv1 *ApiProductV1) GetChangelog() string
- func (apv1 *ApiProductV1) GetDescriptionFeatures() string
- func (apv1 *ApiProductV1) GetDescriptionOverview() string
- func (apv1 *ApiProductV1) GetForumUrl() string
- func (apv1 *ApiProductV1) GetGOGRelease() string
- func (apv1 *ApiProductV1) GetId() int
- func (apv1 *ApiProductV1) GetInDevelopment() bool
- func (apv1 *ApiProductV1) GetNativeLanguages() map[string]string
- func (apv1 *ApiProductV1) GetOperatingSystems() []string
- func (apv1 *ApiProductV1) GetPreOrder() bool
- func (apv1 *ApiProductV1) GetScreenshots() []string
- func (apv1 *ApiProductV1) GetSlug() string
- func (apv1 *ApiProductV1) GetStoreUrl() string
- func (apv1 *ApiProductV1) GetSupportUrl() string
- func (apv1 *ApiProductV1) GetTitle() string
- func (apv1 *ApiProductV1) GetVideoIds() []string
- type ApiProductV2
- func (apv2 *ApiProductV2) GetAdditionalRequirements() string
- func (apv2 *ApiProductV2) GetCopyrights() string
- func (apv2 *ApiProductV2) GetDescriptionFeatures() string
- func (apv2 *ApiProductV2) GetDescriptionOverview() string
- func (apv2 *ApiProductV2) GetDevelopers() []string
- func (apv2 *ApiProductV2) GetFeatures() []string
- func (apv2 *ApiProductV2) GetForumUrl() string
- func (apv2 *ApiProductV2) GetGOGRelease() string
- func (apv2 *ApiProductV2) GetGenres() []string
- func (apv2 *ApiProductV2) GetGlobalRelease() string
- func (apv2 *ApiProductV2) GetId() int
- func (apv2 *ApiProductV2) GetImage() string
- func (apv2 *ApiProductV2) GetInDevelopment() bool
- func (apv2 *ApiProductV2) GetIncludesGames() []string
- func (apv2 *ApiProductV2) GetIsIncludedInGames() []string
- func (apv2 *ApiProductV2) GetIsRequiredByGames() []string
- func (apv2 *ApiProductV2) GetLanguageCodes() []string
- func (apv2 *ApiProductV2) GetLanguages() map[string]string
- func (apv2 *ApiProductV2) GetOperatingSystems() []string
- func (apv2 *ApiProductV2) GetPreOrder() bool
- func (apv2 *ApiProductV2) GetProductType() string
- func (apv2 *ApiProductV2) GetPublishers() []string
- func (apv2 *ApiProductV2) GetRequiresGames() []string
- func (apv2 *ApiProductV2) GetScreenshots() []string
- func (apv2 *ApiProductV2) GetSeries() string
- func (apv2 *ApiProductV2) GetStoreTags() []string
- func (apv2 *ApiProductV2) GetStoreUrl() string
- func (apv2 *ApiProductV2) GetSupportUrl() string
- func (apv2 *ApiProductV2) GetTitle() string
- func (apv2 *ApiProductV2) GetVerticalImage() string
- func (apv2 *ApiProductV2) GetVideoIds() []string
- func (apv2 *ApiProductV2) IsUsingDOSBox() bool
- func (apv2 *ApiProductV2) IsUsingScummVM() bool
- type BasePriceGetter
- type CatalogFilters
- type CatalogPage
- type CatalogPrice
- type CatalogProduct
- func (cp *CatalogProduct) GetBasePrice() string
- func (cp *CatalogProduct) GetComingSoon() bool
- func (cp *CatalogProduct) GetDevelopers() []string
- func (cp *CatalogProduct) GetDiscountPercentage() int
- func (cp *CatalogProduct) GetFeatures() []string
- func (cp *CatalogProduct) GetGenres() []string
- func (cp *CatalogProduct) GetGlobalRelease() string
- func (cp *CatalogProduct) GetId() int
- func (cp *CatalogProduct) GetImage() string
- func (cp *CatalogProduct) GetInDevelopment() bool
- func (cp *CatalogProduct) GetOperatingSystems() []string
- func (cp *CatalogProduct) GetPreOrder() bool
- func (cp *CatalogProduct) GetPrice() string
- func (cp *CatalogProduct) GetProductType() string
- func (cp *CatalogProduct) GetPublishers() []string
- func (cp *CatalogProduct) GetRating() string
- func (cp *CatalogProduct) GetScreenshots() []string
- func (cp *CatalogProduct) GetSlug() string
- func (cp *CatalogProduct) GetStoreTags() []string
- func (cp *CatalogProduct) GetTitle() string
- func (cp *CatalogProduct) GetVerticalImage() string
- func (cp *CatalogProduct) IsDiscounted() bool
- func (cp *CatalogProduct) IsFree() bool
- type CatalogSortOrder
- type ChangelogGetter
- type ComingSoonGetter
- type CopyrightsGetter
- type CreateTagResp
- type DeleteTagResp
- type DescriptionFeaturesGetter
- type DescriptionOverviewGetter
- type Details
- func (det *Details) GetChangelog() string
- func (det *Details) GetFeatures() []string
- func (det *Details) GetForumUrl() string
- func (det *Details) GetGOGRelease() string
- func (det *Details) GetGameDownloads() ([]LangOSManualDownloads, error)
- func (det *Details) GetMovieDownloads() ([]ManualDownload, error)
- func (det *Details) GetTagIds() []string
- func (det *Details) GetTagNames(tagIds []string) map[string]string
- func (det *Details) GetTitle() string
- type DevelopersGetter
- type DiscountPercentageGetter
- type FeaturesGetter
- type ForumUrlGetter
- type GOGReleaseGetter
- type GenresGetter
- type GlobalReleaseGetter
- type IdGetter
- type ImageGetter
- type InDevelopmentGetter
- type IncludesGamesGetter
- type IsDiscountedGetter
- type IsFreeGetter
- type IsIncludedInGamesGetter
- type IsRequiredByGamesGetter
- type IsUsingDOSBoxGetter
- type IsUsingScummVMGetter
- type LangOSManualDownloads
- type LanguageCodesGetter
- type LanguagesGetter
- type Licence
- type Licences
- type ManualDownload
- type NameSlug
- type NativeLanguagesGetter
- type OperatingSystemsGetter
- type Order
- type OrderPage
- type PreOrderGetter
- type PriceGetter
- type ProductTypeGetter
- type ProductsGetter
- type PublishersGetter
- type RatingGetter
- type RequiresGamesGetter
- type ScreenshotsGetter
- type SeriesGetter
- type SlugGetter
- type StoreTagsGetter
- type StoreUrlGetter
- type SupportUrlGetter
- type TagIdsGetter
- type TagNamesGetter
- type TitleGetter
- type TotalPagesGetter
- type TotalPagesProxy
- type UserData
- type UserPreferredLanguage
- type UserWishlist
- type VerticalImageGetter
- type VideoIdsGetter
Constants ¶
const ( AccountSortByTitle AccountSortOrder = "title" AccountSortByPurchaseDate = "date_purchased" AccountSortByTags = "tags" AccountSortByOldestFirst = "release_date_asc" AccountSortByNewestFirst = "release_date_asc" )
const ( CatalogProductStateDefault = "default" CatalogProductStateComingSoon = "coming-soon" CatalogProductStateEarlyAccess = "early-access" CatalogProductStatePreOrder = "pre-order" )
const ( Ascending = "asc" Descending = "desc" )
const ( PngExt = ".png" JpgExt = ".jpg" )
const ( OrderStatusGiftByMe = "gift_by_me" OrderStatusGiftForMe = "gift_for_me" OrderStatusPurchase = "purchase" OrderStatusRefund = "refund" )
const ( GogHost = "gog.com" WwwGogHost = "www." + GogHost ItemsHost = "items." + GogHost CatalogHost = "catalog." + GogHost )
hosts
const GameMedia = "game"
const (
HttpsScheme = "https"
)
Variables ¶
This section is empty.
Functions ¶
func AccountPageUrl ¶
func AddToWishlist ¶ added in v0.1.20
func AddToWishlistUrl ¶
func ApiProductV1Url ¶
func ApiProductV2Url ¶
func AuthHostUrl ¶
func CatalogOrder ¶ added in v0.1.24
func CatalogOrder(sortBy CatalogSortOrder, desc bool) string
func CatalogPageUrl ¶ added in v0.1.21
func CatalogPageUrl(page string, sortBy CatalogSortOrder, desc bool) *url.URL
func CreateTagUrl ¶
func DefaultAccountPageUrl ¶
func DefaultCatalogPageUrl ¶ added in v0.1.21
func DefaultLicencesUrl ¶
func DefaultOrdersPageUrl ¶
func DefaultUserWishlistUrl ¶ added in v0.1.28
func DeleteTagUrl ¶
func DetailsUrl ¶
func LicencesUrl ¶
func Login ¶
Login to GOG.com for account formData queries using username and password
Overall flow is: - Get auth token from the page (this would check for reCaptcha as well) - Post username, password and token for check - Check for presence of second step auth token - (Optional) Post 4 digit second step auth code
func LoginCheckUrl ¶
func LoginHostUrl ¶
func LoginTwoStepUrl ¶
func ManualDownloadUrl ¶
func OnLoginSuccessUrl ¶
func OrdersPageUrl ¶
func ReCaptchaUrl ¶
func RemoveFromWishlist ¶ added in v0.1.20
func RemoveFromWishlistUrl ¶
func RemoveTagUrl ¶
func UpdateTagsUrl ¶
func UserDataUrl ¶
func UserWishlistUrl ¶ added in v0.1.27
Types ¶
type AccountPage ¶
type AccountPage struct { TotalPages int `json:"totalPages"` Page int `json:"page"` SortBy string `json:"sortBy"` TotalProducts int `json:"totalProducts"` ProductsPerPage int `json:"productsPerPage"` // TODO: find data examples where ContentSystemCompatibility is not empty and create a type from that ContentSystemCompatibility interface{} `json:"contentSystemCompatibility"` MoviesCount int `json:"moviesCount"` Tags []accountTag `json:"tags"` Products []AccountProduct `json:"products"` UpdatedProductsCount int `json:"updatedProductsCount"` HiddenUpdatedProductsCount int `json:"hiddenUpdatedProductsCount"` AppliedFilters struct { Tags []struct { Id string `json:"id"` Name string `json:"name"` ProductCount string `json:"productCount"` } `json:"tags"` } `json:"appliedFilters"` HasHiddenProducts bool `json:"hasHiddenProducts"` }
func (*AccountPage) GetProducts ¶
func (app *AccountPage) GetProducts() []IdGetter
func (*AccountPage) GetTagIds ¶
func (app *AccountPage) GetTagIds() []string
func (*AccountPage) GetTagNames ¶
func (app *AccountPage) GetTagNames(tagIds []string) map[string]string
func (*AccountPage) GetTotalPages ¶ added in v0.1.22
func (app *AccountPage) GetTotalPages() int
type AccountProduct ¶
type AccountProduct struct { IsGalaxyCompatible bool `json:"isGalaxyCompatible"` Tags []string `json:"tags"` Id int `json:"id"` Availability struct { IsAvailable bool `json:"isAvailable"` IsAvailableInAccount bool `json:"isAvailableInAccount"` } `json:"availability"` Title string `json:"title"` Image string `json:"image"` Url string `json:"url"` WorksOn struct { Windows bool `json:"Windows"` Mac bool `json:"Mac"` Linux bool `json:"Linux"` } `json:"worksOn"` Category string `json:"category"` Rating int `json:"rating"` IsComingSoon bool `json:"isComingSoon"` IsMovie bool `json:"isMovie"` IsGame bool `json:"isGame"` Slug string `json:"slug"` Updates int `json:"updates"` IsNew bool `json:"isNew"` DlcCount int `json:"dlcCount"` ReleaseDate struct { Date string `json:"date"` TimezoneType int `json:"timezone_type"` Timezone string `json:"timezone"` } `json:"releaseDate"` IsBaseProductMissing bool `json:"isBaseProductMissing"` IsHidingDisabled bool `json:"isHidingDisabled"` IsInDevelopment bool `json:"isInDevelopment"` IsHidden bool `json:"isHidden"` }
func (*AccountProduct) GetGlobalRelease ¶ added in v0.1.31
func (ap *AccountProduct) GetGlobalRelease() string
func (*AccountProduct) GetId ¶
func (ap *AccountProduct) GetId() int
func (*AccountProduct) GetImage ¶
func (ap *AccountProduct) GetImage() string
func (*AccountProduct) GetOperatingSystems ¶
func (ap *AccountProduct) GetOperatingSystems() []string
func (*AccountProduct) GetRating ¶
func (ap *AccountProduct) GetRating() string
func (*AccountProduct) GetSlug ¶
func (ap *AccountProduct) GetSlug() string
func (*AccountProduct) GetStoreUrl ¶ added in v0.1.6
func (ap *AccountProduct) GetStoreUrl() string
func (*AccountProduct) GetTagIds ¶
func (ap *AccountProduct) GetTagIds() []string
func (*AccountProduct) GetTitle ¶
func (ap *AccountProduct) GetTitle() string
type AccountSortOrder ¶
type AccountSortOrder string
type AddRemoveTagResp ¶
type AddRemoveTagResp struct {
Success bool `json:"success"`
}
type AdditionalRequirementsGetter ¶ added in v0.1.17
type AdditionalRequirementsGetter interface {
GetAdditionalRequirements() string
}
type AmountCurrency ¶ added in v0.1.21
type ApiProductV1 ¶
type ApiProductV1 struct { Id int `json:"id"` Title string `json:"title"` PurchaseLink string `json:"purchase_link"` Slug string `json:"slug"` ContentSystemCompatibility struct { Windows bool `json:"windows"` Osx bool `json:"osx"` Linux bool `json:"linux"` } `json:"content_system_compatibility"` //see comment on top of commented out implementation of GetDLCs() //that applies here as well - empty maps are passed as [] by GOG Languages interface{} `json:"languages"` Links struct { PurchaseLink string `json:"purchase_link"` ProductCard string `json:"product_card"` Support string `json:"support"` Forum string `json:"forum"` } `json:"links"` InDevelopment struct { Active bool `json:"active"` Until interface{} `json:"until"` } `json:"in_development"` IsSecret bool `json:"is_secret"` IsInstallable bool `json:"is_installable"` GameType string `json:"game_type"` IsPreOrder bool `json:"is_pre_order"` ReleaseDate string `json:"release_date"` Images images `json:"images"` //see comment on top of commented out implementation of GetDLCs() //that explains why DLCs is an interface and not a struct DLCs interface{} `json:"dlcs"` Downloads struct { Installers []downloadFiles `json:"installers"` Patches []downloadFiles `json:"patches"` LanguagePacks []downloadFiles `json:"language_packs"` BonusContent []bonusFiles `json:"bonus_content"` } `json:"downloads"` ExpandedDLCs []ApiProductV1 `json:"expanded_dlcs"` Description struct { Lead string `json:"lead"` Full string `json:"full"` WhatsCoolAboutIt string `json:"whats_cool_about_it"` } `json:"description"` Screenshots []struct { ImageId string `json:"image_id"` FormatterTemplateUrl string `json:"formatter_template_url"` FormattedImages []struct { FormatterName string `json:"formatter_name"` ImageUrl string `json:"image_url"` } `json:"formatted_images"` } `json:"screenshots"` Videos []struct { VideoUrl string `json:"video_url"` ThumbnailUrl string `json:"thumbnail_url"` Provider string `json:"provider"` } `json:"videos"` RelatedProducts []ApiProductV1 `json:"related_products"` Changelog string `json:"changelog"` }
func (*ApiProductV1) GetChangelog ¶ added in v0.1.6
func (apv1 *ApiProductV1) GetChangelog() string
func (*ApiProductV1) GetDescriptionFeatures ¶ added in v0.1.14
func (apv1 *ApiProductV1) GetDescriptionFeatures() string
func (*ApiProductV1) GetDescriptionOverview ¶ added in v0.1.14
func (apv1 *ApiProductV1) GetDescriptionOverview() string
func (*ApiProductV1) GetForumUrl ¶ added in v0.1.6
func (apv1 *ApiProductV1) GetForumUrl() string
func (*ApiProductV1) GetGOGRelease ¶
func (apv1 *ApiProductV1) GetGOGRelease() string
func (*ApiProductV1) GetId ¶
func (apv1 *ApiProductV1) GetId() int
func (*ApiProductV1) GetInDevelopment ¶ added in v0.1.15
func (apv1 *ApiProductV1) GetInDevelopment() bool
func (*ApiProductV1) GetNativeLanguages ¶
func (apv1 *ApiProductV1) GetNativeLanguages() map[string]string
func (*ApiProductV1) GetOperatingSystems ¶
func (apv1 *ApiProductV1) GetOperatingSystems() []string
func (*ApiProductV1) GetPreOrder ¶ added in v0.1.15
func (apv1 *ApiProductV1) GetPreOrder() bool
func (*ApiProductV1) GetScreenshots ¶
func (apv1 *ApiProductV1) GetScreenshots() []string
func (*ApiProductV1) GetSlug ¶
func (apv1 *ApiProductV1) GetSlug() string
func (*ApiProductV1) GetStoreUrl ¶ added in v0.1.6
func (apv1 *ApiProductV1) GetStoreUrl() string
func (*ApiProductV1) GetSupportUrl ¶ added in v0.1.6
func (apv1 *ApiProductV1) GetSupportUrl() string
func (*ApiProductV1) GetTitle ¶
func (apv1 *ApiProductV1) GetTitle() string
func (*ApiProductV1) GetVideoIds ¶
func (apv1 *ApiProductV1) GetVideoIds() []string
type ApiProductV2 ¶
type ApiProductV2 struct { InDevelopment struct { Active bool `json:"active"` } `json:"inDevelopment"` Copyrights string `json:"copyrights"` IsUsingDosBox bool `json:"isUsingDosBox"` Description string `json:"description"` Size int `json:"size"` Overview string `json:"overview"` FeaturesDescription string `json:"featuresDescription"` AdditionalRequirements string `json:"additionalRequirements"` Links links `json:"_links"` Embedded struct { Product product `json:"product"` ProductType string `json:"productType"` Localizations []localization `json:"localizations"` Videos []video `json:"videos"` Bonuses []bonus `json:"bonuses"` Screenshots []screenshot `json:"screenshots"` Publisher name `json:"publisher"` Developers []name `json:"developers"` SupportedOperatingSystems []supportedOperatingSystem `json:"supportedOperatingSystems"` Tags []tag `json:"tags"` Properties []property `json:"properties"` ESRBRating esrbRating `json:"esrbRating"` PEGIRating pegiRating `json:"pegiRating"` USKRating uskRating `json:"uskRating"` BRRating brRating `json:"brRating"` Features []struct { Id string `json:"id"` // contains filtered or unexported fields } `json:"features"` Editions []edition `json:"editions"` Series struct { Id int `json:"id"` // contains filtered or unexported fields } `json:"series"` } `json:"_embedded"` }
func (*ApiProductV2) GetAdditionalRequirements ¶ added in v0.1.17
func (apv2 *ApiProductV2) GetAdditionalRequirements() string
func (*ApiProductV2) GetCopyrights ¶ added in v0.1.11
func (apv2 *ApiProductV2) GetCopyrights() string
func (*ApiProductV2) GetDescriptionFeatures ¶ added in v0.1.14
func (apv2 *ApiProductV2) GetDescriptionFeatures() string
func (*ApiProductV2) GetDescriptionOverview ¶ added in v0.1.14
func (apv2 *ApiProductV2) GetDescriptionOverview() string
func (*ApiProductV2) GetDevelopers ¶
func (apv2 *ApiProductV2) GetDevelopers() []string
func (*ApiProductV2) GetFeatures ¶
func (apv2 *ApiProductV2) GetFeatures() []string
func (*ApiProductV2) GetForumUrl ¶ added in v0.1.6
func (apv2 *ApiProductV2) GetForumUrl() string
func (*ApiProductV2) GetGOGRelease ¶
func (apv2 *ApiProductV2) GetGOGRelease() string
func (*ApiProductV2) GetGenres ¶
func (apv2 *ApiProductV2) GetGenres() []string
func (*ApiProductV2) GetGlobalRelease ¶
func (apv2 *ApiProductV2) GetGlobalRelease() string
func (*ApiProductV2) GetId ¶
func (apv2 *ApiProductV2) GetId() int
func (*ApiProductV2) GetImage ¶
func (apv2 *ApiProductV2) GetImage() string
func (*ApiProductV2) GetInDevelopment ¶ added in v0.1.15
func (apv2 *ApiProductV2) GetInDevelopment() bool
func (*ApiProductV2) GetIncludesGames ¶
func (apv2 *ApiProductV2) GetIncludesGames() []string
func (*ApiProductV2) GetIsIncludedInGames ¶
func (apv2 *ApiProductV2) GetIsIncludedInGames() []string
func (*ApiProductV2) GetIsRequiredByGames ¶
func (apv2 *ApiProductV2) GetIsRequiredByGames() []string
func (*ApiProductV2) GetLanguageCodes ¶
func (apv2 *ApiProductV2) GetLanguageCodes() []string
func (*ApiProductV2) GetLanguages ¶
func (apv2 *ApiProductV2) GetLanguages() map[string]string
func (*ApiProductV2) GetOperatingSystems ¶
func (apv2 *ApiProductV2) GetOperatingSystems() []string
func (*ApiProductV2) GetPreOrder ¶ added in v0.1.15
func (apv2 *ApiProductV2) GetPreOrder() bool
func (*ApiProductV2) GetProductType ¶ added in v0.1.8
func (apv2 *ApiProductV2) GetProductType() string
func (*ApiProductV2) GetPublishers ¶ added in v0.1.21
func (apv2 *ApiProductV2) GetPublishers() []string
func (*ApiProductV2) GetRequiresGames ¶
func (apv2 *ApiProductV2) GetRequiresGames() []string
func (*ApiProductV2) GetScreenshots ¶
func (apv2 *ApiProductV2) GetScreenshots() []string
func (*ApiProductV2) GetSeries ¶
func (apv2 *ApiProductV2) GetSeries() string
func (*ApiProductV2) GetStoreTags ¶ added in v0.1.21
func (apv2 *ApiProductV2) GetStoreTags() []string
GetStoreTags returns values displayed in Store as "Tags". ApiProductV2 has store tags in Properties
func (*ApiProductV2) GetStoreUrl ¶ added in v0.1.6
func (apv2 *ApiProductV2) GetStoreUrl() string
func (*ApiProductV2) GetSupportUrl ¶ added in v0.1.6
func (apv2 *ApiProductV2) GetSupportUrl() string
func (*ApiProductV2) GetTitle ¶
func (apv2 *ApiProductV2) GetTitle() string
func (*ApiProductV2) GetVerticalImage ¶ added in v0.2.7
func (apv2 *ApiProductV2) GetVerticalImage() string
func (*ApiProductV2) GetVideoIds ¶
func (apv2 *ApiProductV2) GetVideoIds() []string
func (*ApiProductV2) IsUsingDOSBox ¶ added in v0.1.15
func (apv2 *ApiProductV2) IsUsingDOSBox() bool
func (*ApiProductV2) IsUsingScummVM ¶ added in v0.1.18
func (apv2 *ApiProductV2) IsUsingScummVM() bool
type BasePriceGetter ¶ added in v0.1.19
type BasePriceGetter interface {
GetBasePrice() string
}
type CatalogFilters ¶ added in v0.1.21
type CatalogFilters struct { ReleaseDateRange struct { Min int `json:"min"` Max int `json:"max"` } `json:"releaseDateRange"` PriceRange struct { Min float64 `json:"min"` Max float64 `json:"max"` Currency string `json:"currency"` DecimalPlaces int `json:"decimalPlaces"` } `json:"priceRange"` Genres []NameSlug `json:"genres"` Languages []NameSlug `json:"languages"` Systems []NameSlug `json:"systems"` Tags []NameSlug `json:"tags"` Discounted bool `json:"discounted"` Features []NameSlug `json:"features"` ReleaseStatuses []NameSlug `json:"releaseStatuses"` Types []string `json:"types"` FullGenresList []struct { NameSlug Level int `json:"level"` } `json:"fullGenresList"` FullTagsList []NameSlug `json:"fullTagsList"` }
type CatalogPage ¶ added in v0.1.21
type CatalogPage struct { Pages int `json:"pages"` ProductCount int `json:"productCount"` Products []CatalogProduct `json:"products"` Filters CatalogFilters `json:"filters"` }
func (*CatalogPage) GetProducts ¶ added in v0.1.21
func (cp *CatalogPage) GetProducts() []IdGetter
func (*CatalogPage) GetTotalPages ¶ added in v0.1.22
func (cp *CatalogPage) GetTotalPages() int
type CatalogPrice ¶ added in v0.1.21
type CatalogPrice struct { Final string `json:"final"` Base string `json:"base"` Discount *string `json:"discount"` FinalMoney AmountCurrency `json:"finalMoney"` BaseMoney AmountCurrency `json:"baseMoney"` }
type CatalogProduct ¶ added in v0.1.21
type CatalogProduct struct { Id string `json:"id"` Title string `json:"title"` Slug string `json:"slug"` Developers []string `json:"developers"` Publishers []string `json:"publishers"` Features []NameSlug `json:"features"` Genres []NameSlug `json:"genres"` ProductType string `json:"productType"` ReleaseDate *string `json:"releaseDate"` ReviewsRating int `json:"reviewsRating"` OperatingSystems []string `json:"operatingSystems"` CoverHorizontal string `json:"coverHorizontal"` CoverVertical string `json:"coverVertical"` Screenshots []string `json:"screenshots"` ProductState string `json:"productState"` Tags []NameSlug `json:"tags"` UserPreferredLanguage *UserPreferredLanguage `json:"userPreferredLanguage"` Price CatalogPrice `json:"price"` }
func (*CatalogProduct) GetBasePrice ¶ added in v0.1.21
func (cp *CatalogProduct) GetBasePrice() string
func (*CatalogProduct) GetComingSoon ¶ added in v0.1.34
func (cp *CatalogProduct) GetComingSoon() bool
func (*CatalogProduct) GetDevelopers ¶ added in v0.1.21
func (cp *CatalogProduct) GetDevelopers() []string
func (*CatalogProduct) GetDiscountPercentage ¶ added in v0.1.21
func (cp *CatalogProduct) GetDiscountPercentage() int
func (*CatalogProduct) GetFeatures ¶ added in v0.1.21
func (cp *CatalogProduct) GetFeatures() []string
func (*CatalogProduct) GetGenres ¶ added in v0.1.21
func (cp *CatalogProduct) GetGenres() []string
func (*CatalogProduct) GetGlobalRelease ¶ added in v0.1.21
func (cp *CatalogProduct) GetGlobalRelease() string
func (*CatalogProduct) GetId ¶ added in v0.1.21
func (cp *CatalogProduct) GetId() int
func (*CatalogProduct) GetImage ¶ added in v0.1.21
func (cp *CatalogProduct) GetImage() string
func (*CatalogProduct) GetInDevelopment ¶ added in v0.1.34
func (cp *CatalogProduct) GetInDevelopment() bool
func (*CatalogProduct) GetOperatingSystems ¶ added in v0.1.21
func (cp *CatalogProduct) GetOperatingSystems() []string
func (*CatalogProduct) GetPreOrder ¶ added in v0.1.34
func (cp *CatalogProduct) GetPreOrder() bool
func (*CatalogProduct) GetPrice ¶ added in v0.1.21
func (cp *CatalogProduct) GetPrice() string
func (*CatalogProduct) GetProductType ¶ added in v0.1.21
func (cp *CatalogProduct) GetProductType() string
func (*CatalogProduct) GetPublishers ¶ added in v0.1.21
func (cp *CatalogProduct) GetPublishers() []string
func (*CatalogProduct) GetRating ¶ added in v0.1.21
func (cp *CatalogProduct) GetRating() string
func (*CatalogProduct) GetScreenshots ¶ added in v0.1.21
func (cp *CatalogProduct) GetScreenshots() []string
func (*CatalogProduct) GetSlug ¶ added in v0.1.21
func (cp *CatalogProduct) GetSlug() string
func (*CatalogProduct) GetStoreTags ¶ added in v0.1.21
func (cp *CatalogProduct) GetStoreTags() []string
func (*CatalogProduct) GetTitle ¶ added in v0.1.21
func (cp *CatalogProduct) GetTitle() string
func (*CatalogProduct) GetVerticalImage ¶ added in v0.2.4
func (cp *CatalogProduct) GetVerticalImage() string
func (*CatalogProduct) IsDiscounted ¶ added in v0.1.21
func (cp *CatalogProduct) IsDiscounted() bool
func (*CatalogProduct) IsFree ¶ added in v0.1.21
func (cp *CatalogProduct) IsFree() bool
type CatalogSortOrder ¶ added in v0.1.24
type CatalogSortOrder string
const ( CatalogSortByTitle CatalogSortOrder = "title" CatalogSortByDiscount CatalogSortOrder = "discount" CatalogSortByReleaseDate CatalogSortOrder = "releaseDate" CatalogSortByRating CatalogSortOrder = "reviewsRating" CatalogSortByPrice CatalogSortOrder = "price" CatalogSortByBestselling CatalogSortOrder = "bestselling" )
type ChangelogGetter ¶ added in v0.1.6
type ChangelogGetter interface {
GetChangelog() string
}
type ComingSoonGetter ¶ added in v0.1.15
type ComingSoonGetter interface {
GetComingSoon() bool
}
type CopyrightsGetter ¶ added in v0.1.11
type CopyrightsGetter interface {
GetCopyrights() string
}
type CreateTagResp ¶
type CreateTagResp struct {
Id string `json:"id"`
}
type DeleteTagResp ¶
type DeleteTagResp struct {
Status string `json:"status"`
}
type DescriptionFeaturesGetter ¶ added in v0.1.14
type DescriptionFeaturesGetter interface {
GetDescriptionFeatures() string
}
type DescriptionOverviewGetter ¶ added in v0.1.14
type DescriptionOverviewGetter interface {
GetDescriptionOverview() string
}
type Details ¶
type Details struct { Title string `json:"title"` BackgroundImage string `json:"backgroundImage"` CdKey string `json:"cdKey"` TextInformation string `json:"textInformation"` //GetDownloads comment explains why this is [][]interface{} Downloads []interface{} `json:"downloads"` GalaxyDownloads []interface{} `json:"galaxyDownloads"` Extras []ManualDownload `json:"extras"` DLCs []Details `json:"dlcs"` Tags []accountTag `json:"tags"` IsPreOrder bool `json:"isPreOrder"` ReleaseTimestamp int64 `json:"releaseTimestamp"` Messages []string `json:"messages"` Changelog string `json:"changelog"` ForumLink string `json:"forumLink"` IsBaseProductMissing bool `json:"isBaseProductMissing"` MissingBaseProduct interface{} `json:"missingBaseProduct"` Features []string `json:"features"` SimpleGalaxyInstallers []struct { Path string `json:"path"` Os string `json:"os"` } `json:"simpleGalaxyInstallers"` }
func (*Details) GetChangelog ¶ added in v0.1.6
func (*Details) GetFeatures ¶
func (*Details) GetForumUrl ¶ added in v0.1.6
func (*Details) GetGOGRelease ¶
func (*Details) GetGameDownloads ¶
func (det *Details) GetGameDownloads() ([]LangOSManualDownloads, error)
GetGameDownloads extracts downloads for languages and operating systems from GOG.com details. Currently, this data is stored as array of arrays, where the inner array holds the language as the first element and the object containing Windows, Mac, Linux downloads as the second element. To process that we go through the array, save the language of the current element, then encode/decode the next elements using a LangOSDownloads struct.
func (*Details) GetMovieDownloads ¶
func (det *Details) GetMovieDownloads() ([]ManualDownload, error)
type DevelopersGetter ¶
type DevelopersGetter interface {
GetDevelopers() []string
}
type DiscountPercentageGetter ¶ added in v0.1.19
type DiscountPercentageGetter interface {
GetDiscountPercentage() int
}
type FeaturesGetter ¶
type FeaturesGetter interface {
GetFeatures() []string
}
type ForumUrlGetter ¶ added in v0.1.6
type ForumUrlGetter interface {
GetForumUrl() string
}
type GOGReleaseGetter ¶
type GOGReleaseGetter interface {
GetGOGRelease() string
}
type GenresGetter ¶
type GenresGetter interface {
GetGenres() []string
}
type GlobalReleaseGetter ¶
type GlobalReleaseGetter interface {
GetGlobalRelease() string
}
type ImageGetter ¶
type ImageGetter interface {
GetImage() string
}
type InDevelopmentGetter ¶ added in v0.1.15
type InDevelopmentGetter interface {
GetInDevelopment() bool
}
type IncludesGamesGetter ¶
type IncludesGamesGetter interface {
GetIncludesGames() []string
}
type IsDiscountedGetter ¶ added in v0.1.19
type IsDiscountedGetter interface {
IsDiscounted() bool
}
type IsFreeGetter ¶ added in v0.1.19
type IsFreeGetter interface {
IsFree() bool
}
type IsIncludedInGamesGetter ¶
type IsIncludedInGamesGetter interface {
GetIsIncludedInGames() []string
}
type IsRequiredByGamesGetter ¶
type IsRequiredByGamesGetter interface {
GetIsRequiredByGames() []string
}
type IsUsingDOSBoxGetter ¶ added in v0.1.15
type IsUsingDOSBoxGetter interface {
IsUsingDOSBox() bool
}
type IsUsingScummVMGetter ¶ added in v0.1.18
type IsUsingScummVMGetter interface {
IsUsingScummVM() bool
}
type LangOSManualDownloads ¶
type LangOSManualDownloads struct { Language string Windows []ManualDownload `json:"windows"` Mac []ManualDownload `json:"mac"` Linux []ManualDownload `json:"linux"` }
type LanguageCodesGetter ¶
type LanguageCodesGetter interface {
GetLanguageCodes() []string
}
type LanguagesGetter ¶
type ManualDownload ¶
type NativeLanguagesGetter ¶
type OperatingSystemsGetter ¶
type OperatingSystemsGetter interface {
GetOperatingSystems() []string
}
type Order ¶
type Order struct { PublicId string `json:"publicId"` // TODO: find non-nil data to infer type Distributor interface{} `json:"distributor"` Date int `json:"date"` MoneybackGuarantee bool `json:"moneybackGuarantee"` Status string `json:"status"` PaymentMethod string `json:"paymentMethod"` // TODO: find non-nil data to infer type ValidUntil interface{} `json:"validUntil"` CheckoutLink string `json:"checkoutLink"` ReceiptLink string `json:"receiptLink"` Total value `json:"total"` StoreCreditUsed value `json:"storeCreditUsed"` // TODO: find non-nil data to infer type GiftRecipient interface{} `json:"giftRecipient"` // TODO: find non-nil data to infer type GiftSender interface{} `json:"giftSender"` Products []struct { // TODO: find non-nil data to infer type Status interface{} `json:"status"` // TODO: find non-nil data to infer type RelatedAccount interface{} `json:"relatedAccount"` Price struct { BaseAmount string `json:"baseAmount"` Amount string `json:"amount"` IsFree bool `json:"isFree"` IsDiscounted bool `json:"isDiscounted"` Symbol string `json:"symbol"` } `json:"price"` Image string `json:"image"` Title string `json:"title"` Id string `json:"id"` IsRefunded bool `json:"isRefunded"` CashValue value `json:"cashValue"` WalletValue value `json:"walletValue"` IsPreorder bool `json:"isPreorder"` DisplayAutomaticRefundLink bool `json:"displayAutomaticRefundLink"` // TODO: find non-nil data to infer type RefundDate interface{} `json:"refundDate"` } `json:"products"` GiftCode interface{} `json:"giftCode"` IsResendable bool `json:"isResendable"` StatusPageUrl string `json:"statusPageUrl"` }
type PreOrderGetter ¶ added in v0.1.15
type PreOrderGetter interface {
GetPreOrder() bool
}
type PriceGetter ¶ added in v0.1.19
type PriceGetter interface {
GetPrice() string
}
type ProductTypeGetter ¶ added in v0.1.8
type ProductTypeGetter interface {
GetProductType() string
}
type ProductsGetter ¶
type ProductsGetter interface {
GetProducts() []IdGetter
}
type PublishersGetter ¶ added in v0.1.21
type PublishersGetter interface {
GetPublishers() []string
}
type RatingGetter ¶
type RatingGetter interface {
GetRating() string
}
type RequiresGamesGetter ¶
type RequiresGamesGetter interface {
GetRequiresGames() []string
}
type ScreenshotsGetter ¶
type ScreenshotsGetter interface {
GetScreenshots() []string
}
type SeriesGetter ¶
type SeriesGetter interface {
GetSeries() string
}
type SlugGetter ¶
type SlugGetter interface {
GetSlug() string
}
type StoreTagsGetter ¶ added in v0.1.21
type StoreTagsGetter interface {
GetStoreTags() []string
}
type StoreUrlGetter ¶ added in v0.1.6
type StoreUrlGetter interface {
GetStoreUrl() string
}
type SupportUrlGetter ¶ added in v0.1.6
type SupportUrlGetter interface {
GetSupportUrl() string
}
type TagIdsGetter ¶
type TagIdsGetter interface {
GetTagIds() []string
}
type TagNamesGetter ¶
type TitleGetter ¶
type TitleGetter interface {
GetTitle() string
}
type TotalPagesGetter ¶ added in v0.1.22
type TotalPagesGetter interface {
GetTotalPages() int
}
type TotalPagesProxy ¶ added in v0.1.22
TotalPagesProxy allow unmarshalling account, orders, store, wishlist pages (.TotalPages) and catalog pages (.Pages) structs to query total pages with GetTotalPages method
func (*TotalPagesProxy) GetTotalPages ¶ added in v0.1.22
func (tpp *TotalPagesProxy) GetTotalPages() int
type UserData ¶
type UserData struct { // TODO: at the moment we're only using this for a single field, consider completing the type IsLoggedIn bool `json:"isLoggedIn"` }
type UserPreferredLanguage ¶ added in v0.1.21
type UserWishlist ¶ added in v0.1.27
type UserWishlist struct { Wishlist map[string]bool `json:"wishlist"` Checksum string `json:"checksum"` }
func (*UserWishlist) GetProducts ¶ added in v0.1.29
func (uw *UserWishlist) GetProducts() []IdGetter
type VerticalImageGetter ¶ added in v0.2.4
type VerticalImageGetter interface {
GetVerticalImage() string
}
type VideoIdsGetter ¶
type VideoIdsGetter interface {
GetVideoIds() []string
}
Source Files
¶
- account_page.go
- account_product.go
- account_products_url.go
- account_sort_order.go
- account_tags_getter.go
- api_product_v1.go
- api_product_v1_url.go
- api_product_v2.go
- api_product_v2_url.go
- auth_urls.go
- catalog_page.go
- catalog_page_url.go
- catalog_product.go
- catalog_sort_order.go
- default_headers.go
- details.go
- details_url.go
- image_url.go
- interfaces.go
- licences.go
- licences_url.go
- logged_in.go
- login.go
- login_check_url.go
- login_data.go
- login_two_step_url.go
- manual_download_url.go
- media.go
- node_matches.go
- on_login_success_url.go
- operating_systems.go
- order.go
- orders_page.go
- orders_page_url.go
- recaptcha_urls.go
- second_step_data.go
- tags.go
- tags_url.go
- total_pages_proxy.go
- url_const.go
- user_data.go
- user_data_url.go
- user_wishlist.go
- user_wishlist_url.go
- wishlist_methods.go
- wishlist_url.go
- youtube_video_id.go