emailregistration

package
v0.20241128.1084944 Latest Latest
Warning

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

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

README

github.com/hashicorp/go-azure-sdk/resource-manager/datashare/2021-08-01/emailregistration Documentation

The emailregistration SDK allows for interaction with Azure Resource Manager datashare (API Version 2021-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/datashare/2021-08-01/emailregistration"

Client Initialization

client := emailregistration.NewEmailRegistrationClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: EmailRegistrationClient.ActivateEmail

ctx := context.TODO()
id := emailregistration.NewLocationID("locationName")

payload := emailregistration.EmailRegistration{
	// ...
}


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

Example Usage: EmailRegistrationClient.RegisterEmail

ctx := context.TODO()
id := emailregistration.NewLocationID("locationName")

read, err := client.RegisterEmail(ctx, id)
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 PossibleValuesForRegistrationStatus

func PossibleValuesForRegistrationStatus() []string

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 ActivateEmailOperationResponse

type ActivateEmailOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *EmailRegistration
}

type EmailRegistration

type EmailRegistration struct {
	ActivationCode           *string             `json:"activationCode,omitempty"`
	ActivationExpirationDate *string             `json:"activationExpirationDate,omitempty"`
	Email                    *string             `json:"email,omitempty"`
	RegistrationStatus       *RegistrationStatus `json:"registrationStatus,omitempty"`
	TenantId                 *string             `json:"tenantId,omitempty"`
}

func (*EmailRegistration) GetActivationExpirationDateAsTime

func (o *EmailRegistration) GetActivationExpirationDateAsTime() (*time.Time, error)

func (*EmailRegistration) SetActivationExpirationDateAsTime

func (o *EmailRegistration) SetActivationExpirationDateAsTime(input time.Time)

type EmailRegistrationClient

type EmailRegistrationClient struct {
	Client *resourcemanager.Client
}

func NewEmailRegistrationClientWithBaseURI

func NewEmailRegistrationClientWithBaseURI(sdkApi sdkEnv.Api) (*EmailRegistrationClient, error)

func (EmailRegistrationClient) ActivateEmail

ActivateEmail ...

func (EmailRegistrationClient) RegisterEmail

RegisterEmail ...

type LocationId

type LocationId struct {
	LocationName string
}

LocationId is a struct representing the Resource ID for a Location

func NewLocationID

func NewLocationID(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

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 RegisterEmailOperationResponse

type RegisterEmailOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *EmailRegistration
}

type RegistrationStatus

type RegistrationStatus string
const (
	RegistrationStatusActivated                   RegistrationStatus = "Activated"
	RegistrationStatusActivationAttemptsExhausted RegistrationStatus = "ActivationAttemptsExhausted"
	RegistrationStatusActivationPending           RegistrationStatus = "ActivationPending"
)

func (*RegistrationStatus) UnmarshalJSON

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

Jump to

Keyboard shortcuts

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