addressing

package
v2.0.0-beta.5 Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AddressMapAccountDeleteParams

type AddressMapAccountDeleteParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type AddressMapAccountDeleteResponse added in v2.1.0

type AddressMapAccountDeleteResponse interface {
	ImplementsAddressingAddressMapAccountDeleteResponse()
}

Union satisfied by addressing.AddressMapAccountDeleteResponseUnknown, addressing.AddressMapAccountDeleteResponseArray or shared.UnionString.

type AddressMapAccountDeleteResponseArray

type AddressMapAccountDeleteResponseArray []interface{}

func (AddressMapAccountDeleteResponseArray) ImplementsAddressingAddressMapAccountDeleteResponse

func (r AddressMapAccountDeleteResponseArray) ImplementsAddressingAddressMapAccountDeleteResponse()

type AddressMapAccountDeleteResponseEnvelope

type AddressMapAccountDeleteResponseEnvelope struct {
	Errors   []AddressMapAccountDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapAccountDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressMapAccountDeleteResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    AddressMapAccountDeleteResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo AddressMapAccountDeleteResponseEnvelopeResultInfo `json:"result_info"`
	JSON       addressMapAccountDeleteResponseEnvelopeJSON       `json:"-"`
}

func (*AddressMapAccountDeleteResponseEnvelope) UnmarshalJSON

