client

package
v0.0.0-...-64e79c0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 18, 2024 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

View Source
const ResponseFormatJson = "JSON"
View Source
const SortOrderDefault = "Default"

Variables

This section is empty.

Functions

This section is empty.

Types

type Credentials

type Credentials struct {
	AgencyId int64
	UserName string
	Password string
}

type Destination

type Destination struct {
	CityId    int64  `csv:"CityId"`
	City      string `csv:"City"`
	CountryId int64  `csv:"CountryId"`
	Country   string `csv:"Country"`
	IsoCode   string `csv:"IsoCode"`
}

type GoGlobalService

type GoGlobalService interface {
	GetDestinations(context.Context, Credentials) ([]*Destination, error)
	GetHotels(context.Context, Credentials) ([]*Hotel, error)
	Search(context.Context, Credentials, models.HotelSearchRequest, RequestLogger, ResponseLogger) ([]models.HotelSearchResponseItem, error)
	BookingValuation(context.Context, Credentials, models.BookValuationRequest, RequestLogger, ResponseLogger) (models.BookValuationResponse, error)
	BookingInsert(context.Context, Credentials, models.BookingInsertRequest, RequestLogger, ResponseLogger) (models.BookingInsertResponse, error)
	BookingStatus(context.Context, Credentials, models.BookingStatusRequest, RequestLogger, ResponseLogger) (models.BookingStatusResponse, error)
	BookingSearch(context.Context, Credentials, models.BookingSearchRequest, RequestLogger, ResponseLogger) (models.BookingSearchResponse, error)
	AdvBookingSearch(context.Context, Credentials, models.AdvBookingSearchRequest, RequestLogger, ResponseLogger) (models.AdvBookingSearchResponse, error)
	BookingCancel(context.Context, Credentials, models.BookingCancelRequest, RequestLogger, ResponseLogger) (models.BookingCancelResponse, error)
	VoucherDetails(context.Context, Credentials, models.VoucherDetailsRequest, RequestLogger, ResponseLogger) (models.VoucherDetailsResponse, error)
	BookingInfoForAmendment(context.Context, Credentials, models.BookingInfoForAmendmentRequest, RequestLogger, ResponseLogger) (models.BookingInfoForAmendmentResponse, error)
	BookingAmendment(context.Context, Credentials, models.BookingAmendmentRequest, RequestLogger, ResponseLogger) error
	HotelInfo(context.Context, Credentials, models.HotelInfoRequest, RequestLogger, ResponseLogger) (models.HotelInfoResponse, error)
	PriceBreakdown(context.Context, Credentials, models.PriceBreakdownRequest, RequestLogger, ResponseLogger) (models.PriceBreakdownResponse, error)
}

func NewGoGlobalService

func NewGoGlobalService(
	apiUrl string,
) GoGlobalService

type Hotel

type Hotel struct {
	CountryId   int64   `csv:"CountryId"`
	Country     string  `csv:"Country"`
	IsoCode     string  `csv:"IsoCode"`
	CityId      int64   `csv:"CityId"`
	City        string  `csv:"City"`
	HotelID     int64   `csv:"HotelID"`
	Name        string  `csv:"Name"`
	Address     string  `csv:"Address"`
	Phone       string  `csv:"Phone"`
	Fax         string  `csv:"Fax"`
	Stars       string  `csv:"Stars"`
	StarsID     int64   `csv:"StarsID"`
	Longitude   float64 `csv:"Longitude"`
	Latitude    float64 `csv:"Latitude"`
	IsApartment bool    `csv:"IsApartment"`
	GiataCode   string  `csv:"GiataCode"`
}

type RequestLogger

type RequestLogger func(r *http.Request) error

type ResponseLogger

type ResponseLogger func(r *http.Response, responseBody []byte, isError bool) error

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL