customapis

package
v0.20240119.1124806 Latest Latest
Warning

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

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

README

github.com/hashicorp/go-azure-sdk/resource-manager/web/2016-06-01/customapis Documentation

The customapis SDK allows for interaction with the Azure Resource Manager Service web (API Version 2016-06-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/web/2016-06-01/customapis"

Client Initialization

client := customapis.NewCustomAPIsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: CustomAPIsClient.CreateOrUpdate

ctx := context.TODO()
id := customapis.NewCustomApiID("12345678-1234-9876-4563-123456789012", "example-resource-group", "customApiValue")

payload := customapis.CustomApiDefinition{
	// ...
}


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

Example Usage: CustomAPIsClient.Delete

ctx := context.TODO()
id := customapis.NewCustomApiID("12345678-1234-9876-4563-123456789012", "example-resource-group", "customApiValue")

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

Example Usage: CustomAPIsClient.ExtractApiDefinitionFromWsdl

ctx := context.TODO()
id := customapis.NewLocationID("12345678-1234-9876-4563-123456789012", "locationValue")

payload := customapis.WsdlDefinition{
	// ...
}


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

Example Usage: CustomAPIsClient.Get

ctx := context.TODO()
id := customapis.NewCustomApiID("12345678-1234-9876-4563-123456789012", "example-resource-group", "customApiValue")

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: CustomAPIsClient.List

ctx := context.TODO()
id := customapis.NewSubscriptionID("12345678-1234-9876-4563-123456789012")

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

Example Usage: CustomAPIsClient.ListByResourceGroup

ctx := context.TODO()
id := customapis.NewResourceGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group")

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

Example Usage: CustomAPIsClient.ListWsdlInterfaces

ctx := context.TODO()
id := customapis.NewLocationID("12345678-1234-9876-4563-123456789012", "locationValue")

payload := customapis.WsdlDefinition{
	// ...
}


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

Example Usage: CustomAPIsClient.Move

ctx := context.TODO()
id := customapis.NewCustomApiID("12345678-1234-9876-4563-123456789012", "example-resource-group", "customApiValue")

payload := customapis.CustomApiReference{
	// ...
}


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

Example Usage: CustomAPIsClient.Update

ctx := context.TODO()
id := customapis.NewCustomApiID("12345678-1234-9876-4563-123456789012", "example-resource-group", "customApiValue")

payload := customapis.CustomApiDefinition{
	// ...
}


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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForApiType

func PossibleValuesForApiType() []string

func PossibleValuesForConnectionParameterType

func PossibleValuesForConnectionParameterType() []string

func PossibleValuesForWsdlImportMethod

func PossibleValuesForWsdlImportMethod() []string

func ValidateCustomApiID

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

ValidateCustomApiID checks that 'input' can be parsed as a Custom Api ID

func ValidateLocationID

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

ValidateLocationID checks that 'input' can be parsed as a Location ID

Types

type ApiOAuthSettings

type ApiOAuthSettings struct {
	ClientId         *string                               `json:"clientId,omitempty"`
	ClientSecret     *string                               `json:"clientSecret,omitempty"`
	CustomParameters *map[string]ApiOAuthSettingsParameter `json:"customParameters,omitempty"`
	IdentityProvider *string                               `json:"identityProvider,omitempty"`
	Properties       *interface{}                          `json:"properties,omitempty"`
	RedirectUrl      *string                               `json:"redirectUrl,omitempty"`
	Scopes           *[]string                             `json:"scopes,omitempty"`
}

type ApiOAuthSettingsParameter

type ApiOAuthSettingsParameter struct {
	Options      *interface{} `json:"options,omitempty"`
	UiDefinition *interface{} `json:"uiDefinition,omitempty"`
	Value        *string      `json:"value,omitempty"`
}

type ApiResourceBackendService

type ApiResourceBackendService struct {
	ServiceUrl *string `json:"serviceUrl,omitempty"`
}

type ApiResourceDefinitions

type ApiResourceDefinitions struct {
	ModifiedSwaggerUrl *string `json:"modifiedSwaggerUrl,omitempty"`
	OriginalSwaggerUrl *string `json:"originalSwaggerUrl,omitempty"`
}

type ApiType

type ApiType string
const (
	ApiTypeNotSpecified ApiType = "NotSpecified"
	ApiTypeRest         ApiType = "Rest"
	ApiTypeSoap         ApiType = "Soap"
)

func (*ApiType) UnmarshalJSON added in v0.20230725.1205316

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

type ConnectionParameter

type ConnectionParameter struct {
	OAuthSettings *ApiOAuthSettings        `json:"oAuthSettings,omitempty"`
	Type          *ConnectionParameterType `json:"type,omitempty"`
}

type ConnectionParameterType

type ConnectionParameterType string
const (
	ConnectionParameterTypeArray        ConnectionParameterType = "array"
	ConnectionParameterTypeBool         ConnectionParameterType = "bool"
	ConnectionParameterTypeConnection   ConnectionParameterType = "connection"
	ConnectionParameterTypeInt          ConnectionParameterType = "int"
	ConnectionParameterTypeOauthSetting ConnectionParameterType = "oauthSetting"
	ConnectionParameterTypeObject       ConnectionParameterType = "object"
	ConnectionParameterTypeSecureobject ConnectionParameterType = "secureobject"
	ConnectionParameterTypeSecurestring ConnectionParameterType = "securestring"
	ConnectionParameterTypeString       ConnectionParameterType = "string"
)

func (*ConnectionParameterType) UnmarshalJSON added in v0.20230725.1205316

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

type CreateOrUpdateOperationResponse added in v0.20230906.1160501

type CreateOrUpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *CustomApiDefinition
}

type CustomAPIsClient

type CustomAPIsClient struct {
	Client *resourcemanager.Client
}

func NewCustomAPIsClientWithBaseURI

func NewCustomAPIsClientWithBaseURI(sdkApi sdkEnv.Api) (*CustomAPIsClient, error)

func (CustomAPIsClient) CreateOrUpdate added in v0.20230906.1160501

CreateOrUpdate ...

func (CustomAPIsClient) Delete added in v0.20230906.1160501

func (c CustomAPIsClient) Delete(ctx context.Context, id CustomApiId) (result DeleteOperationResponse, err error)

Delete ...

func (CustomAPIsClient) ExtractApiDefinitionFromWsdl added in v0.20230906.1160501

func (c CustomAPIsClient) ExtractApiDefinitionFromWsdl(ctx context.Context, id LocationId, input WsdlDefinition) (result ExtractApiDefinitionFromWsdlOperationResponse, err error)

ExtractApiDefinitionFromWsdl ...

func (CustomAPIsClient) Get added in v0.20230906.1160501

Get ...

func (CustomAPIsClient) List added in v0.20230906.1160501

List ...

func (CustomAPIsClient) ListByResourceGroup added in v0.20230906.1160501

ListByResourceGroup ...

func (CustomAPIsClient) ListWsdlInterfaces added in v0.20230906.1160501

func (c CustomAPIsClient) ListWsdlInterfaces(ctx context.Context, id LocationId, input WsdlDefinition) (result ListWsdlInterfacesOperationResponse, err error)

ListWsdlInterfaces ...

func (CustomAPIsClient) Move added in v0.20230906.1160501

Move ...

func (CustomAPIsClient) Update added in v0.20230906.1160501

Update ...

type CustomApiDefinition

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

type CustomApiDefinitionCollection

type CustomApiDefinitionCollection struct {
	Value *[]CustomApiDefinition `json:"value,omitempty"`
}

type CustomApiId

type CustomApiId struct {
	SubscriptionId    string
	ResourceGroupName string
	CustomApiName     string
}

CustomApiId is a struct representing the Resource ID for a Custom Api

func NewCustomApiID

func NewCustomApiID(subscriptionId string, resourceGroupName string, customApiName string) CustomApiId

NewCustomApiID returns a new CustomApiId struct

func ParseCustomApiID

func ParseCustomApiID(input string) (*CustomApiId, error)

ParseCustomApiID parses 'input' into a CustomApiId

func ParseCustomApiIDInsensitively

func ParseCustomApiIDInsensitively(input string) (*CustomApiId, error)

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

func (*CustomApiId) FromParseResult added in v0.20231127.1171502

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

func (CustomApiId) ID

func (id CustomApiId) ID() string

ID returns the formatted Custom Api ID

func (CustomApiId) Segments

func (id CustomApiId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Custom Api ID

func (CustomApiId) String

func (id CustomApiId) String() string

String returns a human-readable description of this Custom Api ID

type CustomApiPropertiesDefinition

type CustomApiPropertiesDefinition struct {
	ApiDefinitions       *ApiResourceDefinitions         `json:"apiDefinitions,omitempty"`
	ApiType              *ApiType                        `json:"apiType,omitempty"`
	BackendService       *ApiResourceBackendService      `json:"backendService,omitempty"`
	BrandColor           *string                         `json:"brandColor,omitempty"`
	Capabilities         *[]string                       `json:"capabilities,omitempty"`
	ConnectionParameters *map[string]ConnectionParameter `json:"connectionParameters,omitempty"`
	Description          *string                         `json:"description,omitempty"`
	DisplayName          *string                         `json:"displayName,omitempty"`
	IconUri              *string                         `json:"iconUri,omitempty"`
	RuntimeUrls          *[]string                       `json:"runtimeUrls,omitempty"`
	Swagger              *interface{}                    `json:"swagger,omitempty"`
	WsdlDefinition       *WsdlDefinition                 `json:"wsdlDefinition,omitempty"`
}

type CustomApiReference

type CustomApiReference struct {
	BrandColor  *string      `json:"brandColor,omitempty"`
	Description *string      `json:"description,omitempty"`
	DisplayName *string      `json:"displayName,omitempty"`
	IconUri     *string      `json:"iconUri,omitempty"`
	Id          *string      `json:"id,omitempty"`
	Name        *string      `json:"name,omitempty"`
	Swagger     *interface{} `json:"swagger,omitempty"`
	Type        *string      `json:"type,omitempty"`
}

type DeleteOperationResponse added in v0.20230906.1160501

type DeleteOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
}

