README ¶
github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/reservedinstances
Documentation
The reservedinstances
SDK allows for interaction with the Azure Resource Manager Service costmanagement
(API Version 2023-08-01
).
This readme covers example usages, but further information on using this SDK can be found in the project root.
Import Path
import "github.com/hashicorp/go-azure-sdk/resource-manager/costmanagement/2023-08-01/reservedinstances"
Client Initialization
client := reservedinstances.NewReservedInstancesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer
Example Usage: ReservedInstancesClient.GenerateReservationDetailsReportByBillingAccountId
ctx := context.TODO()
id := reservedinstances.NewBillingAccountID("billingAccountIdValue")
if err := client.GenerateReservationDetailsReportByBillingAccountIdThenPoll(ctx, id, reservedinstances.DefaultGenerateReservationDetailsReportByBillingAccountIdOperationOptions()); err != nil {
// handle the error
}
Example Usage: ReservedInstancesClient.GenerateReservationDetailsReportByBillingProfileId
ctx := context.TODO()
id := reservedinstances.NewBillingProfileID("billingAccountIdValue", "billingProfileIdValue")
if err := client.GenerateReservationDetailsReportByBillingProfileIdThenPoll(ctx, id, reservedinstances.DefaultGenerateReservationDetailsReportByBillingProfileIdOperationOptions()); err != nil {
// handle the error
}
Documentation ¶
Index ¶
- func PossibleValuesForOperationStatusType() []string
- func PossibleValuesForReservationReportSchema() []string
- func ValidateBillingAccountID(input interface{}, key string) (warnings []string, errors []error)
- func ValidateBillingProfileID(input interface{}, key string) (warnings []string, errors []error)
- type BillingAccountId
- type BillingProfileId
- type GenerateReservationDetailsReportByBillingAccountIdOperationOptions
- func (o GenerateReservationDetailsReportByBillingAccountIdOperationOptions) ToHeaders() *client.Headers
- func (o GenerateReservationDetailsReportByBillingAccountIdOperationOptions) ToOData() *odata.Query
- func (o GenerateReservationDetailsReportByBillingAccountIdOperationOptions) ToQuery() *client.QueryParams
- type GenerateReservationDetailsReportByBillingAccountIdOperationResponse
- type GenerateReservationDetailsReportByBillingProfileIdOperationOptions
- func (o GenerateReservationDetailsReportByBillingProfileIdOperationOptions) ToHeaders() *client.Headers
- func (o GenerateReservationDetailsReportByBillingProfileIdOperationOptions) ToOData() *odata.Query
- func (o GenerateReservationDetailsReportByBillingProfileIdOperationOptions) ToQuery() *client.QueryParams
- type GenerateReservationDetailsReportByBillingProfileIdOperationResponse
- type OperationStatus
- type OperationStatusType
- type ReportURL
- type ReservationReportSchema
- type ReservedInstancesClient
- func (c ReservedInstancesClient) GenerateReservationDetailsReportByBillingAccountId(ctx context.Context, id BillingAccountId, ...) (result GenerateReservationDetailsReportByBillingAccountIdOperationResponse, ...)
- func (c ReservedInstancesClient) GenerateReservationDetailsReportByBillingAccountIdThenPoll(ctx context.Context, id BillingAccountId, ...) error
- func (c ReservedInstancesClient) GenerateReservationDetailsReportByBillingProfileId(ctx context.Context, id BillingProfileId, ...) (result GenerateReservationDetailsReportByBillingProfileIdOperationResponse, ...)
- func (c ReservedInstancesClient) GenerateReservationDetailsReportByBillingProfileIdThenPoll(ctx context.Context, id BillingProfileId, ...) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PossibleValuesForOperationStatusType ¶
func PossibleValuesForOperationStatusType() []string
func PossibleValuesForReservationReportSchema ¶
func PossibleValuesForReservationReportSchema() []string
func ValidateBillingAccountID ¶
ValidateBillingAccountID checks that 'input' can be parsed as a Billing Account ID
func ValidateBillingProfileID ¶
ValidateBillingProfileID checks that 'input' can be parsed as a Billing Profile ID
Types ¶
type BillingAccountId ¶
type BillingAccountId struct {
BillingAccountId string
}
BillingAccountId is a struct representing the Resource ID for a Billing Account
func NewBillingAccountID ¶
func NewBillingAccountID(billingAccountId string) BillingAccountId
NewBillingAccountID returns a new BillingAccountId struct
func ParseBillingAccountID ¶
func ParseBillingAccountID(input string) (*BillingAccountId, error)
ParseBillingAccountID parses 'input' into a BillingAccountId
func ParseBillingAccountIDInsensitively ¶
func ParseBillingAccountIDInsensitively(input string) (*BillingAccountId, error)
ParseBillingAccountIDInsensitively parses 'input' case-insensitively into a BillingAccountId note: this method should only be used for API response data and not user input
func (*BillingAccountId) FromParseResult ¶ added in v0.20231127.1171502
func (id *BillingAccountId) FromParseResult(input resourceids.ParseResult) error
func (BillingAccountId) ID ¶
func (id BillingAccountId) ID() string
ID returns the formatted Billing Account ID
func (BillingAccountId) Segments ¶
func (id BillingAccountId) Segments() []resourceids.Segment
Segments returns a slice of Resource ID Segments which comprise this Billing Account ID
func (BillingAccountId) String ¶
func (id BillingAccountId) String() string
String returns a human-readable description of this Billing Account ID
type BillingProfileId ¶
BillingProfileId is a struct representing the Resource ID for a Billing Profile
func NewBillingProfileID ¶
func NewBillingProfileID(billingAccountId string, billingProfileId string) BillingProfileId
NewBillingProfileID returns a new BillingProfileId struct
func ParseBillingProfileID ¶
func ParseBillingProfileID(input string) (*BillingProfileId, error)
ParseBillingProfileID parses 'input' into a BillingProfileId
func ParseBillingProfileIDInsensitively ¶
func ParseBillingProfileIDInsensitively(input string) (*BillingProfileId, error)
ParseBillingProfileIDInsensitively parses 'input' case-insensitively into a BillingProfileId note: this method should only be used for API response data and not user input
func (*BillingProfileId) FromParseResult ¶ added in v0.20231127.1171502
func (id *BillingProfileId) FromParseResult(input resourceids.ParseResult) error
func (BillingProfileId) ID ¶
func (id BillingProfileId) ID() string
ID returns the formatted Billing Profile ID
func (BillingProfileId) Segments ¶
func (id BillingProfileId) Segments() []resourceids.Segment
Segments returns a slice of Resource ID Segments which comprise this Billing Profile ID
func (BillingProfileId) String ¶
func (id BillingProfileId) String() string
String returns a human-readable description of this Billing Profile ID
type GenerateReservationDetailsReportByBillingAccountIdOperationOptions ¶
type GenerateReservationDetailsReportByBillingAccountIdOperationOptions struct { EndDate *string StartDate *string }
func DefaultGenerateReservationDetailsReportByBillingAccountIdOperationOptions ¶
func DefaultGenerateReservationDetailsReportByBillingAccountIdOperationOptions() GenerateReservationDetailsReportByBillingAccountIdOperationOptions
func (GenerateReservationDetailsReportByBillingAccountIdOperationOptions) ToHeaders ¶
func (o GenerateReservationDetailsReportByBillingAccountIdOperationOptions) ToHeaders() *client.Headers
func (GenerateReservationDetailsReportByBillingAccountIdOperationOptions) ToOData ¶
func (o GenerateReservationDetailsReportByBillingAccountIdOperationOptions) ToOData() *odata.Query
func (GenerateReservationDetailsReportByBillingAccountIdOperationOptions) ToQuery ¶
func (o GenerateReservationDetailsReportByBillingAccountIdOperationOptions) ToQuery() *client.QueryParams
type GenerateReservationDetailsReportByBillingProfileIdOperationOptions ¶
type GenerateReservationDetailsReportByBillingProfileIdOperationOptions struct { EndDate *string StartDate *string }
func DefaultGenerateReservationDetailsReportByBillingProfileIdOperationOptions ¶
func DefaultGenerateReservationDetailsReportByBillingProfileIdOperationOptions() GenerateReservationDetailsReportByBillingProfileIdOperationOptions
func (GenerateReservationDetailsReportByBillingProfileIdOperationOptions) ToHeaders ¶
func (o GenerateReservationDetailsReportByBillingProfileIdOperationOptions) ToHeaders() *client.Headers
func (GenerateReservationDetailsReportByBillingProfileIdOperationOptions) ToOData ¶
func (o GenerateReservationDetailsReportByBillingProfileIdOperationOptions) ToOData() *odata.Query
func (GenerateReservationDetailsReportByBillingProfileIdOperationOptions) ToQuery ¶
func (o GenerateReservationDetailsReportByBillingProfileIdOperationOptions) ToQuery() *client.QueryParams
type OperationStatus ¶
type OperationStatus struct { Properties *ReportURL `json:"properties,omitempty"` Status *OperationStatusType `json:"status,omitempty"` }
type OperationStatusType ¶
type OperationStatusType string
const ( OperationStatusTypeCompleted OperationStatusType = "Completed" OperationStatusTypeFailed OperationStatusType = "Failed" OperationStatusTypeRunning OperationStatusType = "Running" )
func (*OperationStatusType) UnmarshalJSON ¶
func (s *OperationStatusType) UnmarshalJSON(bytes []byte) error
type ReportURL ¶
type ReportURL struct { ReportUrl *ReservationReportSchema `json:"reportUrl,omitempty"` ValidUntil *string `json:"validUntil,omitempty"` }
func (*ReportURL) GetValidUntilAsTime ¶
func (*ReportURL) SetValidUntilAsTime ¶
type ReservationReportSchema ¶
type ReservationReportSchema string
const ( ReservationReportSchemaInstanceFlexibilityGroup ReservationReportSchema = "InstanceFlexibilityGroup" ReservationReportSchemaInstanceFlexibilityRatio ReservationReportSchema = "InstanceFlexibilityRatio" ReservationReportSchemaInstanceId ReservationReportSchema = "InstanceId" ReservationReportSchemaKind ReservationReportSchema = "Kind" ReservationReportSchemaReservationId ReservationReportSchema = "ReservationId" ReservationReportSchemaReservationOrderId ReservationReportSchema = "ReservationOrderId" ReservationReportSchemaReservedHours ReservationReportSchema = "ReservedHours" ReservationReportSchemaSkuName ReservationReportSchema = "SkuName" ReservationReportSchemaTotalReservedQuantity ReservationReportSchema = "TotalReservedQuantity" ReservationReportSchemaUsageDate ReservationReportSchema = "UsageDate" ReservationReportSchemaUsedHours ReservationReportSchema = "UsedHours" )
func (*ReservationReportSchema) UnmarshalJSON ¶
func (s *ReservationReportSchema) UnmarshalJSON(bytes []byte) error
type ReservedInstancesClient ¶
type ReservedInstancesClient struct {
Client *resourcemanager.Client
}
func NewReservedInstancesClientWithBaseURI ¶
func NewReservedInstancesClientWithBaseURI(sdkApi sdkEnv.Api) (*ReservedInstancesClient, error)
func (ReservedInstancesClient) GenerateReservationDetailsReportByBillingAccountId ¶
func (c ReservedInstancesClient) GenerateReservationDetailsReportByBillingAccountId(ctx context.Context, id BillingAccountId, options GenerateReservationDetailsReportByBillingAccountIdOperationOptions) (result GenerateReservationDetailsReportByBillingAccountIdOperationResponse, err error)
GenerateReservationDetailsReportByBillingAccountId ...
func (ReservedInstancesClient) GenerateReservationDetailsReportByBillingAccountIdThenPoll ¶
func (c ReservedInstancesClient) GenerateReservationDetailsReportByBillingAccountIdThenPoll(ctx context.Context, id BillingAccountId, options GenerateReservationDetailsReportByBillingAccountIdOperationOptions) error
GenerateReservationDetailsReportByBillingAccountIdThenPoll performs GenerateReservationDetailsReportByBillingAccountId then polls until it's completed
func (ReservedInstancesClient) GenerateReservationDetailsReportByBillingProfileId ¶
func (c ReservedInstancesClient) GenerateReservationDetailsReportByBillingProfileId(ctx context.Context, id BillingProfileId, options GenerateReservationDetailsReportByBillingProfileIdOperationOptions) (result GenerateReservationDetailsReportByBillingProfileIdOperationResponse, err error)
GenerateReservationDetailsReportByBillingProfileId ...
func (ReservedInstancesClient) GenerateReservationDetailsReportByBillingProfileIdThenPoll ¶
func (c ReservedInstancesClient) GenerateReservationDetailsReportByBillingProfileIdThenPoll(ctx context.Context, id BillingProfileId, options GenerateReservationDetailsReportByBillingProfileIdOperationOptions) error
GenerateReservationDetailsReportByBillingProfileIdThenPoll performs GenerateReservationDetailsReportByBillingProfileId then polls until it's completed