-
Notifications
You must be signed in to change notification settings - Fork 465
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Update generated code for v1157 * Update generated code for v1158 * Update generated code for v1159 * Update generated code for v1160 * Update generated code for v1162 * Update generated code for v1163 * Update generated code for v1166 * Update generated code for v1167 * Update generated code for v1169 --------- Co-authored-by: Stripe OpenAPI <105521251+stripe-openapi[bot]@users.noreply.github.com> Co-authored-by: prathmesh-stripe <[email protected]>
- Loading branch information
1 parent
cc5e657
commit c152a51
Showing
13 changed files
with
576 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
v1155 | ||
v1169 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
// | ||
// | ||
// File generated from our OpenAPI spec | ||
// | ||
// | ||
|
||
package stripe | ||
|
||
// Defines the type of the alert. | ||
type BillingAlertAlertType string | ||
|
||
// List of values that BillingAlertAlertType can take | ||
const ( | ||
BillingAlertAlertTypeUsageThreshold BillingAlertAlertType = "usage_threshold" | ||
) | ||
|
||
// Status of the alert. This can be active, inactive or archived. | ||
type BillingAlertStatus string | ||
|
||
// List of values that BillingAlertStatus can take | ||
const ( | ||
BillingAlertStatusActive BillingAlertStatus = "active" | ||
BillingAlertStatusArchived BillingAlertStatus = "archived" | ||
BillingAlertStatusInactive BillingAlertStatus = "inactive" | ||
) | ||
|
||
// Defines how the alert will behave. | ||
type BillingAlertUsageThresholdConfigRecurrence string | ||
|
||
// List of values that BillingAlertUsageThresholdConfigRecurrence can take | ||
const ( | ||
BillingAlertUsageThresholdConfigRecurrenceOneTime BillingAlertUsageThresholdConfigRecurrence = "one_time" | ||
) | ||
|
||
// Limits the scope of the alert to a specific [customer](https://stripe.com/docs/api/customers). | ||
type BillingAlertFilter struct { | ||
// Limit the scope of the alert to this customer ID | ||
Customer *Customer `json:"customer"` | ||
} | ||
|
||
// Encapsulates configuration of the alert to monitor usage on a specific [Billing Meter](https://stripe.com/docs/api/billing/meter). | ||
type BillingAlertUsageThresholdConfig struct { | ||
// The value at which this alert will trigger. | ||
GTE int64 `json:"gte"` | ||
// The [Billing Meter](https://stripe.com/api/billing/meter) ID whose usage is monitored. | ||
Meter *BillingMeter `json:"meter"` | ||
// Defines how the alert will behave. | ||
Recurrence BillingAlertUsageThresholdConfigRecurrence `json:"recurrence"` | ||
} | ||
|
||
// A billing alert is a resource that notifies you when a certain usage threshold on a meter is crossed. For example, you might create a billing alert to notify you when a certain user made 100 API requests. | ||
type BillingAlert struct { | ||
// Defines the type of the alert. | ||
AlertType BillingAlertAlertType `json:"alert_type"` | ||
// Limits the scope of the alert to a specific [customer](https://stripe.com/docs/api/customers). | ||
Filter *BillingAlertFilter `json:"filter"` | ||
// Unique identifier for the object. | ||
ID string `json:"id"` | ||
// Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. | ||
Livemode bool `json:"livemode"` | ||
// String representing the object's type. Objects of the same type share the same value. | ||
Object string `json:"object"` | ||
// Status of the alert. This can be active, inactive or archived. | ||
Status BillingAlertStatus `json:"status"` | ||
// Title of the alert. | ||
Title string `json:"title"` | ||
// Encapsulates configuration of the alert to monitor usage on a specific [Billing Meter](https://stripe.com/docs/api/billing/meter). | ||
UsageThresholdConfig *BillingAlertUsageThresholdConfig `json:"usage_threshold_config"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// | ||
// | ||
// File generated from our OpenAPI spec | ||
// | ||
// | ||
|
||
package stripe | ||
|
||
type BillingAlertTriggered struct { | ||
// A billing alert is a resource that notifies you when a certain usage threshold on a meter is crossed. For example, you might create a billing alert to notify you when a certain user made 100 API requests. | ||
Alert *BillingAlert `json:"alert"` | ||
// Time at which the object was created. Measured in seconds since the Unix epoch. | ||
Created int64 `json:"created"` | ||
// ID of customer for which the alert triggered | ||
Customer string `json:"customer"` | ||
// Has the value `true` if the object exists in live mode or the value `false` if the object exists in test mode. | ||
Livemode bool `json:"livemode"` | ||
// String representing the object's type. Objects of the same type share the same value. | ||
Object string `json:"object"` | ||
// The value triggering the alert | ||
Value int64 `json:"value"` | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.