billingsubscriptionsaliases

package
v0.20240122.1052955 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 22, 2024 License: MPL-2.0 Imports: 13 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/billing/2021-10-01/billingsubscriptionsaliases Documentation

The billingsubscriptionsaliases SDK allows for interaction with the Azure Resource Manager Service billing (API Version 2021-10-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/billing/2021-10-01/billingsubscriptionsaliases"

Client Initialization

client := billingsubscriptionsaliases.NewBillingSubscriptionsAliasesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: BillingSubscriptionsAliasesClient.CreateOrUpdate

ctx := context.TODO()
id := billingsubscriptionsaliases.NewBillingSubscriptionAliasID("billingAccountValue", "billingSubscriptionAliasValue")

payload := billingsubscriptionsaliases.BillingSubscriptionAlias{
	// ...
}


if err := client.CreateOrUpdateThenPoll(ctx, id, payload); err != nil {
	// handle the error
}

Example Usage: BillingSubscriptionsAliasesClient.Get

ctx := context.TODO()
id := billingsubscriptionsaliases.NewBillingSubscriptionAliasID("billingAccountValue", "billingSubscriptionAliasValue")

read, err := client.Get(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: BillingSubscriptionsAliasesClient.ListByBillingAccount

ctx := context.TODO()
id := billingsubscriptionsaliases.NewBillingAccountID("billingAccountValue")

// alternatively `client.ListByBillingAccount(ctx, id)` can be used to do batched pagination
items, err := client.ListByBillingAccountComplete(ctx, id)
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForAutoRenew

func PossibleValuesForAutoRenew() []string

func PossibleValuesForBillingSubscriptionStatus

func PossibleValuesForBillingSubscriptionStatus() []string

func PossibleValuesForSubscriptionEnrollmentAccountStatus

func PossibleValuesForSubscriptionEnrollmentAccountStatus() []string

func ValidateBillingAccountID

func ValidateBillingAccountID(input interface{}, key string) (warnings []string, errors []error)

ValidateBillingAccountID checks that 'input' can be parsed as a Billing Account ID

func ValidateBillingSubscriptionAliasID

func ValidateBillingSubscriptionAliasID(input interface{}, key string) (warnings []string, errors []error)

ValidateBillingSubscriptionAliasID checks that 'input' can be parsed as a Billing Subscription Alias ID

Types

type Amount

type Amount struct {
	Currency *string  `json:"currency,omitempty"`
	Value    *float64 `json:"value,omitempty"`
}

type AutoRenew

type AutoRenew string
const (
	AutoRenewOff AutoRenew = "Off"
	AutoRenewOn  AutoRenew = "On"
)

func (*AutoRenew) UnmarshalJSON

func (s *AutoRenew) UnmarshalJSON(bytes []byte) error

type BillingAccountId

type BillingAccountId struct {
	BillingAccountName string
}

BillingAccountId is a struct representing the Resource ID for a Billing Account

func NewBillingAccountID

func NewBillingAccountID(billingAccountName 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

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 BillingSubscriptionAlias

type BillingSubscriptionAlias struct {
	Id         *string                             `json:"id,omitempty"`
	Name       *string                             `json:"name,omitempty"`
	Properties *BillingSubscriptionAliasProperties `json:"properties,omitempty"`
	Type       *string                             `json:"type,omitempty"`
}

type BillingSubscriptionAliasId

type BillingSubscriptionAliasId struct {
	BillingAccountName           string
	BillingSubscriptionAliasName string
}

BillingSubscriptionAliasId is a struct representing the Resource ID for a Billing Subscription Alias

func NewBillingSubscriptionAliasID

func NewBillingSubscriptionAliasID(billingAccountName string, billingSubscriptionAliasName string) BillingSubscriptionAliasId

NewBillingSubscriptionAliasID returns a new BillingSubscriptionAliasId struct

func ParseBillingSubscriptionAliasID

func ParseBillingSubscriptionAliasID(input string) (*BillingSubscriptionAliasId, error)

ParseBillingSubscriptionAliasID parses 'input' into a BillingSubscriptionAliasId

func ParseBillingSubscriptionAliasIDInsensitively

func ParseBillingSubscriptionAliasIDInsensitively(input string) (*BillingSubscriptionAliasId, error)

ParseBillingSubscriptionAliasIDInsensitively parses 'input' case-insensitively into a BillingSubscriptionAliasId note: this method should only be used for API response data and not user input

func (*BillingSubscriptionAliasId) FromParseResult

func (id *BillingSubscriptionAliasId) FromParseResult(input resourceids.ParseResult) error

func (BillingSubscriptionAliasId) ID

ID returns the formatted Billing Subscription Alias ID

func (BillingSubscriptionAliasId) Segments

Segments returns a slice of Resource ID Segments which comprise this Billing Subscription Alias ID

func (BillingSubscriptionAliasId) String

func (id BillingSubscriptionAliasId) String() string

String returns a human-readable description of this Billing Subscription Alias ID

type BillingSubscriptionAliasOperationPredicate

type BillingSubscriptionAliasOperationPredicate struct {
	Id   *string
	Name *string
	Type *string
}

func (BillingSubscriptionAliasOperationPredicate) Matches

type BillingSubscriptionAliasProperties

type BillingSubscriptionAliasProperties struct {
	AutoRenew                            *AutoRenew                            `json:"autoRenew,omitempty"`
	BeneficiaryTenantId                  *string                               `json:"beneficiaryTenantId,omitempty"`
	BillingFrequency                     *string                               `json:"billingFrequency,omitempty"`
	BillingPolicies                      *map[string]string                    `json:"billingPolicies,omitempty"`
	BillingProfileDisplayName            *string                               `json:"billingProfileDisplayName,omitempty"`
	BillingProfileId                     *string                               `json:"billingProfileId,omitempty"`
	BillingProfileName                   *string                               `json:"billingProfileName,omitempty"`
	BillingSubscriptionId                *string                               `json:"billingSubscriptionId,omitempty"`
	ConsumptionCostCenter                *string                               `json:"consumptionCostCenter,omitempty"`
	CustomerDisplayName                  *string                               `json:"customerDisplayName,omitempty"`
	CustomerId                           *string                               `json:"customerId,omitempty"`
	CustomerName                         *string                               `json:"customerName,omitempty"`
	DisplayName                          *string                               `json:"displayName,omitempty"`
	EnrollmentAccountDisplayName         *string                               `json:"enrollmentAccountDisplayName,omitempty"`
	EnrollmentAccountId                  *string                               `json:"enrollmentAccountId,omitempty"`
	EnrollmentAccountSubscriptionDetails *EnrollmentAccountSubscriptionDetails `json:"enrollmentAccountSubscriptionDetails,omitempty"`
	InvoiceSectionDisplayName            *string                               `json:"invoiceSectionDisplayName,omitempty"`
	InvoiceSectionId                     *string                               `json:"invoiceSectionId,omitempty"`
	InvoiceSectionName                   *string                               `json:"invoiceSectionName,omitempty"`
	LastMonthCharges                     *Amount                               `json:"lastMonthCharges,omitempty"`
	MonthToDateCharges                   *Amount                               `json:"monthToDateCharges,omitempty"`
	NextBillingCycleDetails              *NextBillingCycleDetails              `json:"nextBillingCycleDetails,omitempty"`
	OfferId                              *string                               `json:"offerId,omitempty"`
	ProductCategory                      *string                               `json:"productCategory,omitempty"`
	ProductType                          *string                               `json:"productType,omitempty"`
	ProductTypeId                        *string                               `json:"productTypeId,omitempty"`
	PurchaseDate                         *string                               `json:"purchaseDate,omitempty"`
	Quantity                             *int64                                `json:"quantity,omitempty"`
	RenewalTermDetails                   *RenewalTermDetails                   `json:"renewalTermDetails,omitempty"`
	Reseller                             *Reseller                             `json:"reseller,omitempty"`
	SkuDescription                       *string                               `json:"skuDescription,omitempty"`
	SkuId                                *string                               `json:"skuId,omitempty"`
	Status                               *BillingSubscriptionStatus            `json:"status,omitempty"`
	SubscriptionId                       *string                               `json:"subscriptionId,omitempty"`
	SuspensionReasons                    *[]string                             `json:"suspensionReasons,omitempty"`
	TermDuration                         *string                               `json:"termDuration,omitempty"`
	TermEndDate                          *string                               `json:"termEndDate,omitempty"`
	TermStartDate                        *string                               `json:"termStartDate,omitempty"`
}

func (*BillingSubscriptionAliasProperties) GetPurchaseDateAsTime

func (o *BillingSubscriptionAliasProperties) GetPurchaseDateAsTime() (*time.Time, error)

func (*BillingSubscriptionAliasProperties) GetTermEndDateAsTime

func (o *BillingSubscriptionAliasProperties) GetTermEndDateAsTime() (*time.Time, error)

func (*BillingSubscriptionAliasProperties) GetTermStartDateAsTime

func (o *BillingSubscriptionAliasProperties) GetTermStartDateAsTime() (*time.Time, error)

func (*BillingSubscriptionAliasProperties) SetPurchaseDateAsTime

func (o *BillingSubscriptionAliasProperties) SetPurchaseDateAsTime(input time.Time)

func (*BillingSubscriptionAliasProperties) SetTermEndDateAsTime

func (o *BillingSubscriptionAliasProperties) SetTermEndDateAsTime(input time.Time)

func (*BillingSubscriptionAliasProperties) SetTermStartDateAsTime

func (o *BillingSubscriptionAliasProperties) SetTermStartDateAsTime(input time.Time)

type BillingSubscriptionStatus

type BillingSubscriptionStatus string
const (
	BillingSubscriptionStatusActive    BillingSubscriptionStatus = "Active"
	BillingSubscriptionStatusAutoRenew BillingSubscriptionStatus = "AutoRenew"
	BillingSubscriptionStatusCancelled BillingSubscriptionStatus = "Cancelled"
	BillingSubscriptionStatusDeleted   BillingSubscriptionStatus = "Deleted"
	BillingSubscriptionStatusDisabled  BillingSubscriptionStatus = "Disabled"
	BillingSubscriptionStatusExpired   BillingSubscriptionStatus = "Expired"
	BillingSubscriptionStatusExpiring  BillingSubscriptionStatus = "Expiring"
	BillingSubscriptionStatusSuspended BillingSubscriptionStatus = "Suspended"
	BillingSubscriptionStatusUnknown   BillingSubscriptionStatus = "Unknown"
	BillingSubscriptionStatusWarned    BillingSubscriptionStatus = "Warned"
)

func (*BillingSubscriptionStatus) UnmarshalJSON

func (s *BillingSubscriptionStatus) UnmarshalJSON(bytes []byte) error

type BillingSubscriptionsAliasesClient

type BillingSubscriptionsAliasesClient struct {
	Client *resourcemanager.Client
}

func NewBillingSubscriptionsAliasesClientWithBaseURI

func NewBillingSubscriptionsAliasesClientWithBaseURI(sdkApi sdkEnv.Api) (*BillingSubscriptionsAliasesClient, error)

func (BillingSubscriptionsAliasesClient) CreateOrUpdate

CreateOrUpdate ...

func (BillingSubscriptionsAliasesClient) CreateOrUpdateThenPoll

CreateOrUpdateThenPoll performs CreateOrUpdate then polls until it's completed

func (BillingSubscriptionsAliasesClient) Get

Get ...

func (BillingSubscriptionsAliasesClient) ListByBillingAccount

ListByBillingAccount ...

func (BillingSubscriptionsAliasesClient) ListByBillingAccountComplete

ListByBillingAccountComplete retrieves all the results into a single object

func (BillingSubscriptionsAliasesClient) ListByBillingAccountCompleteMatchingPredicate

func (c BillingSubscriptionsAliasesClient) ListByBillingAccountCompleteMatchingPredicate(ctx context.Context, id BillingAccountId, predicate BillingSubscriptionAliasOperationPredicate) (result ListByBillingAccountCompleteResult, err error)

ListByBillingAccountCompleteMatchingPredicate retrieves all the results and then applies the predicate

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
}

type EnrollmentAccountSubscriptionDetails

type EnrollmentAccountSubscriptionDetails struct {
	EnrollmentAccountStartDate          *string                              `json:"enrollmentAccountStartDate,omitempty"`
	SubscriptionEnrollmentAccountStatus *SubscriptionEnrollmentAccountStatus `json:"subscriptionEnrollmentAccountStatus,omitempty"`
}

func (*EnrollmentAccountSubscriptionDetails) GetEnrollmentAccountStartDateAsTime

func (o *EnrollmentAccountSubscriptionDetails) GetEnrollmentAccountStartDateAsTime() (*time.Time, error)

func (*EnrollmentAccountSubscriptionDetails) SetEnrollmentAccountStartDateAsTime

func (o *EnrollmentAccountSubscriptionDetails) SetEnrollmentAccountStartDateAsTime(input time.Time)

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *BillingSubscriptionAlias
}

type ListByBillingAccountCompleteResult

type ListByBillingAccountCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []BillingSubscriptionAlias
}

