marketplaces

package
v0.20240402.1085733 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2024 License: MPL-2.0 Imports: 10 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/consumption/2019-10-01/marketplaces Documentation

The marketplaces SDK allows for interaction with the Azure Resource Manager Service consumption (API Version 2019-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-helpers/resourcemanager/commonids"
import "github.com/hashicorp/go-azure-sdk/resource-manager/consumption/2019-10-01/marketplaces"

Client Initialization

client := marketplaces.NewMarketplacesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: MarketplacesClient.List

ctx := context.TODO()
id := commonids.NewScopeID("/subscriptions/12345678-1234-9876-4563-123456789012/resourceGroups/some-resource-group")

// alternatively `client.List(ctx, id, marketplaces.DefaultListOperationOptions())` can be used to do batched pagination
items, err := client.ListComplete(ctx, id, marketplaces.DefaultListOperationOptions())
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

This section is empty.

Types

type ListCompleteResult

type ListCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []Marketplace
}

type ListOperationOptions

type ListOperationOptions struct {
	Filter *string
	Top    *int64
}

func DefaultListOperationOptions

func DefaultListOperationOptions() ListOperationOptions

func (ListOperationOptions) ToHeaders

func (o ListOperationOptions) ToHeaders() *client.Headers

func (ListOperationOptions) ToOData

func (o ListOperationOptions) ToOData() *odata.Query

func (ListOperationOptions) ToQuery

type ListOperationResponse

type ListOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]Marketplace
}

type Marketplace

type Marketplace struct {
	Etag       *string                `json:"etag,omitempty"`
	Id         *string                `json:"id,omitempty"`
	Name       *string                `json:"name,omitempty"`
	Properties *MarketplaceProperties `json:"properties,omitempty"`
	Tags       *map[string]string     `json:"tags,omitempty"`
	Type       *string                `json:"type,omitempty"`
}

type MarketplaceOperationPredicate

type MarketplaceOperationPredicate struct {
	Etag *string
	Id   *string
	Name *string
	Type *string
}

func (MarketplaceOperationPredicate) Matches

type MarketplaceProperties

type MarketplaceProperties struct {
	AccountName          *string  `json:"accountName,omitempty"`
	AdditionalInfo       *string  `json:"additionalInfo,omitempty"`
	AdditionalProperties *string  `json:"additionalProperties,omitempty"`
	BillingPeriodId      *string  `json:"billingPeriodId,omitempty"`
	ConsumedQuantity     *float64 `json:"consumedQuantity,omitempty"`
	ConsumedService      *string  `json:"consumedService,omitempty"`
	CostCenter           *string  `json:"costCenter,omitempty"`
	Currency             *string  `json:"currency,omitempty"`
	DepartmentName       *string  `json:"departmentName,omitempty"`
	InstanceId           *string  `json:"instanceId,omitempty"`
	InstanceName         *string  `json:"instanceName,omitempty"`
	IsEstimated          *bool    `json:"isEstimated,omitempty"`
	IsRecurringCharge    *bool    `json:"isRecurringCharge,omitempty"`
	MeterId              *string  `json:"meterId,omitempty"`
	OfferName            *string  `json:"offerName,omitempty"`
	OrderNumber          *string  `json:"orderNumber,omitempty"`
	PlanName             *string  `json:"planName,omitempty"`
	PretaxCost           *float64 `json:"pretaxCost,omitempty"`
	PublisherName        *string  `json:"publisherName,omitempty"`
	ResourceGroup        *string  `json:"resourceGroup,omitempty"`
	ResourceRate         *float64 `json:"resourceRate,omitempty"`
	SubscriptionGuid     *string  `json:"subscriptionGuid,omitempty"`
	SubscriptionName     *string  `json:"subscriptionName,omitempty"`
	UnitOfMeasure        *string  `json:"unitOfMeasure,omitempty"`
	UsageEnd             *string  `json:"usageEnd,omitempty"`
	UsageStart           *string  `json:"usageStart,omitempty"`
}

func (*MarketplaceProperties) GetUsageEndAsTime

func (o *MarketplaceProperties) GetUsageEndAsTime() (*time.Time, error)

func (*MarketplaceProperties) GetUsageStartAsTime

func (o *MarketplaceProperties) GetUsageStartAsTime() (*time.Time, error)

func (*MarketplaceProperties) SetUsageEndAsTime

func (o *MarketplaceProperties) SetUsageEndAsTime(input time.Time)

func (*MarketplaceProperties) SetUsageStartAsTime

func (o *MarketplaceProperties) SetUsageStartAsTime(input time.Time)

type MarketplacesClient

type MarketplacesClient struct {
	Client *resourcemanager.Client
}

func NewMarketplacesClientWithBaseURI

func NewMarketplacesClientWithBaseURI(sdkApi sdkEnv.Api) (*MarketplacesClient, error)

func (MarketplacesClient) List

List ...

func (MarketplacesClient) ListComplete

ListComplete retrieves all the results into a single object

func (MarketplacesClient) ListCompleteMatchingPredicate

func (c MarketplacesClient) ListCompleteMatchingPredicate(ctx context.Context, id commonids.ScopeId, options ListOperationOptions, predicate MarketplaceOperationPredicate) (result ListCompleteResult, err error)

ListCompleteMatchingPredicate retrieves all the results and then applies the predicate

Jump to

Keyboard shortcuts

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