Documentation
¶
Index ¶
- Constants
- type ASN
- type ASNParam
- type AuditLog
- type AuditLogAction
- type AuditLogActor
- type AuditLogActorType
- type AuditLogOwner
- type AuditLogResource
- type CertificateCA
- type CertificateRequestType
- type CloudflareTunnel
- type 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 RecipientDeleteParams
- type RecipientDeleteResponse
- type RecipientDeleteResponseAssociationStatus
- type RecipientDeleteResponseEnvelope
- type RecipientGetParams
- type RecipientGetResponse
- type RecipientGetResponseAssociationStatus
- type RecipientGetResponseEnvelope
- type RecipientListParams
- type RecipientListResponse
- type RecipientListResponseAssociationStatus
- type RecipientNewParams
- type RecipientNewResponse
- type RecipientNewResponseAssociationStatus
- type RecipientNewResponseEnvelope
- type RecipientService
- func (r *RecipientService) Delete(ctx context.Context, shareID string, recipientID string, ...) (res *RecipientDeleteResponse, err error)
- func (r *RecipientService) Get(ctx context.Context, shareID string, recipientID string, ...) (res *RecipientGetResponse, err error)
- func (r *RecipientService) List(ctx context.Context, shareID string, params RecipientListParams, ...) (res *pagination.V4PagePaginationArray[RecipientListResponse], err error)
- func (r *RecipientService) ListAutoPaging(ctx context.Context, shareID string, params RecipientListParams, ...) *pagination.V4PagePaginationArrayAutoPager[RecipientListResponse]
- func (r *RecipientService) New(ctx context.Context, shareID string, params RecipientNewParams, ...) (res *RecipientNewResponse, err error)
- type ResourceDeleteParams
- type ResourceDeleteResponse
- type ResourceDeleteResponseEnvelope
- type ResourceDeleteResponseResourceType
- type ResourceDeleteResponseStatus
- type ResourceGetParams
- type ResourceGetResponse
- type ResourceGetResponseEnvelope
- type ResourceGetResponseResourceType
- type ResourceGetResponseStatus
- type ResourceListParams
- type ResourceListParamsResourceType
- type ResourceListParamsStatus
- type ResourceListResponse
- type ResourceListResponseResourceType
- type ResourceListResponseStatus
- type ResourceNewParams
- type ResourceNewParamsResourceType
- type ResourceNewResponse
- type ResourceNewResponseEnvelope
- type ResourceNewResponseResourceType
- type ResourceNewResponseStatus
- type ResourceService
- func (r *ResourceService) Delete(ctx context.Context, shareID string, resourceID string, ...) (res *ResourceDeleteResponse, err error)
- func (r *ResourceService) Get(ctx context.Context, shareID string, resourceID string, ...) (res *ResourceGetResponse, err error)
- func (r *ResourceService) List(ctx context.Context, shareID string, params ResourceListParams, ...) (res *pagination.V4PagePaginationArray[ResourceListResponse], err error)
- func (r *ResourceService) ListAutoPaging(ctx context.Context, shareID string, params ResourceListParams, ...) *pagination.V4PagePaginationArrayAutoPager[ResourceListResponse]
- func (r *ResourceService) New(ctx context.Context, shareID string, params ResourceNewParams, ...) (res *ResourceNewResponse, err error)
- func (r *ResourceService) Update(ctx context.Context, shareID string, resourceID string, ...) (res *ResourceUpdateResponse, err error)
- type ResourceSharingDeleteParams
- type ResourceSharingDeleteResponse
- type ResourceSharingDeleteResponseEnvelope
- type ResourceSharingDeleteResponseKind
- type ResourceSharingDeleteResponseStatus
- type ResourceSharingDeleteResponseTargetType
- type ResourceSharingGetParams
- type ResourceSharingGetResponse
- type ResourceSharingGetResponseEnvelope
- type ResourceSharingGetResponseKind
- type ResourceSharingGetResponseStatus
- type ResourceSharingGetResponseTargetType
- type ResourceSharingListParams
- type ResourceSharingListParamsDirection
- type ResourceSharingListParamsKind
- type ResourceSharingListParamsOrder
- type ResourceSharingListParamsStatus
- type ResourceSharingListParamsTargetType
- type ResourceSharingListResponse
- type ResourceSharingListResponseKind
- type ResourceSharingListResponseStatus
- type ResourceSharingListResponseTargetType
- type ResourceSharingNewParams
- type ResourceSharingNewParamsRecipient
- type ResourceSharingNewParamsResource
- type ResourceSharingNewParamsResourcesResourceType
- type ResourceSharingNewResponse
- type ResourceSharingNewResponseEnvelope
- type ResourceSharingNewResponseKind
- type ResourceSharingNewResponseStatus
- type ResourceSharingNewResponseTargetType
- type ResourceSharingService
- func (r *ResourceSharingService) Delete(ctx context.Context, shareID string, body ResourceSharingDeleteParams, ...) (res *ResourceSharingDeleteResponse, err error)
- func (r *ResourceSharingService) Get(ctx context.Context, shareID string, query ResourceSharingGetParams, ...) (res *ResourceSharingGetResponse, err error)
- func (r *ResourceSharingService) List(ctx context.Context, params ResourceSharingListParams, ...) (res *pagination.V4PagePaginationArray[ResourceSharingListResponse], err error)
- func (r *ResourceSharingService) ListAutoPaging(ctx context.Context, params ResourceSharingListParams, ...) *pagination.V4PagePaginationArrayAutoPager[ResourceSharingListResponse]
- func (r *ResourceSharingService) New(ctx context.Context, params ResourceSharingNewParams, ...) (res *ResourceSharingNewResponse, err error)
- func (r *ResourceSharingService) Update(ctx context.Context, shareID string, params ResourceSharingUpdateParams, ...) (res *ResourceSharingUpdateResponse, err error)
- type ResourceSharingUpdateParams
- type ResourceSharingUpdateResponse
- type ResourceSharingUpdateResponseEnvelope
- type ResourceSharingUpdateResponseKind
- type ResourceSharingUpdateResponseStatus
- type ResourceSharingUpdateResponseTargetType
- type ResourceUpdateParams
- type ResourceUpdateResponse
- type ResourceUpdateResponseEnvelope
- type ResourceUpdateResponseResourceType
- type ResourceUpdateResponseStatus
- type ResponseInfo
- type ResponseInfoSource
- type Role
- type RoleParam
- type RolePermissions
- type RolePermissionsParam
- type SortDirection
- 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 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 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 ¶
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 RecipientDeleteParams ¶
type RecipientDeleteResponse ¶
type RecipientDeleteResponse struct {
// Share Recipient identifier tag.
ID string `json:"id,required"`
// Account identifier.
AccountID string `json:"account_id,required"`
// Share Recipient association status.
AssociationStatus RecipientDeleteResponseAssociationStatus `json:"association_status,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// Share Recipient status message.
StatusMessage string `json:"status_message,required"`
JSON recipientDeleteResponseJSON `json:"-"`
}
func (*RecipientDeleteResponse) UnmarshalJSON ¶
func (r *RecipientDeleteResponse) UnmarshalJSON(data []byte) (err error)
type RecipientDeleteResponseAssociationStatus ¶
type RecipientDeleteResponseAssociationStatus string
Share Recipient association status.
const ( RecipientDeleteResponseAssociationStatusAssociating RecipientDeleteResponseAssociationStatus = "associating" RecipientDeleteResponseAssociationStatusAssociated RecipientDeleteResponseAssociationStatus = "associated" RecipientDeleteResponseAssociationStatusDisassociating RecipientDeleteResponseAssociationStatus = "disassociating" RecipientDeleteResponseAssociationStatusDisassociated RecipientDeleteResponseAssociationStatus = "disassociated" )
func (RecipientDeleteResponseAssociationStatus) IsKnown ¶
func (r RecipientDeleteResponseAssociationStatus) IsKnown() bool
type RecipientDeleteResponseEnvelope ¶
type RecipientDeleteResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result RecipientDeleteResponse `json:"result"`
JSON recipientDeleteResponseEnvelopeJSON `json:"-"`
}
func (*RecipientDeleteResponseEnvelope) UnmarshalJSON ¶
func (r *RecipientDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type RecipientGetParams ¶
type RecipientGetResponse ¶
type RecipientGetResponse struct {
// Share Recipient identifier tag.
ID string `json:"id,required"`
// Account identifier.
AccountID string `json:"account_id,required"`
// Share Recipient association status.
AssociationStatus RecipientGetResponseAssociationStatus `json:"association_status,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// Share Recipient status message.
StatusMessage string `json:"status_message,required"`
JSON recipientGetResponseJSON `json:"-"`
}
func (*RecipientGetResponse) UnmarshalJSON ¶
func (r *RecipientGetResponse) UnmarshalJSON(data []byte) (err error)
type RecipientGetResponseAssociationStatus ¶
type RecipientGetResponseAssociationStatus string
Share Recipient association status.
const ( RecipientGetResponseAssociationStatusAssociating RecipientGetResponseAssociationStatus = "associating" RecipientGetResponseAssociationStatusAssociated RecipientGetResponseAssociationStatus = "associated" RecipientGetResponseAssociationStatusDisassociating RecipientGetResponseAssociationStatus = "disassociating" RecipientGetResponseAssociationStatusDisassociated RecipientGetResponseAssociationStatus = "disassociated" )
func (RecipientGetResponseAssociationStatus) IsKnown ¶
func (r RecipientGetResponseAssociationStatus) IsKnown() bool
type RecipientGetResponseEnvelope ¶
type RecipientGetResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result RecipientGetResponse `json:"result"`
JSON recipientGetResponseEnvelopeJSON `json:"-"`
}
func (*RecipientGetResponseEnvelope) UnmarshalJSON ¶
func (r *RecipientGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type RecipientListParams ¶
type RecipientListParams struct {
// Account identifier.
AccountID param.Field[string] `path:"account_id,required"`
// Page number.
Page param.Field[int64] `query:"page"`
// Number of objects to return per page.
PerPage param.Field[int64] `query:"per_page"`
}
func (RecipientListParams) URLQuery ¶
func (r RecipientListParams) URLQuery() (v url.Values)
URLQuery serializes RecipientListParams's query parameters as `url.Values`.
type RecipientListResponse ¶
type RecipientListResponse struct {
// Share Recipient identifier tag.
ID string `json:"id,required"`
// Account identifier.
AccountID string `json:"account_id,required"`
// Share Recipient association status.
AssociationStatus RecipientListResponseAssociationStatus `json:"association_status,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// Share Recipient status message.
StatusMessage string `json:"status_message,required"`
JSON recipientListResponseJSON `json:"-"`
}
func (*RecipientListResponse) UnmarshalJSON ¶
func (r *RecipientListResponse) UnmarshalJSON(data []byte) (err error)
type RecipientListResponseAssociationStatus ¶
type RecipientListResponseAssociationStatus string
Share Recipient association status.
const ( RecipientListResponseAssociationStatusAssociating RecipientListResponseAssociationStatus = "associating" RecipientListResponseAssociationStatusAssociated RecipientListResponseAssociationStatus = "associated" RecipientListResponseAssociationStatusDisassociating RecipientListResponseAssociationStatus = "disassociating" RecipientListResponseAssociationStatusDisassociated RecipientListResponseAssociationStatus = "disassociated" )
func (RecipientListResponseAssociationStatus) IsKnown ¶
func (r RecipientListResponseAssociationStatus) IsKnown() bool
type RecipientNewParams ¶
type RecipientNewParams struct {
// Account identifier.
PathAccountID param.Field[string] `path:"account_id,required"`
// Account identifier.
BodyAccountID param.Field[string] `json:"account_id"`
// Organization identifier.
OrganizationID param.Field[string] `json:"organization_id"`
}
func (RecipientNewParams) MarshalJSON ¶
func (r RecipientNewParams) MarshalJSON() (data []byte, err error)
type RecipientNewResponse ¶
type RecipientNewResponse struct {
// Share Recipient identifier tag.
ID string `json:"id,required"`
// Account identifier.
AccountID string `json:"account_id,required"`
// Share Recipient association status.
AssociationStatus RecipientNewResponseAssociationStatus `json:"association_status,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// Share Recipient status message.
StatusMessage string `json:"status_message,required"`
JSON recipientNewResponseJSON `json:"-"`
}
func (*RecipientNewResponse) UnmarshalJSON ¶
func (r *RecipientNewResponse) UnmarshalJSON(data []byte) (err error)
type RecipientNewResponseAssociationStatus ¶
type RecipientNewResponseAssociationStatus string
Share Recipient association status.
const ( RecipientNewResponseAssociationStatusAssociating RecipientNewResponseAssociationStatus = "associating" RecipientNewResponseAssociationStatusAssociated RecipientNewResponseAssociationStatus = "associated" RecipientNewResponseAssociationStatusDisassociating RecipientNewResponseAssociationStatus = "disassociating" RecipientNewResponseAssociationStatusDisassociated RecipientNewResponseAssociationStatus = "disassociated" )
func (RecipientNewResponseAssociationStatus) IsKnown ¶
func (r RecipientNewResponseAssociationStatus) IsKnown() bool
type RecipientNewResponseEnvelope ¶
type RecipientNewResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result RecipientNewResponse `json:"result"`
JSON recipientNewResponseEnvelopeJSON `json:"-"`
}
func (*RecipientNewResponseEnvelope) UnmarshalJSON ¶
func (r *RecipientNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type RecipientService ¶
type RecipientService struct {
Options []option.RequestOption
}
RecipientService 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 NewRecipientService method instead.
func NewRecipientService ¶
func NewRecipientService(opts ...option.RequestOption) (r *RecipientService)
NewRecipientService 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 (*RecipientService) Delete ¶
func (r *RecipientService) Delete(ctx context.Context, shareID string, recipientID string, body RecipientDeleteParams, opts ...option.RequestOption) (res *RecipientDeleteResponse, err error)
Deletion is not immediate, an updated share recipient object with a new status will be returned.
func (*RecipientService) Get ¶
func (r *RecipientService) Get(ctx context.Context, shareID string, recipientID string, query RecipientGetParams, opts ...option.RequestOption) (res *RecipientGetResponse, err error)
Get share recipient by ID.
func (*RecipientService) List ¶
func (r *RecipientService) List(ctx context.Context, shareID string, params RecipientListParams, opts ...option.RequestOption) (res *pagination.V4PagePaginationArray[RecipientListResponse], err error)
List share recipients by share ID.
func (*RecipientService) ListAutoPaging ¶
func (r *RecipientService) ListAutoPaging(ctx context.Context, shareID string, params RecipientListParams, opts ...option.RequestOption) *pagination.V4PagePaginationArrayAutoPager[RecipientListResponse]
List share recipients by share ID.
func (*RecipientService) New ¶
func (r *RecipientService) New(ctx context.Context, shareID string, params RecipientNewParams, opts ...option.RequestOption) (res *RecipientNewResponse, err error)
Create a new share recipient
type ResourceDeleteParams ¶
type ResourceDeleteResponse ¶
type ResourceDeleteResponse struct {
// Share Resource identifier.
ID string `json:"id,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// Resource Metadata.
Meta interface{} `json:"meta,required"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// Account identifier.
ResourceAccountID string `json:"resource_account_id,required"`
// Share Resource identifier.
ResourceID string `json:"resource_id,required"`
// Resource Type.
ResourceType ResourceDeleteResponseResourceType `json:"resource_type,required"`
// Resource Version.
ResourceVersion int64 `json:"resource_version,required"`
// Resource Status.
Status ResourceDeleteResponseStatus `json:"status,required"`
JSON resourceDeleteResponseJSON `json:"-"`
}
func (*ResourceDeleteResponse) UnmarshalJSON ¶
func (r *ResourceDeleteResponse) UnmarshalJSON(data []byte) (err error)
type ResourceDeleteResponseEnvelope ¶
type ResourceDeleteResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result ResourceDeleteResponse `json:"result"`
JSON resourceDeleteResponseEnvelopeJSON `json:"-"`
}
func (*ResourceDeleteResponseEnvelope) UnmarshalJSON ¶
func (r *ResourceDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type ResourceDeleteResponseResourceType ¶
type ResourceDeleteResponseResourceType string
Resource Type.
const ( ResourceDeleteResponseResourceTypeCustomRuleset ResourceDeleteResponseResourceType = "custom-ruleset" ResourceDeleteResponseResourceTypeWidget ResourceDeleteResponseResourceType = "widget" )
func (ResourceDeleteResponseResourceType) IsKnown ¶
func (r ResourceDeleteResponseResourceType) IsKnown() bool
type ResourceDeleteResponseStatus ¶
type ResourceDeleteResponseStatus string
Resource Status.
const ( ResourceDeleteResponseStatusActive ResourceDeleteResponseStatus = "active" ResourceDeleteResponseStatusDeleting ResourceDeleteResponseStatus = "deleting" ResourceDeleteResponseStatusDeleted ResourceDeleteResponseStatus = "deleted" )
func (ResourceDeleteResponseStatus) IsKnown ¶
func (r ResourceDeleteResponseStatus) IsKnown() bool
type ResourceGetParams ¶
type ResourceGetResponse ¶
type ResourceGetResponse struct {
// Share Resource identifier.
ID string `json:"id,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// Resource Metadata.
Meta interface{} `json:"meta,required"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// Account identifier.
ResourceAccountID string `json:"resource_account_id,required"`
// Share Resource identifier.
ResourceID string `json:"resource_id,required"`
// Resource Type.
ResourceType ResourceGetResponseResourceType `json:"resource_type,required"`
// Resource Version.
ResourceVersion int64 `json:"resource_version,required"`
// Resource Status.
Status ResourceGetResponseStatus `json:"status,required"`
JSON resourceGetResponseJSON `json:"-"`
}
func (*ResourceGetResponse) UnmarshalJSON ¶
func (r *ResourceGetResponse) UnmarshalJSON(data []byte) (err error)
type ResourceGetResponseEnvelope ¶
type ResourceGetResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result ResourceGetResponse `json:"result"`
JSON resourceGetResponseEnvelopeJSON `json:"-"`
}
func (*ResourceGetResponseEnvelope) UnmarshalJSON ¶
func (r *ResourceGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type ResourceGetResponseResourceType ¶
type ResourceGetResponseResourceType string
Resource Type.
const ( ResourceGetResponseResourceTypeCustomRuleset ResourceGetResponseResourceType = "custom-ruleset" ResourceGetResponseResourceTypeWidget ResourceGetResponseResourceType = "widget" )
func (ResourceGetResponseResourceType) IsKnown ¶
func (r ResourceGetResponseResourceType) IsKnown() bool
type ResourceGetResponseStatus ¶
type ResourceGetResponseStatus string
Resource Status.
const ( ResourceGetResponseStatusActive ResourceGetResponseStatus = "active" ResourceGetResponseStatusDeleting ResourceGetResponseStatus = "deleting" ResourceGetResponseStatusDeleted ResourceGetResponseStatus = "deleted" )
func (ResourceGetResponseStatus) IsKnown ¶
func (r ResourceGetResponseStatus) IsKnown() bool
type ResourceListParams ¶
type ResourceListParams struct {
// Account identifier.
AccountID param.Field[string] `path:"account_id,required"`
// Page number.
Page param.Field[int64] `query:"page"`
// Number of objects to return per page.
PerPage param.Field[int64] `query:"per_page"`
// Filter share resources by resource_type.
ResourceType param.Field[ResourceListParamsResourceType] `query:"resource_type"`
// Filter share resources by status.
Status param.Field[ResourceListParamsStatus] `query:"status"`
}
func (ResourceListParams) URLQuery ¶
func (r ResourceListParams) URLQuery() (v url.Values)
URLQuery serializes ResourceListParams's query parameters as `url.Values`.
type ResourceListParamsResourceType ¶
type ResourceListParamsResourceType string
Filter share resources by resource_type.
const ( ResourceListParamsResourceTypeCustomRuleset ResourceListParamsResourceType = "custom-ruleset" ResourceListParamsResourceTypeWidget ResourceListParamsResourceType = "widget" )
func (ResourceListParamsResourceType) IsKnown ¶
func (r ResourceListParamsResourceType) IsKnown() bool
type ResourceListParamsStatus ¶
type ResourceListParamsStatus string
Filter share resources by status.
const ( ResourceListParamsStatusActive ResourceListParamsStatus = "active" ResourceListParamsStatusDeleting ResourceListParamsStatus = "deleting" ResourceListParamsStatusDeleted ResourceListParamsStatus = "deleted" )
func (ResourceListParamsStatus) IsKnown ¶
func (r ResourceListParamsStatus) IsKnown() bool
type ResourceListResponse ¶
type ResourceListResponse struct {
// Share Resource identifier.
ID string `json:"id,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// Resource Metadata.
Meta interface{} `json:"meta,required"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// Account identifier.
ResourceAccountID string `json:"resource_account_id,required"`
// Share Resource identifier.
ResourceID string `json:"resource_id,required"`
// Resource Type.
ResourceType ResourceListResponseResourceType `json:"resource_type,required"`
// Resource Version.
ResourceVersion int64 `json:"resource_version,required"`
// Resource Status.
Status ResourceListResponseStatus `json:"status,required"`
JSON resourceListResponseJSON `json:"-"`
}
func (*ResourceListResponse) UnmarshalJSON ¶
func (r *ResourceListResponse) UnmarshalJSON(data []byte) (err error)
type ResourceListResponseResourceType ¶
type ResourceListResponseResourceType string
Resource Type.
const ( ResourceListResponseResourceTypeCustomRuleset ResourceListResponseResourceType = "custom-ruleset" ResourceListResponseResourceTypeWidget ResourceListResponseResourceType = "widget" )
func (ResourceListResponseResourceType) IsKnown ¶
func (r ResourceListResponseResourceType) IsKnown() bool
type ResourceListResponseStatus ¶
type ResourceListResponseStatus string
Resource Status.
const ( ResourceListResponseStatusActive ResourceListResponseStatus = "active" ResourceListResponseStatusDeleting ResourceListResponseStatus = "deleting" ResourceListResponseStatusDeleted ResourceListResponseStatus = "deleted" )
func (ResourceListResponseStatus) IsKnown ¶
func (r ResourceListResponseStatus) IsKnown() bool
type ResourceNewParams ¶
type ResourceNewParams struct {
// Account identifier.
AccountID param.Field[string] `path:"account_id,required"`
// Resource Metadata.
Meta param.Field[interface{}] `json:"meta,required"`
// Account identifier.
ResourceAccountID param.Field[string] `json:"resource_account_id,required"`
// Share Resource identifier.
ResourceID param.Field[string] `json:"resource_id,required"`
// Resource Type.
ResourceType param.Field[ResourceNewParamsResourceType] `json:"resource_type,required"`
}
func (ResourceNewParams) MarshalJSON ¶
func (r ResourceNewParams) MarshalJSON() (data []byte, err error)
type ResourceNewParamsResourceType ¶
type ResourceNewParamsResourceType string
Resource Type.
const ( ResourceNewParamsResourceTypeCustomRuleset ResourceNewParamsResourceType = "custom-ruleset" ResourceNewParamsResourceTypeWidget ResourceNewParamsResourceType = "widget" )
func (ResourceNewParamsResourceType) IsKnown ¶
func (r ResourceNewParamsResourceType) IsKnown() bool
type ResourceNewResponse ¶
type ResourceNewResponse struct {
// Share Resource identifier.
ID string `json:"id,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// Resource Metadata.
Meta interface{} `json:"meta,required"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// Account identifier.
ResourceAccountID string `json:"resource_account_id,required"`
// Share Resource identifier.
ResourceID string `json:"resource_id,required"`
// Resource Type.
ResourceType ResourceNewResponseResourceType `json:"resource_type,required"`
// Resource Version.
ResourceVersion int64 `json:"resource_version,required"`
// Resource Status.
Status ResourceNewResponseStatus `json:"status,required"`
JSON resourceNewResponseJSON `json:"-"`
}
func (*ResourceNewResponse) UnmarshalJSON ¶
func (r *ResourceNewResponse) UnmarshalJSON(data []byte) (err error)
type ResourceNewResponseEnvelope ¶
type ResourceNewResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result ResourceNewResponse `json:"result"`
JSON resourceNewResponseEnvelopeJSON `json:"-"`
}
func (*ResourceNewResponseEnvelope) UnmarshalJSON ¶
func (r *ResourceNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type ResourceNewResponseResourceType ¶
type ResourceNewResponseResourceType string
Resource Type.
const ( ResourceNewResponseResourceTypeCustomRuleset ResourceNewResponseResourceType = "custom-ruleset" ResourceNewResponseResourceTypeWidget ResourceNewResponseResourceType = "widget" )
func (ResourceNewResponseResourceType) IsKnown ¶
func (r ResourceNewResponseResourceType) IsKnown() bool
type ResourceNewResponseStatus ¶
type ResourceNewResponseStatus string
Resource Status.
const ( ResourceNewResponseStatusActive ResourceNewResponseStatus = "active" ResourceNewResponseStatusDeleting ResourceNewResponseStatus = "deleting" ResourceNewResponseStatusDeleted ResourceNewResponseStatus = "deleted" )
func (ResourceNewResponseStatus) IsKnown ¶
func (r ResourceNewResponseStatus) IsKnown() bool
type ResourceService ¶
type ResourceService struct {
Options []option.RequestOption
}
ResourceService 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 NewResourceService method instead.
func NewResourceService ¶
func NewResourceService(opts ...option.RequestOption) (r *ResourceService)
NewResourceService 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 (*ResourceService) Delete ¶
func (r *ResourceService) Delete(ctx context.Context, shareID string, resourceID string, body ResourceDeleteParams, opts ...option.RequestOption) (res *ResourceDeleteResponse, err error)
Deletion is not immediate, an updated share resource object with a new status will be returned.
func (*ResourceService) Get ¶
func (r *ResourceService) Get(ctx context.Context, shareID string, resourceID string, query ResourceGetParams, opts ...option.RequestOption) (res *ResourceGetResponse, err error)
Get share resource by ID.
func (*ResourceService) List ¶
func (r *ResourceService) List(ctx context.Context, shareID string, params ResourceListParams, opts ...option.RequestOption) (res *pagination.V4PagePaginationArray[ResourceListResponse], err error)
List share resources by share ID.
func (*ResourceService) ListAutoPaging ¶
func (r *ResourceService) ListAutoPaging(ctx context.Context, shareID string, params ResourceListParams, opts ...option.RequestOption) *pagination.V4PagePaginationArrayAutoPager[ResourceListResponse]
List share resources by share ID.
func (*ResourceService) New ¶
func (r *ResourceService) New(ctx context.Context, shareID string, params ResourceNewParams, opts ...option.RequestOption) (res *ResourceNewResponse, err error)
Create a new share resource
func (*ResourceService) Update ¶
func (r *ResourceService) Update(ctx context.Context, shareID string, resourceID string, params ResourceUpdateParams, opts ...option.RequestOption) (res *ResourceUpdateResponse, err error)
Update is not immediate, an updated share resource object with a new status will be returned.
type ResourceSharingDeleteResponse ¶
type ResourceSharingDeleteResponse struct {
// Share identifier tag.
ID string `json:"id,required"`
// Account identifier.
AccountID string `json:"account_id,required"`
// The display name of an account.
AccountName string `json:"account_name,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// The name of the share.
Name string `json:"name,required"`
// Organization identifier.
OrganizationID string `json:"organization_id,required"`
Status ResourceSharingDeleteResponseStatus `json:"status,required"`
TargetType ResourceSharingDeleteResponseTargetType `json:"target_type,required"`
Kind ResourceSharingDeleteResponseKind `json:"kind"`
JSON resourceSharingDeleteResponseJSON `json:"-"`
}
func (*ResourceSharingDeleteResponse) UnmarshalJSON ¶
func (r *ResourceSharingDeleteResponse) UnmarshalJSON(data []byte) (err error)
type ResourceSharingDeleteResponseEnvelope ¶
type ResourceSharingDeleteResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result ResourceSharingDeleteResponse `json:"result"`
JSON resourceSharingDeleteResponseEnvelopeJSON `json:"-"`
}
func (*ResourceSharingDeleteResponseEnvelope) UnmarshalJSON ¶
func (r *ResourceSharingDeleteResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type ResourceSharingDeleteResponseKind ¶
type ResourceSharingDeleteResponseKind string
const ( ResourceSharingDeleteResponseKindSent ResourceSharingDeleteResponseKind = "sent" ResourceSharingDeleteResponseKindReceived ResourceSharingDeleteResponseKind = "received" )
func (ResourceSharingDeleteResponseKind) IsKnown ¶
func (r ResourceSharingDeleteResponseKind) IsKnown() bool
type ResourceSharingDeleteResponseStatus ¶
type ResourceSharingDeleteResponseStatus string
const ( ResourceSharingDeleteResponseStatusActive ResourceSharingDeleteResponseStatus = "active" ResourceSharingDeleteResponseStatusDeleting ResourceSharingDeleteResponseStatus = "deleting" ResourceSharingDeleteResponseStatusDeleted ResourceSharingDeleteResponseStatus = "deleted" )
func (ResourceSharingDeleteResponseStatus) IsKnown ¶
func (r ResourceSharingDeleteResponseStatus) IsKnown() bool
type ResourceSharingDeleteResponseTargetType ¶
type ResourceSharingDeleteResponseTargetType string
const ( ResourceSharingDeleteResponseTargetTypeAccount ResourceSharingDeleteResponseTargetType = "account" ResourceSharingDeleteResponseTargetTypeOrganization ResourceSharingDeleteResponseTargetType = "organization" )
func (ResourceSharingDeleteResponseTargetType) IsKnown ¶
func (r ResourceSharingDeleteResponseTargetType) IsKnown() bool
type ResourceSharingGetResponse ¶
type ResourceSharingGetResponse struct {
// Share identifier tag.
ID string `json:"id,required"`
// Account identifier.
AccountID string `json:"account_id,required"`
// The display name of an account.
AccountName string `json:"account_name,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// The name of the share.
Name string `json:"name,required"`
// Organization identifier.
OrganizationID string `json:"organization_id,required"`
Status ResourceSharingGetResponseStatus `json:"status,required"`
TargetType ResourceSharingGetResponseTargetType `json:"target_type,required"`
Kind ResourceSharingGetResponseKind `json:"kind"`
JSON resourceSharingGetResponseJSON `json:"-"`
}
func (*ResourceSharingGetResponse) UnmarshalJSON ¶
func (r *ResourceSharingGetResponse) UnmarshalJSON(data []byte) (err error)
type ResourceSharingGetResponseEnvelope ¶
type ResourceSharingGetResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result ResourceSharingGetResponse `json:"result"`
JSON resourceSharingGetResponseEnvelopeJSON `json:"-"`
}
func (*ResourceSharingGetResponseEnvelope) UnmarshalJSON ¶
func (r *ResourceSharingGetResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type ResourceSharingGetResponseKind ¶
type ResourceSharingGetResponseKind string
const ( ResourceSharingGetResponseKindSent ResourceSharingGetResponseKind = "sent" ResourceSharingGetResponseKindReceived ResourceSharingGetResponseKind = "received" )
func (ResourceSharingGetResponseKind) IsKnown ¶
func (r ResourceSharingGetResponseKind) IsKnown() bool
type ResourceSharingGetResponseStatus ¶
type ResourceSharingGetResponseStatus string
const ( ResourceSharingGetResponseStatusActive ResourceSharingGetResponseStatus = "active" ResourceSharingGetResponseStatusDeleting ResourceSharingGetResponseStatus = "deleting" ResourceSharingGetResponseStatusDeleted ResourceSharingGetResponseStatus = "deleted" )
func (ResourceSharingGetResponseStatus) IsKnown ¶
func (r ResourceSharingGetResponseStatus) IsKnown() bool
type ResourceSharingGetResponseTargetType ¶
type ResourceSharingGetResponseTargetType string
const ( ResourceSharingGetResponseTargetTypeAccount ResourceSharingGetResponseTargetType = "account" ResourceSharingGetResponseTargetTypeOrganization ResourceSharingGetResponseTargetType = "organization" )
func (ResourceSharingGetResponseTargetType) IsKnown ¶
func (r ResourceSharingGetResponseTargetType) IsKnown() bool
type ResourceSharingListParams ¶
type ResourceSharingListParams struct {
// Account identifier.
AccountID param.Field[string] `path:"account_id,required"`
// Direction to sort objects.
Direction param.Field[ResourceSharingListParamsDirection] `query:"direction"`
// Filter shares by kind.
Kind param.Field[ResourceSharingListParamsKind] `query:"kind"`
// Order shares by values in the given field.
Order param.Field[ResourceSharingListParamsOrder] `query:"order"`
// Page number.
Page param.Field[int64] `query:"page"`
// Number of objects to return per page.
PerPage param.Field[int64] `query:"per_page"`
// Filter shares by status.
Status param.Field[ResourceSharingListParamsStatus] `query:"status"`
// Filter shares by target_type.
TargetType param.Field[ResourceSharingListParamsTargetType] `query:"target_type"`
}
func (ResourceSharingListParams) URLQuery ¶
func (r ResourceSharingListParams) URLQuery() (v url.Values)
URLQuery serializes ResourceSharingListParams's query parameters as `url.Values`.
type ResourceSharingListParamsDirection ¶
type ResourceSharingListParamsDirection string
Direction to sort objects.
const ( ResourceSharingListParamsDirectionAsc ResourceSharingListParamsDirection = "asc" ResourceSharingListParamsDirectionDesc ResourceSharingListParamsDirection = "desc" )
func (ResourceSharingListParamsDirection) IsKnown ¶
func (r ResourceSharingListParamsDirection) IsKnown() bool
type ResourceSharingListParamsKind ¶
type ResourceSharingListParamsKind string
Filter shares by kind.
const ( ResourceSharingListParamsKindSent ResourceSharingListParamsKind = "sent" ResourceSharingListParamsKindReceived ResourceSharingListParamsKind = "received" )
func (ResourceSharingListParamsKind) IsKnown ¶
func (r ResourceSharingListParamsKind) IsKnown() bool
type ResourceSharingListParamsOrder ¶
type ResourceSharingListParamsOrder string
Order shares by values in the given field.
const ( ResourceSharingListParamsOrderName ResourceSharingListParamsOrder = "name" ResourceSharingListParamsOrderCreated ResourceSharingListParamsOrder = "created" )
func (ResourceSharingListParamsOrder) IsKnown ¶
func (r ResourceSharingListParamsOrder) IsKnown() bool
type ResourceSharingListParamsStatus ¶
type ResourceSharingListParamsStatus string
Filter shares by status.
const ( ResourceSharingListParamsStatusActive ResourceSharingListParamsStatus = "active" ResourceSharingListParamsStatusDeleting ResourceSharingListParamsStatus = "deleting" ResourceSharingListParamsStatusDeleted ResourceSharingListParamsStatus = "deleted" )
func (ResourceSharingListParamsStatus) IsKnown ¶
func (r ResourceSharingListParamsStatus) IsKnown() bool
type ResourceSharingListParamsTargetType ¶
type ResourceSharingListParamsTargetType string
Filter shares by target_type.
const ( ResourceSharingListParamsTargetTypeAccount ResourceSharingListParamsTargetType = "account" ResourceSharingListParamsTargetTypeOrganization ResourceSharingListParamsTargetType = "organization" )
func (ResourceSharingListParamsTargetType) IsKnown ¶
func (r ResourceSharingListParamsTargetType) IsKnown() bool
type ResourceSharingListResponse ¶
type ResourceSharingListResponse struct {
// Share identifier tag.
ID string `json:"id,required"`
// Account identifier.
AccountID string `json:"account_id,required"`
// The display name of an account.
AccountName string `json:"account_name,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// The name of the share.
Name string `json:"name,required"`
// Organization identifier.
OrganizationID string `json:"organization_id,required"`
Status ResourceSharingListResponseStatus `json:"status,required"`
TargetType ResourceSharingListResponseTargetType `json:"target_type,required"`
Kind ResourceSharingListResponseKind `json:"kind"`
JSON resourceSharingListResponseJSON `json:"-"`
}
func (*ResourceSharingListResponse) UnmarshalJSON ¶
func (r *ResourceSharingListResponse) UnmarshalJSON(data []byte) (err error)
type ResourceSharingListResponseKind ¶
type ResourceSharingListResponseKind string
const ( ResourceSharingListResponseKindSent ResourceSharingListResponseKind = "sent" ResourceSharingListResponseKindReceived ResourceSharingListResponseKind = "received" )
func (ResourceSharingListResponseKind) IsKnown ¶
func (r ResourceSharingListResponseKind) IsKnown() bool
type ResourceSharingListResponseStatus ¶
type ResourceSharingListResponseStatus string
const ( ResourceSharingListResponseStatusActive ResourceSharingListResponseStatus = "active" ResourceSharingListResponseStatusDeleting ResourceSharingListResponseStatus = "deleting" ResourceSharingListResponseStatusDeleted ResourceSharingListResponseStatus = "deleted" )
func (ResourceSharingListResponseStatus) IsKnown ¶
func (r ResourceSharingListResponseStatus) IsKnown() bool
type ResourceSharingListResponseTargetType ¶
type ResourceSharingListResponseTargetType string
const ( ResourceSharingListResponseTargetTypeAccount ResourceSharingListResponseTargetType = "account" ResourceSharingListResponseTargetTypeOrganization ResourceSharingListResponseTargetType = "organization" )
func (ResourceSharingListResponseTargetType) IsKnown ¶
func (r ResourceSharingListResponseTargetType) IsKnown() bool
type ResourceSharingNewParams ¶
type ResourceSharingNewParams struct {
// Account identifier.
AccountID param.Field[string] `path:"account_id,required"`
// The name of the share.
Name param.Field[string] `json:"name,required"`
Recipients param.Field[[]ResourceSharingNewParamsRecipient] `json:"recipients,required"`
Resources param.Field[[]ResourceSharingNewParamsResource] `json:"resources,required"`
}
func (ResourceSharingNewParams) MarshalJSON ¶
func (r ResourceSharingNewParams) MarshalJSON() (data []byte, err error)
type ResourceSharingNewParamsRecipient ¶
type ResourceSharingNewParamsRecipient struct {
// Account identifier.
AccountID param.Field[string] `json:"account_id"`
// Organization identifier.
OrganizationID param.Field[string] `json:"organization_id"`
}
Account or organization ID must be provided.
func (ResourceSharingNewParamsRecipient) MarshalJSON ¶
func (r ResourceSharingNewParamsRecipient) MarshalJSON() (data []byte, err error)
type ResourceSharingNewParamsResource ¶
type ResourceSharingNewParamsResource struct {
// Resource Metadata.
Meta param.Field[interface{}] `json:"meta,required"`
// Account identifier.
ResourceAccountID param.Field[string] `json:"resource_account_id,required"`
// Share Resource identifier.
ResourceID param.Field[string] `json:"resource_id,required"`
// Resource Type.
ResourceType param.Field[ResourceSharingNewParamsResourcesResourceType] `json:"resource_type,required"`
}
func (ResourceSharingNewParamsResource) MarshalJSON ¶
func (r ResourceSharingNewParamsResource) MarshalJSON() (data []byte, err error)
type ResourceSharingNewParamsResourcesResourceType ¶
type ResourceSharingNewParamsResourcesResourceType string
Resource Type.
const ( ResourceSharingNewParamsResourcesResourceTypeCustomRuleset ResourceSharingNewParamsResourcesResourceType = "custom-ruleset" ResourceSharingNewParamsResourcesResourceTypeWidget ResourceSharingNewParamsResourcesResourceType = "widget" )
func (ResourceSharingNewParamsResourcesResourceType) IsKnown ¶
func (r ResourceSharingNewParamsResourcesResourceType) IsKnown() bool
type ResourceSharingNewResponse ¶
type ResourceSharingNewResponse struct {
// Share identifier tag.
ID string `json:"id,required"`
// Account identifier.
AccountID string `json:"account_id,required"`
// The display name of an account.
AccountName string `json:"account_name,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// The name of the share.
Name string `json:"name,required"`
// Organization identifier.
OrganizationID string `json:"organization_id,required"`
Status ResourceSharingNewResponseStatus `json:"status,required"`
TargetType ResourceSharingNewResponseTargetType `json:"target_type,required"`
Kind ResourceSharingNewResponseKind `json:"kind"`
JSON resourceSharingNewResponseJSON `json:"-"`
}
func (*ResourceSharingNewResponse) UnmarshalJSON ¶
func (r *ResourceSharingNewResponse) UnmarshalJSON(data []byte) (err error)
type ResourceSharingNewResponseEnvelope ¶
type ResourceSharingNewResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result ResourceSharingNewResponse `json:"result"`
JSON resourceSharingNewResponseEnvelopeJSON `json:"-"`
}
func (*ResourceSharingNewResponseEnvelope) UnmarshalJSON ¶
func (r *ResourceSharingNewResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type ResourceSharingNewResponseKind ¶
type ResourceSharingNewResponseKind string
const ( ResourceSharingNewResponseKindSent ResourceSharingNewResponseKind = "sent" ResourceSharingNewResponseKindReceived ResourceSharingNewResponseKind = "received" )
func (ResourceSharingNewResponseKind) IsKnown ¶
func (r ResourceSharingNewResponseKind) IsKnown() bool
type ResourceSharingNewResponseStatus ¶
type ResourceSharingNewResponseStatus string
const ( ResourceSharingNewResponseStatusActive ResourceSharingNewResponseStatus = "active" ResourceSharingNewResponseStatusDeleting ResourceSharingNewResponseStatus = "deleting" ResourceSharingNewResponseStatusDeleted ResourceSharingNewResponseStatus = "deleted" )
func (ResourceSharingNewResponseStatus) IsKnown ¶
func (r ResourceSharingNewResponseStatus) IsKnown() bool
type ResourceSharingNewResponseTargetType ¶
type ResourceSharingNewResponseTargetType string
const ( ResourceSharingNewResponseTargetTypeAccount ResourceSharingNewResponseTargetType = "account" ResourceSharingNewResponseTargetTypeOrganization ResourceSharingNewResponseTargetType = "organization" )
func (ResourceSharingNewResponseTargetType) IsKnown ¶
func (r ResourceSharingNewResponseTargetType) IsKnown() bool
type ResourceSharingService ¶
type ResourceSharingService struct {
Options []option.RequestOption
Recipients *RecipientService
Resources *ResourceService
}
ResourceSharingService 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 NewResourceSharingService method instead.
func NewResourceSharingService ¶
func NewResourceSharingService(opts ...option.RequestOption) (r *ResourceSharingService)
NewResourceSharingService 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 (*ResourceSharingService) Delete ¶
func (r *ResourceSharingService) Delete(ctx context.Context, shareID string, body ResourceSharingDeleteParams, opts ...option.RequestOption) (res *ResourceSharingDeleteResponse, err error)
Deletion is not immediate, an updated share object with a new status will be returned.
func (*ResourceSharingService) Get ¶
func (r *ResourceSharingService) Get(ctx context.Context, shareID string, query ResourceSharingGetParams, opts ...option.RequestOption) (res *ResourceSharingGetResponse, err error)
Fetches share by ID.
func (*ResourceSharingService) List ¶
func (r *ResourceSharingService) List(ctx context.Context, params ResourceSharingListParams, opts ...option.RequestOption) (res *pagination.V4PagePaginationArray[ResourceSharingListResponse], err error)
Lists all account shares.
func (*ResourceSharingService) ListAutoPaging ¶
func (r *ResourceSharingService) ListAutoPaging(ctx context.Context, params ResourceSharingListParams, opts ...option.RequestOption) *pagination.V4PagePaginationArrayAutoPager[ResourceSharingListResponse]
Lists all account shares.
func (*ResourceSharingService) New ¶
func (r *ResourceSharingService) New(ctx context.Context, params ResourceSharingNewParams, opts ...option.RequestOption) (res *ResourceSharingNewResponse, err error)
Create a new share
func (*ResourceSharingService) Update ¶
func (r *ResourceSharingService) Update(ctx context.Context, shareID string, params ResourceSharingUpdateParams, opts ...option.RequestOption) (res *ResourceSharingUpdateResponse, err error)
Updating is not immediate, an updated share object with a new status will be returned.
type ResourceSharingUpdateParams ¶
type ResourceSharingUpdateParams struct {
// Account identifier.
AccountID param.Field[string] `path:"account_id,required"`
// The name of the share.
Name param.Field[string] `json:"name,required"`
}
func (ResourceSharingUpdateParams) MarshalJSON ¶
func (r ResourceSharingUpdateParams) MarshalJSON() (data []byte, err error)
type ResourceSharingUpdateResponse ¶
type ResourceSharingUpdateResponse struct {
// Share identifier tag.
ID string `json:"id,required"`
// Account identifier.
AccountID string `json:"account_id,required"`
// The display name of an account.
AccountName string `json:"account_name,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// The name of the share.
Name string `json:"name,required"`
// Organization identifier.
OrganizationID string `json:"organization_id,required"`
Status ResourceSharingUpdateResponseStatus `json:"status,required"`
TargetType ResourceSharingUpdateResponseTargetType `json:"target_type,required"`
Kind ResourceSharingUpdateResponseKind `json:"kind"`
JSON resourceSharingUpdateResponseJSON `json:"-"`
}
func (*ResourceSharingUpdateResponse) UnmarshalJSON ¶
func (r *ResourceSharingUpdateResponse) UnmarshalJSON(data []byte) (err error)
type ResourceSharingUpdateResponseEnvelope ¶
type ResourceSharingUpdateResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result ResourceSharingUpdateResponse `json:"result"`
JSON resourceSharingUpdateResponseEnvelopeJSON `json:"-"`
}
func (*ResourceSharingUpdateResponseEnvelope) UnmarshalJSON ¶
func (r *ResourceSharingUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type ResourceSharingUpdateResponseKind ¶
type ResourceSharingUpdateResponseKind string
const ( ResourceSharingUpdateResponseKindSent ResourceSharingUpdateResponseKind = "sent" ResourceSharingUpdateResponseKindReceived ResourceSharingUpdateResponseKind = "received" )
func (ResourceSharingUpdateResponseKind) IsKnown ¶
func (r ResourceSharingUpdateResponseKind) IsKnown() bool
type ResourceSharingUpdateResponseStatus ¶
type ResourceSharingUpdateResponseStatus string
const ( ResourceSharingUpdateResponseStatusActive ResourceSharingUpdateResponseStatus = "active" ResourceSharingUpdateResponseStatusDeleting ResourceSharingUpdateResponseStatus = "deleting" ResourceSharingUpdateResponseStatusDeleted ResourceSharingUpdateResponseStatus = "deleted" )
func (ResourceSharingUpdateResponseStatus) IsKnown ¶
func (r ResourceSharingUpdateResponseStatus) IsKnown() bool
type ResourceSharingUpdateResponseTargetType ¶
type ResourceSharingUpdateResponseTargetType string
const ( ResourceSharingUpdateResponseTargetTypeAccount ResourceSharingUpdateResponseTargetType = "account" ResourceSharingUpdateResponseTargetTypeOrganization ResourceSharingUpdateResponseTargetType = "organization" )
func (ResourceSharingUpdateResponseTargetType) IsKnown ¶
func (r ResourceSharingUpdateResponseTargetType) IsKnown() bool
type ResourceUpdateParams ¶
type ResourceUpdateParams struct {
// Account identifier.
AccountID param.Field[string] `path:"account_id,required"`
// Resource Metadata.
Meta param.Field[interface{}] `json:"meta,required"`
}
func (ResourceUpdateParams) MarshalJSON ¶
func (r ResourceUpdateParams) MarshalJSON() (data []byte, err error)
type ResourceUpdateResponse ¶
type ResourceUpdateResponse struct {
// Share Resource identifier.
ID string `json:"id,required"`
// When the share was created.
Created time.Time `json:"created,required" format:"date-time"`
// Resource Metadata.
Meta interface{} `json:"meta,required"`
// When the share was modified.
Modified time.Time `json:"modified,required" format:"date-time"`
// Account identifier.
ResourceAccountID string `json:"resource_account_id,required"`
// Share Resource identifier.
ResourceID string `json:"resource_id,required"`
// Resource Type.
ResourceType ResourceUpdateResponseResourceType `json:"resource_type,required"`
// Resource Version.
ResourceVersion int64 `json:"resource_version,required"`
// Resource Status.
Status ResourceUpdateResponseStatus `json:"status,required"`
JSON resourceUpdateResponseJSON `json:"-"`
}
func (*ResourceUpdateResponse) UnmarshalJSON ¶
func (r *ResourceUpdateResponse) UnmarshalJSON(data []byte) (err error)
type ResourceUpdateResponseEnvelope ¶
type ResourceUpdateResponseEnvelope struct {
Errors []shared.ResponseInfo `json:"errors,required"`
// Whether the API call was successful.
Success bool `json:"success,required"`
Result ResourceUpdateResponse `json:"result"`
JSON resourceUpdateResponseEnvelopeJSON `json:"-"`
}
func (*ResourceUpdateResponseEnvelope) UnmarshalJSON ¶
func (r *ResourceUpdateResponseEnvelope) UnmarshalJSON(data []byte) (err error)
type ResourceUpdateResponseResourceType ¶
type ResourceUpdateResponseResourceType string
Resource Type.
const ( ResourceUpdateResponseResourceTypeCustomRuleset ResourceUpdateResponseResourceType = "custom-ruleset" ResourceUpdateResponseResourceTypeWidget ResourceUpdateResponseResourceType = "widget" )
func (ResourceUpdateResponseResourceType) IsKnown ¶
func (r ResourceUpdateResponseResourceType) IsKnown() bool
type ResourceUpdateResponseStatus ¶
type ResourceUpdateResponseStatus string
Resource Status.
const ( ResourceUpdateResponseStatusActive ResourceUpdateResponseStatus = "active" ResourceUpdateResponseStatusDeleting ResourceUpdateResponseStatus = "deleting" ResourceUpdateResponseStatusDeleted ResourceUpdateResponseStatus = "deleted" )
func (ResourceUpdateResponseStatus) IsKnown ¶
func (r ResourceUpdateResponseStatus) IsKnown() bool
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 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 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.