domains

package
v0.20230406.1124617 Latest Latest
Warning

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

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

README

github.com/hashicorp/go-azure-sdk/resource-manager/communication/2023-03-31/domains Documentation

The domains SDK allows for interaction with the Azure Resource Manager Service communication (API Version 2023-03-31).

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/communication/2023-03-31/domains"

Client Initialization

client := domains.NewDomainsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: DomainsClient.CancelVerification

ctx := context.TODO()
id := domains.NewDomainID("12345678-1234-9876-4563-123456789012", "example-resource-group", "emailServiceValue", "domainValue")

payload := domains.VerificationParameter{
	// ...
}


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

Example Usage: DomainsClient.CreateOrUpdate

ctx := context.TODO()
id := domains.NewDomainID("12345678-1234-9876-4563-123456789012", "example-resource-group", "emailServiceValue", "domainValue")

payload := domains.DomainResource{
	// ...
}


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

Example Usage: DomainsClient.Delete

ctx := context.TODO()
id := domains.NewDomainID("12345678-1234-9876-4563-123456789012", "example-resource-group", "emailServiceValue", "domainValue")

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

Example Usage: DomainsClient.Get

ctx := context.TODO()
id := domains.NewDomainID("12345678-1234-9876-4563-123456789012", "example-resource-group", "emailServiceValue", "domainValue")

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: DomainsClient.InitiateVerification

ctx := context.TODO()
id := domains.NewDomainID("12345678-1234-9876-4563-123456789012", "example-resource-group", "emailServiceValue", "domainValue")

payload := domains.VerificationParameter{
	// ...
}


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

Example Usage: DomainsClient.ListByEmailServiceResource

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

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

Example Usage: DomainsClient.Update

ctx := context.TODO()
id := domains.NewDomainID("12345678-1234-9876-4563-123456789012", "example-resource-group", "emailServiceValue", "domainValue")

payload := domains.UpdateDomainRequestParameters{
	// ...
}


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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForDomainManagement

func PossibleValuesForDomainManagement() []string

func PossibleValuesForDomainsProvisioningState

func PossibleValuesForDomainsProvisioningState() []string

func PossibleValuesForUserEngagementTracking

func PossibleValuesForUserEngagementTracking() []string

func PossibleValuesForVerificationStatus

func PossibleValuesForVerificationStatus() []string

func PossibleValuesForVerificationType

func PossibleValuesForVerificationType() []string

func ValidateDomainID

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

ValidateDomainID checks that 'input' can be parsed as a Domain ID

func ValidateEmailServiceID

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

ValidateEmailServiceID checks that 'input' can be parsed as a Email Service ID

Types

type CancelVerificationOperationResponse

type CancelVerificationOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type DeleteOperationResponse

type DeleteOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type DnsRecord

type DnsRecord struct {
	Name  *string `json:"name,omitempty"`
	Ttl   *int64  `json:"ttl,omitempty"`
	Type  *string `json:"type,omitempty"`
	Value *string `json:"value,omitempty"`
}

type DomainId

type DomainId struct {
	SubscriptionId    string
	ResourceGroupName string
	EmailServiceName  string
	DomainName        string
}

DomainId is a struct representing the Resource ID for a Domain

func NewDomainID

func NewDomainID(subscriptionId string, resourceGroupName string, emailServiceName string, domainName string) DomainId

NewDomainID returns a new DomainId struct

func ParseDomainID

func ParseDomainID(input string) (*DomainId, error)

ParseDomainID parses 'input' into a DomainId

func ParseDomainIDInsensitively

func ParseDomainIDInsensitively(input string) (*DomainId, error)

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

func (DomainId) ID

func (id DomainId) ID() string

ID returns the formatted Domain ID

func (DomainId) Segments

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

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

func (DomainId) String

func (id DomainId) String() string

String returns a human-readable description of this Domain ID

type DomainManagement

type DomainManagement string
const (
	DomainManagementAzureManaged                    DomainManagement = "AzureManaged"
	DomainManagementCustomerManaged                 DomainManagement = "CustomerManaged"
	DomainManagementCustomerManagedInExchangeOnline DomainManagement = "CustomerManagedInExchangeOnline"
)

type DomainProperties

type DomainProperties struct {
	DataLocation           *string                              `json:"dataLocation,omitempty"`
	DomainManagement       DomainManagement                     `json:"domainManagement"`
	FromSenderDomain       *string                              `json:"fromSenderDomain,omitempty"`
	MailFromSenderDomain   *string                              `json:"mailFromSenderDomain,omitempty"`
	ProvisioningState      *DomainsProvisioningState            `json:"provisioningState,omitempty"`
	UserEngagementTracking *UserEngagementTracking              `json:"userEngagementTracking,omitempty"`
	VerificationRecords    *DomainPropertiesVerificationRecords `json:"verificationRecords,omitempty"`
	VerificationStates     *DomainPropertiesVerificationStates  `json:"verificationStates,omitempty"`
}