type ExtractApiDefinitionFromWsdlOperationResponse added in v0.20230906.1160501

type ExtractApiDefinitionFromWsdlOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *interface{}
}

type GetOperationResponse added in v0.20230906.1160501

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

type ListByResourceGroupOperationOptions added in v0.20230906.1160501

type ListByResourceGroupOperationOptions struct {
	Skiptoken *string
	Top       *int64
}

func DefaultListByResourceGroupOperationOptions added in v0.20230906.1160501

func DefaultListByResourceGroupOperationOptions() ListByResourceGroupOperationOptions

func (ListByResourceGroupOperationOptions) ToHeaders added in v0.20230906.1160501

func (ListByResourceGroupOperationOptions) ToOData added in v0.20230906.1160501

func (ListByResourceGroupOperationOptions) ToQuery added in v0.20230906.1160501

type ListByResourceGroupOperationResponse added in v0.20230906.1160501

type ListByResourceGroupOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *CustomApiDefinitionCollection
}

type ListOperationOptions added in v0.20230906.1160501

type ListOperationOptions struct {
	Skiptoken *string
	Top       *int64
}

func DefaultListOperationOptions added in v0.20230906.1160501

func DefaultListOperationOptions() ListOperationOptions

func (ListOperationOptions) ToHeaders added in v0.20230906.1160501

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

func (ListOperationOptions) ToOData added in v0.20230906.1160501

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

func (ListOperationOptions) ToQuery added in v0.20230906.1160501

type ListOperationResponse added in v0.20230906.1160501

type ListOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *CustomApiDefinitionCollection
}

type ListWsdlInterfacesOperationResponse added in v0.20230906.1160501

type ListWsdlInterfacesOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *WsdlServiceCollection
}

type LocationId

type LocationId struct {
	SubscriptionId string
	LocationName   string
}

LocationId is a struct representing the Resource ID for a Location

func NewLocationID

func NewLocationID(subscriptionId string, locationName string) LocationId

NewLocationID returns a new LocationId struct

func ParseLocationID

func ParseLocationID(input string) (*LocationId, error)

ParseLocationID parses 'input' into a LocationId

func ParseLocationIDInsensitively

func ParseLocationIDInsensitively(input string) (*LocationId, error)

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

func (*LocationId) FromParseResult added in v0.20231127.1171502

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

func (LocationId) ID

func (id LocationId) ID() string

ID returns the formatted Location ID

func (LocationId) Segments

func (id LocationId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Location ID

func (LocationId) String

func (id LocationId) String() string

String returns a human-readable description of this Location ID

type MoveOperationResponse added in v0.20230906.1160501

type MoveOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
}

type UpdateOperationResponse added in v0.20230906.1160501

type UpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *CustomApiDefinition
}

type WsdlDefinition

type WsdlDefinition struct {
	Content      *string           `json:"content,omitempty"`
	ImportMethod *WsdlImportMethod `json:"importMethod,omitempty"`
	Service      *WsdlService      `json:"service,omitempty"`
	Url          *string           `json:"url,omitempty"`
}

type WsdlImportMethod

type WsdlImportMethod string
const (
	WsdlImportMethodNotSpecified    WsdlImportMethod = "NotSpecified"
	WsdlImportMethodSoapPassThrough WsdlImportMethod = "SoapPassThrough"
	WsdlImportMethodSoapToRest      WsdlImportMethod = "SoapToRest"
)

func (*WsdlImportMethod) UnmarshalJSON added in v0.20230725.1205316

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

type WsdlService

type WsdlService struct {
	EndpointQualifiedNames *[]string `json:"endpointQualifiedNames,omitempty"`
	QualifiedName          string    `json:"qualifiedName"`
}

type WsdlServiceCollection

type WsdlServiceCollection struct {
	Value *[]WsdlService `json:"value,omitempty"`
}

Jump to

Keyboard shortcuts

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