Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
// contains filtered or unexported fields
}
Client describes we api client.
func (*Client) Login ¶
func (c *Client) Login() (*CustomerInfo, error)
Login submits email and password to be checked by backend.
func (*Client) LoyaltyPoints ¶
func (c *Client) LoyaltyPoints() (*LoyaltyPointsInfo, error)
LoyaltyPoints returns 4U points of logged in user.
func (*Client) RemainingDays ¶
func (c *Client) RemainingDays() (*RemainingDaysInfo, error)
RemainingDays returns service subscription of logged in user.
type Credentials ¶
Credentials represents login credentials.
type CustomerInfo ¶
type CustomerInfo struct {
CustomerInformationDto struct {
ADSLSpeed string `json:"adslSpeed"`
City string `json:"cityEN"`
District string `json:"districtEN"`
MobileNumber string `json:"mobileNumber1WithPrefix"`
CustomerNumber string `json:"customerNumber"`
EmailAddress string `json:"emailAddress"`
ADSLAreaCode int `json:"adslAreaCode"`
ADSLNumber int `json:"adslNumber"`
CustomerName string `json:"customerName"`
} `json:"customerInformationDto"`
}
CustomerInfo describes customer info.
type ErrorInfo ¶
type ErrorInfo struct {
Exception struct {
MessageEn string `json:"messageEn"`
} `json:"exception"`
}
ErrorInfo describes response errors.
type LoyaltyPointsInfo ¶
type LoyaltyPointsInfo struct {
LoyaltyPoints int `json:"loyaltyPoints"`
}
LoyaltyPointsInfo describes 4U points.
type RemainingDaysInfo ¶
type RemainingDaysInfo struct {
RemainingDays struct {
ADSLExpiryDate string `json:"adslExpiryDateString"`
RemainingDays int `json:"remainingDays"`
PackageName string `json:"packageName"`
AmountDue float64 `json:"amountDue"`
} `json:"remainingDays"`
}
RemainingDaysInfo describes subscription date and remaining service days.
Click to show internal directories.
Click to hide internal directories.