type DomainPropertiesVerificationRecords

type DomainPropertiesVerificationRecords struct {
	DKIM   *DnsRecord `json:"DKIM,omitempty"`
	DKIM2  *DnsRecord `json:"DKIM2,omitempty"`
	DMARC  *DnsRecord `json:"DMARC,omitempty"`
	Domain *DnsRecord `json:"Domain,omitempty"`
	SPF    *DnsRecord `json:"SPF,omitempty"`
}

type DomainPropertiesVerificationStates

type DomainPropertiesVerificationStates struct {
	DKIM   *VerificationStatusRecord `json:"DKIM,omitempty"`
	DKIM2  *VerificationStatusRecord `json:"DKIM2,omitempty"`
	DMARC  *VerificationStatusRecord `json:"DMARC,omitempty"`
	Domain *VerificationStatusRecord `json:"Domain,omitempty"`
	SPF    *VerificationStatusRecord `json:"SPF,omitempty"`
}

type DomainResource

type DomainResource struct {
	Id         *string                `json:"id,omitempty"`
	Location   string                 `json:"location"`
	Name       *string                `json:"name,omitempty"`
	Properties *DomainProperties      `json:"properties,omitempty"`
	SystemData *systemdata.SystemData `json:"systemData,omitempty"`
	Tags       *map[string]string     `json:"tags,omitempty"`
	Type       *string                `json:"type,omitempty"`
}

type DomainResourceOperationPredicate

type DomainResourceOperationPredicate struct {
	Id       *string
	Location *string
	Name     *string
	Type     *string
}

func (DomainResourceOperationPredicate) Matches

type DomainsClient

type DomainsClient struct {
	Client autorest.Client
	// contains filtered or unexported fields
}

func NewDomainsClientWithBaseURI

func NewDomainsClientWithBaseURI(endpoint string) DomainsClient

func (DomainsClient) CancelVerification

func (c DomainsClient) CancelVerification(ctx context.Context, id DomainId, input VerificationParameter) (result CancelVerificationOperationResponse, err error)

CancelVerification ...

func (DomainsClient) CancelVerificationThenPoll

func (c DomainsClient) CancelVerificationThenPoll(ctx context.Context, id DomainId, input VerificationParameter) error

CancelVerificationThenPoll performs CancelVerification then polls until it's completed

func (DomainsClient) CreateOrUpdate

func (c DomainsClient) CreateOrUpdate(ctx context.Context, id DomainId, input DomainResource) (result CreateOrUpdateOperationResponse, err error)

CreateOrUpdate ...

func (DomainsClient) CreateOrUpdateThenPoll

func (c DomainsClient) CreateOrUpdateThenPoll(ctx context.Context, id DomainId, input DomainResource) error

CreateOrUpdateThenPoll performs CreateOrUpdate then polls until it's completed

func (DomainsClient) Delete

func (c DomainsClient) Delete(ctx context.Context, id DomainId) (result DeleteOperationResponse, err error)

Delete ...

func (DomainsClient) DeleteThenPoll

func (c DomainsClient) DeleteThenPoll(ctx context.Context, id DomainId) error

DeleteThenPoll performs Delete then polls until it's completed

func (DomainsClient) Get

func (c DomainsClient) Get(ctx context.Context, id DomainId) (result GetOperationResponse, err error)

Get ...

func (DomainsClient) InitiateVerification

func (c DomainsClient) InitiateVerification(ctx context.Context, id DomainId, input VerificationParameter) (result InitiateVerificationOperationResponse, err error)

InitiateVerification ...

func (DomainsClient) InitiateVerificationThenPoll

func (c DomainsClient) InitiateVerificationThenPoll(ctx context.Context, id DomainId, input VerificationParameter) error

InitiateVerificationThenPoll performs InitiateVerification then polls until it's completed

func (DomainsClient) ListByEmailServiceResource

func (c DomainsClient) ListByEmailServiceResource(ctx context.Context, id EmailServiceId) (resp ListByEmailServiceResourceOperationResponse, err error)

ListByEmailServiceResource ...

func (DomainsClient) ListByEmailServiceResourceComplete

func (c DomainsClient) ListByEmailServiceResourceComplete(ctx context.Context, id EmailServiceId) (ListByEmailServiceResourceCompleteResult, error)

ListByEmailServiceResourceComplete retrieves all of the results into a single object

func (DomainsClient) ListByEmailServiceResourceCompleteMatchingPredicate

func (c DomainsClient) ListByEmailServiceResourceCompleteMatchingPredicate(ctx context.Context, id EmailServiceId, predicate DomainResourceOperationPredicate) (resp ListByEmailServiceResourceCompleteResult, err error)

