// Code generated by @openmeter/typespec-go. DO NOT EDIT. package openmeter import "time" // PlanAddon create request. type CreatePlanAddonRequest struct { // Display name of the resource. // // Between 1 and 256 characters. Name string `json:"name"` // Optional description of the resource. // // Maximum 1024 characters. Description *string `json:"description,omitempty"` Labels *map[string]string `json:"labels,omitempty"` // The add-on associated with the plan. Addon AddonReference `json:"addon"` // The key of the plan phase from which the add-on becomes available for purchase. FromPlanPhase string `json:"from_plan_phase"` // The maximum number of times the add-on can be purchased for the plan. For // single-instance add-ons this field must be omitted. For multi-instance add-ons // when omitted, unlimited quantity can be purchased. MaxQuantity *int64 `json:"max_quantity,omitempty"` } // PlanAddon represents an association between a plan and an add-on, controlling // which add-ons are available for purchase within a plan. type PlanAddon struct { ID string `json:"id"` // Display name of the resource. // // Between 1 and 256 characters. Name string `json:"name"` // Optional description of the resource. // // Maximum 1024 characters. Description *string `json:"description,omitempty"` Labels map[string]string `json:"labels,omitempty"` // An ISO-8601 timestamp representation of entity creation date. CreatedAt time.Time `json:"created_at"` // An ISO-8601 timestamp representation of entity last update date. UpdatedAt time.Time `json:"updated_at"` // An ISO-8601 timestamp representation of entity deletion date. DeletedAt *time.Time `json:"deleted_at,omitempty"` // The add-on associated with the plan. Addon AddonReference `json:"addon"` // The key of the plan phase from which the add-on becomes available for purchase. FromPlanPhase string `json:"from_plan_phase"` // The maximum number of times the add-on can be purchased for the plan. For // single-instance add-ons this field must be omitted. For multi-instance add-ons // when omitted, unlimited quantity can be purchased. MaxQuantity *int64 `json:"max_quantity,omitempty"` // List of validation errors. ValidationErrors []ProductCatalogValidationError `json:"validation_errors,omitempty"` } // Page paginated response. type PlanAddonPagePaginatedResponse struct { Data []PlanAddon `json:"data"` Meta PaginatedMeta `json:"meta"` } // PlanAddon upsert request. type UpsertPlanAddonRequest struct { // Display name of the resource. // // Between 1 and 256 characters. Name string `json:"name"` // Optional description of the resource. // // Maximum 1024 characters. Description *string `json:"description,omitempty"` Labels *map[string]string `json:"labels,omitempty"` // The key of the plan phase from which the add-on becomes available for purchase. FromPlanPhase string `json:"from_plan_phase"` // The maximum number of times the add-on can be purchased for the plan. For // single-instance add-ons this field must be omitted. For multi-instance add-ons // when omitted, unlimited quantity can be purchased. MaxQuantity *int64 `json:"max_quantity,omitempty"` }