func (r *AddressMapAccountDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapAccountDeleteResponseEnvelopeErrors

type AddressMapAccountDeleteResponseEnvelopeErrors struct {
	Code    int64                                             `json:"code,required"`
	Message string                                            `json:"message,required"`
	JSON    addressMapAccountDeleteResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapAccountDeleteResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapAccountDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapAccountDeleteResponseEnvelopeMessages

type AddressMapAccountDeleteResponseEnvelopeMessages struct {
	Code    int64                                               `json:"code,required"`
	Message string                                              `json:"message,required"`
	JSON    addressMapAccountDeleteResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapAccountDeleteResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapAccountDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapAccountDeleteResponseEnvelopeResultInfo

type AddressMapAccountDeleteResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                               `json:"total_count"`
	JSON       addressMapAccountDeleteResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*AddressMapAccountDeleteResponseEnvelopeResultInfo) UnmarshalJSON

func (r *AddressMapAccountDeleteResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type AddressMapAccountDeleteResponseEnvelopeSuccess

type AddressMapAccountDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapAccountDeleteResponseEnvelopeSuccessTrue AddressMapAccountDeleteResponseEnvelopeSuccess = true
)

type AddressMapAccountService

type AddressMapAccountService struct {
	Options []option.RequestOption
}

AddressMapAccountService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAddressMapAccountService method instead.

func NewAddressMapAccountService

func NewAddressMapAccountService(opts ...option.RequestOption) (r *AddressMapAccountService)

NewAddressMapAccountService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*AddressMapAccountService) Delete

Remove an account as a member of a particular address map.

func (*AddressMapAccountService) Update

Add an account as a member of a particular address map.

type AddressMapAccountUpdateParams

type AddressMapAccountUpdateParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type AddressMapAccountUpdateResponse added in v2.1.0

type AddressMapAccountUpdateResponse interface {
	ImplementsAddressingAddressMapAccountUpdateResponse()
}

Union satisfied by addressing.AddressMapAccountUpdateResponseUnknown, addressing.AddressMapAccountUpdateResponseArray or shared.UnionString.

type AddressMapAccountUpdateResponseArray

type AddressMapAccountUpdateResponseArray []interface{}

func (AddressMapAccountUpdateResponseArray) ImplementsAddressingAddressMapAccountUpdateResponse

func (r AddressMapAccountUpdateResponseArray) ImplementsAddressingAddressMapAccountUpdateResponse()

type AddressMapAccountUpdateResponseEnvelope

type AddressMapAccountUpdateResponseEnvelope struct {
	Errors   []AddressMapAccountUpdateResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapAccountUpdateResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressMapAccountUpdateResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    AddressMapAccountUpdateResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo AddressMapAccountUpdateResponseEnvelopeResultInfo `json:"result_info"`
	JSON       addressMapAccountUpdateResponseEnvelopeJSON       `json:"-"`
}

func (*AddressMapAccountUpdateResponseEnvelope) UnmarshalJSON

func (r *AddressMapAccountUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapAccountUpdateResponseEnvelopeErrors

type AddressMapAccountUpdateResponseEnvelopeErrors struct {
	Code    int64                                             `json:"code,required"`
	Message string                                            `json:"message,required"`
	JSON    addressMapAccountUpdateResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapAccountUpdateResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapAccountUpdateResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapAccountUpdateResponseEnvelopeMessages

type AddressMapAccountUpdateResponseEnvelopeMessages struct {
	Code    int64                                               `json:"code,required"`
	Message string                                              `json:"message,required"`
	JSON    addressMapAccountUpdateResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapAccountUpdateResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapAccountUpdateResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapAccountUpdateResponseEnvelopeResultInfo

type AddressMapAccountUpdateResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                               `json:"total_count"`
	JSON       addressMapAccountUpdateResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*AddressMapAccountUpdateResponseEnvelopeResultInfo) UnmarshalJSON

func (r *AddressMapAccountUpdateResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type AddressMapAccountUpdateResponseEnvelopeSuccess

type AddressMapAccountUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapAccountUpdateResponseEnvelopeSuccessTrue AddressMapAccountUpdateResponseEnvelopeSuccess = true
)

type AddressMapDeleteParams

type AddressMapDeleteParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type AddressMapDeleteResponse added in v2.1.0

type AddressMapDeleteResponse interface {
	ImplementsAddressingAddressMapDeleteResponse()
}

Union satisfied by addressing.AddressMapDeleteResponseUnknown, addressing.AddressMapDeleteResponseArray or shared.UnionString.

type AddressMapDeleteResponseArray

type AddressMapDeleteResponseArray []interface{}

func (AddressMapDeleteResponseArray) ImplementsAddressingAddressMapDeleteResponse

func (r AddressMapDeleteResponseArray) ImplementsAddressingAddressMapDeleteResponse()

type AddressMapDeleteResponseEnvelope

type AddressMapDeleteResponseEnvelope struct {
	Errors   []AddressMapDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressMapDeleteResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    AddressMapDeleteResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo AddressMapDeleteResponseEnvelopeResultInfo `json:"result_info"`
	JSON       addressMapDeleteResponseEnvelopeJSON       `json:"-"`
}

func (*AddressMapDeleteResponseEnvelope) UnmarshalJSON

func (r *AddressMapDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapDeleteResponseEnvelopeErrors

type AddressMapDeleteResponseEnvelopeErrors struct {
	Code    int64                                      `json:"code,required"`
	Message string                                     `json:"message,required"`
	JSON    addressMapDeleteResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapDeleteResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapDeleteResponseEnvelopeMessages

type AddressMapDeleteResponseEnvelopeMessages struct {
	Code    int64                                        `json:"code,required"`
	Message string                                       `json:"message,required"`
	JSON    addressMapDeleteResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapDeleteResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapDeleteResponseEnvelopeResultInfo

type AddressMapDeleteResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                        `json:"total_count"`
	JSON       addressMapDeleteResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*AddressMapDeleteResponseEnvelopeResultInfo) UnmarshalJSON

func (r *AddressMapDeleteResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type AddressMapDeleteResponseEnvelopeSuccess

type AddressMapDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapDeleteResponseEnvelopeSuccessTrue AddressMapDeleteResponseEnvelopeSuccess = true
)

type AddressMapEditParams

type AddressMapEditParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// If you have legacy TLS clients which do not send the TLS server name indicator,
	// then you can specify one default SNI on the map. If Cloudflare receives a TLS
	// handshake from a client without an SNI, it will respond with the default SNI on
	// those IPs. The default SNI can be any valid zone or subdomain owned by the
	// account.
	DefaultSni param.Field[string] `json:"default_sni"`
	// An optional description field which may be used to describe the types of IPs or
	// zones on the map.
	Description param.Field[string] `json:"description"`
	// Whether the Address Map is enabled or not. Cloudflare's DNS will not respond
	// with IP addresses on an Address Map until the map is enabled.
	Enabled param.Field[bool] `json:"enabled"`
}

func (AddressMapEditParams) MarshalJSON

func (r AddressMapEditParams) MarshalJSON() (data []byte, err error)

type AddressMapEditResponseEnvelope

type AddressMapEditResponseEnvelope struct {
	Errors   []AddressMapEditResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapEditResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressingAddressMaps                    `json:"result,required"`
	// Whether the API call was successful
	Success AddressMapEditResponseEnvelopeSuccess `json:"success,required"`
	JSON    addressMapEditResponseEnvelopeJSON    `json:"-"`
}

func (*AddressMapEditResponseEnvelope) UnmarshalJSON

func (r *AddressMapEditResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapEditResponseEnvelopeErrors

type AddressMapEditResponseEnvelopeErrors struct {
	Code    int64                                    `json:"code,required"`
	Message string                                   `json:"message,required"`
	JSON    addressMapEditResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapEditResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapEditResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapEditResponseEnvelopeMessages

type AddressMapEditResponseEnvelopeMessages struct {
	Code    int64                                      `json:"code,required"`
	Message string                                     `json:"message,required"`
	JSON    addressMapEditResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapEditResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapEditResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapEditResponseEnvelopeSuccess

type AddressMapEditResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapEditResponseEnvelopeSuccessTrue AddressMapEditResponseEnvelopeSuccess = true
)

type AddressMapGetParams

type AddressMapGetParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type AddressMapGetResponse

type AddressMapGetResponse struct {
	// Identifier
	ID string `json:"id"`
	// If set to false, then the Address Map cannot be deleted via API. This is true
	// for Cloudflare-managed maps.
	CanDelete bool `json:"can_delete"`
	// If set to false, then the IPs on the Address Map cannot be modified via the API.
	// This is true for Cloudflare-managed maps.
	CanModifyIPs bool      `json:"can_modify_ips"`
	CreatedAt    time.Time `json:"created_at" format:"date-time"`
	// If you have legacy TLS clients which do not send the TLS server name indicator,
	// then you can specify one default SNI on the map. If Cloudflare receives a TLS
	// handshake from a client without an SNI, it will respond with the default SNI on
	// those IPs. The default SNI can be any valid zone or subdomain owned by the
	// account.
	DefaultSni string `json:"default_sni,nullable"`
	// An optional description field which may be used to describe the types of IPs or
	// zones on the map.
	Description string `json:"description,nullable"`
	// Whether the Address Map is enabled or not. Cloudflare's DNS will not respond
	// with IP addresses on an Address Map until the map is enabled.
	Enabled bool `json:"enabled,nullable"`
	// The set of IPs on the Address Map.
	IPs []AddressMapGetResponseIP `json:"ips"`
	// Zones and Accounts which will be assigned IPs on this Address Map. A zone
	// membership will take priority over an account membership.
	Memberships []AddressMapGetResponseMembership `json:"memberships"`
	ModifiedAt  time.Time                         `json:"modified_at" format:"date-time"`
	JSON        addressMapGetResponseJSON         `json:"-"`
}

func (*AddressMapGetResponse) UnmarshalJSON

func (r *AddressMapGetResponse) UnmarshalJSON(data []byte) (err error)

type AddressMapGetResponseEnvelope

type AddressMapGetResponseEnvelope struct {
	Errors   []AddressMapGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapGetResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressMapGetResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success AddressMapGetResponseEnvelopeSuccess `json:"success,required"`
	JSON    addressMapGetResponseEnvelopeJSON    `json:"-"`
}

func (*AddressMapGetResponseEnvelope) UnmarshalJSON

func (r *AddressMapGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapGetResponseEnvelopeErrors

type AddressMapGetResponseEnvelopeErrors struct {
	Code    int64                                   `json:"code,required"`
	Message string                                  `json:"message,required"`
	JSON    addressMapGetResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapGetResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapGetResponseEnvelopeMessages

type AddressMapGetResponseEnvelopeMessages struct {
	Code    int64                                     `json:"code,required"`
	Message string                                    `json:"message,required"`
	JSON    addressMapGetResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapGetResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapGetResponseEnvelopeSuccess

type AddressMapGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapGetResponseEnvelopeSuccessTrue AddressMapGetResponseEnvelopeSuccess = true
)

type AddressMapGetResponseIP

type AddressMapGetResponseIP struct {
	CreatedAt time.Time `json:"created_at" format:"date-time"`
	// An IPv4 or IPv6 address.
	IP   string                      `json:"ip"`
	JSON addressMapGetResponseIPJSON `json:"-"`
}

func (*AddressMapGetResponseIP) UnmarshalJSON

func (r *AddressMapGetResponseIP) UnmarshalJSON(data []byte) (err error)

type AddressMapGetResponseMembership

type AddressMapGetResponseMembership struct {
	// Controls whether the membership can be deleted via the API or not.
	CanDelete bool      `json:"can_delete"`
	CreatedAt time.Time `json:"created_at" format:"date-time"`
	// Identifier
	Identifier string `json:"identifier"`
	// The type of the membership.
	Kind AddressMapGetResponseMembershipsKind `json:"kind"`
	JSON addressMapGetResponseMembershipJSON  `json:"-"`
}

func (*AddressMapGetResponseMembership) UnmarshalJSON

func (r *AddressMapGetResponseMembership) UnmarshalJSON(data []byte) (err error)

type AddressMapGetResponseMembershipsKind

type AddressMapGetResponseMembershipsKind string

The type of the membership.

const (
	AddressMapGetResponseMembershipsKindZone    AddressMapGetResponseMembershipsKind = "zone"
	AddressMapGetResponseMembershipsKindAccount AddressMapGetResponseMembershipsKind = "account"
)

type AddressMapIPDeleteParams

type AddressMapIPDeleteParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type AddressMapIPDeleteResponse added in v2.1.0

type AddressMapIPDeleteResponse interface {
	ImplementsAddressingAddressMapIPDeleteResponse()
}

Union satisfied by addressing.AddressMapIPDeleteResponseUnknown, addressing.AddressMapIPDeleteResponseArray or shared.UnionString.

type AddressMapIPDeleteResponseArray

type AddressMapIPDeleteResponseArray []interface{}

func (AddressMapIPDeleteResponseArray) ImplementsAddressingAddressMapIPDeleteResponse

func (r AddressMapIPDeleteResponseArray) ImplementsAddressingAddressMapIPDeleteResponse()

type AddressMapIPDeleteResponseEnvelope

type AddressMapIPDeleteResponseEnvelope struct {
	Errors   []AddressMapIPDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapIPDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressMapIPDeleteResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    AddressMapIPDeleteResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo AddressMapIPDeleteResponseEnvelopeResultInfo `json:"result_info"`
	JSON       addressMapIPDeleteResponseEnvelopeJSON       `json:"-"`
}

func (*AddressMapIPDeleteResponseEnvelope) UnmarshalJSON

func (r *AddressMapIPDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapIPDeleteResponseEnvelopeErrors

type AddressMapIPDeleteResponseEnvelopeErrors struct {
	Code    int64                                        `json:"code,required"`
	Message string                                       `json:"message,required"`
	JSON    addressMapIPDeleteResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapIPDeleteResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapIPDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapIPDeleteResponseEnvelopeMessages

type AddressMapIPDeleteResponseEnvelopeMessages struct {
	Code    int64                                          `json:"code,required"`
	Message string                                         `json:"message,required"`
	JSON    addressMapIPDeleteResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapIPDeleteResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapIPDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapIPDeleteResponseEnvelopeResultInfo

type AddressMapIPDeleteResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                          `json:"total_count"`
	JSON       addressMapIPDeleteResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*AddressMapIPDeleteResponseEnvelopeResultInfo) UnmarshalJSON

func (r *AddressMapIPDeleteResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type AddressMapIPDeleteResponseEnvelopeSuccess

type AddressMapIPDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapIPDeleteResponseEnvelopeSuccessTrue AddressMapIPDeleteResponseEnvelopeSuccess = true
)

type AddressMapIPService

type AddressMapIPService struct {
	Options []option.RequestOption
}

AddressMapIPService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAddressMapIPService method instead.

func NewAddressMapIPService

func NewAddressMapIPService(opts ...option.RequestOption) (r *AddressMapIPService)

NewAddressMapIPService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*AddressMapIPService) Delete

func (r *AddressMapIPService) Delete(ctx context.Context, addressMapID string, ipAddress string, body AddressMapIPDeleteParams, opts ...option.RequestOption) (res *AddressMapIPDeleteResponse, err error)

Remove an IP from a particular address map.

func (*AddressMapIPService) Update

func (r *AddressMapIPService) Update(ctx context.Context, addressMapID string, ipAddress string, body AddressMapIPUpdateParams, opts ...option.RequestOption) (res *AddressMapIPUpdateResponse, err error)

Add an IP from a prefix owned by the account to a particular address map.

type AddressMapIPUpdateParams

type AddressMapIPUpdateParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type AddressMapIPUpdateResponse added in v2.1.0

type AddressMapIPUpdateResponse interface {
	ImplementsAddressingAddressMapIPUpdateResponse()
}

Union satisfied by addressing.AddressMapIPUpdateResponseUnknown, addressing.AddressMapIPUpdateResponseArray or shared.UnionString.

type AddressMapIPUpdateResponseArray

type AddressMapIPUpdateResponseArray []interface{}

func (AddressMapIPUpdateResponseArray) ImplementsAddressingAddressMapIPUpdateResponse

func (r AddressMapIPUpdateResponseArray) ImplementsAddressingAddressMapIPUpdateResponse()

type AddressMapIPUpdateResponseEnvelope

type AddressMapIPUpdateResponseEnvelope struct {
	Errors   []AddressMapIPUpdateResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapIPUpdateResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressMapIPUpdateResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    AddressMapIPUpdateResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo AddressMapIPUpdateResponseEnvelopeResultInfo `json:"result_info"`
	JSON       addressMapIPUpdateResponseEnvelopeJSON       `json:"-"`
}

func (*AddressMapIPUpdateResponseEnvelope) UnmarshalJSON

func (r *AddressMapIPUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapIPUpdateResponseEnvelopeErrors

type AddressMapIPUpdateResponseEnvelopeErrors struct {
	Code    int64                                        `json:"code,required"`
	Message string                                       `json:"message,required"`
	JSON    addressMapIPUpdateResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapIPUpdateResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapIPUpdateResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapIPUpdateResponseEnvelopeMessages

type AddressMapIPUpdateResponseEnvelopeMessages struct {
	Code    int64                                          `json:"code,required"`
	Message string                                         `json:"message,required"`
	JSON    addressMapIPUpdateResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapIPUpdateResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapIPUpdateResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapIPUpdateResponseEnvelopeResultInfo

type AddressMapIPUpdateResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                          `json:"total_count"`
	JSON       addressMapIPUpdateResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*AddressMapIPUpdateResponseEnvelopeResultInfo) UnmarshalJSON

func (r *AddressMapIPUpdateResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type AddressMapIPUpdateResponseEnvelopeSuccess

type AddressMapIPUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapIPUpdateResponseEnvelopeSuccessTrue AddressMapIPUpdateResponseEnvelopeSuccess = true
)

type AddressMapListParams

type AddressMapListParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type AddressMapListResponseEnvelope

type AddressMapListResponseEnvelope struct {
	Errors   []AddressMapListResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapListResponseEnvelopeMessages `json:"messages,required"`
	Result   []AddressingAddressMaps                  `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    AddressMapListResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo AddressMapListResponseEnvelopeResultInfo `json:"result_info"`
	JSON       addressMapListResponseEnvelopeJSON       `json:"-"`
}

func (*AddressMapListResponseEnvelope) UnmarshalJSON

func (r *AddressMapListResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapListResponseEnvelopeErrors

type AddressMapListResponseEnvelopeErrors struct {
	Code    int64                                    `json:"code,required"`
	Message string                                   `json:"message,required"`
	JSON    addressMapListResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapListResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapListResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapListResponseEnvelopeMessages

type AddressMapListResponseEnvelopeMessages struct {
	Code    int64                                      `json:"code,required"`
	Message string                                     `json:"message,required"`
	JSON    addressMapListResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapListResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapListResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapListResponseEnvelopeResultInfo

type AddressMapListResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                      `json:"total_count"`
	JSON       addressMapListResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*AddressMapListResponseEnvelopeResultInfo) UnmarshalJSON

func (r *AddressMapListResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type AddressMapListResponseEnvelopeSuccess

type AddressMapListResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapListResponseEnvelopeSuccessTrue AddressMapListResponseEnvelopeSuccess = true
)

type AddressMapNewParams

type AddressMapNewParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// An optional description field which may be used to describe the types of IPs or
	// zones on the map.
	Description param.Field[string] `json:"description"`
	// Whether the Address Map is enabled or not. Cloudflare's DNS will not respond
	// with IP addresses on an Address Map until the map is enabled.
	Enabled param.Field[bool] `json:"enabled"`
}

func (AddressMapNewParams) MarshalJSON

func (r AddressMapNewParams) MarshalJSON() (data []byte, err error)

type AddressMapNewResponse

type AddressMapNewResponse struct {
	// Identifier
	ID string `json:"id"`
	// If set to false, then the Address Map cannot be deleted via API. This is true
	// for Cloudflare-managed maps.
	CanDelete bool `json:"can_delete"`
	// If set to false, then the IPs on the Address Map cannot be modified via the API.
	// This is true for Cloudflare-managed maps.
	CanModifyIPs bool      `json:"can_modify_ips"`
	CreatedAt    time.Time `json:"created_at" format:"date-time"`
	// If you have legacy TLS clients which do not send the TLS server name indicator,
	// then you can specify one default SNI on the map. If Cloudflare receives a TLS
	// handshake from a client without an SNI, it will respond with the default SNI on
	// those IPs. The default SNI can be any valid zone or subdomain owned by the
	// account.
	DefaultSni string `json:"default_sni,nullable"`
	// An optional description field which may be used to describe the types of IPs or
	// zones on the map.
	Description string `json:"description,nullable"`
	// Whether the Address Map is enabled or not. Cloudflare's DNS will not respond
	// with IP addresses on an Address Map until the map is enabled.
	Enabled bool `json:"enabled,nullable"`
	// The set of IPs on the Address Map.
	IPs []AddressMapNewResponseIP `json:"ips"`
	// Zones and Accounts which will be assigned IPs on this Address Map. A zone
	// membership will take priority over an account membership.
	Memberships []AddressMapNewResponseMembership `json:"memberships"`
	ModifiedAt  time.Time                         `json:"modified_at" format:"date-time"`
	JSON        addressMapNewResponseJSON         `json:"-"`
}

func (*AddressMapNewResponse) UnmarshalJSON

func (r *AddressMapNewResponse) UnmarshalJSON(data []byte) (err error)

type AddressMapNewResponseEnvelope

type AddressMapNewResponseEnvelope struct {
	Errors   []AddressMapNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapNewResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressMapNewResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success AddressMapNewResponseEnvelopeSuccess `json:"success,required"`
	JSON    addressMapNewResponseEnvelopeJSON    `json:"-"`
}

func (*AddressMapNewResponseEnvelope) UnmarshalJSON

func (r *AddressMapNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapNewResponseEnvelopeErrors

type AddressMapNewResponseEnvelopeErrors struct {
	Code    int64                                   `json:"code,required"`
	Message string                                  `json:"message,required"`
	JSON    addressMapNewResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapNewResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapNewResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapNewResponseEnvelopeMessages

type AddressMapNewResponseEnvelopeMessages struct {
	Code    int64                                     `json:"code,required"`
	Message string                                    `json:"message,required"`
	JSON    addressMapNewResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapNewResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapNewResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapNewResponseEnvelopeSuccess

type AddressMapNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapNewResponseEnvelopeSuccessTrue AddressMapNewResponseEnvelopeSuccess = true
)

type AddressMapNewResponseIP

type AddressMapNewResponseIP struct {
	CreatedAt time.Time `json:"created_at" format:"date-time"`
	// An IPv4 or IPv6 address.
	IP   string                      `json:"ip"`
	JSON addressMapNewResponseIPJSON `json:"-"`
}

func (*AddressMapNewResponseIP) UnmarshalJSON

func (r *AddressMapNewResponseIP) UnmarshalJSON(data []byte) (err error)

type AddressMapNewResponseMembership

type AddressMapNewResponseMembership struct {
	// Controls whether the membership can be deleted via the API or not.
	CanDelete bool      `json:"can_delete"`
	CreatedAt time.Time `json:"created_at" format:"date-time"`
	// Identifier
	Identifier string `json:"identifier"`
	// The type of the membership.
	Kind AddressMapNewResponseMembershipsKind `json:"kind"`
	JSON addressMapNewResponseMembershipJSON  `json:"-"`
}

func (*AddressMapNewResponseMembership) UnmarshalJSON

func (r *AddressMapNewResponseMembership) UnmarshalJSON(data []byte) (err error)

type AddressMapNewResponseMembershipsKind

type AddressMapNewResponseMembershipsKind string

The type of the membership.

const (
	AddressMapNewResponseMembershipsKindZone    AddressMapNewResponseMembershipsKind = "zone"
	AddressMapNewResponseMembershipsKindAccount AddressMapNewResponseMembershipsKind = "account"
)

type AddressMapService

type AddressMapService struct {
	Options  []option.RequestOption
	Accounts *AddressMapAccountService
	IPs      *AddressMapIPService
	Zones    *AddressMapZoneService
}

AddressMapService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAddressMapService method instead.

func NewAddressMapService

func NewAddressMapService(opts ...option.RequestOption) (r *AddressMapService)

NewAddressMapService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*AddressMapService) Delete

func (r *AddressMapService) Delete(ctx context.Context, addressMapID string, body AddressMapDeleteParams, opts ...option.RequestOption) (res *AddressMapDeleteResponse, err error)

Delete a particular address map owned by the account. An Address Map must be disabled before it can be deleted.

func (*AddressMapService) Edit

func (r *AddressMapService) Edit(ctx context.Context, addressMapID string, params AddressMapEditParams, opts ...option.RequestOption) (res *AddressingAddressMaps, err error)

Modify properties of an address map owned by the account.

func (*AddressMapService) Get

func (r *AddressMapService) Get(ctx context.Context, addressMapID string, query AddressMapGetParams, opts ...option.RequestOption) (res *AddressMapGetResponse, err error)

Show a particular address map owned by the account.

func (*AddressMapService) List

List all address maps owned by the account.

func (*AddressMapService) New

Create a new address map under the account.

type AddressMapZoneDeleteParams

type AddressMapZoneDeleteParams struct {
	// Identifier
	ZoneID param.Field[string] `path:"zone_id,required"`
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type AddressMapZoneDeleteResponse added in v2.1.0

type AddressMapZoneDeleteResponse interface {
	ImplementsAddressingAddressMapZoneDeleteResponse()
}

Union satisfied by addressing.AddressMapZoneDeleteResponseUnknown, addressing.AddressMapZoneDeleteResponseArray or shared.UnionString.

type AddressMapZoneDeleteResponseArray

type AddressMapZoneDeleteResponseArray []interface{}

func (AddressMapZoneDeleteResponseArray) ImplementsAddressingAddressMapZoneDeleteResponse

func (r AddressMapZoneDeleteResponseArray) ImplementsAddressingAddressMapZoneDeleteResponse()

type AddressMapZoneDeleteResponseEnvelope

type AddressMapZoneDeleteResponseEnvelope struct {
	Errors   []AddressMapZoneDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapZoneDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressMapZoneDeleteResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    AddressMapZoneDeleteResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo AddressMapZoneDeleteResponseEnvelopeResultInfo `json:"result_info"`
	JSON       addressMapZoneDeleteResponseEnvelopeJSON       `json:"-"`
}

func (*AddressMapZoneDeleteResponseEnvelope) UnmarshalJSON

func (r *AddressMapZoneDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapZoneDeleteResponseEnvelopeErrors

type AddressMapZoneDeleteResponseEnvelopeErrors struct {
	Code    int64                                          `json:"code,required"`
	Message string                                         `json:"message,required"`
	JSON    addressMapZoneDeleteResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapZoneDeleteResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapZoneDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapZoneDeleteResponseEnvelopeMessages

type AddressMapZoneDeleteResponseEnvelopeMessages struct {
	Code    int64                                            `json:"code,required"`
	Message string                                           `json:"message,required"`
	JSON    addressMapZoneDeleteResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapZoneDeleteResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapZoneDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapZoneDeleteResponseEnvelopeResultInfo

type AddressMapZoneDeleteResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                            `json:"total_count"`
	JSON       addressMapZoneDeleteResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*AddressMapZoneDeleteResponseEnvelopeResultInfo) UnmarshalJSON

func (r *AddressMapZoneDeleteResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type AddressMapZoneDeleteResponseEnvelopeSuccess

type AddressMapZoneDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapZoneDeleteResponseEnvelopeSuccessTrue AddressMapZoneDeleteResponseEnvelopeSuccess = true
)

type AddressMapZoneService

type AddressMapZoneService struct {
	Options []option.RequestOption
}

AddressMapZoneService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAddressMapZoneService method instead.

func NewAddressMapZoneService

func NewAddressMapZoneService(opts ...option.RequestOption) (r *AddressMapZoneService)

NewAddressMapZoneService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*AddressMapZoneService) Delete

Remove a zone as a member of a particular address map.

func (*AddressMapZoneService) Update

Add a zone as a member of a particular address map.

type AddressMapZoneUpdateParams

type AddressMapZoneUpdateParams struct {
	// Identifier
	ZoneID param.Field[string] `path:"zone_id,required"`
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type AddressMapZoneUpdateResponse added in v2.1.0

type AddressMapZoneUpdateResponse interface {
	ImplementsAddressingAddressMapZoneUpdateResponse()
}

Union satisfied by addressing.AddressMapZoneUpdateResponseUnknown, addressing.AddressMapZoneUpdateResponseArray or shared.UnionString.

type AddressMapZoneUpdateResponseArray

type AddressMapZoneUpdateResponseArray []interface{}

func (AddressMapZoneUpdateResponseArray) ImplementsAddressingAddressMapZoneUpdateResponse

func (r AddressMapZoneUpdateResponseArray) ImplementsAddressingAddressMapZoneUpdateResponse()

type AddressMapZoneUpdateResponseEnvelope

type AddressMapZoneUpdateResponseEnvelope struct {
	Errors   []AddressMapZoneUpdateResponseEnvelopeErrors   `json:"errors,required"`
	Messages []AddressMapZoneUpdateResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressMapZoneUpdateResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    AddressMapZoneUpdateResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo AddressMapZoneUpdateResponseEnvelopeResultInfo `json:"result_info"`
	JSON       addressMapZoneUpdateResponseEnvelopeJSON       `json:"-"`
}

func (*AddressMapZoneUpdateResponseEnvelope) UnmarshalJSON

func (r *AddressMapZoneUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type AddressMapZoneUpdateResponseEnvelopeErrors

type AddressMapZoneUpdateResponseEnvelopeErrors struct {
	Code    int64                                          `json:"code,required"`
	Message string                                         `json:"message,required"`
	JSON    addressMapZoneUpdateResponseEnvelopeErrorsJSON `json:"-"`
}

func (*AddressMapZoneUpdateResponseEnvelopeErrors) UnmarshalJSON

func (r *AddressMapZoneUpdateResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type AddressMapZoneUpdateResponseEnvelopeMessages

type AddressMapZoneUpdateResponseEnvelopeMessages struct {
	Code    int64                                            `json:"code,required"`
	Message string                                           `json:"message,required"`
	JSON    addressMapZoneUpdateResponseEnvelopeMessagesJSON `json:"-"`
}

func (*AddressMapZoneUpdateResponseEnvelopeMessages) UnmarshalJSON

func (r *AddressMapZoneUpdateResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type AddressMapZoneUpdateResponseEnvelopeResultInfo

type AddressMapZoneUpdateResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                            `json:"total_count"`
	JSON       addressMapZoneUpdateResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*AddressMapZoneUpdateResponseEnvelopeResultInfo) UnmarshalJSON

func (r *AddressMapZoneUpdateResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type AddressMapZoneUpdateResponseEnvelopeSuccess

type AddressMapZoneUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	AddressMapZoneUpdateResponseEnvelopeSuccessTrue AddressMapZoneUpdateResponseEnvelopeSuccess = true
)

type AddressingAddressMaps

type AddressingAddressMaps struct {
	// Identifier
	ID string `json:"id"`
	// If set to false, then the Address Map cannot be deleted via API. This is true
	// for Cloudflare-managed maps.
	CanDelete bool `json:"can_delete"`
	// If set to false, then the IPs on the Address Map cannot be modified via the API.
	// This is true for Cloudflare-managed maps.
	CanModifyIPs bool      `json:"can_modify_ips"`
	CreatedAt    time.Time `json:"created_at" format:"date-time"`
	// If you have legacy TLS clients which do not send the TLS server name indicator,
	// then you can specify one default SNI on the map. If Cloudflare receives a TLS
	// handshake from a client without an SNI, it will respond with the default SNI on
	// those IPs. The default SNI can be any valid zone or subdomain owned by the
	// account.
	DefaultSni string `json:"default_sni,nullable"`
	// An optional description field which may be used to describe the types of IPs or
	// zones on the map.
	Description string `json:"description,nullable"`
	// Whether the Address Map is enabled or not. Cloudflare's DNS will not respond
	// with IP addresses on an Address Map until the map is enabled.
	Enabled    bool                      `json:"enabled,nullable"`
	ModifiedAt time.Time                 `json:"modified_at" format:"date-time"`
	JSON       addressingAddressMapsJSON `json:"-"`
}

func (*AddressingAddressMaps) UnmarshalJSON

func (r *AddressingAddressMaps) UnmarshalJSON(data []byte) (err error)

type AddressingIpamBGPPrefixes

type AddressingIpamBGPPrefixes struct {
	// Identifier
	ID string `json:"id"`
	// Autonomous System Number (ASN) the prefix will be advertised under.
	ASN           int64                                  `json:"asn,nullable"`
	BGPSignalOpts AddressingIpamBGPPrefixesBGPSignalOpts `json:"bgp_signal_opts"`
	// IP Prefix in Classless Inter-Domain Routing format.
	CIDR       string                            `json:"cidr"`
	CreatedAt  time.Time                         `json:"created_at" format:"date-time"`
	ModifiedAt time.Time                         `json:"modified_at" format:"date-time"`
	OnDemand   AddressingIpamBGPPrefixesOnDemand `json:"on_demand"`
	JSON       addressingIpamBGPPrefixesJSON     `json:"-"`
}

func (*AddressingIpamBGPPrefixes) UnmarshalJSON

func (r *AddressingIpamBGPPrefixes) UnmarshalJSON(data []byte) (err error)

type AddressingIpamBGPPrefixesBGPSignalOpts

type AddressingIpamBGPPrefixesBGPSignalOpts struct {
	// Whether control of advertisement of the prefix to the Internet is enabled to be
	// performed via BGP signal
	Enabled bool `json:"enabled"`
	// Last time BGP signaling control was toggled. This field is null if BGP signaling
	// has never been enabled.
	ModifiedAt time.Time                                  `json:"modified_at,nullable" format:"date-time"`
	JSON       addressingIpamBGPPrefixesBGPSignalOptsJSON `json:"-"`
}

func (*AddressingIpamBGPPrefixesBGPSignalOpts) UnmarshalJSON

func (r *AddressingIpamBGPPrefixesBGPSignalOpts) UnmarshalJSON(data []byte) (err error)

type AddressingIpamBGPPrefixesOnDemand

type AddressingIpamBGPPrefixesOnDemand struct {
	// Prefix advertisement status to the Internet. This field is only not 'null' if on
	// demand is enabled.
	Advertised bool `json:"advertised,nullable"`
	// Last time the advertisement status was changed. This field is only not 'null' if
	// on demand is enabled.
	AdvertisedModifiedAt time.Time `json:"advertised_modified_at,nullable" format:"date-time"`
	// Whether advertisement of the prefix to the Internet may be dynamically enabled
	// or disabled.
	OnDemandEnabled bool `json:"on_demand_enabled"`
	// Whether advertisement status of the prefix is locked, meaning it cannot be
	// changed.
	OnDemandLocked bool                                  `json:"on_demand_locked"`
	JSON           addressingIpamBGPPrefixesOnDemandJSON `json:"-"`
}

func (*AddressingIpamBGPPrefixesOnDemand) UnmarshalJSON

func (r *AddressingIpamBGPPrefixesOnDemand) UnmarshalJSON(data []byte) (err error)

type AddressingIpamDelegations

type AddressingIpamDelegations struct {
	// Delegation identifier tag.
	ID string `json:"id"`
	// IP Prefix in Classless Inter-Domain Routing format.
	CIDR      string    `json:"cidr"`
	CreatedAt time.Time `json:"created_at" format:"date-time"`
	// Account identifier for the account to which prefix is being delegated.
	DelegatedAccountID string    `json:"delegated_account_id"`
	ModifiedAt         time.Time `json:"modified_at" format:"date-time"`
	// Identifier
	ParentPrefixID string                        `json:"parent_prefix_id"`
	JSON           addressingIpamDelegationsJSON `json:"-"`
}

func (*AddressingIpamDelegations) UnmarshalJSON

func (r *AddressingIpamDelegations) UnmarshalJSON(data []byte) (err error)

type AddressingIpamPrefixes

type AddressingIpamPrefixes struct {
	// Identifier
	ID string `json:"id"`
	// Identifier
	AccountID string `json:"account_id"`
	// Prefix advertisement status to the Internet. This field is only not 'null' if on
	// demand is enabled.
	Advertised bool `json:"advertised,nullable"`
	// Last time the advertisement status was changed. This field is only not 'null' if
	// on demand is enabled.
	AdvertisedModifiedAt time.Time `json:"advertised_modified_at,nullable" format:"date-time"`
	// Approval state of the prefix (P = pending, V = active).
	Approved string `json:"approved"`
	// Autonomous System Number (ASN) the prefix will be advertised under.
	ASN int64 `json:"asn,nullable"`
	// IP Prefix in Classless Inter-Domain Routing format.
	CIDR      string    `json:"cidr"`
	CreatedAt time.Time `json:"created_at" format:"date-time"`
	// Description of the prefix.
	Description string `json:"description"`
	// Identifier for the uploaded LOA document.
	LOADocumentID string    `json:"loa_document_id,nullable"`
	ModifiedAt    time.Time `json:"modified_at" format:"date-time"`
	// Whether advertisement of the prefix to the Internet may be dynamically enabled
	// or disabled.
	OnDemandEnabled bool `json:"on_demand_enabled"`
	// Whether advertisement status of the prefix is locked, meaning it cannot be
	// changed.
	OnDemandLocked bool                       `json:"on_demand_locked"`
	JSON           addressingIpamPrefixesJSON `json:"-"`
}

func (*AddressingIpamPrefixes) UnmarshalJSON

func (r *AddressingIpamPrefixes) UnmarshalJSON(data []byte) (err error)

type AddressingService

type AddressingService struct {
	Options      []option.RequestOption
	Services     *ServiceService
	AddressMaps  *AddressMapService
	LOADocuments *LOADocumentService
	Prefixes     *PrefixService
}

AddressingService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewAddressingService method instead.

func NewAddressingService

func NewAddressingService(opts ...option.RequestOption) (r *AddressingService)

NewAddressingService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

type AddressingServiceBinding

type AddressingServiceBinding struct {
	// Identifier
	ID string `json:"id"`
	// IP Prefix in Classless Inter-Domain Routing format.
	CIDR string `json:"cidr"`
	// Status of a Service Binding's deployment to the Cloudflare network
	Provisioning AddressingServiceBindingProvisioning `json:"provisioning"`
	// Identifier
	ServiceID string `json:"service_id"`
	// Name of a service running on the Cloudflare network
	ServiceName string                       `json:"service_name"`
	JSON        addressingServiceBindingJSON `json:"-"`
}

func (*AddressingServiceBinding) UnmarshalJSON

func (r *AddressingServiceBinding) UnmarshalJSON(data []byte) (err error)

type AddressingServiceBindingProvisioning

type AddressingServiceBindingProvisioning struct {
	// When a binding has been deployed to a majority of Cloudflare datacenters, the
	// binding will become active and can be used with its associated service.
	State AddressingServiceBindingProvisioningState `json:"state"`
	JSON  addressingServiceBindingProvisioningJSON  `json:"-"`
}

Status of a Service Binding's deployment to the Cloudflare network

func (*AddressingServiceBindingProvisioning) UnmarshalJSON

func (r *AddressingServiceBindingProvisioning) UnmarshalJSON(data []byte) (err error)

type AddressingServiceBindingProvisioningState

type AddressingServiceBindingProvisioningState string

When a binding has been deployed to a majority of Cloudflare datacenters, the binding will become active and can be used with its associated service.

const (
	AddressingServiceBindingProvisioningStateProvisioning AddressingServiceBindingProvisioningState = "provisioning"
	AddressingServiceBindingProvisioningStateActive       AddressingServiceBindingProvisioningState = "active"
)

type Error

type Error = apierror.Error

type LOADocumentDownloadGetParams

type LOADocumentDownloadGetParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type LOADocumentDownloadGetResponse

type LOADocumentDownloadGetResponse = interface{}

type LOADocumentDownloadService

type LOADocumentDownloadService struct {
	Options []option.RequestOption
}

LOADocumentDownloadService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewLOADocumentDownloadService method instead.

func NewLOADocumentDownloadService

func NewLOADocumentDownloadService(opts ...option.RequestOption) (r *LOADocumentDownloadService)

NewLOADocumentDownloadService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*LOADocumentDownloadService) Get

Download specified LOA document under the account.

type LOADocumentNewParams

type LOADocumentNewParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// LOA document to upload.
	LOADocument param.Field[string] `json:"loa_document,required"`
}

func (LOADocumentNewParams) MarshalJSON

func (r LOADocumentNewParams) MarshalJSON() (data []byte, err error)

type LOADocumentNewResponse

type LOADocumentNewResponse struct {
	// Name of LOA document.
	Filename string                     `json:"filename"`
	JSON     loaDocumentNewResponseJSON `json:"-"`
}

func (*LOADocumentNewResponse) UnmarshalJSON

func (r *LOADocumentNewResponse) UnmarshalJSON(data []byte) (err error)

type LOADocumentNewResponseEnvelope

type LOADocumentNewResponseEnvelope struct {
	Errors   []LOADocumentNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []LOADocumentNewResponseEnvelopeMessages `json:"messages,required"`
	Result   LOADocumentNewResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success LOADocumentNewResponseEnvelopeSuccess `json:"success,required"`
	JSON    loaDocumentNewResponseEnvelopeJSON    `json:"-"`
}

func (*LOADocumentNewResponseEnvelope) UnmarshalJSON

func (r *LOADocumentNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type LOADocumentNewResponseEnvelopeErrors

type LOADocumentNewResponseEnvelopeErrors struct {
	Code    int64                                    `json:"code,required"`
	Message string                                   `json:"message,required"`
	JSON    loaDocumentNewResponseEnvelopeErrorsJSON `json:"-"`
}

func (*LOADocumentNewResponseEnvelopeErrors) UnmarshalJSON

func (r *LOADocumentNewResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type LOADocumentNewResponseEnvelopeMessages

type LOADocumentNewResponseEnvelopeMessages struct {
	Code    int64                                      `json:"code,required"`
	Message string                                     `json:"message,required"`
	JSON    loaDocumentNewResponseEnvelopeMessagesJSON `json:"-"`
}

func (*LOADocumentNewResponseEnvelopeMessages) UnmarshalJSON

func (r *LOADocumentNewResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type LOADocumentNewResponseEnvelopeSuccess

type LOADocumentNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	LOADocumentNewResponseEnvelopeSuccessTrue LOADocumentNewResponseEnvelopeSuccess = true
)

type LOADocumentService

type LOADocumentService struct {
	Options   []option.RequestOption
	Downloads *LOADocumentDownloadService
}

LOADocumentService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewLOADocumentService method instead.

func NewLOADocumentService

func NewLOADocumentService(opts ...option.RequestOption) (r *LOADocumentService)

NewLOADocumentService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*LOADocumentService) New

Submit LOA document (pdf format) under the account.

type PrefixBGPBindingDeleteParams

type PrefixBGPBindingDeleteParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixBGPBindingDeleteResponse added in v2.1.0

type PrefixBGPBindingDeleteResponse interface {
	ImplementsAddressingPrefixBGPBindingDeleteResponse()
}

Union satisfied by addressing.PrefixBGPBindingDeleteResponseUnknown, addressing.PrefixBGPBindingDeleteResponseArray or shared.UnionString.

type PrefixBGPBindingDeleteResponseArray

type PrefixBGPBindingDeleteResponseArray []interface{}

func (PrefixBGPBindingDeleteResponseArray) ImplementsAddressingPrefixBGPBindingDeleteResponse

func (r PrefixBGPBindingDeleteResponseArray) ImplementsAddressingPrefixBGPBindingDeleteResponse()

type PrefixBGPBindingDeleteResponseEnvelope

type PrefixBGPBindingDeleteResponseEnvelope struct {
	Errors   []PrefixBGPBindingDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixBGPBindingDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   PrefixBGPBindingDeleteResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success PrefixBGPBindingDeleteResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixBGPBindingDeleteResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixBGPBindingDeleteResponseEnvelope) UnmarshalJSON

func (r *PrefixBGPBindingDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingDeleteResponseEnvelopeErrors

type PrefixBGPBindingDeleteResponseEnvelopeErrors struct {
	Code    int64                                            `json:"code,required"`
	Message string                                           `json:"message,required"`
	JSON    prefixBGPBindingDeleteResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixBGPBindingDeleteResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixBGPBindingDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingDeleteResponseEnvelopeMessages

type PrefixBGPBindingDeleteResponseEnvelopeMessages struct {
	Code    int64                                              `json:"code,required"`
	Message string                                             `json:"message,required"`
	JSON    prefixBGPBindingDeleteResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixBGPBindingDeleteResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixBGPBindingDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingDeleteResponseEnvelopeSuccess

type PrefixBGPBindingDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixBGPBindingDeleteResponseEnvelopeSuccessTrue PrefixBGPBindingDeleteResponseEnvelopeSuccess = true
)

type PrefixBGPBindingGetParams

type PrefixBGPBindingGetParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixBGPBindingGetResponseEnvelope

type PrefixBGPBindingGetResponseEnvelope struct {
	Errors   []PrefixBGPBindingGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixBGPBindingGetResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressingServiceBinding                      `json:"result,required"`
	// Whether the API call was successful
	Success PrefixBGPBindingGetResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixBGPBindingGetResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixBGPBindingGetResponseEnvelope) UnmarshalJSON

func (r *PrefixBGPBindingGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingGetResponseEnvelopeErrors

type PrefixBGPBindingGetResponseEnvelopeErrors struct {
	Code    int64                                         `json:"code,required"`
	Message string                                        `json:"message,required"`
	JSON    prefixBGPBindingGetResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixBGPBindingGetResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixBGPBindingGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingGetResponseEnvelopeMessages

type PrefixBGPBindingGetResponseEnvelopeMessages struct {
	Code    int64                                           `json:"code,required"`
	Message string                                          `json:"message,required"`
	JSON    prefixBGPBindingGetResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixBGPBindingGetResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixBGPBindingGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingGetResponseEnvelopeSuccess

type PrefixBGPBindingGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixBGPBindingGetResponseEnvelopeSuccessTrue PrefixBGPBindingGetResponseEnvelopeSuccess = true
)

type PrefixBGPBindingListParams

type PrefixBGPBindingListParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixBGPBindingListResponseEnvelope

type PrefixBGPBindingListResponseEnvelope struct {
	Errors   []PrefixBGPBindingListResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixBGPBindingListResponseEnvelopeMessages `json:"messages,required"`
	Result   []AddressingServiceBinding                     `json:"result,required"`
	// Whether the API call was successful
	Success PrefixBGPBindingListResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixBGPBindingListResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixBGPBindingListResponseEnvelope) UnmarshalJSON

func (r *PrefixBGPBindingListResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingListResponseEnvelopeErrors

type PrefixBGPBindingListResponseEnvelopeErrors struct {
	Code    int64                                          `json:"code,required"`
	Message string                                         `json:"message,required"`
	JSON    prefixBGPBindingListResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixBGPBindingListResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixBGPBindingListResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingListResponseEnvelopeMessages

type PrefixBGPBindingListResponseEnvelopeMessages struct {
	Code    int64                                            `json:"code,required"`
	Message string                                           `json:"message,required"`
	JSON    prefixBGPBindingListResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixBGPBindingListResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixBGPBindingListResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingListResponseEnvelopeSuccess

type PrefixBGPBindingListResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixBGPBindingListResponseEnvelopeSuccessTrue PrefixBGPBindingListResponseEnvelopeSuccess = true
)

type PrefixBGPBindingNewParams

type PrefixBGPBindingNewParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// IP Prefix in Classless Inter-Domain Routing format.
	CIDR param.Field[string] `json:"cidr"`
	// Identifier
	ServiceID param.Field[string] `json:"service_id"`
}

func (PrefixBGPBindingNewParams) MarshalJSON

func (r PrefixBGPBindingNewParams) MarshalJSON() (data []byte, err error)

type PrefixBGPBindingNewResponseEnvelope

type PrefixBGPBindingNewResponseEnvelope struct {
	Errors   []PrefixBGPBindingNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixBGPBindingNewResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressingServiceBinding                      `json:"result,required"`
	// Whether the API call was successful
	Success PrefixBGPBindingNewResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixBGPBindingNewResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixBGPBindingNewResponseEnvelope) UnmarshalJSON

func (r *PrefixBGPBindingNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingNewResponseEnvelopeErrors

type PrefixBGPBindingNewResponseEnvelopeErrors struct {
	Code    int64                                         `json:"code,required"`
	Message string                                        `json:"message,required"`
	JSON    prefixBGPBindingNewResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixBGPBindingNewResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixBGPBindingNewResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingNewResponseEnvelopeMessages

type PrefixBGPBindingNewResponseEnvelopeMessages struct {
	Code    int64                                           `json:"code,required"`
	Message string                                          `json:"message,required"`
	JSON    prefixBGPBindingNewResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixBGPBindingNewResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixBGPBindingNewResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixBGPBindingNewResponseEnvelopeSuccess

type PrefixBGPBindingNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixBGPBindingNewResponseEnvelopeSuccessTrue PrefixBGPBindingNewResponseEnvelopeSuccess = true
)

type PrefixBGPBindingService

type PrefixBGPBindingService struct {
	Options []option.RequestOption
}

PrefixBGPBindingService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewPrefixBGPBindingService method instead.

func NewPrefixBGPBindingService

func NewPrefixBGPBindingService(opts ...option.RequestOption) (r *PrefixBGPBindingService)

NewPrefixBGPBindingService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*PrefixBGPBindingService) Delete

Delete a Service Binding

func (*PrefixBGPBindingService) Get

Fetch a single Service Binding

func (*PrefixBGPBindingService) List

List the Cloudflare services this prefix is currently bound to. Traffic sent to an address within an IP prefix will be routed to the Cloudflare service of the most-specific Service Binding matching the address. **Example:** binding `192.0.2.0/24` to Cloudflare Magic Transit and `192.0.2.1/32` to the Cloudflare CDN would route traffic for `192.0.2.1` to the CDN, and traffic for all other IPs in the prefix to Cloudflare Magic Transit.

func (*PrefixBGPBindingService) New

Creates a new Service Binding, routing traffic to IPs within the given CIDR to a service running on Cloudflare's network. **Note:** This API may only be used on prefixes currently configured with a Magic Transit service binding, and only allows creating service bindings for the Cloudflare CDN or Cloudflare Spectrum.

type PrefixBGPPrefixEditParams

type PrefixBGPPrefixEditParams struct {
	// Identifier
	AccountID param.Field[string]                            `path:"account_id,required"`
	OnDemand  param.Field[PrefixBGPPrefixEditParamsOnDemand] `json:"on_demand"`
}

func (PrefixBGPPrefixEditParams) MarshalJSON

func (r PrefixBGPPrefixEditParams) MarshalJSON() (data []byte, err error)

type PrefixBGPPrefixEditParamsOnDemand

type PrefixBGPPrefixEditParamsOnDemand struct {
	Advertised param.Field[bool] `json:"advertised"`
}

func (PrefixBGPPrefixEditParamsOnDemand) MarshalJSON

func (r PrefixBGPPrefixEditParamsOnDemand) MarshalJSON() (data []byte, err error)

type PrefixBGPPrefixEditResponseEnvelope

type PrefixBGPPrefixEditResponseEnvelope struct {
	Errors   []PrefixBGPPrefixEditResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixBGPPrefixEditResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressingIpamBGPPrefixes                     `json:"result,required"`
	// Whether the API call was successful
	Success PrefixBGPPrefixEditResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixBGPPrefixEditResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixBGPPrefixEditResponseEnvelope) UnmarshalJSON

func (r *PrefixBGPPrefixEditResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixBGPPrefixEditResponseEnvelopeErrors

type PrefixBGPPrefixEditResponseEnvelopeErrors struct {
	Code    int64                                         `json:"code,required"`
	Message string                                        `json:"message,required"`
	JSON    prefixBGPPrefixEditResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixBGPPrefixEditResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixBGPPrefixEditResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixBGPPrefixEditResponseEnvelopeMessages

type PrefixBGPPrefixEditResponseEnvelopeMessages struct {
	Code    int64                                           `json:"code,required"`
	Message string                                          `json:"message,required"`
	JSON    prefixBGPPrefixEditResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixBGPPrefixEditResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixBGPPrefixEditResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixBGPPrefixEditResponseEnvelopeSuccess

type PrefixBGPPrefixEditResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixBGPPrefixEditResponseEnvelopeSuccessTrue PrefixBGPPrefixEditResponseEnvelopeSuccess = true
)

type PrefixBGPPrefixGetParams

type PrefixBGPPrefixGetParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixBGPPrefixGetResponseEnvelope

type PrefixBGPPrefixGetResponseEnvelope struct {
	Errors   []PrefixBGPPrefixGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixBGPPrefixGetResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressingIpamBGPPrefixes                    `json:"result,required"`
	// Whether the API call was successful
	Success PrefixBGPPrefixGetResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixBGPPrefixGetResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixBGPPrefixGetResponseEnvelope) UnmarshalJSON

func (r *PrefixBGPPrefixGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixBGPPrefixGetResponseEnvelopeErrors

type PrefixBGPPrefixGetResponseEnvelopeErrors struct {
	Code    int64                                        `json:"code,required"`
	Message string                                       `json:"message,required"`
	JSON    prefixBGPPrefixGetResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixBGPPrefixGetResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixBGPPrefixGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixBGPPrefixGetResponseEnvelopeMessages

type PrefixBGPPrefixGetResponseEnvelopeMessages struct {
	Code    int64                                          `json:"code,required"`
	Message string                                         `json:"message,required"`
	JSON    prefixBGPPrefixGetResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixBGPPrefixGetResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixBGPPrefixGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixBGPPrefixGetResponseEnvelopeSuccess

type PrefixBGPPrefixGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixBGPPrefixGetResponseEnvelopeSuccessTrue PrefixBGPPrefixGetResponseEnvelopeSuccess = true
)

type PrefixBGPPrefixListParams

type PrefixBGPPrefixListParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixBGPPrefixListResponseEnvelope

type PrefixBGPPrefixListResponseEnvelope struct {
	Errors   []PrefixBGPPrefixListResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixBGPPrefixListResponseEnvelopeMessages `json:"messages,required"`
	Result   []AddressingIpamBGPPrefixes                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    PrefixBGPPrefixListResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo PrefixBGPPrefixListResponseEnvelopeResultInfo `json:"result_info"`
	JSON       prefixBGPPrefixListResponseEnvelopeJSON       `json:"-"`
}

func (*PrefixBGPPrefixListResponseEnvelope) UnmarshalJSON

func (r *PrefixBGPPrefixListResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixBGPPrefixListResponseEnvelopeErrors

type PrefixBGPPrefixListResponseEnvelopeErrors struct {
	Code    int64                                         `json:"code,required"`
	Message string                                        `json:"message,required"`
	JSON    prefixBGPPrefixListResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixBGPPrefixListResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixBGPPrefixListResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixBGPPrefixListResponseEnvelopeMessages

type PrefixBGPPrefixListResponseEnvelopeMessages struct {
	Code    int64                                           `json:"code,required"`
	Message string                                          `json:"message,required"`
	JSON    prefixBGPPrefixListResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixBGPPrefixListResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixBGPPrefixListResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixBGPPrefixListResponseEnvelopeResultInfo

type PrefixBGPPrefixListResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                           `json:"total_count"`
	JSON       prefixBGPPrefixListResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*PrefixBGPPrefixListResponseEnvelopeResultInfo) UnmarshalJSON

func (r *PrefixBGPPrefixListResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type PrefixBGPPrefixListResponseEnvelopeSuccess

type PrefixBGPPrefixListResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixBGPPrefixListResponseEnvelopeSuccessTrue PrefixBGPPrefixListResponseEnvelopeSuccess = true
)

type PrefixBGPPrefixService

type PrefixBGPPrefixService struct {
	Options []option.RequestOption
}

PrefixBGPPrefixService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewPrefixBGPPrefixService method instead.

func NewPrefixBGPPrefixService

func NewPrefixBGPPrefixService(opts ...option.RequestOption) (r *PrefixBGPPrefixService)

NewPrefixBGPPrefixService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*PrefixBGPPrefixService) Edit

func (r *PrefixBGPPrefixService) Edit(ctx context.Context, prefixID string, bgpPrefixID string, params PrefixBGPPrefixEditParams, opts ...option.RequestOption) (res *AddressingIpamBGPPrefixes, err error)

Update the properties of a BGP Prefix, such as the on demand advertisement status (advertised or withdrawn).

func (*PrefixBGPPrefixService) Get

func (r *PrefixBGPPrefixService) Get(ctx context.Context, prefixID string, bgpPrefixID string, query PrefixBGPPrefixGetParams, opts ...option.RequestOption) (res *AddressingIpamBGPPrefixes, err error)

Retrieve a single BGP Prefix according to its identifier

func (*PrefixBGPPrefixService) List

List all BGP Prefixes within the specified IP Prefix. BGP Prefixes are used to control which specific subnets are advertised to the Internet. It is possible to advertise subnets more specific than an IP Prefix by creating more specific BGP Prefixes.

type PrefixBGPService

type PrefixBGPService struct {
	Options  []option.RequestOption
	Bindings *PrefixBGPBindingService
	Prefixes *PrefixBGPPrefixService
	Statuses *PrefixBGPStatusService
}

PrefixBGPService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewPrefixBGPService method instead.

func NewPrefixBGPService

func NewPrefixBGPService(opts ...option.RequestOption) (r *PrefixBGPService)

NewPrefixBGPService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

type PrefixBGPStatusEditParams

type PrefixBGPStatusEditParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// Enablement of prefix advertisement to the Internet.
	Advertised param.Field[bool] `json:"advertised,required"`
}

func (PrefixBGPStatusEditParams) MarshalJSON

func (r PrefixBGPStatusEditParams) MarshalJSON() (data []byte, err error)

type PrefixBGPStatusEditResponse

type PrefixBGPStatusEditResponse struct {
	// Enablement of prefix advertisement to the Internet.
	Advertised bool `json:"advertised"`
	// Last time the advertisement status was changed. This field is only not 'null' if
	// on demand is enabled.
	AdvertisedModifiedAt time.Time                       `json:"advertised_modified_at,nullable" format:"date-time"`
	JSON                 prefixBGPStatusEditResponseJSON `json:"-"`
}

func (*PrefixBGPStatusEditResponse) UnmarshalJSON

func (r *PrefixBGPStatusEditResponse) UnmarshalJSON(data []byte) (err error)

type PrefixBGPStatusEditResponseEnvelope

type PrefixBGPStatusEditResponseEnvelope struct {
	Errors   []PrefixBGPStatusEditResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixBGPStatusEditResponseEnvelopeMessages `json:"messages,required"`
	Result   PrefixBGPStatusEditResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success PrefixBGPStatusEditResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixBGPStatusEditResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixBGPStatusEditResponseEnvelope) UnmarshalJSON

func (r *PrefixBGPStatusEditResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixBGPStatusEditResponseEnvelopeErrors

type PrefixBGPStatusEditResponseEnvelopeErrors struct {
	Code    int64                                         `json:"code,required"`
	Message string                                        `json:"message,required"`
	JSON    prefixBGPStatusEditResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixBGPStatusEditResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixBGPStatusEditResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixBGPStatusEditResponseEnvelopeMessages

type PrefixBGPStatusEditResponseEnvelopeMessages struct {
	Code    int64                                           `json:"code,required"`
	Message string                                          `json:"message,required"`
	JSON    prefixBGPStatusEditResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixBGPStatusEditResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixBGPStatusEditResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixBGPStatusEditResponseEnvelopeSuccess

type PrefixBGPStatusEditResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixBGPStatusEditResponseEnvelopeSuccessTrue PrefixBGPStatusEditResponseEnvelopeSuccess = true
)

type PrefixBGPStatusGetParams

type PrefixBGPStatusGetParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixBGPStatusGetResponse

type PrefixBGPStatusGetResponse struct {
	// Enablement of prefix advertisement to the Internet.
	Advertised bool `json:"advertised"`
	// Last time the advertisement status was changed. This field is only not 'null' if
	// on demand is enabled.
	AdvertisedModifiedAt time.Time                      `json:"advertised_modified_at,nullable" format:"date-time"`
	JSON                 prefixBGPStatusGetResponseJSON `json:"-"`
}

func (*PrefixBGPStatusGetResponse) UnmarshalJSON

func (r *PrefixBGPStatusGetResponse) UnmarshalJSON(data []byte) (err error)

type PrefixBGPStatusGetResponseEnvelope

type PrefixBGPStatusGetResponseEnvelope struct {
	Errors   []PrefixBGPStatusGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixBGPStatusGetResponseEnvelopeMessages `json:"messages,required"`
	Result   PrefixBGPStatusGetResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success PrefixBGPStatusGetResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixBGPStatusGetResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixBGPStatusGetResponseEnvelope) UnmarshalJSON

func (r *PrefixBGPStatusGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixBGPStatusGetResponseEnvelopeErrors

type PrefixBGPStatusGetResponseEnvelopeErrors struct {
	Code    int64                                        `json:"code,required"`
	Message string                                       `json:"message,required"`
	JSON    prefixBGPStatusGetResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixBGPStatusGetResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixBGPStatusGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixBGPStatusGetResponseEnvelopeMessages

type PrefixBGPStatusGetResponseEnvelopeMessages struct {
	Code    int64                                          `json:"code,required"`
	Message string                                         `json:"message,required"`
	JSON    prefixBGPStatusGetResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixBGPStatusGetResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixBGPStatusGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixBGPStatusGetResponseEnvelopeSuccess

type PrefixBGPStatusGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixBGPStatusGetResponseEnvelopeSuccessTrue PrefixBGPStatusGetResponseEnvelopeSuccess = true
)

type PrefixBGPStatusService

type PrefixBGPStatusService struct {
	Options []option.RequestOption
}

PrefixBGPStatusService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewPrefixBGPStatusService method instead.

func NewPrefixBGPStatusService

func NewPrefixBGPStatusService(opts ...option.RequestOption) (r *PrefixBGPStatusService)

NewPrefixBGPStatusService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*PrefixBGPStatusService) Edit

Advertise or withdraw BGP route for a prefix.

func (*PrefixBGPStatusService) Get

List the current advertisement state for a prefix.

type PrefixDelegationDeleteParams

type PrefixDelegationDeleteParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixDelegationDeleteResponse

type PrefixDelegationDeleteResponse struct {
	// Delegation identifier tag.
	ID   string                             `json:"id"`
	JSON prefixDelegationDeleteResponseJSON `json:"-"`
}

func (*PrefixDelegationDeleteResponse) UnmarshalJSON

func (r *PrefixDelegationDeleteResponse) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationDeleteResponseEnvelope

type PrefixDelegationDeleteResponseEnvelope struct {
	Errors   []PrefixDelegationDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixDelegationDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   PrefixDelegationDeleteResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success PrefixDelegationDeleteResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixDelegationDeleteResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixDelegationDeleteResponseEnvelope) UnmarshalJSON

func (r *PrefixDelegationDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationDeleteResponseEnvelopeErrors

type PrefixDelegationDeleteResponseEnvelopeErrors struct {
	Code    int64                                            `json:"code,required"`
	Message string                                           `json:"message,required"`
	JSON    prefixDelegationDeleteResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixDelegationDeleteResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixDelegationDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationDeleteResponseEnvelopeMessages

type PrefixDelegationDeleteResponseEnvelopeMessages struct {
	Code    int64                                              `json:"code,required"`
	Message string                                             `json:"message,required"`
	JSON    prefixDelegationDeleteResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixDelegationDeleteResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixDelegationDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationDeleteResponseEnvelopeSuccess

type PrefixDelegationDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixDelegationDeleteResponseEnvelopeSuccessTrue PrefixDelegationDeleteResponseEnvelopeSuccess = true
)

type PrefixDelegationListParams

type PrefixDelegationListParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixDelegationListResponseEnvelope

type PrefixDelegationListResponseEnvelope struct {
	Errors   []PrefixDelegationListResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixDelegationListResponseEnvelopeMessages `json:"messages,required"`
	Result   []AddressingIpamDelegations                    `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    PrefixDelegationListResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo PrefixDelegationListResponseEnvelopeResultInfo `json:"result_info"`
	JSON       prefixDelegationListResponseEnvelopeJSON       `json:"-"`
}

func (*PrefixDelegationListResponseEnvelope) UnmarshalJSON

func (r *PrefixDelegationListResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationListResponseEnvelopeErrors

type PrefixDelegationListResponseEnvelopeErrors struct {
	Code    int64                                          `json:"code,required"`
	Message string                                         `json:"message,required"`
	JSON    prefixDelegationListResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixDelegationListResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixDelegationListResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationListResponseEnvelopeMessages

type PrefixDelegationListResponseEnvelopeMessages struct {
	Code    int64                                            `json:"code,required"`
	Message string                                           `json:"message,required"`
	JSON    prefixDelegationListResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixDelegationListResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixDelegationListResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationListResponseEnvelopeResultInfo

type PrefixDelegationListResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                            `json:"total_count"`
	JSON       prefixDelegationListResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*PrefixDelegationListResponseEnvelopeResultInfo) UnmarshalJSON

func (r *PrefixDelegationListResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationListResponseEnvelopeSuccess

type PrefixDelegationListResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixDelegationListResponseEnvelopeSuccessTrue PrefixDelegationListResponseEnvelopeSuccess = true
)

type PrefixDelegationNewParams

type PrefixDelegationNewParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// IP Prefix in Classless Inter-Domain Routing format.
	CIDR param.Field[string] `json:"cidr,required"`
	// Account identifier for the account to which prefix is being delegated.
	DelegatedAccountID param.Field[string] `json:"delegated_account_id,required"`
}

func (PrefixDelegationNewParams) MarshalJSON

func (r PrefixDelegationNewParams) MarshalJSON() (data []byte, err error)

type PrefixDelegationNewResponseEnvelope

type PrefixDelegationNewResponseEnvelope struct {
	Errors   []PrefixDelegationNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixDelegationNewResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressingIpamDelegations                     `json:"result,required"`
	// Whether the API call was successful
	Success PrefixDelegationNewResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixDelegationNewResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixDelegationNewResponseEnvelope) UnmarshalJSON

func (r *PrefixDelegationNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationNewResponseEnvelopeErrors

type PrefixDelegationNewResponseEnvelopeErrors struct {
	Code    int64                                         `json:"code,required"`
	Message string                                        `json:"message,required"`
	JSON    prefixDelegationNewResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixDelegationNewResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixDelegationNewResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationNewResponseEnvelopeMessages

type PrefixDelegationNewResponseEnvelopeMessages struct {
	Code    int64                                           `json:"code,required"`
	Message string                                          `json:"message,required"`
	JSON    prefixDelegationNewResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixDelegationNewResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixDelegationNewResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixDelegationNewResponseEnvelopeSuccess

type PrefixDelegationNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixDelegationNewResponseEnvelopeSuccessTrue PrefixDelegationNewResponseEnvelopeSuccess = true
)

type PrefixDelegationService

type PrefixDelegationService struct {
	Options []option.RequestOption
}

PrefixDelegationService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewPrefixDelegationService method instead.

func NewPrefixDelegationService

func NewPrefixDelegationService(opts ...option.RequestOption) (r *PrefixDelegationService)

NewPrefixDelegationService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*PrefixDelegationService) Delete

Delete an account delegation for a given IP prefix.

func (*PrefixDelegationService) List

List all delegations for a given account IP prefix.

func (*PrefixDelegationService) New

Create a new account delegation for a given IP prefix.

type PrefixDeleteParams

type PrefixDeleteParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixDeleteResponse added in v2.1.0

type PrefixDeleteResponse interface {
	ImplementsAddressingPrefixDeleteResponse()
}

Union satisfied by addressing.PrefixDeleteResponseUnknown, addressing.PrefixDeleteResponseArray or shared.UnionString.

type PrefixDeleteResponseArray

type PrefixDeleteResponseArray []interface{}

func (PrefixDeleteResponseArray) ImplementsAddressingPrefixDeleteResponse

func (r PrefixDeleteResponseArray) ImplementsAddressingPrefixDeleteResponse()

type PrefixDeleteResponseEnvelope

type PrefixDeleteResponseEnvelope struct {
	Errors   []PrefixDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   PrefixDeleteResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    PrefixDeleteResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo PrefixDeleteResponseEnvelopeResultInfo `json:"result_info"`
	JSON       prefixDeleteResponseEnvelopeJSON       `json:"-"`
}

func (*PrefixDeleteResponseEnvelope) UnmarshalJSON

func (r *PrefixDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixDeleteResponseEnvelopeErrors

type PrefixDeleteResponseEnvelopeErrors struct {
	Code    int64                                  `json:"code,required"`
	Message string                                 `json:"message,required"`
	JSON    prefixDeleteResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixDeleteResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixDeleteResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixDeleteResponseEnvelopeMessages

type PrefixDeleteResponseEnvelopeMessages struct {
	Code    int64                                    `json:"code,required"`
	Message string                                   `json:"message,required"`
	JSON    prefixDeleteResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixDeleteResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixDeleteResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixDeleteResponseEnvelopeResultInfo

type PrefixDeleteResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                    `json:"total_count"`
	JSON       prefixDeleteResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*PrefixDeleteResponseEnvelopeResultInfo) UnmarshalJSON

func (r *PrefixDeleteResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type PrefixDeleteResponseEnvelopeSuccess

type PrefixDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixDeleteResponseEnvelopeSuccessTrue PrefixDeleteResponseEnvelopeSuccess = true
)

type PrefixEditParams

type PrefixEditParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// Description of the prefix.
	Description param.Field[string] `json:"description,required"`
}

func (PrefixEditParams) MarshalJSON

func (r PrefixEditParams) MarshalJSON() (data []byte, err error)

type PrefixEditResponseEnvelope

type PrefixEditResponseEnvelope struct {
	Errors   []PrefixEditResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixEditResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressingIpamPrefixes               `json:"result,required"`
	// Whether the API call was successful
	Success PrefixEditResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixEditResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixEditResponseEnvelope) UnmarshalJSON

func (r *PrefixEditResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixEditResponseEnvelopeErrors

type PrefixEditResponseEnvelopeErrors struct {
	Code    int64                                `json:"code,required"`
	Message string                               `json:"message,required"`
	JSON    prefixEditResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixEditResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixEditResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixEditResponseEnvelopeMessages

type PrefixEditResponseEnvelopeMessages struct {
	Code    int64                                  `json:"code,required"`
	Message string                                 `json:"message,required"`
	JSON    prefixEditResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixEditResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixEditResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixEditResponseEnvelopeSuccess

type PrefixEditResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixEditResponseEnvelopeSuccessTrue PrefixEditResponseEnvelopeSuccess = true
)

type PrefixGetParams

type PrefixGetParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixGetResponseEnvelope

type PrefixGetResponseEnvelope struct {
	Errors   []PrefixGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixGetResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressingIpamPrefixes              `json:"result,required"`
	// Whether the API call was successful
	Success PrefixGetResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixGetResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixGetResponseEnvelope) UnmarshalJSON

func (r *PrefixGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixGetResponseEnvelopeErrors

type PrefixGetResponseEnvelopeErrors struct {
	Code    int64                               `json:"code,required"`
	Message string                              `json:"message,required"`
	JSON    prefixGetResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixGetResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixGetResponseEnvelopeMessages

type PrefixGetResponseEnvelopeMessages struct {
	Code    int64                                 `json:"code,required"`
	Message string                                `json:"message,required"`
	JSON    prefixGetResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixGetResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixGetResponseEnvelopeSuccess

type PrefixGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixGetResponseEnvelopeSuccessTrue PrefixGetResponseEnvelopeSuccess = true
)

type PrefixListParams

type PrefixListParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type PrefixListResponseEnvelope

type PrefixListResponseEnvelope struct {
	Errors   []PrefixListResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixListResponseEnvelopeMessages `json:"messages,required"`
	Result   []AddressingIpamPrefixes             `json:"result,required,nullable"`
	// Whether the API call was successful
	Success    PrefixListResponseEnvelopeSuccess    `json:"success,required"`
	ResultInfo PrefixListResponseEnvelopeResultInfo `json:"result_info"`
	JSON       prefixListResponseEnvelopeJSON       `json:"-"`
}

func (*PrefixListResponseEnvelope) UnmarshalJSON

func (r *PrefixListResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixListResponseEnvelopeErrors

type PrefixListResponseEnvelopeErrors struct {
	Code    int64                                `json:"code,required"`
	Message string                               `json:"message,required"`
	JSON    prefixListResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixListResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixListResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixListResponseEnvelopeMessages

type PrefixListResponseEnvelopeMessages struct {
	Code    int64                                  `json:"code,required"`
	Message string                                 `json:"message,required"`
	JSON    prefixListResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixListResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixListResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixListResponseEnvelopeResultInfo

type PrefixListResponseEnvelopeResultInfo struct {
	// Total number of results for the requested service
	Count float64 `json:"count"`
	// Current page within paginated list of results
	Page float64 `json:"page"`
	// Number of results per page of results
	PerPage float64 `json:"per_page"`
	// Total results available without any search parameters
	TotalCount float64                                  `json:"total_count"`
	JSON       prefixListResponseEnvelopeResultInfoJSON `json:"-"`
}

func (*PrefixListResponseEnvelopeResultInfo) UnmarshalJSON

func (r *PrefixListResponseEnvelopeResultInfo) UnmarshalJSON(data []byte) (err error)

type PrefixListResponseEnvelopeSuccess

type PrefixListResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixListResponseEnvelopeSuccessTrue PrefixListResponseEnvelopeSuccess = true
)

type PrefixNewParams

type PrefixNewParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// Autonomous System Number (ASN) the prefix will be advertised under.
	ASN param.Field[int64] `json:"asn,required"`
	// IP Prefix in Classless Inter-Domain Routing format.
	CIDR param.Field[string] `json:"cidr,required"`
	// Identifier for the uploaded LOA document.
	LOADocumentID param.Field[string] `json:"loa_document_id,required"`
}

func (PrefixNewParams) MarshalJSON

func (r PrefixNewParams) MarshalJSON() (data []byte, err error)

type PrefixNewResponseEnvelope

type PrefixNewResponseEnvelope struct {
	Errors   []PrefixNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []PrefixNewResponseEnvelopeMessages `json:"messages,required"`
	Result   AddressingIpamPrefixes              `json:"result,required"`
	// Whether the API call was successful
	Success PrefixNewResponseEnvelopeSuccess `json:"success,required"`
	JSON    prefixNewResponseEnvelopeJSON    `json:"-"`
}

func (*PrefixNewResponseEnvelope) UnmarshalJSON

func (r *PrefixNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type PrefixNewResponseEnvelopeErrors

type PrefixNewResponseEnvelopeErrors struct {
	Code    int64                               `json:"code,required"`
	Message string                              `json:"message,required"`
	JSON    prefixNewResponseEnvelopeErrorsJSON `json:"-"`
}

func (*PrefixNewResponseEnvelopeErrors) UnmarshalJSON

func (r *PrefixNewResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type PrefixNewResponseEnvelopeMessages

type PrefixNewResponseEnvelopeMessages struct {
	Code    int64                                 `json:"code,required"`
	Message string                                `json:"message,required"`
	JSON    prefixNewResponseEnvelopeMessagesJSON `json:"-"`
}

func (*PrefixNewResponseEnvelopeMessages) UnmarshalJSON

func (r *PrefixNewResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type PrefixNewResponseEnvelopeSuccess

type PrefixNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	PrefixNewResponseEnvelopeSuccessTrue PrefixNewResponseEnvelopeSuccess = true
)

type PrefixService

type PrefixService struct {
	Options     []option.RequestOption
	BGP         *PrefixBGPService
	Delegations *PrefixDelegationService
}

PrefixService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewPrefixService method instead.

func NewPrefixService

func NewPrefixService(opts ...option.RequestOption) (r *PrefixService)

NewPrefixService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*PrefixService) Delete

func (r *PrefixService) Delete(ctx context.Context, prefixID string, body PrefixDeleteParams, opts ...option.RequestOption) (res *PrefixDeleteResponse, err error)

Delete an unapproved prefix owned by the account.

func (*PrefixService) Edit

func (r *PrefixService) Edit(ctx context.Context, prefixID string, params PrefixEditParams, opts ...option.RequestOption) (res *AddressingIpamPrefixes, err error)

Modify the description for a prefix owned by the account.

func (*PrefixService) Get

func (r *PrefixService) Get(ctx context.Context, prefixID string, query PrefixGetParams, opts ...option.RequestOption) (res *AddressingIpamPrefixes, err error)

List a particular prefix owned by the account.

func (*PrefixService) List

List all prefixes owned by the account.

func (*PrefixService) New

Add a new prefix under the account.

type ServiceListParams

type ServiceListParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
}

type ServiceListResponse

type ServiceListResponse struct {
	// Identifier
	ID string `json:"id"`
	// Name of a service running on the Cloudflare network
	Name string                  `json:"name"`
	JSON serviceListResponseJSON `json:"-"`
}

func (*ServiceListResponse) UnmarshalJSON

func (r *ServiceListResponse) UnmarshalJSON(data []byte) (err error)

type ServiceListResponseEnvelope

type ServiceListResponseEnvelope struct {
	Errors   []ServiceListResponseEnvelopeErrors   `json:"errors,required"`
	Messages []ServiceListResponseEnvelopeMessages `json:"messages,required"`
	Result   []ServiceListResponse                 `json:"result,required"`
	// Whether the API call was successful
	Success ServiceListResponseEnvelopeSuccess `json:"success,required"`
	JSON    serviceListResponseEnvelopeJSON    `json:"-"`
}

func (*ServiceListResponseEnvelope) UnmarshalJSON

func (r *ServiceListResponseEnvelope) UnmarshalJSON(data []byte) (err error)

type ServiceListResponseEnvelopeErrors

type ServiceListResponseEnvelopeErrors struct {
	Code    int64                                 `json:"code,required"`
	Message string                                `json:"message,required"`
	JSON    serviceListResponseEnvelopeErrorsJSON `json:"-"`
}

func (*ServiceListResponseEnvelopeErrors) UnmarshalJSON

func (r *ServiceListResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)

type ServiceListResponseEnvelopeMessages

type ServiceListResponseEnvelopeMessages struct {
	Code    int64                                   `json:"code,required"`
	Message string                                  `json:"message,required"`
	JSON    serviceListResponseEnvelopeMessagesJSON `json:"-"`
}

func (*ServiceListResponseEnvelopeMessages) UnmarshalJSON

func (r *ServiceListResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)

type ServiceListResponseEnvelopeSuccess

type ServiceListResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	ServiceListResponseEnvelopeSuccessTrue ServiceListResponseEnvelopeSuccess = true
)

type ServiceService

type ServiceService struct {
	Options []option.RequestOption
}

ServiceService contains methods and other services that help with interacting with the cloudflare API. Note, unlike clients, this service does not read variables from the environment automatically. You should not instantiate this service directly, and instead use the NewServiceService method instead.

func NewServiceService

func NewServiceService(opts ...option.RequestOption) (r *ServiceService)

NewServiceService generates a new service that applies the given options to each request. These options are applied after the parent client's options (if there is one), and before any request-specific options.

func (*ServiceService) List

func (r *ServiceService) List(ctx context.Context, query ServiceListParams, opts ...option.RequestOption) (res *[]ServiceListResponse, err error)

Bring-Your-Own IP (BYOIP) prefixes onboarded to Cloudflare must be bound to a service running on the Cloudflare network to enable a Cloudflare product on the IP addresses. This endpoint can be used as a reference of available services on the Cloudflare network, and their service IDs.

Jump to

Keyboard shortcuts

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