cache
packageThis package is not in the latest version of its module.
Details
Validgo.mod file
The Go module system was introduced in Go 1.11 and is the official dependency management solution for Go.
Redistributable license
Redistributable licenses place minimal restrictions on how software can be used, modified, and redistributed.
Tagged version
Modules with tagged versions give importers more predictable builds.
Stable version
When a project reaches major version v1 it is considered stable.
- Learn more about best practices
Repository
Links
Documentation¶
Index¶
- Constants
- type ASN
- type ASNParam
- type AuditLog
- type AuditLogAction
- type AuditLogActor
- type AuditLogActorType
- type AuditLogOwner
- type AuditLogResource
- type CachePurgeParams
- type CachePurgeParamsBody
- type CachePurgeParamsBodyCachePurgeEverything
- type CachePurgeParamsBodyCachePurgeFlexPurgeByHostnames
- type CachePurgeParamsBodyCachePurgeFlexPurgeByPrefixes
- type CachePurgeParamsBodyCachePurgeFlexPurgeByTags
- type CachePurgeParamsBodyCachePurgeSingleFile
- type CachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeaders
- type CachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeadersFile
- type CachePurgeParamsBodyUnion
- type CachePurgeResponse
- type CachePurgeResponseEnvelope
- type CachePurgeResponseEnvelopeErrors
- type CachePurgeResponseEnvelopeErrorsSource
- type CachePurgeResponseEnvelopeMessages
- type CachePurgeResponseEnvelopeMessagesSource
- type CachePurgeResponseEnvelopeSuccess
- type CacheReserve
- type CacheReserveClear
- type CacheReserveClearParams
- type CacheReserveClearResponse
- type CacheReserveClearResponseEnvelope
- type CacheReserveClearResponseEnvelopeSuccess
- type CacheReserveEditParams
- type CacheReserveEditParamsValue
- type CacheReserveEditResponse
- type CacheReserveEditResponseEnvelope
- type CacheReserveEditResponseEnvelopeSuccess
- type CacheReserveEditResponseValue
- type CacheReserveGetParams
- type CacheReserveGetResponse
- type CacheReserveGetResponseEnvelope
- type CacheReserveGetResponseEnvelopeSuccess
- type CacheReserveGetResponseValue
- type CacheReserveService
- func (r *CacheReserveService) Clear(ctx context.Context, params CacheReserveClearParams, ...) (res *CacheReserveClearResponse, err error)
- func (r *CacheReserveService) Edit(ctx context.Context, params CacheReserveEditParams, ...) (res *CacheReserveEditResponse, err error)
- func (r *CacheReserveService) Get(ctx context.Context, query CacheReserveGetParams, opts ...option.RequestOption) (res *CacheReserveGetResponse, err error)
- func (r *CacheReserveService) Status(ctx context.Context, query CacheReserveStatusParams, ...) (res *CacheReserveStatusResponse, err error)
- type CacheReserveStatusParams
- type CacheReserveStatusResponse
- type CacheReserveStatusResponseEnvelope
- type CacheReserveStatusResponseEnvelopeSuccess
- type CacheService
- type CertificateCA
- type CertificateRequestType
- type CloudflareTunnel
- 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 RegionalTieredCache
- type RegionalTieredCacheEditParams
- type RegionalTieredCacheEditParamsValue
- type RegionalTieredCacheEditResponse
- type RegionalTieredCacheEditResponseEnvelope
- type RegionalTieredCacheEditResponseEnvelopeSuccess
- type RegionalTieredCacheEditResponseValue
- type RegionalTieredCacheGetParams
- type RegionalTieredCacheGetResponse
- type RegionalTieredCacheGetResponseEnvelope
- type RegionalTieredCacheGetResponseEnvelopeSuccess
- type RegionalTieredCacheGetResponseValue
- type RegionalTieredCacheService
- func (r *RegionalTieredCacheService) Edit(ctx context.Context, params RegionalTieredCacheEditParams, ...) (res *RegionalTieredCacheEditResponse, err error)
- func (r *RegionalTieredCacheService) Get(ctx context.Context, query RegionalTieredCacheGetParams, ...) (res *RegionalTieredCacheGetResponse, err error)
- type ResponseInfo
- type ResponseInfoSource
- type Role
- type RoleParam
- type RolePermissions
- type RolePermissionsParam
- type SmartTieredCacheDeleteParams
- type SmartTieredCacheDeleteResponse
- type SmartTieredCacheDeleteResponseEnvelope
- type SmartTieredCacheDeleteResponseEnvelopeSuccess
- type SmartTieredCacheDeleteResponseID
- type SmartTieredCacheEditParams
- type SmartTieredCacheEditParamsValue
- type SmartTieredCacheEditResponse
- type SmartTieredCacheEditResponseEnvelope
- type SmartTieredCacheEditResponseEnvelopeSuccess
- type SmartTieredCacheEditResponseID
- type SmartTieredCacheEditResponseValue
- type SmartTieredCacheGetParams
- type SmartTieredCacheGetResponse
- type SmartTieredCacheGetResponseEnvelope
- type SmartTieredCacheGetResponseEnvelopeSuccess
- type SmartTieredCacheGetResponseID
- type SmartTieredCacheGetResponseValue
- type SmartTieredCacheService
- func (r *SmartTieredCacheService) Delete(ctx context.Context, body SmartTieredCacheDeleteParams, ...) (res *SmartTieredCacheDeleteResponse, err error)
- func (r *SmartTieredCacheService) Edit(ctx context.Context, params SmartTieredCacheEditParams, ...) (res *SmartTieredCacheEditResponse, err error)
- func (r *SmartTieredCacheService) Get(ctx context.Context, query SmartTieredCacheGetParams, ...) (res *SmartTieredCacheGetResponse, err error)
- type SortDirection
- type State
- type Subscription
- type SubscriptionFrequency
- type SubscriptionParam
- type SubscriptionState
- 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 TokenPolicyResourcesMap
- type TokenPolicyResourcesMapParam
- type TokenPolicyResourcesUnion
- type TokenPolicyResourcesUnionParam
- type TokenStatus
- type TokenValue
- type VariantDeleteParams
- type VariantDeleteResponse
- type VariantDeleteResponseEnvelope
- type VariantDeleteResponseEnvelopeSuccess
- type VariantDeleteResponseID
- type VariantEditParams
- type VariantEditParamsValue
- type VariantEditResponse
- type VariantEditResponseEnvelope
- type VariantEditResponseEnvelopeSuccess
- type VariantEditResponseID
- type VariantGetParams
- type VariantGetResponse
- type VariantGetResponseEnvelope
- type VariantGetResponseEnvelopeSuccess
- type VariantGetResponseID
- type VariantService
- func (r *VariantService) Delete(ctx context.Context, body VariantDeleteParams, opts ...option.RequestOption) (res *VariantDeleteResponse, err error)
- func (r *VariantService) Edit(ctx context.Context, params VariantEditParams, opts ...option.RequestOption) (res *VariantEditResponse, err error)
- func (r *VariantService) Get(ctx context.Context, query VariantGetParams, opts ...option.RequestOption) (res *VariantGetResponse, err error)
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 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¶
typeAuditLogActorType¶
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.
typeAuditLogResource¶
type AuditLogResource =shared.AuditLogResource
This is an alias to an internal type.
typeCachePurgeParams¶
type CachePurgeParams struct {ZoneIDparam.Field[string] `path:"zone_id,required"`BodyCachePurgeParamsBodyUnion `json:"body,required"`}
func (CachePurgeParams)MarshalJSON¶
func (rCachePurgeParams) MarshalJSON() (data []byte, errerror)
typeCachePurgeParamsBody¶
type CachePurgeParamsBody struct {Filesparam.Field[interface{}] `json:"files"`Hostsparam.Field[interface{}] `json:"hosts"`Prefixesparam.Field[interface{}] `json:"prefixes"`// For more information, please refer to// [purge everything documentation page](https://developers.cloudflare.com/cache/how-to/purge-cache/purge-everything/).PurgeEverythingparam.Field[bool] `json:"purge_everything"`Tagsparam.Field[interface{}] `json:"tags"`}
func (CachePurgeParamsBody)MarshalJSON¶
func (rCachePurgeParamsBody) MarshalJSON() (data []byte, errerror)
typeCachePurgeParamsBodyCachePurgeEverything¶
type CachePurgeParamsBodyCachePurgeEverything struct {// For more information, please refer to// [purge everything documentation page](https://developers.cloudflare.com/cache/how-to/purge-cache/purge-everything/).PurgeEverythingparam.Field[bool] `json:"purge_everything"`}
func (CachePurgeParamsBodyCachePurgeEverything)MarshalJSON¶
func (rCachePurgeParamsBodyCachePurgeEverything) MarshalJSON() (data []byte, errerror)
typeCachePurgeParamsBodyCachePurgeFlexPurgeByHostnames¶
type CachePurgeParamsBodyCachePurgeFlexPurgeByHostnames struct {// For more information purging by hostnames, please refer to// [purge by hostname documentation page](https://developers.cloudflare.com/cache/how-to/purge-cache/purge-by-hostname/).Hostsparam.Field[[]string] `json:"hosts"`}
func (CachePurgeParamsBodyCachePurgeFlexPurgeByHostnames)MarshalJSON¶
func (rCachePurgeParamsBodyCachePurgeFlexPurgeByHostnames) MarshalJSON() (data []byte, errerror)
typeCachePurgeParamsBodyCachePurgeFlexPurgeByPrefixes¶
type CachePurgeParamsBodyCachePurgeFlexPurgeByPrefixes struct {// For more information on purging by prefixes, please refer to// [purge by prefix documentation page](https://developers.cloudflare.com/cache/how-to/purge-cache/purge_by_prefix/).Prefixesparam.Field[[]string] `json:"prefixes"`}
func (CachePurgeParamsBodyCachePurgeFlexPurgeByPrefixes)MarshalJSON¶
func (rCachePurgeParamsBodyCachePurgeFlexPurgeByPrefixes) MarshalJSON() (data []byte, errerror)
typeCachePurgeParamsBodyCachePurgeFlexPurgeByTags¶
type CachePurgeParamsBodyCachePurgeFlexPurgeByTags struct {// For more information on cache tags and purging by tags, please refer to// [purge by cache-tags documentation page](https://developers.cloudflare.com/cache/how-to/purge-cache/purge-by-tags/).Tagsparam.Field[[]string] `json:"tags"`}
func (CachePurgeParamsBodyCachePurgeFlexPurgeByTags)MarshalJSON¶
func (rCachePurgeParamsBodyCachePurgeFlexPurgeByTags) MarshalJSON() (data []byte, errerror)
typeCachePurgeParamsBodyCachePurgeSingleFile¶
type CachePurgeParamsBodyCachePurgeSingleFile struct {// For more information on purging files, please refer to// [purge by single-file documentation page](https://developers.cloudflare.com/cache/how-to/purge-cache/purge-by-single-file/).Filesparam.Field[[]string] `json:"files"`}
func (CachePurgeParamsBodyCachePurgeSingleFile)MarshalJSON¶
func (rCachePurgeParamsBodyCachePurgeSingleFile) MarshalJSON() (data []byte, errerror)
typeCachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeaders¶
type CachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeaders struct {// For more information on purging files with URL and headers, please refer to// [purge by single-file documentation page](https://developers.cloudflare.com/cache/how-to/purge-cache/purge-by-single-file/).Filesparam.Field[[]CachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeadersFile] `json:"files"`}
func (CachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeaders)MarshalJSON¶
func (rCachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeaders) MarshalJSON() (data []byte, errerror)
typeCachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeadersFile¶
type CachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeadersFile struct {Headersparam.Field[map[string]string] `json:"headers"`URLparam.Field[string] `json:"url"`}
func (CachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeadersFile)MarshalJSON¶
func (rCachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeadersFile) MarshalJSON() (data []byte, errerror)
typeCachePurgeParamsBodyUnion¶
type CachePurgeParamsBodyUnion interface {// contains filtered or unexported methods}
Satisfied bycache.CachePurgeParamsBodyCachePurgeFlexPurgeByTags,cache.CachePurgeParamsBodyCachePurgeFlexPurgeByHostnames,cache.CachePurgeParamsBodyCachePurgeFlexPurgeByPrefixes,cache.CachePurgeParamsBodyCachePurgeEverything,cache.CachePurgeParamsBodyCachePurgeSingleFile,cache.CachePurgeParamsBodyCachePurgeSingleFileWithURLAndHeaders,CachePurgeParamsBody.
typeCachePurgeResponse¶
type CachePurgeResponse struct {// Identifier.IDstring `json:"id,required"`JSON cachePurgeResponseJSON `json:"-"`}
func (*CachePurgeResponse)UnmarshalJSON¶
func (r *CachePurgeResponse) UnmarshalJSON(data []byte) (errerror)
typeCachePurgeResponseEnvelope¶
type CachePurgeResponseEnvelope struct {Errors []CachePurgeResponseEnvelopeErrors `json:"errors,required"`Messages []CachePurgeResponseEnvelopeMessages `json:"messages,required"`// Whether the API call was successful.SuccessCachePurgeResponseEnvelopeSuccess `json:"success,required"`ResultCachePurgeResponse `json:"result,nullable"`JSON cachePurgeResponseEnvelopeJSON `json:"-"`}
func (*CachePurgeResponseEnvelope)UnmarshalJSON¶
func (r *CachePurgeResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeCachePurgeResponseEnvelopeErrors¶added inv4.3.0
type CachePurgeResponseEnvelopeErrors struct {Codeint64 `json:"code,required"`Messagestring `json:"message,required"`DocumentationURLstring `json:"documentation_url"`SourceCachePurgeResponseEnvelopeErrorsSource `json:"source"`JSON cachePurgeResponseEnvelopeErrorsJSON `json:"-"`}
func (*CachePurgeResponseEnvelopeErrors)UnmarshalJSON¶added inv4.3.0
func (r *CachePurgeResponseEnvelopeErrors) UnmarshalJSON(data []byte) (errerror)
typeCachePurgeResponseEnvelopeErrorsSource¶added inv4.3.0
type CachePurgeResponseEnvelopeErrorsSource struct {Pointerstring `json:"pointer"`JSON cachePurgeResponseEnvelopeErrorsSourceJSON `json:"-"`}
func (*CachePurgeResponseEnvelopeErrorsSource)UnmarshalJSON¶added inv4.3.0
func (r *CachePurgeResponseEnvelopeErrorsSource) UnmarshalJSON(data []byte) (errerror)
typeCachePurgeResponseEnvelopeMessages¶added inv4.3.0
type CachePurgeResponseEnvelopeMessages struct {Codeint64 `json:"code,required"`Messagestring `json:"message,required"`DocumentationURLstring `json:"documentation_url"`SourceCachePurgeResponseEnvelopeMessagesSource `json:"source"`JSON cachePurgeResponseEnvelopeMessagesJSON `json:"-"`}
func (*CachePurgeResponseEnvelopeMessages)UnmarshalJSON¶added inv4.3.0
func (r *CachePurgeResponseEnvelopeMessages) UnmarshalJSON(data []byte) (errerror)
typeCachePurgeResponseEnvelopeMessagesSource¶added inv4.3.0
type CachePurgeResponseEnvelopeMessagesSource struct {Pointerstring `json:"pointer"`JSON cachePurgeResponseEnvelopeMessagesSourceJSON `json:"-"`}
func (*CachePurgeResponseEnvelopeMessagesSource)UnmarshalJSON¶added inv4.3.0
func (r *CachePurgeResponseEnvelopeMessagesSource) UnmarshalJSON(data []byte) (errerror)
typeCachePurgeResponseEnvelopeSuccess¶
type CachePurgeResponseEnvelopeSuccessbool
Whether the API call was successful.
const (CachePurgeResponseEnvelopeSuccessTrueCachePurgeResponseEnvelopeSuccess =true)
func (CachePurgeResponseEnvelopeSuccess)IsKnown¶
func (rCachePurgeResponseEnvelopeSuccess) IsKnown()bool
typeCacheReserve¶
type CacheReservestring
ID of the zone setting.
const (CacheReserveCacheReserveCacheReserve = "cache_reserve")
func (CacheReserve)IsKnown¶
func (rCacheReserve) IsKnown()bool
typeCacheReserveClear¶
type CacheReserveClearstring
ID of the zone setting.
const (CacheReserveClearCacheReserveClearCacheReserveClear = "cache_reserve_clear")
func (CacheReserveClear)IsKnown¶
func (rCacheReserveClear) IsKnown()bool
typeCacheReserveClearParams¶
type CacheReserveClearParams struct {// IdentifierZoneIDparam.Field[string] `path:"zone_id,required"`Body interface{} `json:"body,required"`}
func (CacheReserveClearParams)MarshalJSON¶
func (rCacheReserveClearParams) MarshalJSON() (data []byte, errerror)
typeCacheReserveClearResponse¶
type CacheReserveClearResponse struct {// ID of the zone setting.IDCacheReserveClear `json:"id,required"`// The time that the latest Cache Reserve Clear operation started.StartTstime.Time `json:"start_ts,required" format:"date-time"`// The current state of the Cache Reserve Clear operation.StateState `json:"state,required"`// The time that the latest Cache Reserve Clear operation completed.EndTstime.Time `json:"end_ts" format:"date-time"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON cacheReserveClearResponseJSON `json:"-"`}
You can use Cache Reserve Clear to clear your Cache Reserve, but you must firstdisable Cache Reserve. In most cases, this will be accomplished within 24 hours.You cannot re-enable Cache Reserve while this process is ongoing. Keep in mindthat you cannot undo or cancel this operation.
func (*CacheReserveClearResponse)UnmarshalJSON¶
func (r *CacheReserveClearResponse) UnmarshalJSON(data []byte) (errerror)
typeCacheReserveClearResponseEnvelope¶
type CacheReserveClearResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessCacheReserveClearResponseEnvelopeSuccess `json:"success,required"`// You can use Cache Reserve Clear to clear your Cache Reserve, but you must first// disable Cache Reserve. In most cases, this will be accomplished within 24 hours.// You cannot re-enable Cache Reserve while this process is ongoing. Keep in mind// that you cannot undo or cancel this operation.ResultCacheReserveClearResponse `json:"result"`JSON cacheReserveClearResponseEnvelopeJSON `json:"-"`}
func (*CacheReserveClearResponseEnvelope)UnmarshalJSON¶
func (r *CacheReserveClearResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeCacheReserveClearResponseEnvelopeSuccess¶
type CacheReserveClearResponseEnvelopeSuccessbool
Whether the API call was successful
const (CacheReserveClearResponseEnvelopeSuccessTrueCacheReserveClearResponseEnvelopeSuccess =true)
func (CacheReserveClearResponseEnvelopeSuccess)IsKnown¶
func (rCacheReserveClearResponseEnvelopeSuccess) IsKnown()bool
typeCacheReserveEditParams¶
type CacheReserveEditParams struct {// IdentifierZoneIDparam.Field[string] `path:"zone_id,required"`// Value of the Cache Reserve zone setting.Valueparam.Field[CacheReserveEditParamsValue] `json:"value,required"`}
func (CacheReserveEditParams)MarshalJSON¶
func (rCacheReserveEditParams) MarshalJSON() (data []byte, errerror)
typeCacheReserveEditParamsValue¶
type CacheReserveEditParamsValuestring
Value of the Cache Reserve zone setting.
const (CacheReserveEditParamsValueOnCacheReserveEditParamsValue = "on"CacheReserveEditParamsValueOffCacheReserveEditParamsValue = "off")
func (CacheReserveEditParamsValue)IsKnown¶
func (rCacheReserveEditParamsValue) IsKnown()bool
typeCacheReserveEditResponse¶
type CacheReserveEditResponse struct {// ID of the zone setting.IDCacheReserve `json:"id,required"`// Whether the setting is editableEditablebool `json:"editable,required"`// The value of the featureValueCacheReserveEditResponseValue `json:"value,required"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON cacheReserveEditResponseJSON `json:"-"`}
func (*CacheReserveEditResponse)UnmarshalJSON¶
func (r *CacheReserveEditResponse) UnmarshalJSON(data []byte) (errerror)
typeCacheReserveEditResponseEnvelope¶
type CacheReserveEditResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessCacheReserveEditResponseEnvelopeSuccess `json:"success,required"`ResultCacheReserveEditResponse `json:"result"`JSON cacheReserveEditResponseEnvelopeJSON `json:"-"`}
func (*CacheReserveEditResponseEnvelope)UnmarshalJSON¶
func (r *CacheReserveEditResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeCacheReserveEditResponseEnvelopeSuccess¶
type CacheReserveEditResponseEnvelopeSuccessbool
Whether the API call was successful
const (CacheReserveEditResponseEnvelopeSuccessTrueCacheReserveEditResponseEnvelopeSuccess =true)
func (CacheReserveEditResponseEnvelopeSuccess)IsKnown¶
func (rCacheReserveEditResponseEnvelopeSuccess) IsKnown()bool
typeCacheReserveEditResponseValue¶
type CacheReserveEditResponseValuestring
The value of the feature
const (CacheReserveEditResponseValueOnCacheReserveEditResponseValue = "on"CacheReserveEditResponseValueOffCacheReserveEditResponseValue = "off")
func (CacheReserveEditResponseValue)IsKnown¶
func (rCacheReserveEditResponseValue) IsKnown()bool
typeCacheReserveGetResponse¶
type CacheReserveGetResponse struct {// ID of the zone setting.IDCacheReserve `json:"id,required"`// Whether the setting is editableEditablebool `json:"editable,required"`// The value of the featureValueCacheReserveGetResponseValue `json:"value,required"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON cacheReserveGetResponseJSON `json:"-"`}
func (*CacheReserveGetResponse)UnmarshalJSON¶
func (r *CacheReserveGetResponse) UnmarshalJSON(data []byte) (errerror)
typeCacheReserveGetResponseEnvelope¶
type CacheReserveGetResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessCacheReserveGetResponseEnvelopeSuccess `json:"success,required"`ResultCacheReserveGetResponse `json:"result"`JSON cacheReserveGetResponseEnvelopeJSON `json:"-"`}
func (*CacheReserveGetResponseEnvelope)UnmarshalJSON¶
func (r *CacheReserveGetResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeCacheReserveGetResponseEnvelopeSuccess¶
type CacheReserveGetResponseEnvelopeSuccessbool
Whether the API call was successful
const (CacheReserveGetResponseEnvelopeSuccessTrueCacheReserveGetResponseEnvelopeSuccess =true)
func (CacheReserveGetResponseEnvelopeSuccess)IsKnown¶
func (rCacheReserveGetResponseEnvelopeSuccess) IsKnown()bool
typeCacheReserveGetResponseValue¶
type CacheReserveGetResponseValuestring
The value of the feature
const (CacheReserveGetResponseValueOnCacheReserveGetResponseValue = "on"CacheReserveGetResponseValueOffCacheReserveGetResponseValue = "off")
func (CacheReserveGetResponseValue)IsKnown¶
func (rCacheReserveGetResponseValue) IsKnown()bool
typeCacheReserveService¶
type CacheReserveService struct {Options []option.RequestOption}
CacheReserveService contains methods and other services that help withinteracting with the cloudflare API.
Note, unlike clients, this service does not read variables from the environmentautomatically. You should not instantiate this service directly, and instead usetheNewCacheReserveService method instead.
funcNewCacheReserveService¶
func NewCacheReserveService(opts ...option.RequestOption) (r *CacheReserveService)
NewCacheReserveService generates a new service that applies the given options toeach request. These options are applied after the parent client's options (ifthere is one), and before any request-specific options.
func (*CacheReserveService)Clear¶
func (r *CacheReserveService) Clear(ctxcontext.Context, paramsCacheReserveClearParams, opts ...option.RequestOption) (res *CacheReserveClearResponse, errerror)
You can use Cache Reserve Clear to clear your Cache Reserve, but you must firstdisable Cache Reserve. In most cases, this will be accomplished within 24 hours.You cannot re-enable Cache Reserve while this process is ongoing. Keep in mindthat you cannot undo or cancel this operation.
func (*CacheReserveService)Edit¶
func (r *CacheReserveService) Edit(ctxcontext.Context, paramsCacheReserveEditParams, opts ...option.RequestOption) (res *CacheReserveEditResponse, errerror)
Increase cache lifetimes by automatically storing all cacheable files intoCloudflare's persistent object storage buckets. Requires Cache Reservesubscription. Note: using Tiered Cache with Cache Reserve is highly recommendedto reduce Reserve operations costs. See the[developer docs](https://developers.cloudflare.com/cache/about/cache-reserve)for more information.
func (*CacheReserveService)Get¶
func (r *CacheReserveService) Get(ctxcontext.Context, queryCacheReserveGetParams, opts ...option.RequestOption) (res *CacheReserveGetResponse, errerror)
Increase cache lifetimes by automatically storing all cacheable files intoCloudflare's persistent object storage buckets. Requires Cache Reservesubscription. Note: using Tiered Cache with Cache Reserve is highly recommendedto reduce Reserve operations costs. See the[developer docs](https://developers.cloudflare.com/cache/about/cache-reserve)for more information.
func (*CacheReserveService)Status¶
func (r *CacheReserveService) Status(ctxcontext.Context, queryCacheReserveStatusParams, opts ...option.RequestOption) (res *CacheReserveStatusResponse, errerror)
You can use Cache Reserve Clear to clear your Cache Reserve, but you must firstdisable Cache Reserve. In most cases, this will be accomplished within 24 hours.You cannot re-enable Cache Reserve while this process is ongoing. Keep in mindthat you cannot undo or cancel this operation.
typeCacheReserveStatusResponse¶
type CacheReserveStatusResponse struct {// ID of the zone setting.IDCacheReserveClear `json:"id,required"`// The time that the latest Cache Reserve Clear operation started.StartTstime.Time `json:"start_ts,required" format:"date-time"`// The current state of the Cache Reserve Clear operation.StateState `json:"state,required"`// The time that the latest Cache Reserve Clear operation completed.EndTstime.Time `json:"end_ts" format:"date-time"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON cacheReserveStatusResponseJSON `json:"-"`}
You can use Cache Reserve Clear to clear your Cache Reserve, but you must firstdisable Cache Reserve. In most cases, this will be accomplished within 24 hours.You cannot re-enable Cache Reserve while this process is ongoing. Keep in mindthat you cannot undo or cancel this operation.
func (*CacheReserveStatusResponse)UnmarshalJSON¶
func (r *CacheReserveStatusResponse) UnmarshalJSON(data []byte) (errerror)
typeCacheReserveStatusResponseEnvelope¶
type CacheReserveStatusResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessCacheReserveStatusResponseEnvelopeSuccess `json:"success,required"`// You can use Cache Reserve Clear to clear your Cache Reserve, but you must first// disable Cache Reserve. In most cases, this will be accomplished within 24 hours.// You cannot re-enable Cache Reserve while this process is ongoing. Keep in mind// that you cannot undo or cancel this operation.ResultCacheReserveStatusResponse `json:"result"`JSON cacheReserveStatusResponseEnvelopeJSON `json:"-"`}
func (*CacheReserveStatusResponseEnvelope)UnmarshalJSON¶
func (r *CacheReserveStatusResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeCacheReserveStatusResponseEnvelopeSuccess¶
type CacheReserveStatusResponseEnvelopeSuccessbool
Whether the API call was successful
const (CacheReserveStatusResponseEnvelopeSuccessTrueCacheReserveStatusResponseEnvelopeSuccess =true)
func (CacheReserveStatusResponseEnvelopeSuccess)IsKnown¶
func (rCacheReserveStatusResponseEnvelopeSuccess) IsKnown()bool
typeCacheService¶
type CacheService struct {Options []option.RequestOptionCacheReserve *CacheReserveServiceSmartTieredCache *SmartTieredCacheServiceVariants *VariantServiceRegionalTieredCache *RegionalTieredCacheService}
CacheService contains methods and other services that help with interacting withthe cloudflare API.
Note, unlike clients, this service does not read variables from the environmentautomatically. You should not instantiate this service directly, and instead usetheNewCacheService method instead.
funcNewCacheService¶
func NewCacheService(opts ...option.RequestOption) (r *CacheService)
NewCacheService generates a new service that applies the given options to eachrequest. These options are applied after the parent client's options (if thereis one), and before any request-specific options.
func (*CacheService)Purge¶
func (r *CacheService) Purge(ctxcontext.Context, paramsCachePurgeParams, opts ...option.RequestOption) (res *CachePurgeResponse, errerror)
### Purge All Cached Content
Removes ALL files from Cloudflare's cache. All tiers can purge everything.
```{"purge_everything": true}```
### Purge Cached Content by URL
Granularly removes one or more files from Cloudflare's cache by specifying URLs.All tiers can purge by URL.
To purge files with custom cache keys, include the headers used to compute thecache key as in the example. If you have a device type or geo in your cache key,you will need to include the CF-Device-Type or CF-IPCountry headers. If you havelang in your cache key, you will need to include the Accept-Language header.
**NB:** When including the Origin header, be sure to include the **scheme** and**hostname**. The port number can be omitted if it is the default port (80 forhttp, 443 for https), but must be included otherwise.
Single file purge example with files:
```{"files": ["http://www.example.com/css/styles.css", "http://www.example.com/js/index.js"]}```
Single file purge example with url and header pairs:
```{"files": [{url: "http://www.example.com/cat_picture.jpg", headers: { "CF-IPCountry": "US", "CF-Device-Type": "desktop", "Accept-Language": "zh-CN" }}, {url: "http://www.example.com/dog_picture.jpg", headers: { "CF-IPCountry": "EU", "CF-Device-Type": "mobile", "Accept-Language": "en-US" }}]}```
### Purge Cached Content by Tag, Host or Prefix
Granularly removes one or more files from Cloudflare's cache either byspecifying the host, the associated Cache-Tag, or a Prefix.
Flex purge with tags:
```{"tags": ["a-cache-tag", "another-cache-tag"]}```
Flex purge with hosts:
```{"hosts": ["www.example.com", "images.example.com"]}```
Flex purge with prefixes:
```{"prefixes": ["www.example.com/foo", "images.example.com/bar/baz"]}```
### Availability and limits
please refer to[purge cache availability and limits documentation page](https://developers.cloudflare.com/cache/how-to/purge-cache/#availability-and-limits).
typeCertificateCA¶
type CertificateCA =shared.CertificateCA
The Certificate Authority that will issue the certificate
This is an alias to an internal type.
typeCertificateRequestType¶
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.
typeCloudflareTunnel¶
type CloudflareTunnel =shared.CloudflareTunnel
A Cloudflare Tunnel that connects your origin to Cloudflare's edge.
This is an alias to an internal type.
typeCloudflareTunnelConnection¶
type CloudflareTunnelConnection =shared.CloudflareTunnelConnection
This is an alias to an internal type.
typeCloudflareTunnelStatus¶
type CloudflareTunnelStatus =shared.CloudflareTunnelStatus
The status of the tunnel. Valid values are `inactive` (tunnel has never beenrun), `degraded` (tunnel is active and able to serve traffic but in an unhealthystate), `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.
typeCloudflareTunnelTunType¶
type CloudflareTunnelTunType =shared.CloudflareTunnelTunType
The type of tunnel.
This is an alias to an internal type.
typeErrorDataSource¶added inv4.2.0
type ErrorDataSource =shared.ErrorDataSource
This is an alias to an internal type.
typeMemberPoliciesAccess¶
type MemberPoliciesAccess =shared.MemberPoliciesAccess
Allow or deny operations against the resources.
This is an alias to an internal type.
typeMemberPoliciesPermissionGroup¶
type MemberPoliciesPermissionGroup =shared.MemberPoliciesPermissionGroup
A named group of permissions that map to a group of operations againstresources.
This is an alias to an internal type.
typeMemberPoliciesPermissionGroupsMeta¶
type MemberPoliciesPermissionGroupsMeta =shared.MemberPoliciesPermissionGroupsMeta
Attributes associated to the permission group.
This is an alias to an internal type.
typeMemberPoliciesResourceGroup¶
type MemberPoliciesResourceGroup =shared.MemberPoliciesResourceGroup
A group of scoped resources.
This is an alias to an internal type.
typeMemberPoliciesResourceGroupsMeta¶
type MemberPoliciesResourceGroupsMeta =shared.MemberPoliciesResourceGroupsMeta
Attributes associated to the resource group.
This is an alias to an internal type.
typeMemberPoliciesResourceGroupsScope¶
type MemberPoliciesResourceGroupsScope =shared.MemberPoliciesResourceGroupsScope
A scope is a combination of scope objects which provides additional context.
This is an alias to an internal type.
typeMemberPoliciesResourceGroupsScopeObject¶
type MemberPoliciesResourceGroupsScopeObject =shared.MemberPoliciesResourceGroupsScopeObject
A scope object represents any resource that can have actions applied againstinvite.
This is an alias to an internal type.
typeMemberStatus¶
type MemberStatus =shared.MemberStatus
A member's status in the account.
This is an alias to an internal type.
typeMemberUser¶
type MemberUser =shared.MemberUser
Details of the user associated to the membership.
This is an alias to an internal type.
typePermissionGrant¶
type PermissionGrant =shared.PermissionGrant
This is an alias to an internal type.
typePermissionGrantParam¶
type PermissionGrantParam =shared.PermissionGrantParam
This is an alias to an internal type.
typeRatePlanID¶added inv4.1.0
type RatePlanID =shared.RatePlanID
The ID of the rate plan.
This is an alias to an internal type.
typeRatePlanParam¶
type RatePlanParam =shared.RatePlanParam
The rate plan applied to the subscription.
This is an alias to an internal type.
typeRegionalTieredCache¶
type RegionalTieredCachestring
ID of the zone setting.
const (RegionalTieredCacheTcRegionalRegionalTieredCache = "tc_regional")
func (RegionalTieredCache)IsKnown¶
func (rRegionalTieredCache) IsKnown()bool
typeRegionalTieredCacheEditParams¶
type RegionalTieredCacheEditParams struct {// IdentifierZoneIDparam.Field[string] `path:"zone_id,required"`// Value of the Regional Tiered Cache zone setting.Valueparam.Field[RegionalTieredCacheEditParamsValue] `json:"value,required"`}
func (RegionalTieredCacheEditParams)MarshalJSON¶
func (rRegionalTieredCacheEditParams) MarshalJSON() (data []byte, errerror)
typeRegionalTieredCacheEditParamsValue¶
type RegionalTieredCacheEditParamsValuestring
Value of the Regional Tiered Cache zone setting.
const (RegionalTieredCacheEditParamsValueOnRegionalTieredCacheEditParamsValue = "on"RegionalTieredCacheEditParamsValueOffRegionalTieredCacheEditParamsValue = "off")
func (RegionalTieredCacheEditParamsValue)IsKnown¶
func (rRegionalTieredCacheEditParamsValue) IsKnown()bool
typeRegionalTieredCacheEditResponse¶
type RegionalTieredCacheEditResponse struct {// ID of the zone setting.IDRegionalTieredCache `json:"id,required"`// Whether the setting is editableEditablebool `json:"editable,required"`// The value of the featureValueRegionalTieredCacheEditResponseValue `json:"value,required"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON regionalTieredCacheEditResponseJSON `json:"-"`}
func (*RegionalTieredCacheEditResponse)UnmarshalJSON¶
func (r *RegionalTieredCacheEditResponse) UnmarshalJSON(data []byte) (errerror)
typeRegionalTieredCacheEditResponseEnvelope¶
type RegionalTieredCacheEditResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessRegionalTieredCacheEditResponseEnvelopeSuccess `json:"success,required"`ResultRegionalTieredCacheEditResponse `json:"result"`JSON regionalTieredCacheEditResponseEnvelopeJSON `json:"-"`}
func (*RegionalTieredCacheEditResponseEnvelope)UnmarshalJSON¶
func (r *RegionalTieredCacheEditResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeRegionalTieredCacheEditResponseEnvelopeSuccess¶
type RegionalTieredCacheEditResponseEnvelopeSuccessbool
Whether the API call was successful
const (RegionalTieredCacheEditResponseEnvelopeSuccessTrueRegionalTieredCacheEditResponseEnvelopeSuccess =true)
func (RegionalTieredCacheEditResponseEnvelopeSuccess)IsKnown¶
func (rRegionalTieredCacheEditResponseEnvelopeSuccess) IsKnown()bool
typeRegionalTieredCacheEditResponseValue¶
type RegionalTieredCacheEditResponseValuestring
The value of the feature
const (RegionalTieredCacheEditResponseValueOnRegionalTieredCacheEditResponseValue = "on"RegionalTieredCacheEditResponseValueOffRegionalTieredCacheEditResponseValue = "off")
func (RegionalTieredCacheEditResponseValue)IsKnown¶
func (rRegionalTieredCacheEditResponseValue) IsKnown()bool
typeRegionalTieredCacheGetResponse¶
type RegionalTieredCacheGetResponse struct {// ID of the zone setting.IDRegionalTieredCache `json:"id,required"`// Whether the setting is editableEditablebool `json:"editable,required"`// The value of the featureValueRegionalTieredCacheGetResponseValue `json:"value,required"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON regionalTieredCacheGetResponseJSON `json:"-"`}
func (*RegionalTieredCacheGetResponse)UnmarshalJSON¶
func (r *RegionalTieredCacheGetResponse) UnmarshalJSON(data []byte) (errerror)
typeRegionalTieredCacheGetResponseEnvelope¶
type RegionalTieredCacheGetResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessRegionalTieredCacheGetResponseEnvelopeSuccess `json:"success,required"`ResultRegionalTieredCacheGetResponse `json:"result"`JSON regionalTieredCacheGetResponseEnvelopeJSON `json:"-"`}
func (*RegionalTieredCacheGetResponseEnvelope)UnmarshalJSON¶
func (r *RegionalTieredCacheGetResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeRegionalTieredCacheGetResponseEnvelopeSuccess¶
type RegionalTieredCacheGetResponseEnvelopeSuccessbool
Whether the API call was successful
const (RegionalTieredCacheGetResponseEnvelopeSuccessTrueRegionalTieredCacheGetResponseEnvelopeSuccess =true)
func (RegionalTieredCacheGetResponseEnvelopeSuccess)IsKnown¶
func (rRegionalTieredCacheGetResponseEnvelopeSuccess) IsKnown()bool
typeRegionalTieredCacheGetResponseValue¶
type RegionalTieredCacheGetResponseValuestring
The value of the feature
const (RegionalTieredCacheGetResponseValueOnRegionalTieredCacheGetResponseValue = "on"RegionalTieredCacheGetResponseValueOffRegionalTieredCacheGetResponseValue = "off")
func (RegionalTieredCacheGetResponseValue)IsKnown¶
func (rRegionalTieredCacheGetResponseValue) IsKnown()bool
typeRegionalTieredCacheService¶
type RegionalTieredCacheService struct {Options []option.RequestOption}
RegionalTieredCacheService contains methods and other services that help withinteracting with the cloudflare API.
Note, unlike clients, this service does not read variables from the environmentautomatically. You should not instantiate this service directly, and instead usetheNewRegionalTieredCacheService method instead.
funcNewRegionalTieredCacheService¶
func NewRegionalTieredCacheService(opts ...option.RequestOption) (r *RegionalTieredCacheService)
NewRegionalTieredCacheService generates a new service that applies the givenoptions to each request. These options are applied after the parent client'soptions (if there is one), and before any request-specific options.
func (*RegionalTieredCacheService)Edit¶
func (r *RegionalTieredCacheService) Edit(ctxcontext.Context, paramsRegionalTieredCacheEditParams, opts ...option.RequestOption) (res *RegionalTieredCacheEditResponse, errerror)
Instructs Cloudflare to check a regional hub data center on the way to yourupper tier. This can help improve performance for smart and custom tiered cachetopologies.
func (*RegionalTieredCacheService)Get¶
func (r *RegionalTieredCacheService) Get(ctxcontext.Context, queryRegionalTieredCacheGetParams, opts ...option.RequestOption) (res *RegionalTieredCacheGetResponse, errerror)
Instructs Cloudflare to check a regional hub data center on the way to yourupper tier. This can help improve performance for smart and custom tiered cachetopologies.
typeResponseInfoSource¶added inv4.3.0
type ResponseInfoSource =shared.ResponseInfoSource
This is an alias to an internal type.
typeRolePermissions¶
type RolePermissions =shared.RolePermissions
This is an alias to an internal type.
typeRolePermissionsParam¶
type RolePermissionsParam =shared.RolePermissionsParam
This is an alias to an internal type.
typeSmartTieredCacheDeleteResponse¶
type SmartTieredCacheDeleteResponse struct {// ID of the zone setting.IDSmartTieredCacheDeleteResponseID `json:"id,required"`// Whether the setting is editableEditablebool `json:"editable,required"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON smartTieredCacheDeleteResponseJSON `json:"-"`}
func (*SmartTieredCacheDeleteResponse)UnmarshalJSON¶
func (r *SmartTieredCacheDeleteResponse) UnmarshalJSON(data []byte) (errerror)
typeSmartTieredCacheDeleteResponseEnvelope¶
type SmartTieredCacheDeleteResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessSmartTieredCacheDeleteResponseEnvelopeSuccess `json:"success,required"`ResultSmartTieredCacheDeleteResponse `json:"result"`JSON smartTieredCacheDeleteResponseEnvelopeJSON `json:"-"`}
func (*SmartTieredCacheDeleteResponseEnvelope)UnmarshalJSON¶
func (r *SmartTieredCacheDeleteResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeSmartTieredCacheDeleteResponseEnvelopeSuccess¶
type SmartTieredCacheDeleteResponseEnvelopeSuccessbool
Whether the API call was successful
const (SmartTieredCacheDeleteResponseEnvelopeSuccessTrueSmartTieredCacheDeleteResponseEnvelopeSuccess =true)
func (SmartTieredCacheDeleteResponseEnvelopeSuccess)IsKnown¶
func (rSmartTieredCacheDeleteResponseEnvelopeSuccess) IsKnown()bool
typeSmartTieredCacheDeleteResponseID¶
type SmartTieredCacheDeleteResponseIDstring
ID of the zone setting.
const (SmartTieredCacheDeleteResponseIDTieredCacheSmartTopologyEnableSmartTieredCacheDeleteResponseID = "tiered_cache_smart_topology_enable")
func (SmartTieredCacheDeleteResponseID)IsKnown¶
func (rSmartTieredCacheDeleteResponseID) IsKnown()bool
typeSmartTieredCacheEditParams¶
type SmartTieredCacheEditParams struct {// IdentifierZoneIDparam.Field[string] `path:"zone_id,required"`// Enable or disable the Smart Tiered CacheValueparam.Field[SmartTieredCacheEditParamsValue] `json:"value,required"`}
func (SmartTieredCacheEditParams)MarshalJSON¶
func (rSmartTieredCacheEditParams) MarshalJSON() (data []byte, errerror)
typeSmartTieredCacheEditParamsValue¶
type SmartTieredCacheEditParamsValuestring
Enable or disable the Smart Tiered Cache
const (SmartTieredCacheEditParamsValueOnSmartTieredCacheEditParamsValue = "on"SmartTieredCacheEditParamsValueOffSmartTieredCacheEditParamsValue = "off")
func (SmartTieredCacheEditParamsValue)IsKnown¶
func (rSmartTieredCacheEditParamsValue) IsKnown()bool
typeSmartTieredCacheEditResponse¶
type SmartTieredCacheEditResponse struct {// ID of the zone setting.IDSmartTieredCacheEditResponseID `json:"id,required"`// Whether the setting is editableEditablebool `json:"editable,required"`// The value of the featureValueSmartTieredCacheEditResponseValue `json:"value,required"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON smartTieredCacheEditResponseJSON `json:"-"`}
func (*SmartTieredCacheEditResponse)UnmarshalJSON¶
func (r *SmartTieredCacheEditResponse) UnmarshalJSON(data []byte) (errerror)
typeSmartTieredCacheEditResponseEnvelope¶
type SmartTieredCacheEditResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessSmartTieredCacheEditResponseEnvelopeSuccess `json:"success,required"`ResultSmartTieredCacheEditResponse `json:"result"`JSON smartTieredCacheEditResponseEnvelopeJSON `json:"-"`}
func (*SmartTieredCacheEditResponseEnvelope)UnmarshalJSON¶
func (r *SmartTieredCacheEditResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeSmartTieredCacheEditResponseEnvelopeSuccess¶
type SmartTieredCacheEditResponseEnvelopeSuccessbool
Whether the API call was successful
const (SmartTieredCacheEditResponseEnvelopeSuccessTrueSmartTieredCacheEditResponseEnvelopeSuccess =true)
func (SmartTieredCacheEditResponseEnvelopeSuccess)IsKnown¶
func (rSmartTieredCacheEditResponseEnvelopeSuccess) IsKnown()bool
typeSmartTieredCacheEditResponseID¶
type SmartTieredCacheEditResponseIDstring
ID of the zone setting.
const (SmartTieredCacheEditResponseIDTieredCacheSmartTopologyEnableSmartTieredCacheEditResponseID = "tiered_cache_smart_topology_enable")
func (SmartTieredCacheEditResponseID)IsKnown¶
func (rSmartTieredCacheEditResponseID) IsKnown()bool
typeSmartTieredCacheEditResponseValue¶
type SmartTieredCacheEditResponseValuestring
The value of the feature
const (SmartTieredCacheEditResponseValueOnSmartTieredCacheEditResponseValue = "on"SmartTieredCacheEditResponseValueOffSmartTieredCacheEditResponseValue = "off")
func (SmartTieredCacheEditResponseValue)IsKnown¶
func (rSmartTieredCacheEditResponseValue) IsKnown()bool
typeSmartTieredCacheGetResponse¶
type SmartTieredCacheGetResponse struct {// ID of the zone setting.IDSmartTieredCacheGetResponseID `json:"id,required"`// Whether the setting is editableEditablebool `json:"editable,required"`// The value of the featureValueSmartTieredCacheGetResponseValue `json:"value,required"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON smartTieredCacheGetResponseJSON `json:"-"`}
func (*SmartTieredCacheGetResponse)UnmarshalJSON¶
func (r *SmartTieredCacheGetResponse) UnmarshalJSON(data []byte) (errerror)
typeSmartTieredCacheGetResponseEnvelope¶
type SmartTieredCacheGetResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessSmartTieredCacheGetResponseEnvelopeSuccess `json:"success,required"`ResultSmartTieredCacheGetResponse `json:"result"`JSON smartTieredCacheGetResponseEnvelopeJSON `json:"-"`}
func (*SmartTieredCacheGetResponseEnvelope)UnmarshalJSON¶
func (r *SmartTieredCacheGetResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeSmartTieredCacheGetResponseEnvelopeSuccess¶
type SmartTieredCacheGetResponseEnvelopeSuccessbool
Whether the API call was successful
const (SmartTieredCacheGetResponseEnvelopeSuccessTrueSmartTieredCacheGetResponseEnvelopeSuccess =true)
func (SmartTieredCacheGetResponseEnvelopeSuccess)IsKnown¶
func (rSmartTieredCacheGetResponseEnvelopeSuccess) IsKnown()bool
typeSmartTieredCacheGetResponseID¶
type SmartTieredCacheGetResponseIDstring
ID of the zone setting.
const (SmartTieredCacheGetResponseIDTieredCacheSmartTopologyEnableSmartTieredCacheGetResponseID = "tiered_cache_smart_topology_enable")
func (SmartTieredCacheGetResponseID)IsKnown¶
func (rSmartTieredCacheGetResponseID) IsKnown()bool
typeSmartTieredCacheGetResponseValue¶
type SmartTieredCacheGetResponseValuestring
The value of the feature
const (SmartTieredCacheGetResponseValueOnSmartTieredCacheGetResponseValue = "on"SmartTieredCacheGetResponseValueOffSmartTieredCacheGetResponseValue = "off")
func (SmartTieredCacheGetResponseValue)IsKnown¶
func (rSmartTieredCacheGetResponseValue) IsKnown()bool
typeSmartTieredCacheService¶
type SmartTieredCacheService struct {Options []option.RequestOption}
SmartTieredCacheService contains methods and other services that help withinteracting with the cloudflare API.
Note, unlike clients, this service does not read variables from the environmentautomatically. You should not instantiate this service directly, and instead usetheNewSmartTieredCacheService method instead.
funcNewSmartTieredCacheService¶
func NewSmartTieredCacheService(opts ...option.RequestOption) (r *SmartTieredCacheService)
NewSmartTieredCacheService generates a new service that applies the givenoptions to each request. These options are applied after the parent client'soptions (if there is one), and before any request-specific options.
func (*SmartTieredCacheService)Delete¶
func (r *SmartTieredCacheService) Delete(ctxcontext.Context, bodySmartTieredCacheDeleteParams, opts ...option.RequestOption) (res *SmartTieredCacheDeleteResponse, errerror)
Smart Tiered Cache dynamically selects the single closest upper tier for each ofyour website’s origins with no configuration required, using our in-houseperformance and routing data. Cloudflare collects latency data for each requestto an origin, and uses the latency data to determine how well any upper-tierdata center is connected with an origin. As a result, Cloudflare can select thedata center with the lowest latency to be the upper-tier for an origin.
func (*SmartTieredCacheService)Edit¶
func (r *SmartTieredCacheService) Edit(ctxcontext.Context, paramsSmartTieredCacheEditParams, opts ...option.RequestOption) (res *SmartTieredCacheEditResponse, errerror)
Smart Tiered Cache dynamically selects the single closest upper tier for each ofyour website’s origins with no configuration required, using our in-houseperformance and routing data. Cloudflare collects latency data for each requestto an origin, and uses the latency data to determine how well any upper-tierdata center is connected with an origin. As a result, Cloudflare can select thedata center with the lowest latency to be the upper-tier for an origin.
func (*SmartTieredCacheService)Get¶
func (r *SmartTieredCacheService) Get(ctxcontext.Context, querySmartTieredCacheGetParams, opts ...option.RequestOption) (res *SmartTieredCacheGetResponse, errerror)
Smart Tiered Cache dynamically selects the single closest upper tier for each ofyour website’s origins with no configuration required, using our in-houseperformance and routing data. Cloudflare collects latency data for each requestto an origin, and uses the latency data to determine how well any upper-tierdata center is connected with an origin. As a result, Cloudflare can select thedata center with the lowest latency to be the upper-tier for an origin.
typeSortDirection¶
type SortDirection =shared.SortDirection
Direction to order DNS records in.
This is an alias to an internal type.
typeSubscriptionFrequency¶
type SubscriptionFrequency =shared.SubscriptionFrequency
How often the subscription is renewed automatically.
This is an alias to an internal type.
typeSubscriptionParam¶
type SubscriptionParam =shared.SubscriptionParam
This is an alias to an internal type.
typeSubscriptionState¶
type SubscriptionState =shared.SubscriptionState
The state that the subscription is in.
This is an alias to an internal type.
typeTokenConditionCIDRList¶
type TokenConditionCIDRList =shared.TokenConditionCIDRList
IPv4/IPv6 CIDR.
This is an alias to an internal type.
typeTokenConditionCIDRListParam¶
type TokenConditionCIDRListParam =shared.TokenConditionCIDRListParam
IPv4/IPv6 CIDR.
This is an alias to an internal type.
typeTokenConditionParam¶
type TokenConditionParam =shared.TokenConditionParam
This is an alias to an internal type.
typeTokenConditionRequestIP¶
type TokenConditionRequestIP =shared.TokenConditionRequestIP
Client IP restrictions.
This is an alias to an internal type.
typeTokenConditionRequestIPParam¶
type TokenConditionRequestIPParam =shared.TokenConditionRequestIPParam
Client IP restrictions.
This is an alias to an internal type.
typeTokenPolicyEffect¶
type TokenPolicyEffect =shared.TokenPolicyEffect
Allow or deny operations against the resources.
This is an alias to an internal type.
typeTokenPolicyParam¶
type TokenPolicyParam =shared.TokenPolicyParam
This is an alias to an internal type.
typeTokenPolicyPermissionGroup¶
type TokenPolicyPermissionGroup =shared.TokenPolicyPermissionGroup
A named group of permissions that map to a group of operations againstresources.
This is an alias to an internal type.
typeTokenPolicyPermissionGroupParam¶
type TokenPolicyPermissionGroupParam =shared.TokenPolicyPermissionGroupParam
A named group of permissions that map to a group of operations againstresources.
This is an alias to an internal type.
typeTokenPolicyPermissionGroupsMeta¶
type TokenPolicyPermissionGroupsMeta =shared.TokenPolicyPermissionGroupsMeta
Attributes associated to the permission group.
This is an alias to an internal type.
typeTokenPolicyPermissionGroupsMetaParam¶
type TokenPolicyPermissionGroupsMetaParam =shared.TokenPolicyPermissionGroupsMetaParam
Attributes associated to the permission group.
This is an alias to an internal type.
typeTokenPolicyResourcesMap¶added inv4.6.0
type TokenPolicyResourcesMap =shared.TokenPolicyResourcesMap
A nested permission grant for further scoping.
This is an alias to an internal type.
typeTokenPolicyResourcesMapParam¶added inv4.6.0
type TokenPolicyResourcesMapParam =shared.TokenPolicyResourcesMapParam
A nested permission grant for further scoping.
This is an alias to an internal type.
typeTokenPolicyResourcesUnion¶added inv4.6.0
type TokenPolicyResourcesUnion =shared.TokenPolicyResourcesUnion
A simple wildcard permission, e.g., "\*".
This is an alias to an internal type.
typeTokenPolicyResourcesUnionParam¶added inv4.6.0
type TokenPolicyResourcesUnionParam =shared.TokenPolicyResourcesUnionParam
A simple wildcard permission, e.g., "\*".
This is an alias to an internal type.
typeTokenStatus¶
type TokenStatus =shared.TokenStatus
Status of the token.
This is an alias to an internal type.
typeTokenValue¶
type TokenValue =shared.TokenValue
The token value.
This is an alias to an internal type.
typeVariantDeleteResponse¶
type VariantDeleteResponse struct {// ID of the zone setting.IDVariantDeleteResponseID `json:"id,required"`// Whether the setting is editableEditablebool `json:"editable,required"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON variantDeleteResponseJSON `json:"-"`}
func (*VariantDeleteResponse)UnmarshalJSON¶
func (r *VariantDeleteResponse) UnmarshalJSON(data []byte) (errerror)
typeVariantDeleteResponseEnvelope¶
type VariantDeleteResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessVariantDeleteResponseEnvelopeSuccess `json:"success,required"`ResultVariantDeleteResponse `json:"result"`JSON variantDeleteResponseEnvelopeJSON `json:"-"`}
func (*VariantDeleteResponseEnvelope)UnmarshalJSON¶
func (r *VariantDeleteResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeVariantDeleteResponseEnvelopeSuccess¶
type VariantDeleteResponseEnvelopeSuccessbool
Whether the API call was successful
const (VariantDeleteResponseEnvelopeSuccessTrueVariantDeleteResponseEnvelopeSuccess =true)
func (VariantDeleteResponseEnvelopeSuccess)IsKnown¶
func (rVariantDeleteResponseEnvelopeSuccess) IsKnown()bool
typeVariantDeleteResponseID¶
type VariantDeleteResponseIDstring
ID of the zone setting.
const (VariantDeleteResponseIDVariantsVariantDeleteResponseID = "variants")
func (VariantDeleteResponseID)IsKnown¶
func (rVariantDeleteResponseID) IsKnown()bool
typeVariantEditParams¶
type VariantEditParams struct {// IdentifierZoneIDparam.Field[string] `path:"zone_id,required"`// Value of the zone setting.Valueparam.Field[VariantEditParamsValue] `json:"value,required"`}
func (VariantEditParams)MarshalJSON¶
func (rVariantEditParams) MarshalJSON() (data []byte, errerror)
typeVariantEditParamsValue¶
type VariantEditParamsValue struct {// List of strings with the MIME types of all the variants that should be served// for avif.AVIFparam.Field[[]string] `json:"avif"`// List of strings with the MIME types of all the variants that should be served// for bmp.BMPparam.Field[[]string] `json:"bmp"`// List of strings with the MIME types of all the variants that should be served// for gif.GIFparam.Field[[]string] `json:"gif"`// List of strings with the MIME types of all the variants that should be served// for jp2.JP2param.Field[[]string] `json:"jp2"`// List of strings with the MIME types of all the variants that should be served// for jpeg.JPEGparam.Field[[]string] `json:"jpeg"`// List of strings with the MIME types of all the variants that should be served// for jpg.JPGparam.Field[[]string] `json:"jpg"`// List of strings with the MIME types of all the variants that should be served// for jpg2.JPG2param.Field[[]string] `json:"jpg2"`// List of strings with the MIME types of all the variants that should be served// for png.PNGparam.Field[[]string] `json:"png"`// List of strings with the MIME types of all the variants that should be served// for tif.TIFparam.Field[[]string] `json:"tif"`// List of strings with the MIME types of all the variants that should be served// for tiff.TIFFparam.Field[[]string] `json:"tiff"`// List of strings with the MIME types of all the variants that should be served// for webp.WebPparam.Field[[]string] `json:"webp"`}
Value of the zone setting.
func (VariantEditParamsValue)MarshalJSON¶
func (rVariantEditParamsValue) MarshalJSON() (data []byte, errerror)
typeVariantEditResponse¶
type VariantEditResponse struct {// ID of the zone setting.IDVariantEditResponseID `json:"id,required"`// Whether the setting is editableEditablebool `json:"editable,required"`// The value of the featureValuestring `json:"value,required"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON variantEditResponseJSON `json:"-"`}
func (*VariantEditResponse)UnmarshalJSON¶
func (r *VariantEditResponse) UnmarshalJSON(data []byte) (errerror)
typeVariantEditResponseEnvelope¶
type VariantEditResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessVariantEditResponseEnvelopeSuccess `json:"success,required"`ResultVariantEditResponse `json:"result"`JSON variantEditResponseEnvelopeJSON `json:"-"`}
func (*VariantEditResponseEnvelope)UnmarshalJSON¶
func (r *VariantEditResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeVariantEditResponseEnvelopeSuccess¶
type VariantEditResponseEnvelopeSuccessbool
Whether the API call was successful
const (VariantEditResponseEnvelopeSuccessTrueVariantEditResponseEnvelopeSuccess =true)
func (VariantEditResponseEnvelopeSuccess)IsKnown¶
func (rVariantEditResponseEnvelopeSuccess) IsKnown()bool
typeVariantEditResponseID¶
type VariantEditResponseIDstring
ID of the zone setting.
const (VariantEditResponseIDVariantsVariantEditResponseID = "variants")
func (VariantEditResponseID)IsKnown¶
func (rVariantEditResponseID) IsKnown()bool
typeVariantGetResponse¶
type VariantGetResponse struct {// ID of the zone setting.IDVariantGetResponseID `json:"id,required"`// Whether the setting is editableEditablebool `json:"editable,required"`// The value of the featureValuestring `json:"value,required"`// Last time this setting was modified.ModifiedOntime.Time `json:"modified_on,nullable" format:"date-time"`JSON variantGetResponseJSON `json:"-"`}
func (*VariantGetResponse)UnmarshalJSON¶
func (r *VariantGetResponse) UnmarshalJSON(data []byte) (errerror)
typeVariantGetResponseEnvelope¶
type VariantGetResponseEnvelope struct {Errors []shared.ResponseInfo `json:"errors,required"`Messages []shared.ResponseInfo `json:"messages,required"`// Whether the API call was successfulSuccessVariantGetResponseEnvelopeSuccess `json:"success,required"`ResultVariantGetResponse `json:"result"`JSON variantGetResponseEnvelopeJSON `json:"-"`}
func (*VariantGetResponseEnvelope)UnmarshalJSON¶
func (r *VariantGetResponseEnvelope) UnmarshalJSON(data []byte) (errerror)
typeVariantGetResponseEnvelopeSuccess¶
type VariantGetResponseEnvelopeSuccessbool
Whether the API call was successful
const (VariantGetResponseEnvelopeSuccessTrueVariantGetResponseEnvelopeSuccess =true)
func (VariantGetResponseEnvelopeSuccess)IsKnown¶
func (rVariantGetResponseEnvelopeSuccess) IsKnown()bool
typeVariantGetResponseID¶
type VariantGetResponseIDstring
ID of the zone setting.
const (VariantGetResponseIDVariantsVariantGetResponseID = "variants")
func (VariantGetResponseID)IsKnown¶
func (rVariantGetResponseID) IsKnown()bool
typeVariantService¶
type VariantService struct {Options []option.RequestOption}
VariantService contains methods and other services that help with interactingwith the cloudflare API.
Note, unlike clients, this service does not read variables from the environmentautomatically. You should not instantiate this service directly, and instead usetheNewVariantService method instead.
funcNewVariantService¶
func NewVariantService(opts ...option.RequestOption) (r *VariantService)
NewVariantService generates a new service that applies the given options to eachrequest. These options are applied after the parent client's options (if thereis one), and before any request-specific options.
func (*VariantService)Delete¶
func (r *VariantService) Delete(ctxcontext.Context, bodyVariantDeleteParams, opts ...option.RequestOption) (res *VariantDeleteResponse, errerror)
Variant support enables caching variants of images with certain file extensionsin addition to the original. This only applies when the origin server sends the'Vary: Accept' response header. If the origin server sends 'Vary: Accept' butdoes not serve the variant requested, the response will not be cached. This willbe indicated with BYPASS cache status in the response headers.
func (*VariantService)Edit¶
func (r *VariantService) Edit(ctxcontext.Context, paramsVariantEditParams, opts ...option.RequestOption) (res *VariantEditResponse, errerror)
Variant support enables caching variants of images with certain file extensionsin addition to the original. This only applies when the origin server sends the'Vary: Accept' response header. If the origin server sends 'Vary: Accept' butdoes not serve the variant requested, the response will not be cached. This willbe indicated with BYPASS cache status in the response headers.
func (*VariantService)Get¶
func (r *VariantService) Get(ctxcontext.Context, queryVariantGetParams, opts ...option.RequestOption) (res *VariantGetResponse, errerror)
Variant support enables caching variants of images with certain file extensionsin addition to the original. This only applies when the origin server sends the'Vary: Accept' response header. If the origin server sends 'Vary: Accept' butdoes not serve the variant requested, the response will not be cached. This willbe indicated with BYPASS cache status in the response headers.