Documentation
¶
Index ¶
- Constants
- type ASN
- type ASNParam
- type AuditLog
- type AuditLogAction
- type AuditLogActor
- type AuditLogActorType
- type AuditLogOwner
- type AuditLogResource
- type BotFightModeConfiguration
- type BotFightModeConfigurationAIBotsProtection
- type BotFightModeConfigurationCrawlerProtection
- type BotFightModeConfigurationParam
- type BotFightModeConfigurationStaleZoneConfiguration
- type BotFightModeConfigurationStaleZoneConfigurationParam
- type BotManagementGetParams
- type BotManagementGetResponse
- type BotManagementGetResponseAIBotsProtection
- type BotManagementGetResponseCrawlerProtection
- type BotManagementGetResponseEnvelope
- type BotManagementGetResponseEnvelopeErrors
- type BotManagementGetResponseEnvelopeErrorsSource
- type BotManagementGetResponseEnvelopeMessages
- type BotManagementGetResponseEnvelopeMessagesSource
- type BotManagementGetResponseEnvelopeSuccess
- type BotManagementGetResponseSBFMDefinitelyAutomated
- type BotManagementGetResponseSBFMLikelyAutomated
- type BotManagementGetResponseSBFMVerifiedBots
- type BotManagementGetResponseUnion
- type BotManagementService
- type BotManagementUpdateParams
- type BotManagementUpdateParamsBody
- type BotManagementUpdateParamsBodyAIBotsProtection
- type BotManagementUpdateParamsBodyCrawlerProtection
- type BotManagementUpdateParamsBodySBFMDefinitelyAutomated
- type BotManagementUpdateParamsBodySBFMLikelyAutomated
- type BotManagementUpdateParamsBodySBFMVerifiedBots
- type BotManagementUpdateParamsBodyUnion
- type BotManagementUpdateResponse
- type BotManagementUpdateResponseAIBotsProtection
- type BotManagementUpdateResponseCrawlerProtection
- type BotManagementUpdateResponseEnvelope
- type BotManagementUpdateResponseEnvelopeErrors
- type BotManagementUpdateResponseEnvelopeErrorsSource
- type BotManagementUpdateResponseEnvelopeMessages
- type BotManagementUpdateResponseEnvelopeMessagesSource
- type BotManagementUpdateResponseEnvelopeSuccess
- type BotManagementUpdateResponseSBFMDefinitelyAutomated
- type BotManagementUpdateResponseSBFMLikelyAutomated
- type BotManagementUpdateResponseSBFMVerifiedBots
- type BotManagementUpdateResponseUnion
- type CertificateCA
- type CertificateRequestType
- type CloudflareTunnel
- type CloudflareTunnelConfigSrc
- type CloudflareTunnelConnection
- type CloudflareTunnelStatus
- type CloudflareTunnelTunType
- type Error
- type ErrorData
- type ErrorDataSource
- type Member
- type MemberPoliciesAccess
- type MemberPoliciesPermissionGroup
- type MemberPoliciesPermissionGroupsMeta
- type MemberPoliciesResourceGroup
- type MemberPoliciesResourceGroupsMeta
- type MemberPoliciesResourceGroupsScope
- type MemberPoliciesResourceGroupsScopeObject
- type MemberPolicy
- type MemberStatus
- type MemberUser
- type Permission
- type PermissionGrant
- type PermissionGrantParam
- type RatePlan
- type RatePlanID
- type RatePlanParam
- type ResponseInfo
- type ResponseInfoSource
- type Role
- type RoleParam
- type RolePermissions
- type RolePermissionsParam
- type SortDirection
- type Subscription
- type SubscriptionConfiguration
- type SubscriptionConfigurationAIBotsProtection
- type SubscriptionConfigurationCrawlerProtection
- type SubscriptionConfigurationParam
- type SubscriptionConfigurationStaleZoneConfiguration
- type SubscriptionConfigurationStaleZoneConfigurationParam
- type SubscriptionFrequency
- type SubscriptionParam
- type SubscriptionState
- type SuperBotFightModeDefinitelyConfiguration
- type SuperBotFightModeDefinitelyConfigurationAIBotsProtection
- type SuperBotFightModeDefinitelyConfigurationCrawlerProtection
- type SuperBotFightModeDefinitelyConfigurationParam
- type SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomated
- type SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBots
- type SuperBotFightModeDefinitelyConfigurationStaleZoneConfiguration
- type SuperBotFightModeDefinitelyConfigurationStaleZoneConfigurationParam
- type SuperBotFightModeLikelyConfiguration
- type SuperBotFightModeLikelyConfigurationAIBotsProtection
- type SuperBotFightModeLikelyConfigurationCrawlerProtection
- type SuperBotFightModeLikelyConfigurationParam
- type SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomated
- type SuperBotFightModeLikelyConfigurationSBFMLikelyAutomated
- type SuperBotFightModeLikelyConfigurationSBFMVerifiedBots
- type SuperBotFightModeLikelyConfigurationStaleZoneConfiguration
- type SuperBotFightModeLikelyConfigurationStaleZoneConfigurationParam
- type Token
- type TokenCondition
- type TokenConditionCIDRList
- type TokenConditionCIDRListParam
- type TokenConditionParam
- type TokenConditionRequestIP
- type TokenConditionRequestIPParam
- type TokenParam
- type TokenPolicy
- type TokenPolicyEffect
- type TokenPolicyParam
- type TokenPolicyPermissionGroup
- type TokenPolicyPermissionGroupParam
- type TokenPolicyPermissionGroupsMeta
- type TokenPolicyPermissionGroupsMetaParam
- type TokenPolicyResourcesIAMResourcesTypeObjectNested
- type TokenPolicyResourcesIAMResourcesTypeObjectNestedParam
- type TokenPolicyResourcesIAMResourcesTypeObjectString
- type TokenPolicyResourcesIAMResourcesTypeObjectStringParam
- type TokenPolicyResourcesUnion
- type TokenPolicyResourcesUnionParam
- type TokenStatus
- type TokenValue
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 CertificateCASSLCom = shared.CertificateCASSLCom
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 CloudflareTunnelConfigSrcCloudflare = shared.CloudflareTunnelConfigSrcCloudflare
This is an alias to an internal value.
const CloudflareTunnelConfigSrcLocal = shared.CloudflareTunnelConfigSrcLocal
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 CloudflareTunnelTunTypeMagic = shared.CloudflareTunnelTunTypeMagic
This is an alias to an internal value.
const CloudflareTunnelTunTypeWARP = shared.CloudflareTunnelTunTypeWARP
This is an alias to an internal value.
const CloudflareTunnelTunTypeWARPConnector = shared.CloudflareTunnelTunTypeWARPConnector
This is an alias to an internal value.
const MemberPoliciesAccessAllow = shared.MemberPoliciesAccessAllow
This is an alias to an internal value.
const MemberPoliciesAccessDeny = shared.MemberPoliciesAccessDeny
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 RatePlanIDBusiness = shared.RatePlanIDBusiness
This is an alias to an internal value.
const RatePlanIDEnterprise = shared.RatePlanIDEnterprise
This is an alias to an internal value.
const RatePlanIDFree = shared.RatePlanIDFree
This is an alias to an internal value.
const RatePlanIDLite = shared.RatePlanIDLite
This is an alias to an internal value.
const RatePlanIDPartnersBusiness = shared.RatePlanIDPartnersBusiness
This is an alias to an internal value.
const RatePlanIDPartnersEnterprise = shared.RatePlanIDPartnersEnterprise
This is an alias to an internal value.
const RatePlanIDPartnersFree = shared.RatePlanIDPartnersFree
This is an alias to an internal value.
const RatePlanIDPartnersPro = shared.RatePlanIDPartnersPro
This is an alias to an internal value.
const RatePlanIDPro = shared.RatePlanIDPro
This is an alias to an internal value.
const RatePlanIDProPlus = shared.RatePlanIDProPlus
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.
const SubscriptionFrequencyMonthly = shared.SubscriptionFrequencyMonthly
This is an alias to an internal value.
const SubscriptionFrequencyQuarterly = shared.SubscriptionFrequencyQuarterly
This is an alias to an internal value.
const SubscriptionFrequencyWeekly = shared.SubscriptionFrequencyWeekly
This is an alias to an internal value.
const SubscriptionFrequencyYearly = shared.SubscriptionFrequencyYearly
This is an alias to an internal value.
const SubscriptionStateAwaitingPayment = shared.SubscriptionStateAwaitingPayment
This is an alias to an internal value.
const SubscriptionStateCancelled = shared.SubscriptionStateCancelled
This is an alias to an internal value.
const SubscriptionStateExpired = shared.SubscriptionStateExpired
This is an alias to an internal value.
const SubscriptionStateFailed = shared.SubscriptionStateFailed
This is an alias to an internal value.
const SubscriptionStatePaid = shared.SubscriptionStatePaid
This is an alias to an internal value.
const SubscriptionStateProvisioned = shared.SubscriptionStateProvisioned
This is an alias to an internal value.
const SubscriptionStateTrial = shared.SubscriptionStateTrial
This is an alias to an internal value.
const TokenPolicyEffectAllow = shared.TokenPolicyEffectAllow
This is an alias to an internal value.
const TokenPolicyEffectDeny = shared.TokenPolicyEffectDeny
This is an alias to an internal value.
const TokenStatusActive = shared.TokenStatusActive
This is an alias to an internal value.
const TokenStatusDisabled = shared.TokenStatusDisabled
This is an alias to an internal value.
const TokenStatusExpired = shared.TokenStatusExpired
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 BotFightModeConfiguration ¶
type BotFightModeConfiguration struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection BotFightModeConfigurationAIBotsProtection `json:"ai_bots_protection"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection BotFightModeConfigurationCrawlerProtection `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS bool `json:"enable_js"`
// Whether to enable Bot Fight Mode.
FightMode bool `json:"fight_mode"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged bool `json:"is_robots_txt_managed"`
// A read-only field that shows which unauthorized settings are currently active on
// the zone. These settings typically result from upgrades or downgrades.
StaleZoneConfiguration BotFightModeConfigurationStaleZoneConfiguration `json:"stale_zone_configuration"`
// A read-only field that indicates whether the zone currently is running the
// latest ML model.
UsingLatestModel bool `json:"using_latest_model"`
JSON botFightModeConfigurationJSON `json:"-"`
}
func (*BotFightModeConfiguration) UnmarshalJSON ¶
func (r *BotFightModeConfiguration) UnmarshalJSON(data []byte) (err error)
type BotFightModeConfigurationAIBotsProtection ¶
type BotFightModeConfigurationAIBotsProtection string
Enable rule to block AI Scrapers and Crawlers. Please note the value `only_on_ad_pages` is currently not available for Enterprise customers.
const ( BotFightModeConfigurationAIBotsProtectionBlock BotFightModeConfigurationAIBotsProtection = "block" BotFightModeConfigurationAIBotsProtectionDisabled BotFightModeConfigurationAIBotsProtection = "disabled" BotFightModeConfigurationAIBotsProtectionOnlyOnADPages BotFightModeConfigurationAIBotsProtection = "only_on_ad_pages" )
func (BotFightModeConfigurationAIBotsProtection) IsKnown ¶
func (r BotFightModeConfigurationAIBotsProtection) IsKnown() bool
type BotFightModeConfigurationCrawlerProtection ¶
type BotFightModeConfigurationCrawlerProtection string
Enable rule to punish AI Scrapers and Crawlers via a link maze.
const ( BotFightModeConfigurationCrawlerProtectionEnabled BotFightModeConfigurationCrawlerProtection = "enabled" BotFightModeConfigurationCrawlerProtectionDisabled BotFightModeConfigurationCrawlerProtection = "disabled" )
func (BotFightModeConfigurationCrawlerProtection) IsKnown ¶
func (r BotFightModeConfigurationCrawlerProtection) IsKnown() bool
type BotFightModeConfigurationParam ¶
type BotFightModeConfigurationParam struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection param.Field[BotFightModeConfigurationAIBotsProtection] `json:"ai_bots_protection"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection param.Field[BotFightModeConfigurationCrawlerProtection] `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS param.Field[bool] `json:"enable_js"`
// Whether to enable Bot Fight Mode.
FightMode param.Field[bool] `json:"fight_mode"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged param.Field[bool] `json:"is_robots_txt_managed"`
}
func (BotFightModeConfigurationParam) MarshalJSON ¶
func (r BotFightModeConfigurationParam) MarshalJSON() (data []byte, err error)
type BotFightModeConfigurationStaleZoneConfiguration ¶
type BotFightModeConfigurationStaleZoneConfiguration struct {
// Indicates that the zone's wordpress optimization for SBFM is turned on.
OptimizeWordpress bool `json:"optimize_wordpress"`
// Indicates that the zone's definitely automated requests are being blocked or
// challenged.
SBFMDefinitelyAutomated string `json:"sbfm_definitely_automated"`
// Indicates that the zone's likely automated requests are being blocked or
// challenged.
SBFMLikelyAutomated string `json:"sbfm_likely_automated"`
// Indicates that the zone's static resource protection is turned on.
SBFMStaticResourceProtection string `json:"sbfm_static_resource_protection"`
// Indicates that the zone's verified bot requests are being blocked.
SBFMVerifiedBots string `json:"sbfm_verified_bots"`
// Indicates that the zone's session score tracking is disabled.
SuppressSessionScore bool `json:"suppress_session_score"`
JSON botFightModeConfigurationStaleZoneConfigurationJSON `json:"-"`
}
A read-only field that shows which unauthorized settings are currently active on the zone. These settings typically result from upgrades or downgrades.
func (*BotFightModeConfigurationStaleZoneConfiguration) UnmarshalJSON ¶
func (r *BotFightModeConfigurationStaleZoneConfiguration) UnmarshalJSON(data []byte) (err error)
type BotFightModeConfigurationStaleZoneConfigurationParam ¶
type BotFightModeConfigurationStaleZoneConfigurationParam struct {
// Indicates that the zone's wordpress optimization for SBFM is turned on.
OptimizeWordpress param.Field[bool] `json:"optimize_wordpress"`
// Indicates that the zone's definitely automated requests are being blocked or
// challenged.
SBFMDefinitelyAutomated param.Field[string] `json:"sbfm_definitely_automated"`
// Indicates that the zone's likely automated requests are being blocked or
// challenged.
SBFMLikelyAutomated param.Field[string] `json:"sbfm_likely_automated"`
// Indicates that the zone's static resource protection is turned on.
SBFMStaticResourceProtection param.Field[string] `json:"sbfm_static_resource_protection"`
// Indicates that the zone's verified bot requests are being blocked.
SBFMVerifiedBots param.Field[string] `json:"sbfm_verified_bots"`
// Indicates that the zone's session score tracking is disabled.
SuppressSessionScore param.Field[bool] `json:"suppress_session_score"`
}
A read-only field that shows which unauthorized settings are currently active on the zone. These settings typically result from upgrades or downgrades.
func (BotFightModeConfigurationStaleZoneConfigurationParam) MarshalJSON ¶
func (r BotFightModeConfigurationStaleZoneConfigurationParam) MarshalJSON() (data []byte, err error)
type BotManagementGetParams ¶
type BotManagementGetResponse ¶
type BotManagementGetResponse struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection BotManagementGetResponseAIBotsProtection `json:"ai_bots_protection"`
// Automatically update to the newest bot detection models created by Cloudflare as
// they are released.
// [Learn more.](https://developers.cloudflare.com/bots/reference/machine-learning-models#model-versions-and-release-notes)
AutoUpdateModel bool `json:"auto_update_model"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection BotManagementGetResponseCrawlerProtection `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS bool `json:"enable_js"`
// Whether to enable Bot Fight Mode.
FightMode bool `json:"fight_mode"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged bool `json:"is_robots_txt_managed"`
// Whether to optimize Super Bot Fight Mode protections for Wordpress.
OptimizeWordpress bool `json:"optimize_wordpress"`
// Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
SBFMDefinitelyAutomated BotManagementGetResponseSBFMDefinitelyAutomated `json:"sbfm_definitely_automated"`
// Super Bot Fight Mode (SBFM) action to take on likely automated requests.
SBFMLikelyAutomated BotManagementGetResponseSBFMLikelyAutomated `json:"sbfm_likely_automated"`
// Super Bot Fight Mode (SBFM) to enable static resource protection. Enable if
// static resources on your application need bot protection. Note: Static resource
// protection can also result in legitimate traffic being blocked.
SBFMStaticResourceProtection bool `json:"sbfm_static_resource_protection"`
// Super Bot Fight Mode (SBFM) action to take on verified bots requests.
SBFMVerifiedBots BotManagementGetResponseSBFMVerifiedBots `json:"sbfm_verified_bots"`
// This field can have the runtime type of
// [BotFightModeConfigurationStaleZoneConfiguration],
// [SuperBotFightModeDefinitelyConfigurationStaleZoneConfiguration],
// [SuperBotFightModeLikelyConfigurationStaleZoneConfiguration],
// [SubscriptionConfigurationStaleZoneConfiguration].
StaleZoneConfiguration interface{} `json:"stale_zone_configuration"`
// Whether to disable tracking the highest bot score for a session in the Bot
// Management cookie.
SuppressSessionScore bool `json:"suppress_session_score"`
// A read-only field that indicates whether the zone currently is running the
// latest ML model.
UsingLatestModel bool `json:"using_latest_model"`
JSON botManagementGetResponseJSON `json:"-"`
// contains filtered or unexported fields
}
func (BotManagementGetResponse) AsUnion ¶
func (r BotManagementGetResponse) AsUnion() BotManagementGetResponseUnion
AsUnion returns a BotManagementGetResponseUnion interface which you can cast to the specific types for more type safety.
Possible runtime types of the union are BotFightModeConfiguration, SuperBotFightModeDefinitelyConfiguration, SuperBotFightModeLikelyConfiguration, SubscriptionConfiguration.
func (*BotManagementGetResponse) UnmarshalJSON ¶
func (r *BotManagementGetResponse) UnmarshalJSON(data []byte) (err error)
type BotManagementGetResponseAIBotsProtection ¶
type BotManagementGetResponseAIBotsProtection string
Enable rule to block AI Scrapers and Crawlers. Please note the value `only_on_ad_pages` is currently not available for Enterprise customers.
const ( BotManagementGetResponseAIBotsProtectionBlock BotManagementGetResponseAIBotsProtection = "block" BotManagementGetResponseAIBotsProtectionDisabled BotManagementGetResponseAIBotsProtection = "disabled" BotManagementGetResponseAIBotsProtectionOnlyOnADPages BotManagementGetResponseAIBotsProtection = "only_on_ad_pages" )
func (BotManagementGetResponseAIBotsProtection) IsKnown ¶
func (r BotManagementGetResponseAIBotsProtection) IsKnown() bool
type BotManagementGetResponseCrawlerProtection ¶
type BotManagementGetResponseCrawlerProtection string
Enable rule to punish AI Scrapers and Crawlers via a link maze.
const ( BotManagementGetResponseCrawlerProtectionEnabled BotManagementGetResponseCrawlerProtection = "enabled" BotManagementGetResponseCrawlerProtectionDisabled BotManagementGetResponseCrawlerProtection = "disabled" )
func (BotManagementGetResponseCrawlerProtection) IsKnown ¶
func (r BotManagementGetResponseCrawlerProtection) IsKnown() bool
type BotManagementGetResponseEnvelope ¶
type BotManagementGetResponseEnvelope struct {
Errors []BotManagementGetResponseEnvelopeErrors `json:"errors,required"`
Messages []BotManagementGetResponseEnvelopeMessages `json:"messages,required"`
// Whether the API call was successful.
Success BotManagementGetResponseEnvelopeSuccess `json:"success,required"`
Result BotManagementGetResponse `json:"result"`
JSON botManagementGetResponseEnvelopeJSON `json:"-"`
}
func (*BotManagementGetResponseEnvelope) UnmarshalJSON ¶
func (r *BotManagementGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type BotManagementGetResponseEnvelopeErrors ¶
type BotManagementGetResponseEnvelopeErrors struct {
Code int64 `json:"code,required"`
Message string `json:"message,required"`
DocumentationURL string `json:"documentation_url"`
Source BotManagementGetResponseEnvelopeErrorsSource `json:"source"`
JSON botManagementGetResponseEnvelopeErrorsJSON `json:"-"`
}
func (*BotManagementGetResponseEnvelopeErrors) UnmarshalJSON ¶
func (r *BotManagementGetResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)
type BotManagementGetResponseEnvelopeErrorsSource ¶
type BotManagementGetResponseEnvelopeErrorsSource struct {
Pointer string `json:"pointer"`
JSON botManagementGetResponseEnvelopeErrorsSourceJSON `json:"-"`
}
func (*BotManagementGetResponseEnvelopeErrorsSource) UnmarshalJSON ¶
func (r *BotManagementGetResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)
type BotManagementGetResponseEnvelopeMessages ¶
type BotManagementGetResponseEnvelopeMessages struct {
Code int64 `json:"code,required"`
Message string `json:"message,required"`
DocumentationURL string `json:"documentation_url"`
Source BotManagementGetResponseEnvelopeMessagesSource `json:"source"`
JSON botManagementGetResponseEnvelopeMessagesJSON `json:"-"`
}
func (*BotManagementGetResponseEnvelopeMessages) UnmarshalJSON ¶
func (r *BotManagementGetResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)
type BotManagementGetResponseEnvelopeMessagesSource ¶
type BotManagementGetResponseEnvelopeMessagesSource struct {
Pointer string `json:"pointer"`
JSON botManagementGetResponseEnvelopeMessagesSourceJSON `json:"-"`
}
func (*BotManagementGetResponseEnvelopeMessagesSource) UnmarshalJSON ¶
func (r *BotManagementGetResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)
type BotManagementGetResponseEnvelopeSuccess ¶
type BotManagementGetResponseEnvelopeSuccess bool
Whether the API call was successful.
const (
BotManagementGetResponseEnvelopeSuccessTrue BotManagementGetResponseEnvelopeSuccess = true
)
func (BotManagementGetResponseEnvelopeSuccess) IsKnown ¶
func (r BotManagementGetResponseEnvelopeSuccess) IsKnown() bool
type BotManagementGetResponseSBFMDefinitelyAutomated ¶
type BotManagementGetResponseSBFMDefinitelyAutomated string
Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
const ( BotManagementGetResponseSBFMDefinitelyAutomatedAllow BotManagementGetResponseSBFMDefinitelyAutomated = "allow" BotManagementGetResponseSBFMDefinitelyAutomatedBlock BotManagementGetResponseSBFMDefinitelyAutomated = "block" BotManagementGetResponseSBFMDefinitelyAutomatedManagedChallenge BotManagementGetResponseSBFMDefinitelyAutomated = "managed_challenge" )
func (BotManagementGetResponseSBFMDefinitelyAutomated) IsKnown ¶
func (r BotManagementGetResponseSBFMDefinitelyAutomated) IsKnown() bool
type BotManagementGetResponseSBFMLikelyAutomated ¶
type BotManagementGetResponseSBFMLikelyAutomated string
Super Bot Fight Mode (SBFM) action to take on likely automated requests.
const ( BotManagementGetResponseSBFMLikelyAutomatedAllow BotManagementGetResponseSBFMLikelyAutomated = "allow" BotManagementGetResponseSBFMLikelyAutomatedBlock BotManagementGetResponseSBFMLikelyAutomated = "block" BotManagementGetResponseSBFMLikelyAutomatedManagedChallenge BotManagementGetResponseSBFMLikelyAutomated = "managed_challenge" )
func (BotManagementGetResponseSBFMLikelyAutomated) IsKnown ¶
func (r BotManagementGetResponseSBFMLikelyAutomated) IsKnown() bool
type BotManagementGetResponseSBFMVerifiedBots ¶
type BotManagementGetResponseSBFMVerifiedBots string
Super Bot Fight Mode (SBFM) action to take on verified bots requests.
const ( BotManagementGetResponseSBFMVerifiedBotsAllow BotManagementGetResponseSBFMVerifiedBots = "allow" BotManagementGetResponseSBFMVerifiedBotsBlock BotManagementGetResponseSBFMVerifiedBots = "block" )
func (BotManagementGetResponseSBFMVerifiedBots) IsKnown ¶
func (r BotManagementGetResponseSBFMVerifiedBots) IsKnown() bool
type BotManagementGetResponseUnion ¶
type BotManagementGetResponseUnion interface {
// contains filtered or unexported methods
}
Union satisfied by BotFightModeConfiguration, SuperBotFightModeDefinitelyConfiguration, SuperBotFightModeLikelyConfiguration or SubscriptionConfiguration.
type BotManagementService ¶
type BotManagementService struct {
Options []option.RequestOption
}
BotManagementService 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 NewBotManagementService method instead.
func NewBotManagementService ¶
func NewBotManagementService(opts ...option.RequestOption) (r *BotManagementService)
NewBotManagementService 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 (*BotManagementService) Get ¶
func (r *BotManagementService) Get(ctx context.Context, query BotManagementGetParams, opts ...option.RequestOption) (res *BotManagementGetResponse, err error)
Retrieve a zone's Bot Management Config
func (*BotManagementService) Update ¶
func (r *BotManagementService) Update(ctx context.Context, params BotManagementUpdateParams, opts ...option.RequestOption) (res *BotManagementUpdateResponse, err error)
Updates the Bot Management configuration for a zone.
This API is used to update:
- **Bot Fight Mode** - **Super Bot Fight Mode** - **Bot Management for Enterprise**
See [Bot Plans](https://developers.cloudflare.com/bots/plans/) for more information on the different plans \ If you recently upgraded or downgraded your plan, refer to the following examples to clean up old configurations. Copy and paste the example body to remove old zone configurations based on your current plan.
#### Clean up configuration for Bot Fight Mode plan
```json
{
"sbfm_likely_automated": "allow",
"sbfm_definitely_automated": "allow",
"sbfm_verified_bots": "allow",
"sbfm_static_resource_protection": false,
"optimize_wordpress": false,
"suppress_session_score": false
}
```
#### Clean up configuration for SBFM Pro plan
```json
{
"sbfm_likely_automated": "allow",
"fight_mode": false
}
```
#### Clean up configuration for SBFM Biz plan
```json
{
"fight_mode": false
}
```
#### Clean up configuration for BM Enterprise Subscription plan
It is strongly recommended that you ensure you have [custom rules](https://developers.cloudflare.com/waf/custom-rules/) in place to protect your zone before disabling the SBFM rules. Without these protections, your zone is vulnerable to attacks.
```json
{
"sbfm_likely_automated": "allow",
"sbfm_definitely_automated": "allow",
"sbfm_verified_bots": "allow",
"sbfm_static_resource_protection": false,
"optimize_wordpress": false,
"fight_mode": false
}
```
type BotManagementUpdateParams ¶
type BotManagementUpdateParams struct {
// Identifier.
ZoneID param.Field[string] `path:"zone_id,required"`
Body BotManagementUpdateParamsBodyUnion `json:"body,required"`
}
func (BotManagementUpdateParams) MarshalJSON ¶
func (r BotManagementUpdateParams) MarshalJSON() (data []byte, err error)
type BotManagementUpdateParamsBody ¶
type BotManagementUpdateParamsBody struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection param.Field[BotManagementUpdateParamsBodyAIBotsProtection] `json:"ai_bots_protection"`
// Automatically update to the newest bot detection models created by Cloudflare as
// they are released.
// [Learn more.](https://developers.cloudflare.com/bots/reference/machine-learning-models#model-versions-and-release-notes)
AutoUpdateModel param.Field[bool] `json:"auto_update_model"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection param.Field[BotManagementUpdateParamsBodyCrawlerProtection] `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS param.Field[bool] `json:"enable_js"`
// Whether to enable Bot Fight Mode.
FightMode param.Field[bool] `json:"fight_mode"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged param.Field[bool] `json:"is_robots_txt_managed"`
// Whether to optimize Super Bot Fight Mode protections for Wordpress.
OptimizeWordpress param.Field[bool] `json:"optimize_wordpress"`
// Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
SBFMDefinitelyAutomated param.Field[BotManagementUpdateParamsBodySBFMDefinitelyAutomated] `json:"sbfm_definitely_automated"`
// Super Bot Fight Mode (SBFM) action to take on likely automated requests.
SBFMLikelyAutomated param.Field[BotManagementUpdateParamsBodySBFMLikelyAutomated] `json:"sbfm_likely_automated"`
// Super Bot Fight Mode (SBFM) to enable static resource protection. Enable if
// static resources on your application need bot protection. Note: Static resource
// protection can also result in legitimate traffic being blocked.
SBFMStaticResourceProtection param.Field[bool] `json:"sbfm_static_resource_protection"`
// Super Bot Fight Mode (SBFM) action to take on verified bots requests.
SBFMVerifiedBots param.Field[BotManagementUpdateParamsBodySBFMVerifiedBots] `json:"sbfm_verified_bots"`
StaleZoneConfiguration param.Field[interface{}] `json:"stale_zone_configuration"`
// Whether to disable tracking the highest bot score for a session in the Bot
// Management cookie.
SuppressSessionScore param.Field[bool] `json:"suppress_session_score"`
}
func (BotManagementUpdateParamsBody) MarshalJSON ¶
func (r BotManagementUpdateParamsBody) MarshalJSON() (data []byte, err error)
type BotManagementUpdateParamsBodyAIBotsProtection ¶
type BotManagementUpdateParamsBodyAIBotsProtection string
Enable rule to block AI Scrapers and Crawlers. Please note the value `only_on_ad_pages` is currently not available for Enterprise customers.
const ( BotManagementUpdateParamsBodyAIBotsProtectionBlock BotManagementUpdateParamsBodyAIBotsProtection = "block" BotManagementUpdateParamsBodyAIBotsProtectionDisabled BotManagementUpdateParamsBodyAIBotsProtection = "disabled" BotManagementUpdateParamsBodyAIBotsProtectionOnlyOnADPages BotManagementUpdateParamsBodyAIBotsProtection = "only_on_ad_pages" )
func (BotManagementUpdateParamsBodyAIBotsProtection) IsKnown ¶
func (r BotManagementUpdateParamsBodyAIBotsProtection) IsKnown() bool
type BotManagementUpdateParamsBodyCrawlerProtection ¶
type BotManagementUpdateParamsBodyCrawlerProtection string
Enable rule to punish AI Scrapers and Crawlers via a link maze.
const ( BotManagementUpdateParamsBodyCrawlerProtectionEnabled BotManagementUpdateParamsBodyCrawlerProtection = "enabled" BotManagementUpdateParamsBodyCrawlerProtectionDisabled BotManagementUpdateParamsBodyCrawlerProtection = "disabled" )
func (BotManagementUpdateParamsBodyCrawlerProtection) IsKnown ¶
func (r BotManagementUpdateParamsBodyCrawlerProtection) IsKnown() bool
type BotManagementUpdateParamsBodySBFMDefinitelyAutomated ¶
type BotManagementUpdateParamsBodySBFMDefinitelyAutomated string
Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
const ( BotManagementUpdateParamsBodySBFMDefinitelyAutomatedAllow BotManagementUpdateParamsBodySBFMDefinitelyAutomated = "allow" BotManagementUpdateParamsBodySBFMDefinitelyAutomatedBlock BotManagementUpdateParamsBodySBFMDefinitelyAutomated = "block" BotManagementUpdateParamsBodySBFMDefinitelyAutomatedManagedChallenge BotManagementUpdateParamsBodySBFMDefinitelyAutomated = "managed_challenge" )
func (BotManagementUpdateParamsBodySBFMDefinitelyAutomated) IsKnown ¶
func (r BotManagementUpdateParamsBodySBFMDefinitelyAutomated) IsKnown() bool
type BotManagementUpdateParamsBodySBFMLikelyAutomated ¶
type BotManagementUpdateParamsBodySBFMLikelyAutomated string
Super Bot Fight Mode (SBFM) action to take on likely automated requests.
const ( BotManagementUpdateParamsBodySBFMLikelyAutomatedAllow BotManagementUpdateParamsBodySBFMLikelyAutomated = "allow" BotManagementUpdateParamsBodySBFMLikelyAutomatedBlock BotManagementUpdateParamsBodySBFMLikelyAutomated = "block" BotManagementUpdateParamsBodySBFMLikelyAutomatedManagedChallenge BotManagementUpdateParamsBodySBFMLikelyAutomated = "managed_challenge" )
func (BotManagementUpdateParamsBodySBFMLikelyAutomated) IsKnown ¶
func (r BotManagementUpdateParamsBodySBFMLikelyAutomated) IsKnown() bool
type BotManagementUpdateParamsBodySBFMVerifiedBots ¶
type BotManagementUpdateParamsBodySBFMVerifiedBots string
Super Bot Fight Mode (SBFM) action to take on verified bots requests.
const ( BotManagementUpdateParamsBodySBFMVerifiedBotsAllow BotManagementUpdateParamsBodySBFMVerifiedBots = "allow" BotManagementUpdateParamsBodySBFMVerifiedBotsBlock BotManagementUpdateParamsBodySBFMVerifiedBots = "block" )
func (BotManagementUpdateParamsBodySBFMVerifiedBots) IsKnown ¶
func (r BotManagementUpdateParamsBodySBFMVerifiedBots) IsKnown() bool
type BotManagementUpdateParamsBodyUnion ¶
type BotManagementUpdateParamsBodyUnion interface {
// contains filtered or unexported methods
}
Satisfied by bot_management.BotFightModeConfigurationParam, bot_management.SuperBotFightModeDefinitelyConfigurationParam, bot_management.SuperBotFightModeLikelyConfigurationParam, bot_management.SubscriptionConfigurationParam, BotManagementUpdateParamsBody.
type BotManagementUpdateResponse ¶
type BotManagementUpdateResponse struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection BotManagementUpdateResponseAIBotsProtection `json:"ai_bots_protection"`
// Automatically update to the newest bot detection models created by Cloudflare as
// they are released.
// [Learn more.](https://developers.cloudflare.com/bots/reference/machine-learning-models#model-versions-and-release-notes)
AutoUpdateModel bool `json:"auto_update_model"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection BotManagementUpdateResponseCrawlerProtection `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS bool `json:"enable_js"`
// Whether to enable Bot Fight Mode.
FightMode bool `json:"fight_mode"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged bool `json:"is_robots_txt_managed"`
// Whether to optimize Super Bot Fight Mode protections for Wordpress.
OptimizeWordpress bool `json:"optimize_wordpress"`
// Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
SBFMDefinitelyAutomated BotManagementUpdateResponseSBFMDefinitelyAutomated `json:"sbfm_definitely_automated"`
// Super Bot Fight Mode (SBFM) action to take on likely automated requests.
SBFMLikelyAutomated BotManagementUpdateResponseSBFMLikelyAutomated `json:"sbfm_likely_automated"`
// Super Bot Fight Mode (SBFM) to enable static resource protection. Enable if
// static resources on your application need bot protection. Note: Static resource
// protection can also result in legitimate traffic being blocked.
SBFMStaticResourceProtection bool `json:"sbfm_static_resource_protection"`
// Super Bot Fight Mode (SBFM) action to take on verified bots requests.
SBFMVerifiedBots BotManagementUpdateResponseSBFMVerifiedBots `json:"sbfm_verified_bots"`
// This field can have the runtime type of
// [BotFightModeConfigurationStaleZoneConfiguration],
// [SuperBotFightModeDefinitelyConfigurationStaleZoneConfiguration],
// [SuperBotFightModeLikelyConfigurationStaleZoneConfiguration],
// [SubscriptionConfigurationStaleZoneConfiguration].
StaleZoneConfiguration interface{} `json:"stale_zone_configuration"`
// Whether to disable tracking the highest bot score for a session in the Bot
// Management cookie.
SuppressSessionScore bool `json:"suppress_session_score"`
// A read-only field that indicates whether the zone currently is running the
// latest ML model.
UsingLatestModel bool `json:"using_latest_model"`
JSON botManagementUpdateResponseJSON `json:"-"`
// contains filtered or unexported fields
}
func (BotManagementUpdateResponse) AsUnion ¶
func (r BotManagementUpdateResponse) AsUnion() BotManagementUpdateResponseUnion
AsUnion returns a BotManagementUpdateResponseUnion interface which you can cast to the specific types for more type safety.
Possible runtime types of the union are BotFightModeConfiguration, SuperBotFightModeDefinitelyConfiguration, SuperBotFightModeLikelyConfiguration, SubscriptionConfiguration.
func (*BotManagementUpdateResponse) UnmarshalJSON ¶
func (r *BotManagementUpdateResponse) UnmarshalJSON(data []byte) (err error)
type BotManagementUpdateResponseAIBotsProtection ¶
type BotManagementUpdateResponseAIBotsProtection string
Enable rule to block AI Scrapers and Crawlers. Please note the value `only_on_ad_pages` is currently not available for Enterprise customers.
const ( BotManagementUpdateResponseAIBotsProtectionBlock BotManagementUpdateResponseAIBotsProtection = "block" BotManagementUpdateResponseAIBotsProtectionDisabled BotManagementUpdateResponseAIBotsProtection = "disabled" BotManagementUpdateResponseAIBotsProtectionOnlyOnADPages BotManagementUpdateResponseAIBotsProtection = "only_on_ad_pages" )
func (BotManagementUpdateResponseAIBotsProtection) IsKnown ¶
func (r BotManagementUpdateResponseAIBotsProtection) IsKnown() bool
type BotManagementUpdateResponseCrawlerProtection ¶
type BotManagementUpdateResponseCrawlerProtection string
Enable rule to punish AI Scrapers and Crawlers via a link maze.
const ( BotManagementUpdateResponseCrawlerProtectionEnabled BotManagementUpdateResponseCrawlerProtection = "enabled" BotManagementUpdateResponseCrawlerProtectionDisabled BotManagementUpdateResponseCrawlerProtection = "disabled" )
func (BotManagementUpdateResponseCrawlerProtection) IsKnown ¶
func (r BotManagementUpdateResponseCrawlerProtection) IsKnown() bool
type BotManagementUpdateResponseEnvelope ¶
type BotManagementUpdateResponseEnvelope struct {
Errors []BotManagementUpdateResponseEnvelopeErrors `json:"errors,required"`
Messages []BotManagementUpdateResponseEnvelopeMessages `json:"messages,required"`
// Whether the API call was successful.
Success BotManagementUpdateResponseEnvelopeSuccess `json:"success,required"`
Result BotManagementUpdateResponse `json:"result"`
JSON botManagementUpdateResponseEnvelopeJSON `json:"-"`
}
func (*BotManagementUpdateResponseEnvelope) UnmarshalJSON ¶
func (r *BotManagementUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type BotManagementUpdateResponseEnvelopeErrors ¶
type BotManagementUpdateResponseEnvelopeErrors struct {
Code int64 `json:"code,required"`
Message string `json:"message,required"`
DocumentationURL string `json:"documentation_url"`
Source BotManagementUpdateResponseEnvelopeErrorsSource `json:"source"`
JSON botManagementUpdateResponseEnvelopeErrorsJSON `json:"-"`
}
func (*BotManagementUpdateResponseEnvelopeErrors) UnmarshalJSON ¶
func (r *BotManagementUpdateResponseEnvelopeErrors) UnmarshalJSON(data []byte) (err error)
type BotManagementUpdateResponseEnvelopeErrorsSource ¶
type BotManagementUpdateResponseEnvelopeErrorsSource struct {
Pointer string `json:"pointer"`
JSON botManagementUpdateResponseEnvelopeErrorsSourceJSON `json:"-"`
}
func (*BotManagementUpdateResponseEnvelopeErrorsSource) UnmarshalJSON ¶
func (r *BotManagementUpdateResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (err error)
type BotManagementUpdateResponseEnvelopeMessages ¶
type BotManagementUpdateResponseEnvelopeMessages struct {
Code int64 `json:"code,required"`
Message string `json:"message,required"`
DocumentationURL string `json:"documentation_url"`
Source BotManagementUpdateResponseEnvelopeMessagesSource `json:"source"`
JSON botManagementUpdateResponseEnvelopeMessagesJSON `json:"-"`
}
func (*BotManagementUpdateResponseEnvelopeMessages) UnmarshalJSON ¶
func (r *BotManagementUpdateResponseEnvelopeMessages) UnmarshalJSON(data []byte) (err error)
type BotManagementUpdateResponseEnvelopeMessagesSource ¶
type BotManagementUpdateResponseEnvelopeMessagesSource struct {
Pointer string `json:"pointer"`
JSON botManagementUpdateResponseEnvelopeMessagesSourceJSON `json:"-"`
}
func (*BotManagementUpdateResponseEnvelopeMessagesSource) UnmarshalJSON ¶
func (r *BotManagementUpdateResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (err error)
type BotManagementUpdateResponseEnvelopeSuccess ¶
type BotManagementUpdateResponseEnvelopeSuccess bool
Whether the API call was successful.
const (
BotManagementUpdateResponseEnvelopeSuccessTrue BotManagementUpdateResponseEnvelopeSuccess = true
)
func (BotManagementUpdateResponseEnvelopeSuccess) IsKnown ¶
func (r BotManagementUpdateResponseEnvelopeSuccess) IsKnown() bool
type BotManagementUpdateResponseSBFMDefinitelyAutomated ¶
type BotManagementUpdateResponseSBFMDefinitelyAutomated string
Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
const ( BotManagementUpdateResponseSBFMDefinitelyAutomatedAllow BotManagementUpdateResponseSBFMDefinitelyAutomated = "allow" BotManagementUpdateResponseSBFMDefinitelyAutomatedBlock BotManagementUpdateResponseSBFMDefinitelyAutomated = "block" BotManagementUpdateResponseSBFMDefinitelyAutomatedManagedChallenge BotManagementUpdateResponseSBFMDefinitelyAutomated = "managed_challenge" )
func (BotManagementUpdateResponseSBFMDefinitelyAutomated) IsKnown ¶
func (r BotManagementUpdateResponseSBFMDefinitelyAutomated) IsKnown() bool
type BotManagementUpdateResponseSBFMLikelyAutomated ¶
type BotManagementUpdateResponseSBFMLikelyAutomated string
Super Bot Fight Mode (SBFM) action to take on likely automated requests.
const ( BotManagementUpdateResponseSBFMLikelyAutomatedAllow BotManagementUpdateResponseSBFMLikelyAutomated = "allow" BotManagementUpdateResponseSBFMLikelyAutomatedBlock BotManagementUpdateResponseSBFMLikelyAutomated = "block" BotManagementUpdateResponseSBFMLikelyAutomatedManagedChallenge BotManagementUpdateResponseSBFMLikelyAutomated = "managed_challenge" )
func (BotManagementUpdateResponseSBFMLikelyAutomated) IsKnown ¶
func (r BotManagementUpdateResponseSBFMLikelyAutomated) IsKnown() bool
type BotManagementUpdateResponseSBFMVerifiedBots ¶
type BotManagementUpdateResponseSBFMVerifiedBots string
Super Bot Fight Mode (SBFM) action to take on verified bots requests.
const ( BotManagementUpdateResponseSBFMVerifiedBotsAllow BotManagementUpdateResponseSBFMVerifiedBots = "allow" BotManagementUpdateResponseSBFMVerifiedBotsBlock BotManagementUpdateResponseSBFMVerifiedBots = "block" )
func (BotManagementUpdateResponseSBFMVerifiedBots) IsKnown ¶
func (r BotManagementUpdateResponseSBFMVerifiedBots) IsKnown() bool
type BotManagementUpdateResponseUnion ¶
type BotManagementUpdateResponseUnion interface {
// contains filtered or unexported methods
}
Union satisfied by BotFightModeConfiguration, SuperBotFightModeDefinitelyConfiguration, SuperBotFightModeLikelyConfiguration or SubscriptionConfiguration.
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 CloudflareTunnelConfigSrc ¶ added in v5.1.0
type CloudflareTunnelConfigSrc = shared.CloudflareTunnelConfigSrc
Indicates if this is a locally or remotely configured tunnel. If `local`, manage the tunnel using a YAML file on the origin machine. If `cloudflare`, manage the tunnel on the Zero Trust dashboard.
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 ErrorDataSource ¶
type ErrorDataSource = shared.ErrorDataSource
This is an alias to an internal type.
type MemberPoliciesAccess ¶
type MemberPoliciesAccess = shared.MemberPoliciesAccess
Allow or deny operations against the resources.
This is an alias to an internal type.
type MemberPoliciesPermissionGroup ¶
type MemberPoliciesPermissionGroup = shared.MemberPoliciesPermissionGroup
A named group of permissions that map to a group of operations against resources.
This is an alias to an internal type.
type MemberPoliciesPermissionGroupsMeta ¶
type MemberPoliciesPermissionGroupsMeta = shared.MemberPoliciesPermissionGroupsMeta
Attributes associated to the permission group.
This is an alias to an internal type.
type MemberPoliciesResourceGroup ¶
type MemberPoliciesResourceGroup = shared.MemberPoliciesResourceGroup
A group of scoped resources.
This is an alias to an internal type.
type MemberPoliciesResourceGroupsMeta ¶
type MemberPoliciesResourceGroupsMeta = shared.MemberPoliciesResourceGroupsMeta
Attributes associated to the resource group.
This is an alias to an internal type.
type MemberPoliciesResourceGroupsScope ¶
type MemberPoliciesResourceGroupsScope = shared.MemberPoliciesResourceGroupsScope
A scope is a combination of scope objects which provides additional context.
This is an alias to an internal type.
type MemberPoliciesResourceGroupsScopeObject ¶
type MemberPoliciesResourceGroupsScopeObject = shared.MemberPoliciesResourceGroupsScopeObject
A scope object represents any resource that can have actions applied against invite.
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 MemberUser ¶
type MemberUser = shared.MemberUser
Details of the user associated to the membership.
This is an alias to an internal type.
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 RatePlanID ¶
type RatePlanID = shared.RatePlanID
The ID of the rate plan.
This is an alias to an internal type.
type RatePlanParam ¶
type RatePlanParam = shared.RatePlanParam
The rate plan applied to the subscription.
This is an alias to an internal type.
type ResponseInfoSource ¶
type ResponseInfoSource = shared.ResponseInfoSource
This is an alias to an internal type.
type RolePermissions ¶
type RolePermissions = shared.RolePermissions
This is an alias to an internal type.
type RolePermissionsParam ¶
type RolePermissionsParam = shared.RolePermissionsParam
This is an alias to an internal type.
type SortDirection ¶
type SortDirection = shared.SortDirection
Direction to order DNS records in.
This is an alias to an internal type.
type SubscriptionConfiguration ¶
type SubscriptionConfiguration struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection SubscriptionConfigurationAIBotsProtection `json:"ai_bots_protection"`
// Automatically update to the newest bot detection models created by Cloudflare as
// they are released.
// [Learn more.](https://developers.cloudflare.com/bots/reference/machine-learning-models#model-versions-and-release-notes)
AutoUpdateModel bool `json:"auto_update_model"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection SubscriptionConfigurationCrawlerProtection `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS bool `json:"enable_js"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged bool `json:"is_robots_txt_managed"`
// A read-only field that shows which unauthorized settings are currently active on
// the zone. These settings typically result from upgrades or downgrades.
StaleZoneConfiguration SubscriptionConfigurationStaleZoneConfiguration `json:"stale_zone_configuration"`
// Whether to disable tracking the highest bot score for a session in the Bot
// Management cookie.
SuppressSessionScore bool `json:"suppress_session_score"`
// A read-only field that indicates whether the zone currently is running the
// latest ML model.
UsingLatestModel bool `json:"using_latest_model"`
JSON subscriptionConfigurationJSON `json:"-"`
}
func (*SubscriptionConfiguration) UnmarshalJSON ¶
func (r *SubscriptionConfiguration) UnmarshalJSON(data []byte) (err error)
type SubscriptionConfigurationAIBotsProtection ¶
type SubscriptionConfigurationAIBotsProtection string
Enable rule to block AI Scrapers and Crawlers. Please note the value `only_on_ad_pages` is currently not available for Enterprise customers.
const ( SubscriptionConfigurationAIBotsProtectionBlock SubscriptionConfigurationAIBotsProtection = "block" SubscriptionConfigurationAIBotsProtectionDisabled SubscriptionConfigurationAIBotsProtection = "disabled" SubscriptionConfigurationAIBotsProtectionOnlyOnADPages SubscriptionConfigurationAIBotsProtection = "only_on_ad_pages" )
func (SubscriptionConfigurationAIBotsProtection) IsKnown ¶
func (r SubscriptionConfigurationAIBotsProtection) IsKnown() bool
type SubscriptionConfigurationCrawlerProtection ¶
type SubscriptionConfigurationCrawlerProtection string
Enable rule to punish AI Scrapers and Crawlers via a link maze.
const ( SubscriptionConfigurationCrawlerProtectionEnabled SubscriptionConfigurationCrawlerProtection = "enabled" SubscriptionConfigurationCrawlerProtectionDisabled SubscriptionConfigurationCrawlerProtection = "disabled" )
func (SubscriptionConfigurationCrawlerProtection) IsKnown ¶
func (r SubscriptionConfigurationCrawlerProtection) IsKnown() bool
type SubscriptionConfigurationParam ¶
type SubscriptionConfigurationParam struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection param.Field[SubscriptionConfigurationAIBotsProtection] `json:"ai_bots_protection"`
// Automatically update to the newest bot detection models created by Cloudflare as
// they are released.
// [Learn more.](https://developers.cloudflare.com/bots/reference/machine-learning-models#model-versions-and-release-notes)
AutoUpdateModel param.Field[bool] `json:"auto_update_model"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection param.Field[SubscriptionConfigurationCrawlerProtection] `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS param.Field[bool] `json:"enable_js"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged param.Field[bool] `json:"is_robots_txt_managed"`
// Whether to disable tracking the highest bot score for a session in the Bot
// Management cookie.
SuppressSessionScore param.Field[bool] `json:"suppress_session_score"`
}
func (SubscriptionConfigurationParam) MarshalJSON ¶
func (r SubscriptionConfigurationParam) MarshalJSON() (data []byte, err error)
type SubscriptionConfigurationStaleZoneConfiguration ¶
type SubscriptionConfigurationStaleZoneConfiguration struct {
// Indicates that the zone's Bot Fight Mode is turned on.
FightMode bool `json:"fight_mode"`
// Indicates that the zone's wordpress optimization for SBFM is turned on.
OptimizeWordpress bool `json:"optimize_wordpress"`
// Indicates that the zone's definitely automated requests are being blocked or
// challenged.
SBFMDefinitelyAutomated string `json:"sbfm_definitely_automated"`
// Indicates that the zone's likely automated requests are being blocked or
// challenged.
SBFMLikelyAutomated string `json:"sbfm_likely_automated"`
// Indicates that the zone's static resource protection is turned on.
SBFMStaticResourceProtection string `json:"sbfm_static_resource_protection"`
// Indicates that the zone's verified bot requests are being blocked.
SBFMVerifiedBots string `json:"sbfm_verified_bots"`
JSON subscriptionConfigurationStaleZoneConfigurationJSON `json:"-"`
}
A read-only field that shows which unauthorized settings are currently active on the zone. These settings typically result from upgrades or downgrades.
func (*SubscriptionConfigurationStaleZoneConfiguration) UnmarshalJSON ¶
func (r *SubscriptionConfigurationStaleZoneConfiguration) UnmarshalJSON(data []byte) (err error)
type SubscriptionConfigurationStaleZoneConfigurationParam ¶
type SubscriptionConfigurationStaleZoneConfigurationParam struct {
// Indicates that the zone's Bot Fight Mode is turned on.
FightMode param.Field[bool] `json:"fight_mode"`
// Indicates that the zone's wordpress optimization for SBFM is turned on.
OptimizeWordpress param.Field[bool] `json:"optimize_wordpress"`
// Indicates that the zone's definitely automated requests are being blocked or
// challenged.
SBFMDefinitelyAutomated param.Field[string] `json:"sbfm_definitely_automated"`
// Indicates that the zone's likely automated requests are being blocked or
// challenged.
SBFMLikelyAutomated param.Field[string] `json:"sbfm_likely_automated"`
// Indicates that the zone's static resource protection is turned on.
SBFMStaticResourceProtection param.Field[string] `json:"sbfm_static_resource_protection"`
// Indicates that the zone's verified bot requests are being blocked.
SBFMVerifiedBots param.Field[string] `json:"sbfm_verified_bots"`
}
A read-only field that shows which unauthorized settings are currently active on the zone. These settings typically result from upgrades or downgrades.
func (SubscriptionConfigurationStaleZoneConfigurationParam) MarshalJSON ¶
func (r SubscriptionConfigurationStaleZoneConfigurationParam) MarshalJSON() (data []byte, err error)
type SubscriptionFrequency ¶
type SubscriptionFrequency = shared.SubscriptionFrequency
How often the subscription is renewed automatically.
This is an alias to an internal type.
type SubscriptionParam ¶
type SubscriptionParam = shared.SubscriptionParam
This is an alias to an internal type.
type SubscriptionState ¶
type SubscriptionState = shared.SubscriptionState
The state that the subscription is in.
This is an alias to an internal type.
type SuperBotFightModeDefinitelyConfiguration ¶
type SuperBotFightModeDefinitelyConfiguration struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection SuperBotFightModeDefinitelyConfigurationAIBotsProtection `json:"ai_bots_protection"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection SuperBotFightModeDefinitelyConfigurationCrawlerProtection `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS bool `json:"enable_js"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged bool `json:"is_robots_txt_managed"`
// Whether to optimize Super Bot Fight Mode protections for Wordpress.
OptimizeWordpress bool `json:"optimize_wordpress"`
// Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
SBFMDefinitelyAutomated SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomated `json:"sbfm_definitely_automated"`
// Super Bot Fight Mode (SBFM) to enable static resource protection. Enable if
// static resources on your application need bot protection. Note: Static resource
// protection can also result in legitimate traffic being blocked.
SBFMStaticResourceProtection bool `json:"sbfm_static_resource_protection"`
// Super Bot Fight Mode (SBFM) action to take on verified bots requests.
SBFMVerifiedBots SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBots `json:"sbfm_verified_bots"`
// A read-only field that shows which unauthorized settings are currently active on
// the zone. These settings typically result from upgrades or downgrades.
StaleZoneConfiguration SuperBotFightModeDefinitelyConfigurationStaleZoneConfiguration `json:"stale_zone_configuration"`
// A read-only field that indicates whether the zone currently is running the
// latest ML model.
UsingLatestModel bool `json:"using_latest_model"`
JSON superBotFightModeDefinitelyConfigurationJSON `json:"-"`
}
func (*SuperBotFightModeDefinitelyConfiguration) UnmarshalJSON ¶
func (r *SuperBotFightModeDefinitelyConfiguration) UnmarshalJSON(data []byte) (err error)
type SuperBotFightModeDefinitelyConfigurationAIBotsProtection ¶
type SuperBotFightModeDefinitelyConfigurationAIBotsProtection string
Enable rule to block AI Scrapers and Crawlers. Please note the value `only_on_ad_pages` is currently not available for Enterprise customers.
const ( SuperBotFightModeDefinitelyConfigurationAIBotsProtectionBlock SuperBotFightModeDefinitelyConfigurationAIBotsProtection = "block" SuperBotFightModeDefinitelyConfigurationAIBotsProtectionDisabled SuperBotFightModeDefinitelyConfigurationAIBotsProtection = "disabled" SuperBotFightModeDefinitelyConfigurationAIBotsProtectionOnlyOnADPages SuperBotFightModeDefinitelyConfigurationAIBotsProtection = "only_on_ad_pages" )
func (SuperBotFightModeDefinitelyConfigurationAIBotsProtection) IsKnown ¶
func (r SuperBotFightModeDefinitelyConfigurationAIBotsProtection) IsKnown() bool
type SuperBotFightModeDefinitelyConfigurationCrawlerProtection ¶
type SuperBotFightModeDefinitelyConfigurationCrawlerProtection string
Enable rule to punish AI Scrapers and Crawlers via a link maze.
const ( SuperBotFightModeDefinitelyConfigurationCrawlerProtectionEnabled SuperBotFightModeDefinitelyConfigurationCrawlerProtection = "enabled" SuperBotFightModeDefinitelyConfigurationCrawlerProtectionDisabled SuperBotFightModeDefinitelyConfigurationCrawlerProtection = "disabled" )
func (SuperBotFightModeDefinitelyConfigurationCrawlerProtection) IsKnown ¶
func (r SuperBotFightModeDefinitelyConfigurationCrawlerProtection) IsKnown() bool
type SuperBotFightModeDefinitelyConfigurationParam ¶
type SuperBotFightModeDefinitelyConfigurationParam struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection param.Field[SuperBotFightModeDefinitelyConfigurationAIBotsProtection] `json:"ai_bots_protection"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection param.Field[SuperBotFightModeDefinitelyConfigurationCrawlerProtection] `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS param.Field[bool] `json:"enable_js"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged param.Field[bool] `json:"is_robots_txt_managed"`
// Whether to optimize Super Bot Fight Mode protections for Wordpress.
OptimizeWordpress param.Field[bool] `json:"optimize_wordpress"`
// Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
SBFMDefinitelyAutomated param.Field[SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomated] `json:"sbfm_definitely_automated"`
// Super Bot Fight Mode (SBFM) to enable static resource protection. Enable if
// static resources on your application need bot protection. Note: Static resource
// protection can also result in legitimate traffic being blocked.
SBFMStaticResourceProtection param.Field[bool] `json:"sbfm_static_resource_protection"`
// Super Bot Fight Mode (SBFM) action to take on verified bots requests.
SBFMVerifiedBots param.Field[SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBots] `json:"sbfm_verified_bots"`
}
func (SuperBotFightModeDefinitelyConfigurationParam) MarshalJSON ¶
func (r SuperBotFightModeDefinitelyConfigurationParam) MarshalJSON() (data []byte, err error)
type SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomated ¶
type SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomated string
Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
const ( SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomatedAllow SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomated = "allow" SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomatedBlock SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomated = "block" SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomatedManagedChallenge SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomated = "managed_challenge" )
func (SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomated) IsKnown ¶
func (r SuperBotFightModeDefinitelyConfigurationSBFMDefinitelyAutomated) IsKnown() bool
type SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBots ¶
type SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBots string
Super Bot Fight Mode (SBFM) action to take on verified bots requests.
const ( SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBotsAllow SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBots = "allow" SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBotsBlock SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBots = "block" )
func (SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBots) IsKnown ¶
func (r SuperBotFightModeDefinitelyConfigurationSBFMVerifiedBots) IsKnown() bool
type SuperBotFightModeDefinitelyConfigurationStaleZoneConfiguration ¶
type SuperBotFightModeDefinitelyConfigurationStaleZoneConfiguration struct {
// Indicates that the zone's Bot Fight Mode is turned on.
FightMode bool `json:"fight_mode"`
// Indicates that the zone's likely automated requests are being blocked or
// challenged.
SBFMLikelyAutomated string `json:"sbfm_likely_automated"`
JSON superBotFightModeDefinitelyConfigurationStaleZoneConfigurationJSON `json:"-"`
}
A read-only field that shows which unauthorized settings are currently active on the zone. These settings typically result from upgrades or downgrades.
func (*SuperBotFightModeDefinitelyConfigurationStaleZoneConfiguration) UnmarshalJSON ¶
func (r *SuperBotFightModeDefinitelyConfigurationStaleZoneConfiguration) UnmarshalJSON(data []byte) (err error)
type SuperBotFightModeDefinitelyConfigurationStaleZoneConfigurationParam ¶
type SuperBotFightModeDefinitelyConfigurationStaleZoneConfigurationParam struct {
// Indicates that the zone's Bot Fight Mode is turned on.
FightMode param.Field[bool] `json:"fight_mode"`
// Indicates that the zone's likely automated requests are being blocked or
// challenged.
SBFMLikelyAutomated param.Field[string] `json:"sbfm_likely_automated"`
}
A read-only field that shows which unauthorized settings are currently active on the zone. These settings typically result from upgrades or downgrades.
func (SuperBotFightModeDefinitelyConfigurationStaleZoneConfigurationParam) MarshalJSON ¶
func (r SuperBotFightModeDefinitelyConfigurationStaleZoneConfigurationParam) MarshalJSON() (data []byte, err error)
type SuperBotFightModeLikelyConfiguration ¶
type SuperBotFightModeLikelyConfiguration struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection SuperBotFightModeLikelyConfigurationAIBotsProtection `json:"ai_bots_protection"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection SuperBotFightModeLikelyConfigurationCrawlerProtection `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS bool `json:"enable_js"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged bool `json:"is_robots_txt_managed"`
// Whether to optimize Super Bot Fight Mode protections for Wordpress.
OptimizeWordpress bool `json:"optimize_wordpress"`
// Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
SBFMDefinitelyAutomated SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomated `json:"sbfm_definitely_automated"`
// Super Bot Fight Mode (SBFM) action to take on likely automated requests.
SBFMLikelyAutomated SuperBotFightModeLikelyConfigurationSBFMLikelyAutomated `json:"sbfm_likely_automated"`
// Super Bot Fight Mode (SBFM) to enable static resource protection. Enable if
// static resources on your application need bot protection. Note: Static resource
// protection can also result in legitimate traffic being blocked.
SBFMStaticResourceProtection bool `json:"sbfm_static_resource_protection"`
// Super Bot Fight Mode (SBFM) action to take on verified bots requests.
SBFMVerifiedBots SuperBotFightModeLikelyConfigurationSBFMVerifiedBots `json:"sbfm_verified_bots"`
// A read-only field that shows which unauthorized settings are currently active on
// the zone. These settings typically result from upgrades or downgrades.
StaleZoneConfiguration SuperBotFightModeLikelyConfigurationStaleZoneConfiguration `json:"stale_zone_configuration"`
// A read-only field that indicates whether the zone currently is running the
// latest ML model.
UsingLatestModel bool `json:"using_latest_model"`
JSON superBotFightModeLikelyConfigurationJSON `json:"-"`
}
func (*SuperBotFightModeLikelyConfiguration) UnmarshalJSON ¶
func (r *SuperBotFightModeLikelyConfiguration) UnmarshalJSON(data []byte) (err error)
type SuperBotFightModeLikelyConfigurationAIBotsProtection ¶
type SuperBotFightModeLikelyConfigurationAIBotsProtection string
Enable rule to block AI Scrapers and Crawlers. Please note the value `only_on_ad_pages` is currently not available for Enterprise customers.
const ( SuperBotFightModeLikelyConfigurationAIBotsProtectionBlock SuperBotFightModeLikelyConfigurationAIBotsProtection = "block" SuperBotFightModeLikelyConfigurationAIBotsProtectionDisabled SuperBotFightModeLikelyConfigurationAIBotsProtection = "disabled" SuperBotFightModeLikelyConfigurationAIBotsProtectionOnlyOnADPages SuperBotFightModeLikelyConfigurationAIBotsProtection = "only_on_ad_pages" )
func (SuperBotFightModeLikelyConfigurationAIBotsProtection) IsKnown ¶
func (r SuperBotFightModeLikelyConfigurationAIBotsProtection) IsKnown() bool
type SuperBotFightModeLikelyConfigurationCrawlerProtection ¶
type SuperBotFightModeLikelyConfigurationCrawlerProtection string
Enable rule to punish AI Scrapers and Crawlers via a link maze.
const ( SuperBotFightModeLikelyConfigurationCrawlerProtectionEnabled SuperBotFightModeLikelyConfigurationCrawlerProtection = "enabled" SuperBotFightModeLikelyConfigurationCrawlerProtectionDisabled SuperBotFightModeLikelyConfigurationCrawlerProtection = "disabled" )
func (SuperBotFightModeLikelyConfigurationCrawlerProtection) IsKnown ¶
func (r SuperBotFightModeLikelyConfigurationCrawlerProtection) IsKnown() bool
type SuperBotFightModeLikelyConfigurationParam ¶
type SuperBotFightModeLikelyConfigurationParam struct {
// Enable rule to block AI Scrapers and Crawlers. Please note the value
// `only_on_ad_pages` is currently not available for Enterprise customers.
AIBotsProtection param.Field[SuperBotFightModeLikelyConfigurationAIBotsProtection] `json:"ai_bots_protection"`
// Enable rule to punish AI Scrapers and Crawlers via a link maze.
CrawlerProtection param.Field[SuperBotFightModeLikelyConfigurationCrawlerProtection] `json:"crawler_protection"`
// Use lightweight, invisible JavaScript detections to improve Bot Management.
// [Learn more about JavaScript Detections](https://developers.cloudflare.com/bots/reference/javascript-detections/).
EnableJS param.Field[bool] `json:"enable_js"`
// Enable cloudflare managed robots.txt. If an existing robots.txt is detected,
// then managed robots.txt will be prepended to the existing robots.txt.
IsRobotsTXTManaged param.Field[bool] `json:"is_robots_txt_managed"`
// Whether to optimize Super Bot Fight Mode protections for Wordpress.
OptimizeWordpress param.Field[bool] `json:"optimize_wordpress"`
// Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
SBFMDefinitelyAutomated param.Field[SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomated] `json:"sbfm_definitely_automated"`
// Super Bot Fight Mode (SBFM) action to take on likely automated requests.
SBFMLikelyAutomated param.Field[SuperBotFightModeLikelyConfigurationSBFMLikelyAutomated] `json:"sbfm_likely_automated"`
// Super Bot Fight Mode (SBFM) to enable static resource protection. Enable if
// static resources on your application need bot protection. Note: Static resource
// protection can also result in legitimate traffic being blocked.
SBFMStaticResourceProtection param.Field[bool] `json:"sbfm_static_resource_protection"`
// Super Bot Fight Mode (SBFM) action to take on verified bots requests.
SBFMVerifiedBots param.Field[SuperBotFightModeLikelyConfigurationSBFMVerifiedBots] `json:"sbfm_verified_bots"`
}
func (SuperBotFightModeLikelyConfigurationParam) MarshalJSON ¶
func (r SuperBotFightModeLikelyConfigurationParam) MarshalJSON() (data []byte, err error)
type SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomated ¶
type SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomated string
Super Bot Fight Mode (SBFM) action to take on definitely automated requests.
const ( SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomatedAllow SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomated = "allow" SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomatedBlock SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomated = "block" SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomatedManagedChallenge SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomated = "managed_challenge" )
func (SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomated) IsKnown ¶
func (r SuperBotFightModeLikelyConfigurationSBFMDefinitelyAutomated) IsKnown() bool
type SuperBotFightModeLikelyConfigurationSBFMLikelyAutomated ¶
type SuperBotFightModeLikelyConfigurationSBFMLikelyAutomated string
Super Bot Fight Mode (SBFM) action to take on likely automated requests.
const ( SuperBotFightModeLikelyConfigurationSBFMLikelyAutomatedAllow SuperBotFightModeLikelyConfigurationSBFMLikelyAutomated = "allow" SuperBotFightModeLikelyConfigurationSBFMLikelyAutomatedBlock SuperBotFightModeLikelyConfigurationSBFMLikelyAutomated = "block" SuperBotFightModeLikelyConfigurationSBFMLikelyAutomatedManagedChallenge SuperBotFightModeLikelyConfigurationSBFMLikelyAutomated = "managed_challenge" )
func (SuperBotFightModeLikelyConfigurationSBFMLikelyAutomated) IsKnown ¶
func (r SuperBotFightModeLikelyConfigurationSBFMLikelyAutomated) IsKnown() bool
type SuperBotFightModeLikelyConfigurationSBFMVerifiedBots ¶
type SuperBotFightModeLikelyConfigurationSBFMVerifiedBots string
Super Bot Fight Mode (SBFM) action to take on verified bots requests.
const ( SuperBotFightModeLikelyConfigurationSBFMVerifiedBotsAllow SuperBotFightModeLikelyConfigurationSBFMVerifiedBots = "allow" SuperBotFightModeLikelyConfigurationSBFMVerifiedBotsBlock SuperBotFightModeLikelyConfigurationSBFMVerifiedBots = "block" )
func (SuperBotFightModeLikelyConfigurationSBFMVerifiedBots) IsKnown ¶
func (r SuperBotFightModeLikelyConfigurationSBFMVerifiedBots) IsKnown() bool
type SuperBotFightModeLikelyConfigurationStaleZoneConfiguration ¶
type SuperBotFightModeLikelyConfigurationStaleZoneConfiguration struct {
// Indicates that the zone's Bot Fight Mode is turned on.
FightMode bool `json:"fight_mode"`
JSON superBotFightModeLikelyConfigurationStaleZoneConfigurationJSON `json:"-"`
}
A read-only field that shows which unauthorized settings are currently active on the zone. These settings typically result from upgrades or downgrades.
func (*SuperBotFightModeLikelyConfigurationStaleZoneConfiguration) UnmarshalJSON ¶
func (r *SuperBotFightModeLikelyConfigurationStaleZoneConfiguration) UnmarshalJSON(data []byte) (err error)
type SuperBotFightModeLikelyConfigurationStaleZoneConfigurationParam ¶
type SuperBotFightModeLikelyConfigurationStaleZoneConfigurationParam struct {
// Indicates that the zone's Bot Fight Mode is turned on.
FightMode param.Field[bool] `json:"fight_mode"`
}
A read-only field that shows which unauthorized settings are currently active on the zone. These settings typically result from upgrades or downgrades.
func (SuperBotFightModeLikelyConfigurationStaleZoneConfigurationParam) MarshalJSON ¶
func (r SuperBotFightModeLikelyConfigurationStaleZoneConfigurationParam) MarshalJSON() (data []byte, err error)
type TokenCondition ¶
type TokenCondition = shared.TokenCondition
This is an alias to an internal type.
type TokenConditionCIDRList ¶
type TokenConditionCIDRList = shared.TokenConditionCIDRList
IPv4/IPv6 CIDR.
This is an alias to an internal type.
type TokenConditionCIDRListParam ¶
type TokenConditionCIDRListParam = shared.TokenConditionCIDRListParam
IPv4/IPv6 CIDR.
This is an alias to an internal type.
type TokenConditionParam ¶
type TokenConditionParam = shared.TokenConditionParam
This is an alias to an internal type.
type TokenConditionRequestIP ¶
type TokenConditionRequestIP = shared.TokenConditionRequestIP
Client IP restrictions.
This is an alias to an internal type.
type TokenConditionRequestIPParam ¶
type TokenConditionRequestIPParam = shared.TokenConditionRequestIPParam
Client IP restrictions.
This is an alias to an internal type.
type TokenPolicyEffect ¶
type TokenPolicyEffect = shared.TokenPolicyEffect
Allow or deny operations against the resources.
This is an alias to an internal type.
type TokenPolicyParam ¶
type TokenPolicyParam = shared.TokenPolicyParam
This is an alias to an internal type.
type TokenPolicyPermissionGroup ¶
type TokenPolicyPermissionGroup = shared.TokenPolicyPermissionGroup
A named group of permissions that map to a group of operations against resources.
This is an alias to an internal type.
type TokenPolicyPermissionGroupParam ¶
type TokenPolicyPermissionGroupParam = shared.TokenPolicyPermissionGroupParam
A named group of permissions that map to a group of operations against resources.
This is an alias to an internal type.
type TokenPolicyPermissionGroupsMeta ¶
type TokenPolicyPermissionGroupsMeta = shared.TokenPolicyPermissionGroupsMeta
Attributes associated to the permission group.
This is an alias to an internal type.
type TokenPolicyPermissionGroupsMetaParam ¶
type TokenPolicyPermissionGroupsMetaParam = shared.TokenPolicyPermissionGroupsMetaParam
Attributes associated to the permission group.
This is an alias to an internal type.
type TokenPolicyResourcesIAMResourcesTypeObjectNested ¶
type TokenPolicyResourcesIAMResourcesTypeObjectNested = shared.TokenPolicyResourcesIAMResourcesTypeObjectNested
Map of nested resource permissions
This is an alias to an internal type.
type TokenPolicyResourcesIAMResourcesTypeObjectNestedParam ¶
type TokenPolicyResourcesIAMResourcesTypeObjectNestedParam = shared.TokenPolicyResourcesIAMResourcesTypeObjectNestedParam
Map of nested resource permissions
This is an alias to an internal type.
type TokenPolicyResourcesIAMResourcesTypeObjectString ¶
type TokenPolicyResourcesIAMResourcesTypeObjectString = shared.TokenPolicyResourcesIAMResourcesTypeObjectString
Map of simple string resource permissions
This is an alias to an internal type.
type TokenPolicyResourcesIAMResourcesTypeObjectStringParam ¶
type TokenPolicyResourcesIAMResourcesTypeObjectStringParam = shared.TokenPolicyResourcesIAMResourcesTypeObjectStringParam
Map of simple string resource permissions
This is an alias to an internal type.
type TokenPolicyResourcesUnion ¶
type TokenPolicyResourcesUnion = shared.TokenPolicyResourcesUnion
A list of resource names that the policy applies to.
This is an alias to an internal type.
type TokenPolicyResourcesUnionParam ¶
type TokenPolicyResourcesUnionParam = shared.TokenPolicyResourcesUnionParam
A list of resource names that the policy applies to.
This is an alias to an internal type.
type TokenStatus ¶
type TokenStatus = shared.TokenStatus
Status of the token.
This is an alias to an internal type.
type TokenValue ¶
type TokenValue = shared.TokenValue
The token value.
This is an alias to an internal type.