-
Notifications
You must be signed in to change notification settings - Fork 3
/
address.go
28 lines (25 loc) · 988 Bytes
/
address.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
package patreon
// AddressFields is all fields in the Address Attributes struct
var AddressFields = getObjectFields(AddressAttributes{})
// Address represents a Patreon's shipping address.
type Address struct {
Type string `json:"type"`
ID string `json:"id"`
Attributes AddressAttributes `json:"attributes"`
Relationships struct {
Campaigns *CampaignsRelationship `json:"campaigns,omitempty"`
User *UserRelationship `json:"user,omitempty"`
} `json:"relationships"`
}
// AddressAttributes is the attributes struct for the Address
type AddressAttributes struct {
Addressee string `json:"addressee"`
City string `json:"city"`
Country string `json:"country"`
CreatedAt NullTime `json:"created_at"`
Line1 string `json:"line_1"`
Line2 string `json:"line_2"`
PhoneNumber string `json:"phone_number"`
PostalCode string `json:"postal_code"`
State string `json:"state"`
}