type ListByBillingAccountOperationResponse

type ListByBillingAccountOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]BillingSubscriptionAlias
}

type NextBillingCycleDetails

type NextBillingCycleDetails struct {
	BillingFrequency *string `json:"billingFrequency,omitempty"`
}

type RenewalTermDetails

type RenewalTermDetails struct {
	BillingFrequency *string `json:"billingFrequency,omitempty"`
	ProductTypeId    *string `json:"productTypeId,omitempty"`
	Quantity         *int64  `json:"quantity,omitempty"`
	SkuId            *string `json:"skuId,omitempty"`
	TermDuration     *string `json:"termDuration,omitempty"`
}

type Reseller

type Reseller struct {
	Description *string `json:"description,omitempty"`
	ResellerId  *string `json:"resellerId,omitempty"`
}

type SubscriptionEnrollmentAccountStatus

type SubscriptionEnrollmentAccountStatus string
const (
	SubscriptionEnrollmentAccountStatusActive         SubscriptionEnrollmentAccountStatus = "Active"
	SubscriptionEnrollmentAccountStatusCancelled      SubscriptionEnrollmentAccountStatus = "Cancelled"
	SubscriptionEnrollmentAccountStatusDeleted        SubscriptionEnrollmentAccountStatus = "Deleted"
	SubscriptionEnrollmentAccountStatusExpired        SubscriptionEnrollmentAccountStatus = "Expired"
	SubscriptionEnrollmentAccountStatusTransferredOut SubscriptionEnrollmentAccountStatus = "TransferredOut"
	SubscriptionEnrollmentAccountStatusTransferring   SubscriptionEnrollmentAccountStatus = "Transferring"
)

func (*SubscriptionEnrollmentAccountStatus) UnmarshalJSON

func (s *SubscriptionEnrollmentAccountStatus) UnmarshalJSON(bytes []byte) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL