Documentation ¶
Index ¶
- type AgreementProperties
- type AgreementTerms
- type ClientFactory
- type CreatedByType
- type ErrorResponse
- type ErrorResponseError
- type MarketplaceAgreementsClient
- func (client *MarketplaceAgreementsClient) Cancel(ctx context.Context, publisherID string, offerID string, planID string, ...) (MarketplaceAgreementsClientCancelResponse, error)
- func (client *MarketplaceAgreementsClient) Create(ctx context.Context, offerType OfferType, publisherID string, offerID string, ...) (MarketplaceAgreementsClientCreateResponse, error)
- func (client *MarketplaceAgreementsClient) Get(ctx context.Context, offerType OfferType, publisherID string, offerID string, ...) (MarketplaceAgreementsClientGetResponse, error)
- func (client *MarketplaceAgreementsClient) GetAgreement(ctx context.Context, publisherID string, offerID string, planID string, ...) (MarketplaceAgreementsClientGetAgreementResponse, error)
- func (client *MarketplaceAgreementsClient) List(ctx context.Context, options *MarketplaceAgreementsClientListOptions) (MarketplaceAgreementsClientListResponse, error)
- func (client *MarketplaceAgreementsClient) Sign(ctx context.Context, publisherID string, offerID string, planID string, ...) (MarketplaceAgreementsClientSignResponse, error)
- type MarketplaceAgreementsClientCancelOptions
- type MarketplaceAgreementsClientCancelResponse
- type MarketplaceAgreementsClientCreateOptions
- type MarketplaceAgreementsClientCreateResponse
- type MarketplaceAgreementsClientGetAgreementOptions
- type MarketplaceAgreementsClientGetAgreementResponse
- type MarketplaceAgreementsClientGetOptions
- type MarketplaceAgreementsClientGetResponse
- type MarketplaceAgreementsClientListOptions
- type MarketplaceAgreementsClientListResponse
- type MarketplaceAgreementsClientSignOptions
- type MarketplaceAgreementsClientSignResponse
- type OfferType
- type Operation
- type OperationDisplay
- type OperationListResult
- type OperationsClient
- type OperationsClientListOptions
- type OperationsClientListResponse
- type Resource
- type SystemData
Examples ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AgreementProperties ¶
type AgreementProperties struct { // If any version of the terms have been accepted, otherwise false. Accepted *bool // Link to HTML with Microsoft and Publisher terms. LicenseTextLink *string // Link to HTML with Azure Marketplace terms. MarketplaceTermsLink *string // Plan identifier string of image being deployed. Plan *string // Link to the privacy policy of the publisher. PrivacyPolicyLink *string // Offer identifier string of image being deployed. Product *string // Publisher identifier string of image being deployed. Publisher *string // Date and time in UTC of when the terms were accepted. This is empty if Accepted is false. RetrieveDatetime *time.Time // Terms signature. Signature *string }
AgreementProperties - Agreement Terms definition
func (AgreementProperties) MarshalJSON ¶
func (a AgreementProperties) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AgreementProperties.
func (*AgreementProperties) UnmarshalJSON ¶
func (a *AgreementProperties) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AgreementProperties.
type AgreementTerms ¶
type AgreementTerms struct { // Represents the properties of the resource. Properties *AgreementProperties // READ-ONLY; Resource ID. ID *string // READ-ONLY; Resource name. Name *string // READ-ONLY; The system meta data relating to this resource. SystemData *SystemData // READ-ONLY; Resource type. Type *string }
AgreementTerms - Terms properties for provided Publisher/Offer/Plan tuple
func (AgreementTerms) MarshalJSON ¶
func (a AgreementTerms) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type AgreementTerms.
func (*AgreementTerms) UnmarshalJSON ¶
func (a *AgreementTerms) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type AgreementTerms.
type ClientFactory ¶
type ClientFactory struct {
// contains filtered or unexported fields
}
ClientFactory is a client factory used to create any client in this module. Don't use this type directly, use NewClientFactory instead.
func NewClientFactory ¶
func NewClientFactory(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*ClientFactory, error)
NewClientFactory creates a new instance of ClientFactory with the specified values. The parameter values will be propagated to any client created from this factory.
- subscriptionID - The subscription ID that identifies an Azure subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*ClientFactory) NewMarketplaceAgreementsClient ¶
func (c *ClientFactory) NewMarketplaceAgreementsClient() *MarketplaceAgreementsClient
NewMarketplaceAgreementsClient creates a new instance of MarketplaceAgreementsClient.
func (*ClientFactory) NewOperationsClient ¶
func (c *ClientFactory) NewOperationsClient() *OperationsClient
NewOperationsClient creates a new instance of OperationsClient.
type CreatedByType ¶
type CreatedByType string
CreatedByType - The type of identity that created the resource.
const ( CreatedByTypeApplication CreatedByType = "Application" CreatedByTypeKey CreatedByType = "Key" CreatedByTypeManagedIdentity CreatedByType = "ManagedIdentity" CreatedByTypeUser CreatedByType = "User" )
func PossibleCreatedByTypeValues ¶
func PossibleCreatedByTypeValues() []CreatedByType
PossibleCreatedByTypeValues returns the possible values for the CreatedByType const type.
type ErrorResponse ¶
type ErrorResponse struct { // The details of the error. Error *ErrorResponseError }
ErrorResponse - Error response indicates Microsoft.MarketplaceOrdering service is not able to process the incoming request. The reason is provided in the error message.
func (ErrorResponse) MarshalJSON ¶
func (e ErrorResponse) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorResponse.
func (*ErrorResponse) UnmarshalJSON ¶
func (e *ErrorResponse) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorResponse.
type ErrorResponseError ¶
type ErrorResponseError struct { // READ-ONLY; Error code. Code *string // READ-ONLY; Error message indicating why the operation failed. Message *string }
ErrorResponseError - The details of the error.
func (ErrorResponseError) MarshalJSON ¶
func (e ErrorResponseError) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type ErrorResponseError.
func (*ErrorResponseError) UnmarshalJSON ¶
func (e *ErrorResponseError) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type ErrorResponseError.
type MarketplaceAgreementsClient ¶
type MarketplaceAgreementsClient struct {
// contains filtered or unexported fields
}
MarketplaceAgreementsClient contains the methods for the MarketplaceAgreements group. Don't use this type directly, use NewMarketplaceAgreementsClient() instead.
func NewMarketplaceAgreementsClient ¶
func NewMarketplaceAgreementsClient(subscriptionID string, credential azcore.TokenCredential, options *arm.ClientOptions) (*MarketplaceAgreementsClient, error)
NewMarketplaceAgreementsClient creates a new instance of MarketplaceAgreementsClient with the specified values.
- subscriptionID - The subscription ID that identifies an Azure subscription.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*MarketplaceAgreementsClient) Cancel ¶
func (client *MarketplaceAgreementsClient) Cancel(ctx context.Context, publisherID string, offerID string, planID string, options *MarketplaceAgreementsClientCancelOptions) (MarketplaceAgreementsClientCancelResponse, error)
Cancel - Cancel marketplace terms. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2021-01-01
- publisherID - Publisher identifier string of image being deployed.
- offerID - Offer identifier string of image being deployed.
- planID - Plan identifier string of image being deployed.
- options - MarketplaceAgreementsClientCancelOptions contains the optional parameters for the MarketplaceAgreementsClient.Cancel method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d55b8005f05b040b852c15e74a0f3e36494a15e1/specification/marketplaceordering/resource-manager/Microsoft.MarketplaceOrdering/stable/2021-01-01/examples/CancelMarketplaceTerms.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/marketplaceordering/armmarketplaceordering" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armmarketplaceordering.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMarketplaceAgreementsClient().Cancel(ctx, "pubid", "offid", "planid", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } // You could use response here. We use blank identifier for just demo purposes. _ = res // If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // res.AgreementTerms = armmarketplaceordering.AgreementTerms{ // Name: to.Ptr("planid"), // Type: to.Ptr("Microsoft.MarketplaceOrdering/offertypes"), // ID: to.Ptr("id"), // Properties: &armmarketplaceordering.AgreementProperties{ // Accepted: to.Ptr(false), // LicenseTextLink: to.Ptr("test.licenseLink"), // MarketplaceTermsLink: to.Ptr("test.marketplaceTermsLink"), // Plan: to.Ptr("planid"), // PrivacyPolicyLink: to.Ptr("test.privacyPolicyLink"), // Product: to.Ptr("offid"), // Publisher: to.Ptr("pubid"), // RetrieveDatetime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-08-15T11:33:07.121Z"); return t}()), // Signature: to.Ptr("ASDFSDAFWEFASDGWERLWER"), // }, // } }
Output:
func (*MarketplaceAgreementsClient) Create ¶
func (client *MarketplaceAgreementsClient) Create(ctx context.Context, offerType OfferType, publisherID string, offerID string, planID string, parameters AgreementTerms, options *MarketplaceAgreementsClientCreateOptions) (MarketplaceAgreementsClientCreateResponse, error)
Create - Save marketplace terms. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2021-01-01
- offerType - Offer Type, currently only virtualmachine type is supported.
- publisherID - Publisher identifier string of image being deployed.
- offerID - Offer identifier string of image being deployed.
- planID - Plan identifier string of image being deployed.
- parameters - Parameters supplied to the Create Marketplace Terms operation.
- options - MarketplaceAgreementsClientCreateOptions contains the optional parameters for the MarketplaceAgreementsClient.Create method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d55b8005f05b040b852c15e74a0f3e36494a15e1/specification/marketplaceordering/resource-manager/Microsoft.MarketplaceOrdering/stable/2021-01-01/examples/SetMarketplaceTerms.json
package main import ( "context" "log" "time" "github.com/Azure/azure-sdk-for-go/sdk/azcore/to" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/marketplaceordering/armmarketplaceordering" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armmarketplaceordering.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMarketplaceAgreementsClient().Create(ctx, armmarketplaceordering.OfferTypeVirtualmachine, "pubid", "offid", "planid", armmarketplaceordering.AgreementTerms{ Properties: &armmarketplaceordering.AgreementProperties{ Accepted: to.Ptr(false), LicenseTextLink: to.Ptr("test.licenseLink"), MarketplaceTermsLink: to.Ptr("test.marketplaceTermsLink"), Plan: to.Ptr("planid"), PrivacyPolicyLink: to.Ptr("test.privacyPolicyLink"), Product: to.Ptr("offid"), Publisher: to.Ptr("pubid"), RetrieveDatetime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-08-15T11:33:07.121Z"); return t }()), Signature: to.Ptr("ASDFSDAFWEFASDGWERLWER"), }, }, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } // You could use response here. We use blank identifier for just demo purposes. _ = res // If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // res.AgreementTerms = armmarketplaceordering.AgreementTerms{ // Name: to.Ptr("planid"), // Type: to.Ptr("Microsoft.MarketplaceOrdering/offertypes"), // ID: to.Ptr("id"), // Properties: &armmarketplaceordering.AgreementProperties{ // Accepted: to.Ptr(true), // LicenseTextLink: to.Ptr("test.licenseLink"), // MarketplaceTermsLink: to.Ptr("test.marketplaceTermsLink"), // Plan: to.Ptr("planid"), // PrivacyPolicyLink: to.Ptr("test.privacyPolicyLink"), // Product: to.Ptr("offid"), // Publisher: to.Ptr("pubid"), // RetrieveDatetime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-08-15T11:33:07.121Z"); return t}()), // Signature: to.Ptr("ASDFSDAFWEFASDGWERLWER"), // }, // } }
Output:
func (*MarketplaceAgreementsClient) Get ¶
func (client *MarketplaceAgreementsClient) Get(ctx context.Context, offerType OfferType, publisherID string, offerID string, planID string, options *MarketplaceAgreementsClientGetOptions) (MarketplaceAgreementsClientGetResponse, error)
Get - Get marketplace terms. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2021-01-01
- offerType - Offer Type, currently only virtualmachine type is supported.
- publisherID - Publisher identifier string of image being deployed.
- offerID - Offer identifier string of image being deployed.
- planID - Plan identifier string of image being deployed.
- options - MarketplaceAgreementsClientGetOptions contains the optional parameters for the MarketplaceAgreementsClient.Get method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d55b8005f05b040b852c15e74a0f3e36494a15e1/specification/marketplaceordering/resource-manager/Microsoft.MarketplaceOrdering/stable/2021-01-01/examples/GetMarketplaceTerms.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/marketplaceordering/armmarketplaceordering" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armmarketplaceordering.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMarketplaceAgreementsClient().Get(ctx, armmarketplaceordering.OfferTypeVirtualmachine, "pubid", "offid", "planid", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } // You could use response here. We use blank identifier for just demo purposes. _ = res // If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // res.AgreementTerms = armmarketplaceordering.AgreementTerms{ // Name: to.Ptr("planid"), // Type: to.Ptr("Microsoft.MarketplaceOrdering/offertypes"), // ID: to.Ptr("id"), // Properties: &armmarketplaceordering.AgreementProperties{ // Accepted: to.Ptr(true), // LicenseTextLink: to.Ptr("test.licenseLink"), // MarketplaceTermsLink: to.Ptr("test.marketplaceTermsLink"), // Plan: to.Ptr("planid"), // PrivacyPolicyLink: to.Ptr("test.privacyPolicyLink"), // Product: to.Ptr("offid"), // Publisher: to.Ptr("pubid"), // RetrieveDatetime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-08-15T11:33:07.121Z"); return t}()), // Signature: to.Ptr("ASDFSDAFWEFASDGWERLWER"), // }, // } }
Output:
func (*MarketplaceAgreementsClient) GetAgreement ¶
func (client *MarketplaceAgreementsClient) GetAgreement(ctx context.Context, publisherID string, offerID string, planID string, options *MarketplaceAgreementsClientGetAgreementOptions) (MarketplaceAgreementsClientGetAgreementResponse, error)
GetAgreement - Get marketplace agreement. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2021-01-01
- publisherID - Publisher identifier string of image being deployed.
- offerID - Offer identifier string of image being deployed.
- planID - Plan identifier string of image being deployed.
- options - MarketplaceAgreementsClientGetAgreementOptions contains the optional parameters for the MarketplaceAgreementsClient.GetAgreement method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d55b8005f05b040b852c15e74a0f3e36494a15e1/specification/marketplaceordering/resource-manager/Microsoft.MarketplaceOrdering/stable/2021-01-01/examples/GetAgreementMarketplaceTerms.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/marketplaceordering/armmarketplaceordering" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armmarketplaceordering.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMarketplaceAgreementsClient().GetAgreement(ctx, "pubid", "offid", "planid", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } // You could use response here. We use blank identifier for just demo purposes. _ = res // If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // res.AgreementTerms = armmarketplaceordering.AgreementTerms{ // Name: to.Ptr("planid"), // Type: to.Ptr("Microsoft.MarketplaceOrdering/offertypes"), // ID: to.Ptr("id"), // Properties: &armmarketplaceordering.AgreementProperties{ // Accepted: to.Ptr(true), // LicenseTextLink: to.Ptr("test.licenseLink"), // MarketplaceTermsLink: to.Ptr("test.marketplaceTermsLink"), // Plan: to.Ptr("planid"), // PrivacyPolicyLink: to.Ptr("test.privacyPolicyLink"), // Product: to.Ptr("offid"), // Publisher: to.Ptr("pubid"), // RetrieveDatetime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-08-15T11:33:07.121Z"); return t}()), // Signature: to.Ptr("ASDFSDAFWEFASDGWERLWER"), // }, // } }
Output:
func (*MarketplaceAgreementsClient) List ¶
func (client *MarketplaceAgreementsClient) List(ctx context.Context, options *MarketplaceAgreementsClientListOptions) (MarketplaceAgreementsClientListResponse, error)
List - List marketplace agreements in the subscription. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2021-01-01
- options - MarketplaceAgreementsClientListOptions contains the optional parameters for the MarketplaceAgreementsClient.List method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d55b8005f05b040b852c15e74a0f3e36494a15e1/specification/marketplaceordering/resource-manager/Microsoft.MarketplaceOrdering/stable/2021-01-01/examples/ListMarketplaceTerms.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/marketplaceordering/armmarketplaceordering" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armmarketplaceordering.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMarketplaceAgreementsClient().List(ctx, nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } // You could use response here. We use blank identifier for just demo purposes. _ = res // If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // res.AgreementTermsArray = []*armmarketplaceordering.AgreementTerms{ // { // Name: to.Ptr("planid"), // Type: to.Ptr("Microsoft.MarketplaceOrdering/offertypes"), // ID: to.Ptr("id"), // Properties: &armmarketplaceordering.AgreementProperties{ // Accepted: to.Ptr(true), // LicenseTextLink: to.Ptr("test.licenseLink"), // MarketplaceTermsLink: to.Ptr("test.marketplaceTermsLink"), // Plan: to.Ptr("planid"), // PrivacyPolicyLink: to.Ptr("test.privacyPolicyLink"), // Product: to.Ptr("offid"), // Publisher: to.Ptr("pubid"), // RetrieveDatetime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-08-15T11:33:07.121Z"); return t}()), // Signature: to.Ptr("ASDFSDAFWEFASDGWERLWER"), // }, // }} }
Output:
func (*MarketplaceAgreementsClient) Sign ¶
func (client *MarketplaceAgreementsClient) Sign(ctx context.Context, publisherID string, offerID string, planID string, options *MarketplaceAgreementsClientSignOptions) (MarketplaceAgreementsClientSignResponse, error)
Sign - Sign marketplace terms. If the operation fails it returns an *azcore.ResponseError type.
Generated from API version 2021-01-01
- publisherID - Publisher identifier string of image being deployed.
- offerID - Offer identifier string of image being deployed.
- planID - Plan identifier string of image being deployed.
- options - MarketplaceAgreementsClientSignOptions contains the optional parameters for the MarketplaceAgreementsClient.Sign method.
Example ¶
Generated from example definition: https://github.com/Azure/azure-rest-api-specs/blob/d55b8005f05b040b852c15e74a0f3e36494a15e1/specification/marketplaceordering/resource-manager/Microsoft.MarketplaceOrdering/stable/2021-01-01/examples/SignMarketplaceTerms.json
package main import ( "context" "log" "github.com/Azure/azure-sdk-for-go/sdk/azidentity" "github.com/Azure/azure-sdk-for-go/sdk/resourcemanager/marketplaceordering/armmarketplaceordering" ) func main() { cred, err := azidentity.NewDefaultAzureCredential(nil) if err != nil { log.Fatalf("failed to obtain a credential: %v", err) } ctx := context.Background() clientFactory, err := armmarketplaceordering.NewClientFactory("<subscription-id>", cred, nil) if err != nil { log.Fatalf("failed to create client: %v", err) } res, err := clientFactory.NewMarketplaceAgreementsClient().Sign(ctx, "pubid", "offid", "planid", nil) if err != nil { log.Fatalf("failed to finish the request: %v", err) } // You could use response here. We use blank identifier for just demo purposes. _ = res // If the HTTP response code is 200 as defined in example definition, your response structure would look as follows. Please pay attention that all the values in the output are fake values for just demo purposes. // res.AgreementTerms = armmarketplaceordering.AgreementTerms{ // Name: to.Ptr("planid"), // Type: to.Ptr("Microsoft.MarketplaceOrdering/offertypes"), // ID: to.Ptr("id"), // Properties: &armmarketplaceordering.AgreementProperties{ // Accepted: to.Ptr(true), // LicenseTextLink: to.Ptr("test.licenseLink"), // MarketplaceTermsLink: to.Ptr("test.marketplaceTermsLink"), // Plan: to.Ptr("planid"), // PrivacyPolicyLink: to.Ptr("test.privacyPolicyLink"), // Product: to.Ptr("offid"), // Publisher: to.Ptr("pubid"), // RetrieveDatetime: to.Ptr(func() time.Time { t, _ := time.Parse(time.RFC3339Nano, "2017-08-15T11:33:07.121Z"); return t}()), // Signature: to.Ptr("ASDFSDAFWEFASDGWERLWER"), // }, // } }
Output:
type MarketplaceAgreementsClientCancelOptions ¶
type MarketplaceAgreementsClientCancelOptions struct { }
MarketplaceAgreementsClientCancelOptions contains the optional parameters for the MarketplaceAgreementsClient.Cancel method.
type MarketplaceAgreementsClientCancelResponse ¶
type MarketplaceAgreementsClientCancelResponse struct { // Terms properties for provided Publisher/Offer/Plan tuple AgreementTerms }
MarketplaceAgreementsClientCancelResponse contains the response from method MarketplaceAgreementsClient.Cancel.
type MarketplaceAgreementsClientCreateOptions ¶
type MarketplaceAgreementsClientCreateOptions struct { }
MarketplaceAgreementsClientCreateOptions contains the optional parameters for the MarketplaceAgreementsClient.Create method.
type MarketplaceAgreementsClientCreateResponse ¶
type MarketplaceAgreementsClientCreateResponse struct { // Terms properties for provided Publisher/Offer/Plan tuple AgreementTerms }
MarketplaceAgreementsClientCreateResponse contains the response from method MarketplaceAgreementsClient.Create.
type MarketplaceAgreementsClientGetAgreementOptions ¶
type MarketplaceAgreementsClientGetAgreementOptions struct { }
MarketplaceAgreementsClientGetAgreementOptions contains the optional parameters for the MarketplaceAgreementsClient.GetAgreement method.
type MarketplaceAgreementsClientGetAgreementResponse ¶
type MarketplaceAgreementsClientGetAgreementResponse struct { // Terms properties for provided Publisher/Offer/Plan tuple AgreementTerms }
MarketplaceAgreementsClientGetAgreementResponse contains the response from method MarketplaceAgreementsClient.GetAgreement.
type MarketplaceAgreementsClientGetOptions ¶
type MarketplaceAgreementsClientGetOptions struct { }
MarketplaceAgreementsClientGetOptions contains the optional parameters for the MarketplaceAgreementsClient.Get method.
type MarketplaceAgreementsClientGetResponse ¶
type MarketplaceAgreementsClientGetResponse struct { // Terms properties for provided Publisher/Offer/Plan tuple AgreementTerms }
MarketplaceAgreementsClientGetResponse contains the response from method MarketplaceAgreementsClient.Get.
type MarketplaceAgreementsClientListOptions ¶
type MarketplaceAgreementsClientListOptions struct { }
MarketplaceAgreementsClientListOptions contains the optional parameters for the MarketplaceAgreementsClient.List method.
type MarketplaceAgreementsClientListResponse ¶
type MarketplaceAgreementsClientListResponse struct { // Array of AgreementTerms AgreementTermsArray []*AgreementTerms }
MarketplaceAgreementsClientListResponse contains the response from method MarketplaceAgreementsClient.List.
type MarketplaceAgreementsClientSignOptions ¶
type MarketplaceAgreementsClientSignOptions struct { }
MarketplaceAgreementsClientSignOptions contains the optional parameters for the MarketplaceAgreementsClient.Sign method.
type MarketplaceAgreementsClientSignResponse ¶
type MarketplaceAgreementsClientSignResponse struct { // Terms properties for provided Publisher/Offer/Plan tuple AgreementTerms }
MarketplaceAgreementsClientSignResponse contains the response from method MarketplaceAgreementsClient.Sign.
type OfferType ¶
type OfferType string
const (
OfferTypeVirtualmachine OfferType = "virtualmachine"
)
func PossibleOfferTypeValues ¶
func PossibleOfferTypeValues() []OfferType
PossibleOfferTypeValues returns the possible values for the OfferType const type.
type Operation ¶
type Operation struct { // The object that represents the operation. Display *OperationDisplay // Operation name: {provider}/{resource}/{operation} Name *string }
Operation - Microsoft.MarketplaceOrdering REST API operation
func (Operation) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Operation.
func (*Operation) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Operation.
type OperationDisplay ¶
type OperationDisplay struct { // Operation description. Description *string // Operation type: Get Agreement, Sign Agreement, Cancel Agreement etc. Operation *string // Service provider: Microsoft.MarketplaceOrdering Provider *string // Resource on which the operation is performed: Agreement, virtualmachine, etc. Resource *string }
OperationDisplay - The object that represents the operation.
func (OperationDisplay) MarshalJSON ¶
func (o OperationDisplay) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationDisplay.
func (*OperationDisplay) UnmarshalJSON ¶
func (o *OperationDisplay) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationDisplay.
type OperationListResult ¶
type OperationListResult struct { // List of Microsoft.MarketplaceOrdering operations supported by the Microsoft.MarketplaceOrdering resource provider. Value []*Operation // READ-ONLY; URL to get the next set of operation list results if there are any. NextLink *string }
OperationListResult - Result of the request to list MarketplaceOrdering operations. It contains a list of operations and a URL link to get the next set of results.
func (OperationListResult) MarshalJSON ¶
func (o OperationListResult) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type OperationListResult.
func (*OperationListResult) UnmarshalJSON ¶
func (o *OperationListResult) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type OperationListResult.
type OperationsClient ¶
type OperationsClient struct {
// contains filtered or unexported fields
}
OperationsClient contains the methods for the Operations group. Don't use this type directly, use NewOperationsClient() instead.
func NewOperationsClient ¶
func NewOperationsClient(credential azcore.TokenCredential, options *arm.ClientOptions) (*OperationsClient, error)
NewOperationsClient creates a new instance of OperationsClient with the specified values.
- credential - used to authorize requests. Usually a credential from azidentity.
- options - pass nil to accept the default values.
func (*OperationsClient) NewListPager ¶
func (client *OperationsClient) NewListPager(options *OperationsClientListOptions) *runtime.Pager[OperationsClientListResponse]
NewListPager - Lists all of the available Microsoft.MarketplaceOrdering REST API operations.
Generated from API version 2021-01-01
- options - OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
type OperationsClientListOptions ¶
type OperationsClientListOptions struct { }
OperationsClientListOptions contains the optional parameters for the OperationsClient.NewListPager method.
type OperationsClientListResponse ¶
type OperationsClientListResponse struct { // Result of the request to list MarketplaceOrdering operations. It contains a list of operations and a URL link to get the // next set of results. OperationListResult }
OperationsClientListResponse contains the response from method OperationsClient.NewListPager.
type Resource ¶
type Resource struct { // READ-ONLY; Resource ID. ID *string // READ-ONLY; Resource name. Name *string // READ-ONLY; Resource type. Type *string }
Resource - ARM resource.
func (Resource) MarshalJSON ¶
MarshalJSON implements the json.Marshaller interface for type Resource.
func (*Resource) UnmarshalJSON ¶
UnmarshalJSON implements the json.Unmarshaller interface for type Resource.
type SystemData ¶
type SystemData struct { // The timestamp of resource creation (UTC). CreatedAt *time.Time // The identity that created the resource. CreatedBy *string // The type of identity that created the resource. CreatedByType *CreatedByType // The timestamp of resource last modification (UTC) LastModifiedAt *time.Time // The identity that last modified the resource. LastModifiedBy *string // The type of identity that last modified the resource. LastModifiedByType *CreatedByType }
SystemData - Metadata pertaining to creation and last modification of the resource.
func (SystemData) MarshalJSON ¶
func (s SystemData) MarshalJSON() ([]byte, error)
MarshalJSON implements the json.Marshaller interface for type SystemData.
func (*SystemData) UnmarshalJSON ¶
func (s *SystemData) UnmarshalJSON(data []byte) error
UnmarshalJSON implements the json.Unmarshaller interface for type SystemData.