Documentation
¶
Index ¶
- Constants
- type ASN
- type ASNParam
- type AuditLog
- type AuditLogAction
- type AuditLogActor
- type AuditLogActorType
- type AuditLogOwner
- type AuditLogResource
- type CertificateCA
- type CertificateRequestType
- type CloudflareTunnel
- type CloudflareTunnelConnection
- type CloudflareTunnelStatus
- type CloudflareTunnelTunType
- type Error
- type ErrorData
- type MemberParam
- type MemberRoleParam
- type MemberRolesPermissionsParam
- type MemberStatus
- type MemberUserParam
- type PageRule
- type PageRuleStatus
- type PageruleDeleteResponse
- type PageruleDeleteResponseEnvelope
- type PageruleDeleteResponseEnvelopeSuccess
- type PageruleEditParams
- type PageruleEditParamsStatus
- type PageruleEditResponseEnvelope
- type PageruleEditResponseEnvelopeSuccess
- type PageruleEditResponseUnion
- type PageruleGetResponseEnvelope
- type PageruleGetResponseEnvelopeSuccess
- type PageruleGetResponseUnion
- type PageruleListParams
- type PageruleListParamsDirection
- type PageruleListParamsMatch
- type PageruleListParamsOrder
- type PageruleListParamsStatus
- type PageruleListResponseEnvelope
- type PageruleListResponseEnvelopeSuccess
- type PageruleNewParams
- type PageruleNewParamsStatus
- type PageruleNewResponseEnvelope
- type PageruleNewResponseEnvelopeSuccess
- type PageruleNewResponseUnion
- type PageruleService
- func (r *PageruleService) Delete(ctx context.Context, zoneID string, pageruleID string, ...) (res *PageruleDeleteResponse, err error)deprecated
- func (r *PageruleService) Edit(ctx context.Context, zoneID string, pageruleID string, body PageruleEditParams, ...) (res *PageruleEditResponseUnion, err error)deprecated
- func (r *PageruleService) Get(ctx context.Context, zoneID string, pageruleID string, ...) (res *PageruleGetResponseUnion, err error)deprecated
- func (r *PageruleService) List(ctx context.Context, zoneID string, query PageruleListParams, ...) (res *[]PageRule, err error)deprecated
- func (r *PageruleService) New(ctx context.Context, zoneID string, body PageruleNewParams, ...) (res *PageruleNewResponseUnion, err error)deprecated
- func (r *PageruleService) Update(ctx context.Context, zoneID string, pageruleID string, ...) (res *PageruleUpdateResponseUnion, err error)deprecated
- type PageruleUpdateParams
- type PageruleUpdateParamsStatus
- type PageruleUpdateResponseEnvelope
- type PageruleUpdateResponseEnvelopeSuccess
- type PageruleUpdateResponseUnion
- type Permission
- type PermissionGrant
- type PermissionGrantParam
- type ResponseInfo
- type Role
- type Route
- type RouteName
- type RouteParam
- type RouteValue
- type RouteValueParam
- type RouteValueType
- type SettingListResponse
- type SettingListResponseEnvelope
- type SettingListResponseEnvelopeSuccess
- type SettingService
- type SortDirection
- type Target
- type TargetConstraint
- type TargetConstraintOperator
- type TargetConstraintParam
- type TargetParam
- type TargetTarget
Constants ¶
const AuditLogActorTypeAdmin = shared.AuditLogActorTypeAdmin
This is an alias to an internal value.
const AuditLogActorTypeCloudflare = shared.AuditLogActorTypeCloudflare
This is an alias to an internal value.
const AuditLogActorTypeUser = shared.AuditLogActorTypeUser
This is an alias to an internal value.
const CertificateCADigicert = shared.CertificateCADigicert
This is an alias to an internal value.
const CertificateCAGoogle = shared.CertificateCAGoogle
This is an alias to an internal value.
const CertificateCALetsEncrypt = shared.CertificateCALetsEncrypt
This is an alias to an internal value.
const CertificateRequestTypeKeylessCertificate = shared.CertificateRequestTypeKeylessCertificate
This is an alias to an internal value.
const CertificateRequestTypeOriginECC = shared.CertificateRequestTypeOriginECC
This is an alias to an internal value.
const CertificateRequestTypeOriginRSA = shared.CertificateRequestTypeOriginRSA
This is an alias to an internal value.
const CloudflareTunnelStatusDegraded = shared.CloudflareTunnelStatusDegraded
This is an alias to an internal value.
const CloudflareTunnelStatusDown = shared.CloudflareTunnelStatusDown
This is an alias to an internal value.
const CloudflareTunnelStatusHealthy = shared.CloudflareTunnelStatusHealthy
This is an alias to an internal value.
const CloudflareTunnelStatusInactive = shared.CloudflareTunnelStatusInactive
This is an alias to an internal value.
const CloudflareTunnelTunTypeCNI = shared.CloudflareTunnelTunTypeCNI
This is an alias to an internal value.
const CloudflareTunnelTunTypeCfdTunnel = shared.CloudflareTunnelTunTypeCfdTunnel
This is an alias to an internal value.
const CloudflareTunnelTunTypeGRE = shared.CloudflareTunnelTunTypeGRE
This is an alias to an internal value.
const CloudflareTunnelTunTypeIPSec = shared.CloudflareTunnelTunTypeIPSec
This is an alias to an internal value.
const CloudflareTunnelTunTypeWARPConnector = shared.CloudflareTunnelTunTypeWARPConnector
This is an alias to an internal value.
const MemberStatusAccepted = shared.MemberStatusAccepted
This is an alias to an internal value.
const MemberStatusPending = shared.MemberStatusPending
This is an alias to an internal value.
const SortDirectionAsc = shared.SortDirectionAsc
This is an alias to an internal value.
const SortDirectionDesc = shared.SortDirectionDesc
This is an alias to an internal value.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AuditLogAction ¶
type AuditLogAction = shared.AuditLogAction
This is an alias to an internal type.
type AuditLogActor ¶
type AuditLogActor = shared.AuditLogActor
This is an alias to an internal type.
type AuditLogActorType ¶
type AuditLogActorType = shared.AuditLogActorType
The type of actor, whether a User, Cloudflare Admin, or an Automated System.
This is an alias to an internal type.
type AuditLogOwner ¶
type AuditLogOwner = shared.AuditLogOwner
This is an alias to an internal type.
type AuditLogResource ¶
type AuditLogResource = shared.AuditLogResource
This is an alias to an internal type.
type CertificateCA ¶
type CertificateCA = shared.CertificateCA
The Certificate Authority that will issue the certificate
This is an alias to an internal type.
type CertificateRequestType ¶
type CertificateRequestType = shared.CertificateRequestType
Signature type desired on certificate ("origin-rsa" (rsa), "origin-ecc" (ecdsa), or "keyless-certificate" (for Keyless SSL servers).
This is an alias to an internal type.
type CloudflareTunnel ¶
type CloudflareTunnel = shared.CloudflareTunnel
A Cloudflare Tunnel that connects your origin to Cloudflare's edge.
This is an alias to an internal type.
type CloudflareTunnelConnection ¶
type CloudflareTunnelConnection = shared.CloudflareTunnelConnection
This is an alias to an internal type.
type CloudflareTunnelStatus ¶
type CloudflareTunnelStatus = shared.CloudflareTunnelStatus
The status of the tunnel. Valid values are `inactive` (tunnel has never been run), `degraded` (tunnel is active and able to serve traffic but in an unhealthy state), `healthy` (tunnel is active and able to serve traffic), or `down` (tunnel can not serve traffic as it has no connections to the Cloudflare Edge).
This is an alias to an internal type.
type CloudflareTunnelTunType ¶
type CloudflareTunnelTunType = shared.CloudflareTunnelTunType
The type of tunnel.
This is an alias to an internal type.
type MemberRoleParam ¶
type MemberRoleParam = shared.MemberRoleParam
This is an alias to an internal type.
type MemberRolesPermissionsParam ¶
type MemberRolesPermissionsParam = shared.MemberRolesPermissionsParam
This is an alias to an internal type.
type MemberStatus ¶
type MemberStatus = shared.MemberStatus
A member's status in the account.
This is an alias to an internal type.
type MemberUserParam ¶
type MemberUserParam = shared.MemberUserParam
Details of the user associated to the membership.
This is an alias to an internal type.
type PageRule ¶
type PageRule struct { // Identifier ID string `json:"id,required"` // The set of actions to perform if the targets of this rule match the request. // Actions can redirect to another URL or override settings, but not both. Actions []Route `json:"actions,required"` // The timestamp of when the Page Rule was created. CreatedOn time.Time `json:"created_on,required" format:"date-time"` // The timestamp of when the Page Rule was last modified. ModifiedOn time.Time `json:"modified_on,required" format:"date-time"` // The priority of the rule, used to define which Page Rule is processed over // another. A higher number indicates a higher priority. For example, if you have a // catch-all Page Rule (rule A: `/images/*`) but want a more specific Page Rule to // take precedence (rule B: `/images/special/*`), specify a higher priority for // rule B so it overrides rule A. Priority int64 `json:"priority,required"` // The status of the Page Rule. Status PageRuleStatus `json:"status,required"` // The rule targets to evaluate on each request. Targets []Target `json:"targets,required"` JSON pageRuleJSON `json:"-"` }
func (*PageRule) UnmarshalJSON ¶
type PageRuleStatus ¶
type PageRuleStatus string
The status of the Page Rule.
const ( PageRuleStatusActive PageRuleStatus = "active" PageRuleStatusDisabled PageRuleStatus = "disabled" )
func (PageRuleStatus) IsKnown ¶
func (r PageRuleStatus) IsKnown() bool
type PageruleDeleteResponse ¶
type PageruleDeleteResponse struct { // Identifier ID string `json:"id,required"` JSON pageruleDeleteResponseJSON `json:"-"` }
func (*PageruleDeleteResponse) UnmarshalJSON ¶
func (r *PageruleDeleteResponse) UnmarshalJSON(data []byte) (err error)
type PageruleDeleteResponseEnvelope ¶
type PageruleDeleteResponseEnvelope struct { Errors []shared.ResponseInfo `json:"errors,required"` Messages []shared.ResponseInfo `json:"messages,required"` Result PageruleDeleteResponse `json:"result,required,nullable"` // Whether the API call was successful Success PageruleDeleteResponseEnvelopeSuccess `json:"success,required"` JSON pageruleDeleteResponseEnvelopeJSON `json:"-"` }
func (*PageruleDeleteResponseEnvelope) UnmarshalJSON ¶
func (r *PageruleDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type PageruleDeleteResponseEnvelopeSuccess ¶
type PageruleDeleteResponseEnvelopeSuccess bool
Whether the API call was successful
const (
PageruleDeleteResponseEnvelopeSuccessTrue PageruleDeleteResponseEnvelopeSuccess = true
)
func (PageruleDeleteResponseEnvelopeSuccess) IsKnown ¶
func (r PageruleDeleteResponseEnvelopeSuccess) IsKnown() bool
type PageruleEditParams ¶
type PageruleEditParams struct { // The set of actions to perform if the targets of this rule match the request. // Actions can redirect to another URL or override settings, but not both. Actions param.Field[[]RouteParam] `json:"actions"` // The priority of the rule, used to define which Page Rule is processed over // another. A higher number indicates a higher priority. For example, if you have a // catch-all Page Rule (rule A: `/images/*`) but want a more specific Page Rule to // take precedence (rule B: `/images/special/*`), specify a higher priority for // rule B so it overrides rule A. Priority param.Field[int64] `json:"priority"` // The status of the Page Rule. Status param.Field[PageruleEditParamsStatus] `json:"status"` // The rule targets to evaluate on each request. Targets param.Field[[]TargetParam] `json:"targets"` }
func (PageruleEditParams) MarshalJSON ¶
func (r PageruleEditParams) MarshalJSON() (data []byte, err error)
type PageruleEditParamsStatus ¶
type PageruleEditParamsStatus string
The status of the Page Rule.
const ( PageruleEditParamsStatusActive PageruleEditParamsStatus = "active" PageruleEditParamsStatusDisabled PageruleEditParamsStatus = "disabled" )
func (PageruleEditParamsStatus) IsKnown ¶
func (r PageruleEditParamsStatus) IsKnown() bool
type PageruleEditResponseEnvelope ¶
type PageruleEditResponseEnvelope struct { Errors []shared.ResponseInfo `json:"errors,required"` Messages []shared.ResponseInfo `json:"messages,required"` Result PageruleEditResponseUnion `json:"result,required"` // Whether the API call was successful Success PageruleEditResponseEnvelopeSuccess `json:"success,required"` JSON pageruleEditResponseEnvelopeJSON `json:"-"` }
func (*PageruleEditResponseEnvelope) UnmarshalJSON ¶
func (r *PageruleEditResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type PageruleEditResponseEnvelopeSuccess ¶
type PageruleEditResponseEnvelopeSuccess bool
Whether the API call was successful
const (
PageruleEditResponseEnvelopeSuccessTrue PageruleEditResponseEnvelopeSuccess = true
)
func (PageruleEditResponseEnvelopeSuccess) IsKnown ¶
func (r PageruleEditResponseEnvelopeSuccess) IsKnown() bool
type PageruleEditResponseUnion ¶
type PageruleEditResponseUnion interface {
ImplementsPagerulesPageruleEditResponseUnion()
}
Union satisfied by pagerules.PageruleEditResponseUnknown or shared.UnionString.
type PageruleGetResponseEnvelope ¶
type PageruleGetResponseEnvelope struct { Errors []shared.ResponseInfo `json:"errors,required"` Messages []shared.ResponseInfo `json:"messages,required"` Result PageruleGetResponseUnion `json:"result,required"` // Whether the API call was successful Success PageruleGetResponseEnvelopeSuccess `json:"success,required"` JSON pageruleGetResponseEnvelopeJSON `json:"-"` }
func (*PageruleGetResponseEnvelope) UnmarshalJSON ¶
func (r *PageruleGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type PageruleGetResponseEnvelopeSuccess ¶
type PageruleGetResponseEnvelopeSuccess bool
Whether the API call was successful
const (
PageruleGetResponseEnvelopeSuccessTrue PageruleGetResponseEnvelopeSuccess = true
)
func (PageruleGetResponseEnvelopeSuccess) IsKnown ¶
func (r PageruleGetResponseEnvelopeSuccess) IsKnown() bool
type PageruleGetResponseUnion ¶
type PageruleGetResponseUnion interface {
ImplementsPagerulesPageruleGetResponseUnion()
}
Union satisfied by pagerules.PageruleGetResponseUnknown or shared.UnionString.
type PageruleListParams ¶
type PageruleListParams struct { // The direction used to sort returned Page Rules. Direction param.Field[PageruleListParamsDirection] `query:"direction"` // When set to `all`, all the search requirements must match. When set to `any`, // only one of the search requirements has to match. Match param.Field[PageruleListParamsMatch] `query:"match"` // The field used to sort returned Page Rules. Order param.Field[PageruleListParamsOrder] `query:"order"` // The status of the Page Rule. Status param.Field[PageruleListParamsStatus] `query:"status"` }
func (PageruleListParams) URLQuery ¶
func (r PageruleListParams) URLQuery() (v url.Values)
URLQuery serializes PageruleListParams's query parameters as `url.Values`.
type PageruleListParamsDirection ¶
type PageruleListParamsDirection string
The direction used to sort returned Page Rules.
const ( PageruleListParamsDirectionAsc PageruleListParamsDirection = "asc" PageruleListParamsDirectionDesc PageruleListParamsDirection = "desc" )
func (PageruleListParamsDirection) IsKnown ¶
func (r PageruleListParamsDirection) IsKnown() bool
type PageruleListParamsMatch ¶
type PageruleListParamsMatch string
When set to `all`, all the search requirements must match. When set to `any`, only one of the search requirements has to match.
const ( PageruleListParamsMatchAny PageruleListParamsMatch = "any" PageruleListParamsMatchAll PageruleListParamsMatch = "all" )
func (PageruleListParamsMatch) IsKnown ¶
func (r PageruleListParamsMatch) IsKnown() bool
type PageruleListParamsOrder ¶
type PageruleListParamsOrder string
The field used to sort returned Page Rules.
const ( PageruleListParamsOrderStatus PageruleListParamsOrder = "status" PageruleListParamsOrderPriority PageruleListParamsOrder = "priority" )
func (PageruleListParamsOrder) IsKnown ¶
func (r PageruleListParamsOrder) IsKnown() bool
type PageruleListParamsStatus ¶
type PageruleListParamsStatus string
The status of the Page Rule.
const ( PageruleListParamsStatusActive PageruleListParamsStatus = "active" PageruleListParamsStatusDisabled PageruleListParamsStatus = "disabled" )
func (PageruleListParamsStatus) IsKnown ¶
func (r PageruleListParamsStatus) IsKnown() bool
type PageruleListResponseEnvelope ¶
type PageruleListResponseEnvelope struct { Errors []shared.ResponseInfo `json:"errors,required"` Messages []shared.ResponseInfo `json:"messages,required"` Result []PageRule `json:"result,required"` // Whether the API call was successful Success PageruleListResponseEnvelopeSuccess `json:"success,required"` JSON pageruleListResponseEnvelopeJSON `json:"-"` }
func (*PageruleListResponseEnvelope) UnmarshalJSON ¶
func (r *PageruleListResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type PageruleListResponseEnvelopeSuccess ¶
type PageruleListResponseEnvelopeSuccess bool
Whether the API call was successful
const (
PageruleListResponseEnvelopeSuccessTrue PageruleListResponseEnvelopeSuccess = true
)
func (PageruleListResponseEnvelopeSuccess) IsKnown ¶
func (r PageruleListResponseEnvelopeSuccess) IsKnown() bool
type PageruleNewParams ¶
type PageruleNewParams struct { // The set of actions to perform if the targets of this rule match the request. // Actions can redirect to another URL or override settings, but not both. Actions param.Field[[]RouteParam] `json:"actions,required"` // The rule targets to evaluate on each request. Targets param.Field[[]TargetParam] `json:"targets,required"` // The priority of the rule, used to define which Page Rule is processed over // another. A higher number indicates a higher priority. For example, if you have a // catch-all Page Rule (rule A: `/images/*`) but want a more specific Page Rule to // take precedence (rule B: `/images/special/*`), specify a higher priority for // rule B so it overrides rule A. Priority param.Field[int64] `json:"priority"` // The status of the Page Rule. Status param.Field[PageruleNewParamsStatus] `json:"status"` }
func (PageruleNewParams) MarshalJSON ¶
func (r PageruleNewParams) MarshalJSON() (data []byte, err error)
type PageruleNewParamsStatus ¶
type PageruleNewParamsStatus string
The status of the Page Rule.
const ( PageruleNewParamsStatusActive PageruleNewParamsStatus = "active" PageruleNewParamsStatusDisabled PageruleNewParamsStatus = "disabled" )
func (PageruleNewParamsStatus) IsKnown ¶
func (r PageruleNewParamsStatus) IsKnown() bool
type PageruleNewResponseEnvelope ¶
type PageruleNewResponseEnvelope struct { Errors []shared.ResponseInfo `json:"errors,required"` Messages []shared.ResponseInfo `json:"messages,required"` Result PageruleNewResponseUnion `json:"result,required"` // Whether the API call was successful Success PageruleNewResponseEnvelopeSuccess `json:"success,required"` JSON pageruleNewResponseEnvelopeJSON `json:"-"` }
func (*PageruleNewResponseEnvelope) UnmarshalJSON ¶
func (r *PageruleNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type PageruleNewResponseEnvelopeSuccess ¶
type PageruleNewResponseEnvelopeSuccess bool
Whether the API call was successful
const (
PageruleNewResponseEnvelopeSuccessTrue PageruleNewResponseEnvelopeSuccess = true
)
func (PageruleNewResponseEnvelopeSuccess) IsKnown ¶
func (r PageruleNewResponseEnvelopeSuccess) IsKnown() bool
type PageruleNewResponseUnion ¶
type PageruleNewResponseUnion interface {
ImplementsPagerulesPageruleNewResponseUnion()
}
Union satisfied by pagerules.PageruleNewResponseUnknown or shared.UnionString.
type PageruleService ¶
type PageruleService struct { Options []option.RequestOption Settings *SettingService }
PageruleService contains methods and other services that help with interacting with the testcloudflare 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 NewPageruleService method instead.
func NewPageruleService ¶
func NewPageruleService(opts ...option.RequestOption) (r *PageruleService)
NewPageruleService 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 (*PageruleService) Delete
deprecated
func (r *PageruleService) Delete(ctx context.Context, zoneID string, pageruleID string, opts ...option.RequestOption) (res *PageruleDeleteResponse, err error)
Deletes an existing Page Rule.
Deprecated: The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
func (*PageruleService) Edit
deprecated
func (r *PageruleService) Edit(ctx context.Context, zoneID string, pageruleID string, body PageruleEditParams, opts ...option.RequestOption) (res *PageruleEditResponseUnion, err error)
Updates one or more fields of an existing Page Rule.
Deprecated: The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
func (*PageruleService) Get
deprecated
func (r *PageruleService) Get(ctx context.Context, zoneID string, pageruleID string, opts ...option.RequestOption) (res *PageruleGetResponseUnion, err error)
Fetches the details of a Page Rule.
Deprecated: The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
func (*PageruleService) List
deprecated
func (r *PageruleService) List(ctx context.Context, zoneID string, query PageruleListParams, opts ...option.RequestOption) (res *[]PageRule, err error)
Fetches Page Rules in a zone.
Deprecated: The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
func (*PageruleService) New
deprecated
func (r *PageruleService) New(ctx context.Context, zoneID string, body PageruleNewParams, opts ...option.RequestOption) (res *PageruleNewResponseUnion, err error)
Creates a new Page Rule.
Deprecated: The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
func (*PageruleService) Update
deprecated
func (r *PageruleService) Update(ctx context.Context, zoneID string, pageruleID string, body PageruleUpdateParams, opts ...option.RequestOption) (res *PageruleUpdateResponseUnion, err error)
Replaces the configuration of an existing Page Rule. The configuration of the updated Page Rule will exactly match the data passed in the API request.
Deprecated: The Page Rules API is deprecated in favour of the Ruleset Engine. See https://developers.cloudflare.com/fundamentals/api/reference/deprecations/#page-rules for full details.
type PageruleUpdateParams ¶
type PageruleUpdateParams struct { // The set of actions to perform if the targets of this rule match the request. // Actions can redirect to another URL or override settings, but not both. Actions param.Field[[]RouteParam] `json:"actions,required"` // The rule targets to evaluate on each request. Targets param.Field[[]TargetParam] `json:"targets,required"` // The priority of the rule, used to define which Page Rule is processed over // another. A higher number indicates a higher priority. For example, if you have a // catch-all Page Rule (rule A: `/images/*`) but want a more specific Page Rule to // take precedence (rule B: `/images/special/*`), specify a higher priority for // rule B so it overrides rule A. Priority param.Field[int64] `json:"priority"` // The status of the Page Rule. Status param.Field[PageruleUpdateParamsStatus] `json:"status"` }
func (PageruleUpdateParams) MarshalJSON ¶
func (r PageruleUpdateParams) MarshalJSON() (data []byte, err error)
type PageruleUpdateParamsStatus ¶
type PageruleUpdateParamsStatus string
The status of the Page Rule.
const ( PageruleUpdateParamsStatusActive PageruleUpdateParamsStatus = "active" PageruleUpdateParamsStatusDisabled PageruleUpdateParamsStatus = "disabled" )
func (PageruleUpdateParamsStatus) IsKnown ¶
func (r PageruleUpdateParamsStatus) IsKnown() bool
type PageruleUpdateResponseEnvelope ¶
type PageruleUpdateResponseEnvelope struct { Errors []shared.ResponseInfo `json:"errors,required"` Messages []shared.ResponseInfo `json:"messages,required"` Result PageruleUpdateResponseUnion `json:"result,required"` // Whether the API call was successful Success PageruleUpdateResponseEnvelopeSuccess `json:"success,required"` JSON pageruleUpdateResponseEnvelopeJSON `json:"-"` }
func (*PageruleUpdateResponseEnvelope) UnmarshalJSON ¶
func (r *PageruleUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type PageruleUpdateResponseEnvelopeSuccess ¶
type PageruleUpdateResponseEnvelopeSuccess bool
Whether the API call was successful
const (
PageruleUpdateResponseEnvelopeSuccessTrue PageruleUpdateResponseEnvelopeSuccess = true
)
func (PageruleUpdateResponseEnvelopeSuccess) IsKnown ¶
func (r PageruleUpdateResponseEnvelopeSuccess) IsKnown() bool
type PageruleUpdateResponseUnion ¶
type PageruleUpdateResponseUnion interface {
ImplementsPagerulesPageruleUpdateResponseUnion()
}
Union satisfied by pagerules.PageruleUpdateResponseUnknown or shared.UnionString.
type PermissionGrant ¶
type PermissionGrant = shared.PermissionGrant
This is an alias to an internal type.
type PermissionGrantParam ¶
type PermissionGrantParam = shared.PermissionGrantParam
This is an alias to an internal type.
type Route ¶
type Route struct { // The timestamp of when the override was last modified. ModifiedOn time.Time `json:"modified_on" format:"date-time"` // The type of route. Name RouteName `json:"name"` Value RouteValue `json:"value"` JSON routeJSON `json:"-"` }
func (*Route) UnmarshalJSON ¶
type RouteName ¶
type RouteName string
The type of route.
const (
RouteNameForwardURL RouteName = "forward_url"
)
type RouteParam ¶
type RouteParam struct { // The type of route. Name param.Field[RouteName] `json:"name"` Value param.Field[RouteValueParam] `json:"value"` }
func (RouteParam) MarshalJSON ¶
func (r RouteParam) MarshalJSON() (data []byte, err error)
type RouteValue ¶
type RouteValue struct { // The response type for the URL redirect. Type RouteValueType `json:"type"` // The URL to redirect the request to. Notes: ${num} refers to the position of '\*' // in the constraint value. URL string `json:"url"` JSON routeValueJSON `json:"-"` }
func (*RouteValue) UnmarshalJSON ¶
func (r *RouteValue) UnmarshalJSON(data []byte) (err error)
type RouteValueParam ¶
type RouteValueParam struct { // The response type for the URL redirect. Type param.Field[RouteValueType] `json:"type"` // The URL to redirect the request to. Notes: ${num} refers to the position of '\*' // in the constraint value. URL param.Field[string] `json:"url"` }
func (RouteValueParam) MarshalJSON ¶
func (r RouteValueParam) MarshalJSON() (data []byte, err error)
type RouteValueType ¶
type RouteValueType string
The response type for the URL redirect.
const ( RouteValueTypeTemporary RouteValueType = "temporary" RouteValueTypePermanent RouteValueType = "permanent" )
func (RouteValueType) IsKnown ¶
func (r RouteValueType) IsKnown() bool
type SettingListResponse ¶
type SettingListResponse = interface{}
type SettingListResponseEnvelope ¶
type SettingListResponseEnvelope struct { Errors []shared.ResponseInfo `json:"errors,required"` Messages []shared.ResponseInfo `json:"messages,required"` // Settings available for the zone. Result []SettingListResponse `json:"result,required"` // Whether the API call was successful Success SettingListResponseEnvelopeSuccess `json:"success,required"` JSON settingListResponseEnvelopeJSON `json:"-"` }
func (*SettingListResponseEnvelope) UnmarshalJSON ¶
func (r *SettingListResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type SettingListResponseEnvelopeSuccess ¶
type SettingListResponseEnvelopeSuccess bool
Whether the API call was successful
const (
SettingListResponseEnvelopeSuccessTrue SettingListResponseEnvelopeSuccess = true
)
func (SettingListResponseEnvelopeSuccess) IsKnown ¶
func (r SettingListResponseEnvelopeSuccess) IsKnown() bool
type SettingService ¶
type SettingService struct {
Options []option.RequestOption
}
SettingService contains methods and other services that help with interacting with the testcloudflare 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 NewSettingService method instead.
func NewSettingService ¶
func NewSettingService(opts ...option.RequestOption) (r *SettingService)
NewSettingService 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 (*SettingService) List ¶
func (r *SettingService) List(ctx context.Context, zoneID string, opts ...option.RequestOption) (res *[]SettingListResponse, err error)
Returns a list of settings (and their details) that Page Rules can apply to matching requests.
type SortDirection ¶
type SortDirection = shared.SortDirection
Direction to order DNS records in.
This is an alias to an internal type.
type Target ¶
type Target struct { // String constraint. Constraint TargetConstraint `json:"constraint"` // A target based on the URL of the request. Target TargetTarget `json:"target"` JSON targetJSON `json:"-"` }
URL target.
func (*Target) UnmarshalJSON ¶
type TargetConstraint ¶
type TargetConstraint struct { // The matches operator can use asterisks and pipes as wildcard and 'or' operators. Operator TargetConstraintOperator `json:"operator,required"` // The URL pattern to match against the current request. The pattern may contain up // to four asterisks ('\*') as placeholders. Value string `json:"value,required"` JSON targetConstraintJSON `json:"-"` }
String constraint.
func (*TargetConstraint) UnmarshalJSON ¶
func (r *TargetConstraint) UnmarshalJSON(data []byte) (err error)
type TargetConstraintOperator ¶
type TargetConstraintOperator string
The matches operator can use asterisks and pipes as wildcard and 'or' operators.
const ( TargetConstraintOperatorMatches TargetConstraintOperator = "matches" TargetConstraintOperatorContains TargetConstraintOperator = "contains" TargetConstraintOperatorEquals TargetConstraintOperator = "equals" TargetConstraintOperatorNotEqual TargetConstraintOperator = "not_equal" TargetConstraintOperatorNotContain TargetConstraintOperator = "not_contain" )
func (TargetConstraintOperator) IsKnown ¶
func (r TargetConstraintOperator) IsKnown() bool
type TargetConstraintParam ¶
type TargetConstraintParam struct { // The matches operator can use asterisks and pipes as wildcard and 'or' operators. Operator param.Field[TargetConstraintOperator] `json:"operator,required"` // The URL pattern to match against the current request. The pattern may contain up // to four asterisks ('\*') as placeholders. Value param.Field[string] `json:"value,required"` }
String constraint.
func (TargetConstraintParam) MarshalJSON ¶
func (r TargetConstraintParam) MarshalJSON() (data []byte, err error)
type TargetParam ¶
type TargetParam struct { // String constraint. Constraint param.Field[TargetConstraintParam] `json:"constraint"` // A target based on the URL of the request. Target param.Field[TargetTarget] `json:"target"` }
URL target.
func (TargetParam) MarshalJSON ¶
func (r TargetParam) MarshalJSON() (data []byte, err error)
type TargetTarget ¶
type TargetTarget string
A target based on the URL of the request.
const (
TargetTargetURL TargetTarget = "url"
)
func (TargetTarget) IsKnown ¶
func (r TargetTarget) IsKnown() bool