forked from getlago/lago-go-client
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathusage_threshold.go
29 lines (24 loc) · 942 Bytes
/
usage_threshold.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
package lago
import (
"time"
"github.com/google/uuid"
)
type UsageThresholdInput struct {
LagoId *uuid.UUID `json:"id,omitempty"`
ThresholdDisplayName string `json:"threshold_display_name,omitempty"`
AmountCents int `json:"amount_cents"`
Recurring bool `json:"recurring"`
}
type UsageThreshold struct {
LagoID uuid.UUID `json:"lago_id"`
ThresholdDisplayName string `json:"threshold_display_name,omitempty"`
AmountCents int `json:"amount_cents"`
Recurring bool `json:"recurring"`
CreatedAt time.Time `json:"created_at"`
UpdatedAt time.Time `json:"updated_at"`
}
type AppliedUsageThreshold struct {
LifetimeUsageAmountCents int `json:"lifetime_usage_amount_cents"`
CreatedAt time.Time `json:"created_at"`
UsageThreshold UsageThreshold `json:"usage_threshold"`
}