domain

package
v0.6.0 Latest Latest
Warning

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

Go to latest
Published: May 7, 2024 License: Apache-2.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DomainStateTypeChoices added in v0.3.0

func DomainStateTypeChoices() []string

func OrganizationDomainAddStateTypeChoices added in v0.3.0

func OrganizationDomainAddStateTypeChoices() []string

func OrganizationDomainStateTypeChoices added in v0.3.0

func OrganizationDomainStateTypeChoices() []string

func VerificationTypeChoices

func VerificationTypeChoices() []string

Types

type DomainHandler

type DomainHandler struct {
	// contains filtered or unexported fields
}

func NewHandler

func NewHandler(doer doer) DomainHandler

func (*DomainHandler) OrganizationDomainAdd

func (h *DomainHandler) OrganizationDomainAdd(ctx context.Context, organizationId string, in *OrganizationDomainAddIn) (*OrganizationDomainAddOut, error)

func (*DomainHandler) OrganizationDomainUpdate

func (h *DomainHandler) OrganizationDomainUpdate(ctx context.Context, organizationId string, domainId string, in *OrganizationDomainUpdateIn) (*OrganizationDomainUpdateOut, error)

func (*DomainHandler) OrganizationDomainVerify

func (h *DomainHandler) OrganizationDomainVerify(ctx context.Context, organizationId string, domainId string) (*OrganizationDomainVerifyOut, error)

func (*DomainHandler) OrganizationDomainsList

func (h *DomainHandler) OrganizationDomainsList(ctx context.Context, organizationId string) ([]DomainOut, error)

func (*DomainHandler) OrganizationDomainsRemove

func (h *DomainHandler) OrganizationDomainsRemove(ctx context.Context, organizationId string, domainId string) error

type DomainOut

type DomainOut struct {
	ChallengeToken                string           `json:"challenge_token"`
	CreateTime                    time.Time        `json:"create_time"`
	DomainId                      string           `json:"domain_id"`
	DomainName                    string           `json:"domain_name"`
	LinkedAuthenticationMethodIds []string         `json:"linked_authentication_method_ids"`
	OrganizationId                string           `json:"organization_id"`
	State                         DomainStateType  `json:"state"`
	VerificationType              VerificationType `json:"verification_type"`
}

type DomainStateType added in v0.3.0

type DomainStateType string
const (
	DomainStateTypeDeleted    DomainStateType = "deleted"
	DomainStateTypeUnverified DomainStateType = "unverified"
	DomainStateTypeVerified   DomainStateType = "verified"
)

type Handler

type Handler interface {
	// OrganizationDomainAdd create a domain
	// POST /v1/organization/{organization_id}/domains
	// https://api.aiven.io/doc/#tag/Domains/operation/OrganizationDomainAdd
	OrganizationDomainAdd(ctx context.Context, organizationId string, in *OrganizationDomainAddIn) (*OrganizationDomainAddOut, error)

	// OrganizationDomainUpdate update a domain
	// PATCH /v1/organization/{organization_id}/domains/{domain_id}
	// https://api.aiven.io/doc/#tag/Domains/operation/OrganizationDomainUpdate
	OrganizationDomainUpdate(ctx context.Context, organizationId string, domainId string, in *OrganizationDomainUpdateIn) (*OrganizationDomainUpdateOut, error)

	// OrganizationDomainVerify verify a domain
	// POST /v1/organization/{organization_id}/domains/{domain_id}/verify
	// https://api.aiven.io/doc/#tag/Domains/operation/OrganizationDomainVerify
	OrganizationDomainVerify(ctx context.Context, organizationId string, domainId string) (*OrganizationDomainVerifyOut, error)

	// OrganizationDomainsList list domains
	// GET /v1/organization/{organization_id}/domains
	// https://api.aiven.io/doc/#tag/Domains/operation/OrganizationDomainsList
	OrganizationDomainsList(ctx context.Context, organizationId string) ([]DomainOut, error)

	// OrganizationDomainsRemove delete a domain
	// DELETE /v1/organization/{organization_id}/domains/{domain_id}
	// https://api.aiven.io/doc/#tag/Domains/operation/OrganizationDomainsRemove
	OrganizationDomainsRemove(ctx context.Context, organizationId string, domainId string) error
}

type OrganizationDomainAddIn

type OrganizationDomainAddIn struct {
	DomainName       string           `json:"domain_name"`
	VerificationType VerificationType `json:"verification_type"`
}

type OrganizationDomainAddOut

type OrganizationDomainAddOut struct {
	ChallengeToken                string                         `json:"challenge_token"`
	CreateTime                    time.Time                      `json:"create_time"`
	DomainId                      string                         `json:"domain_id"`
	DomainName                    string                         `json:"domain_name"`
	LinkedAuthenticationMethodIds []string                       `json:"linked_authentication_method_ids"`
	OrganizationId                string                         `json:"organization_id"`
	State                         OrganizationDomainAddStateType `json:"state"`
	VerificationType              VerificationType               `json:"verification_type"`
}

type OrganizationDomainAddStateType added in v0.3.0

type OrganizationDomainAddStateType string
const (
	OrganizationDomainAddStateTypeDeleted    OrganizationDomainAddStateType = "deleted"
	OrganizationDomainAddStateTypeUnverified OrganizationDomainAddStateType = "unverified"
	OrganizationDomainAddStateTypeVerified   OrganizationDomainAddStateType = "verified"
)

type OrganizationDomainStateType added in v0.3.0

type OrganizationDomainStateType string
const (
	OrganizationDomainStateTypeDeleted    OrganizationDomainStateType = "deleted"
	OrganizationDomainStateTypeUnverified OrganizationDomainStateType = "unverified"
	OrganizationDomainStateTypeVerified   OrganizationDomainStateType = "verified"
)

type OrganizationDomainUpdateIn

type OrganizationDomainUpdateIn struct {
	VerificationType VerificationType `json:"verification_type,omitempty"`
}

type OrganizationDomainUpdateOut

type OrganizationDomainUpdateOut struct {
	ChallengeToken                string                      `json:"challenge_token"`
	CreateTime                    time.Time                   `json:"create_time"`
	DomainId                      string                      `json:"domain_id"`
	DomainName                    string                      `json:"domain_name"`
	LinkedAuthenticationMethodIds []string                    `json:"linked_authentication_method_ids"`
	OrganizationId                string                      `json:"organization_id"`
	State                         OrganizationDomainStateType `json:"state"`
	VerificationType              VerificationType            `json:"verification_type"`
}

type OrganizationDomainVerifyOut

type OrganizationDomainVerifyOut struct {
	ChallengeToken                string                      `json:"challenge_token"`
	CreateTime                    time.Time                   `json:"create_time"`
	DomainId                      string                      `json:"domain_id"`
	DomainName                    string                      `json:"domain_name"`
	LinkedAuthenticationMethodIds []string                    `json:"linked_authentication_method_ids"`
	OrganizationId                string                      `json:"organization_id"`
	State                         OrganizationDomainStateType `json:"state"`
	VerificationType              VerificationType            `json:"verification_type"`
}

type VerificationType

type VerificationType string
const (
	VerificationTypeDns  VerificationType = "dns"
	VerificationTypeHttp VerificationType = "http"
)

Jump to

Keyboard shortcuts

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