-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathpaypal_type.go
40 lines (32 loc) · 892 Bytes
/
paypal_type.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
package paypal
import "time"
const (
kSuccess = "SUCCESS"
)
type jsonString string
func (s jsonString) MarshalJSON() ([]byte, error) {
return []byte(s), nil
}
type Token struct {
Scope string `json:"scope"`
Nonce string `json:"nonce"`
AccessToken string `json:"access_token"`
TokenType string `json:"token_type"`
AppId string `json:"app_id"`
ExpiresIn int `json:"expires_in"`
ExpiresAt time.Time `json:"expires_at"`
}
type RelatedResources struct {
Sale *Sale `json:"sale,omitempty"`
Refund *Refund `json:"refund,omitempty"`
}
type Currency struct {
Currency string `json:"currency,omitempty"`
Value string `json:"value,omitempty"`
}
type Link struct {
Href string `json:"href,omitempty"`
Rel string `json:"rel,omitempty"`
Method string `json:"method,omitempty"`
EncType string `json:"encType,omitempty"`
}