-
Notifications
You must be signed in to change notification settings - Fork 35
/
sku.go
44 lines (37 loc) · 945 Bytes
/
sku.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
41
42
43
44
package discord
import (
"time"
"github.com/disgoorg/snowflake/v2"
)
type SKU struct {
ID snowflake.ID `json:"id"`
Type SKUType `json:"type"`
ApplicationID snowflake.ID `json:"application_id"`
Name string `json:"name"`
Slug string `json:"slug"`
DependentSkuID *snowflake.ID `json:"dependent_sku_id"`
AccessType int `json:"access_type"`
Features []string `json:"features"`
ReleaseDate *time.Time `json:"release_date"`
Premium bool `json:"premium"`
Flags SKUFlags `json:"flags"`
ShowAgeGate bool `json:"show_age_gate"`
}
type SKUType int
const (
SKUTypeDurable SKUType = iota + 2
SKUTypeConsumable
_
SKUTypeSubscription
SKUTypeSubscriptionGroup
)
type SKUFlags int
const (
SKUFlagAvailable SKUFlags = 1 << (iota + 2)
_
_
_
_
SKUFlagGuildSubscription
SKUFlagUserSubscription
)