ListByEmailServiceResourceCompleteMatchingPredicate retrieves all of the results and then applied the predicate

func (DomainsClient) Update

Update ...

func (DomainsClient) UpdateThenPoll

func (c DomainsClient) UpdateThenPoll(ctx context.Context, id DomainId, input UpdateDomainRequestParameters) error

UpdateThenPoll performs Update then polls until it's completed

type DomainsProvisioningState

type DomainsProvisioningState string
const (
	DomainsProvisioningStateCanceled  DomainsProvisioningState = "Canceled"
	DomainsProvisioningStateCreating  DomainsProvisioningState = "Creating"
	DomainsProvisioningStateDeleting  DomainsProvisioningState = "Deleting"
	DomainsProvisioningStateFailed    DomainsProvisioningState = "Failed"
	DomainsProvisioningStateMoving    DomainsProvisioningState = "Moving"
	DomainsProvisioningStateRunning   DomainsProvisioningState = "Running"
	DomainsProvisioningStateSucceeded DomainsProvisioningState = "Succeeded"
	DomainsProvisioningStateUnknown   DomainsProvisioningState = "Unknown"
	DomainsProvisioningStateUpdating  DomainsProvisioningState = "Updating"
)

type EmailServiceId

type EmailServiceId struct {
	SubscriptionId    string
	ResourceGroupName string
	EmailServiceName  string
}

EmailServiceId is a struct representing the Resource ID for a Email Service

func NewEmailServiceID

func NewEmailServiceID(subscriptionId string, resourceGroupName string, emailServiceName string) EmailServiceId

NewEmailServiceID returns a new EmailServiceId struct

func ParseEmailServiceID

func ParseEmailServiceID(input string) (*EmailServiceId, error)

ParseEmailServiceID parses 'input' into a EmailServiceId

func ParseEmailServiceIDInsensitively

func ParseEmailServiceIDInsensitively(input string) (*EmailServiceId, error)

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

func (EmailServiceId) ID

func (id EmailServiceId) ID() string

ID returns the formatted Email Service ID

func (EmailServiceId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Email Service ID

func (EmailServiceId) String

func (id EmailServiceId) String() string

String returns a human-readable description of this Email Service ID

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	Model        *DomainResource
}

type InitiateVerificationOperationResponse

type InitiateVerificationOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type ListByEmailServiceResourceCompleteResult

type ListByEmailServiceResourceCompleteResult struct {
	Items []DomainResource
}

type ListByEmailServiceResourceOperationResponse

type ListByEmailServiceResourceOperationResponse struct {
	HttpResponse *http.Response
	Model        *[]DomainResource
	// contains filtered or unexported fields
}

func (ListByEmailServiceResourceOperationResponse) HasMore

func (ListByEmailServiceResourceOperationResponse) LoadMore

type UpdateDomainProperties

type UpdateDomainProperties struct {
	UserEngagementTracking *UserEngagementTracking `json:"userEngagementTracking,omitempty"`
}

type UpdateDomainRequestParameters

type UpdateDomainRequestParameters struct {
	Properties *UpdateDomainProperties `json:"properties,omitempty"`
	Tags       *map[string]string      `json:"tags,omitempty"`
}

type UpdateOperationResponse

type UpdateOperationResponse struct {
	Poller       polling.LongRunningPoller
	HttpResponse *http.Response
}

type UserEngagementTracking

type UserEngagementTracking string
const (
	UserEngagementTrackingDisabled UserEngagementTracking = "Disabled"
	UserEngagementTrackingEnabled  UserEngagementTracking = "Enabled"
)

type VerificationParameter

type VerificationParameter struct {
	VerificationType VerificationType `json:"verificationType"`
}

type VerificationStatus

type VerificationStatus string
const (
	VerificationStatusCancellationRequested  VerificationStatus = "CancellationRequested"
	VerificationStatusNotStarted             VerificationStatus = "NotStarted"
	VerificationStatusVerificationFailed     VerificationStatus = "VerificationFailed"
	VerificationStatusVerificationInProgress VerificationStatus = "VerificationInProgress"
	VerificationStatusVerificationRequested  VerificationStatus = "VerificationRequested"
	VerificationStatusVerified               VerificationStatus = "Verified"
)

type VerificationStatusRecord

type VerificationStatusRecord struct {
	ErrorCode *string             `json:"errorCode,omitempty"`
	Status    *VerificationStatus `json:"status,omitempty"`
}

type VerificationType

type VerificationType string
const (
	VerificationTypeDKIM    VerificationType = "DKIM"
	VerificationTypeDKIMTwo VerificationType = "DKIM2"
	VerificationTypeDMARC   VerificationType = "DMARC"
	VerificationTypeDomain  VerificationType = "Domain"
	VerificationTypeSPF     VerificationType = "SPF"
)

Jump to

Keyboard shortcuts

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