Documentation
¶
Index ¶
Constants ¶
View Source
const ( ItemRankingURL = "https://app.rakuten.co.jp/services/api/IchibaItem/Ranking/20170628" ItemSearchURL = "https://app.rakuten.co.jp/services/api/IchibaItem/Search/20170706" TravelKeyWordURL = "https://app.rakuten.co.jp/services/api/Travel/KeywordHotelSearch/20170426" )
View Source
const ( SearchDisabled int = iota SearchEnabled )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Hotel ¶
type Hotel struct {
HotelBasicInfo struct {
HotelNo int `json:"hotelNo"`
HotelName string `json:"hotelName"`
HotelInformationUrl string `json:"hotelInformationUrl"`
PlanListUrl string `json:"planListUrl"`
DpPlanListUrl string `json:"dpPlanListUrl"`
ReviewUrl string `json:"reviewUrl"`
HotelKanaName string `json:"hotelKanaName"`
HotelSpecial string `json:"hotelSpecial"`
HotelMinCharge int `json:"hotelMinCharge"`
Latitude float64 `json:"latitude"`
Longitude float64 `json:"longitude"`
PostalCode string `json:"postalCode"`
Address1 string `json:"address1"`
Address2 string `json:"address2"`
TelephoneNo string `json:"telephoneNo"`
FaxNo string `json:"faxNo"`
Access string `json:"access"`
ParkingInformation string `json:"parkingInformation"`
NearestStation string `json:"nearestStation"`
HotelImageUrl string `json:"hotelImageUrl"`
HotelThumbnailUrl string `json:"hotelThumbnailUrl"`
RoomImageUrl string `json:"roomImageUrl"`
RoomThumbnailUrl string `json:"roomThumbnailUrl"`
HotelMapImageUrl string `json:"hotelMapImageUrl"`
ReviewCount int `json:"reviewCount"`
ReviewAverage float64 `json:"reviewAverage"`
UserReview string `json:"userReview"`
} `json:"hotelBasicInfo"`
HotelRatingInfo struct {
ServiceAverage float64 `json:"serviceAverage"`
LocationAverage float64 `json:"locationAverage"`
RoomAverage float64 `json:"roomAverage"`
EquipmentAverage float64 `json:"equipmentAverage"`
BathAverage float64 `json:"bathAverage"`
MealAverage float64 `json:"mealAverage"`
} `json:"hotelRatingInfo"`
}
type Item ¶
type Item struct {
AffiliateUrl string `json:"affiliateUrl"`
AffiliateRate float64 `json:"affiliateRate"`
AsurakuArea string `json:"asurakuArea"`
AsurakuFlag int `json:"asurakuFlag"`
AsurakuClosingTime string `json:"asurakuClosingTime"`
Availability int `json:"availability"`
CreditCardFlag int `json:"creditCardFlag"`
Catchcopy string `json:"catchcopy"`
Carrier int `json:"carrier"`
GenreId int `json:"genreId"`
EndTime string `json:"endTime"`
MediumImageUrls []string `json:"mediumImageUrls"`
ItemCaption string `json:"itemCaption"`
ImageFlag int `json:"imageFlag"`
ItemCode string `json:"itemCode"`
ItemName string `json:"itemName"`
ItemPrice int `json:"itemPrice"`
ItemUrl string `json:"itemUrl"`
PointRate int `json:"pointRate"`
PointRateEndTime string `json:"pointRateEndTime"`
PointRateStartTime string `json:"pointRateStartTime"`
PostageFlag int `json:"postageFlag"`
Rank int `json:"rank"`
ReviewAverage float64 `json:"reviewAverage"`
ReviewCount int `json:"reviewCount"`
SmallImageUrls []string `json:"imageUrl"`
ShipOverseasArea string `json:"shipOverseasArea"`
ShipOverseasFlag int `json:"shipOverseasFlag"`
ShopAffiliateUrl string `json:"shopAffiliateUrl"`
ShopCode string `json:"shopCode"`
ShopName string `json:"shopName"`
ShopOfTheYearFlag int `json:"shopOfTheYearFlag"`
ShopUrl string `json:"shopUrl"`
StartTime string `json:"startTime"`
TaxFlag int `json:"taxFlagmediumImageUrls"`
TagIds []int `json:"tagIds"`
}
FormatVersion 2専用オブジェクト
type ItemSearchResponse ¶
type ItemSearchResponse struct {
Count int `json:"count"`
Page int `json:"page"`
First int `json:"first"`
Last int `json:"last"`
Hits int `json:"hits"`
Carrier int `json:"carrier"`
PageCount int `json:"pageCount"`
Items []Item `json:"Items"`
GenreInformation []interface{} `json:"GenreInformation"`
TagInformation []interface{} `json:"TagInformation"`
}
type RakutenAPI ¶
type RakutenAPI struct {
RakutenAffiliateAccount
}
func NewRakutenAPI ¶
func NewRakutenAPI(account RakutenAffiliateAccount) (*RakutenAPI, error)
func (*RakutenAPI) GetItemSearch ¶
func (api *RakutenAPI) GetItemSearch(params map[string]string) ([]byte, error)
func (*RakutenAPI) GetRaktenRunking ¶
func (api *RakutenAPI) GetRaktenRunking(params map[string]string) ([]byte, error)
func (*RakutenAPI) GetTravelKeywordSearch ¶
func (api *RakutenAPI) GetTravelKeywordSearch(params map[string]string) ([]byte, error)
type RakutenAffiliateAccount ¶
type RakutenSearchParameter ¶
type RakutenSearchParameter uint
const ( // For general use ApplicationID RakutenSearchParameter = iota /* Required */ AffiliateID /* Your affiliate id*/ Format /* Responsed format "json" or "xml", default "json" */ CallBack /* For jsonp callback function name */ Elements /* Elements responsed target columns, default "ALL" */ FormatVersion /* "1" or "2", recommended "2", responsed be a simple. */ Carrier Page GenreID /* use Ranking and Search. */ // For Raunking API use Age Sex Period // For ItemSearch API use Keyword ShopCode ItemCode TagId Hits Sort MinPrice MaxPrice Availability Field ImageFlag OrFlag NGKeyword PurchaseType ShipOverseasFlag ShipOverseasArea AsurakuFlag AsurakuArea PointRateFlag PointRate PostageFlag CreditCardFlag GiftFlag HasReviewFlag MaxAffiliateRate MinAffiliateRate HasMovieFlag PamphletFlag AppointDeliveryDateFlag GenreInformationFlag TagInformationFlag )
func (RakutenSearchParameter) String ¶
func (v RakutenSearchParameter) String() string
type RankingResponse ¶
Click to show internal directories.
Click to hide internal directories.