workers_for_platforms

package
v2.0.0-beta.17 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2024 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DispatchNamespaceDeleteParams

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

type DispatchNamespaceDeleteResponse

type DispatchNamespaceDeleteResponse = interface{}

type DispatchNamespaceDeleteResponseEnvelope

type DispatchNamespaceDeleteResponseEnvelope struct {
	Errors   []DispatchNamespaceDeleteResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DispatchNamespaceDeleteResponseEnvelopeMessages `json:"messages,required"`
	Result   DispatchNamespaceDeleteResponse                   `json:"result,required,nullable"`
	// Whether the API call was successful
	Success DispatchNamespaceDeleteResponseEnvelopeSuccess `json:"success,required"`
	JSON    dispatchNamespaceDeleteResponseEnvelopeJSON    `json:"-"`
}

func (*DispatchNamespaceDeleteResponseEnvelope) UnmarshalJSON

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

type DispatchNamespaceDeleteResponseEnvelopeErrors

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

func (*DispatchNamespaceDeleteResponseEnvelopeErrors) UnmarshalJSON

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

type DispatchNamespaceDeleteResponseEnvelopeMessages

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

func (*DispatchNamespaceDeleteResponseEnvelopeMessages) UnmarshalJSON

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

type DispatchNamespaceDeleteResponseEnvelopeSuccess

type DispatchNamespaceDeleteResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	DispatchNamespaceDeleteResponseEnvelopeSuccessTrue DispatchNamespaceDeleteResponseEnvelopeSuccess = true
)

func (DispatchNamespaceDeleteResponseEnvelopeSuccess) IsKnown

type DispatchNamespaceGetParams

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

type DispatchNamespaceGetResponse

type DispatchNamespaceGetResponse struct {
	// Identifier
	CreatedBy string `json:"created_by"`
	// When the script was created.
	CreatedOn time.Time `json:"created_on" format:"date-time"`
	// Identifier
	ModifiedBy string `json:"modified_by"`
	// When the script was last modified.
	ModifiedOn time.Time `json:"modified_on" format:"date-time"`
	// API Resource UUID tag.
	NamespaceID string `json:"namespace_id"`
	// Name of the Workers for Platforms dispatch namespace.
	NamespaceName string `json:"namespace_name"`
	// The current number of scripts in this Dispatch Namespace
	ScriptCount int64                            `json:"script_count"`
	JSON        dispatchNamespaceGetResponseJSON `json:"-"`
}

func (*DispatchNamespaceGetResponse) UnmarshalJSON

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

type DispatchNamespaceGetResponseEnvelope

type DispatchNamespaceGetResponseEnvelope struct {
	Errors   []DispatchNamespaceGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DispatchNamespaceGetResponseEnvelopeMessages `json:"messages,required"`
	Result   DispatchNamespaceGetResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success DispatchNamespaceGetResponseEnvelopeSuccess `json:"success,required"`
	JSON    dispatchNamespaceGetResponseEnvelopeJSON    `json:"-"`
}

func (*DispatchNamespaceGetResponseEnvelope) UnmarshalJSON

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

type DispatchNamespaceGetResponseEnvelopeErrors

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

func (*DispatchNamespaceGetResponseEnvelopeErrors) UnmarshalJSON

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

type DispatchNamespaceGetResponseEnvelopeMessages

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

func (*DispatchNamespaceGetResponseEnvelopeMessages) UnmarshalJSON

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

type DispatchNamespaceGetResponseEnvelopeSuccess

type DispatchNamespaceGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	DispatchNamespaceGetResponseEnvelopeSuccessTrue DispatchNamespaceGetResponseEnvelopeSuccess = true
)

func (DispatchNamespaceGetResponseEnvelopeSuccess) IsKnown

type DispatchNamespaceListParams

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

type DispatchNamespaceListResponse

type DispatchNamespaceListResponse struct {
	// Identifier
	CreatedBy string `json:"created_by"`
	// When the script was created.
	CreatedOn time.Time `json:"created_on" format:"date-time"`
	// Identifier
	ModifiedBy string `json:"modified_by"`
	// When the script was last modified.
	ModifiedOn time.Time `json:"modified_on" format:"date-time"`
	// API Resource UUID tag.
	NamespaceID string `json:"namespace_id"`
	// Name of the Workers for Platforms dispatch namespace.
	NamespaceName string `json:"namespace_name"`
	// The current number of scripts in this Dispatch Namespace
	ScriptCount int64                             `json:"script_count"`
	JSON        dispatchNamespaceListResponseJSON `json:"-"`
}

func (*DispatchNamespaceListResponse) UnmarshalJSON

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

type DispatchNamespaceNewParams

type DispatchNamespaceNewParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// The name of the dispatch namespace
	Name param.Field[string] `json:"name"`
}

func (DispatchNamespaceNewParams) MarshalJSON

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

type DispatchNamespaceNewResponse

type DispatchNamespaceNewResponse struct {
	// Identifier
	CreatedBy string `json:"created_by"`
	// When the script was created.
	CreatedOn time.Time `json:"created_on" format:"date-time"`
	// Identifier
	ModifiedBy string `json:"modified_by"`
	// When the script was last modified.
	ModifiedOn time.Time `json:"modified_on" format:"date-time"`
	// API Resource UUID tag.
	NamespaceID string `json:"namespace_id"`
	// Name of the Workers for Platforms dispatch namespace.
	NamespaceName string `json:"namespace_name"`
	// The current number of scripts in this Dispatch Namespace
	ScriptCount int64                            `json:"script_count"`
	JSON        dispatchNamespaceNewResponseJSON `json:"-"`
}

func (*DispatchNamespaceNewResponse) UnmarshalJSON

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

type DispatchNamespaceNewResponseEnvelope

type DispatchNamespaceNewResponseEnvelope struct {
	Errors   []DispatchNamespaceNewResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DispatchNamespaceNewResponseEnvelopeMessages `json:"messages,required"`
	Result   DispatchNamespaceNewResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success DispatchNamespaceNewResponseEnvelopeSuccess `json:"success,required"`
	JSON    dispatchNamespaceNewResponseEnvelopeJSON    `json:"-"`
}

func (*DispatchNamespaceNewResponseEnvelope) UnmarshalJSON

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

type DispatchNamespaceNewResponseEnvelopeErrors

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

func (*DispatchNamespaceNewResponseEnvelopeErrors) UnmarshalJSON

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

type DispatchNamespaceNewResponseEnvelopeMessages

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

func (*DispatchNamespaceNewResponseEnvelopeMessages) UnmarshalJSON

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

type DispatchNamespaceNewResponseEnvelopeSuccess

type DispatchNamespaceNewResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	DispatchNamespaceNewResponseEnvelopeSuccessTrue DispatchNamespaceNewResponseEnvelopeSuccess = true
)

func (DispatchNamespaceNewResponseEnvelopeSuccess) IsKnown

type DispatchNamespaceScriptBindingGetParams

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

type DispatchNamespaceScriptBindingGetResponseWorkersD1Binding

type DispatchNamespaceScriptBindingGetResponseWorkersD1Binding struct {
	// ID of the D1 database to bind to
	ID string `json:"id,required"`
	// A JavaScript variable name for the binding.
	Binding string `json:"binding,required"`
	// The name of the D1 database associated with the 'id' provided.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptBindingGetResponseWorkersD1BindingType `json:"type,required"`
	JSON dispatchNamespaceScriptBindingGetResponseWorkersD1BindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptBindingGetResponseWorkersD1Binding) UnmarshalJSON

type DispatchNamespaceScriptBindingGetResponseWorkersD1BindingType

type DispatchNamespaceScriptBindingGetResponseWorkersD1BindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptBindingGetResponseWorkersD1BindingTypeD1 DispatchNamespaceScriptBindingGetResponseWorkersD1BindingType = "d1"
)

func (DispatchNamespaceScriptBindingGetResponseWorkersD1BindingType) IsKnown

type DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBinding

type DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Namespace to bind to
	Namespace string `json:"namespace,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingType `json:"type,required"`
	// Outbound worker
	Outbound DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingOutbound `json:"outbound"`
	JSON     dispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingJSON     `json:"-"`
}

func (*DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBinding) UnmarshalJSON

type DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingOutbound

type DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingOutbound struct {
	// Pass information from the Dispatch Worker to the Outbound Worker through the
	// parameters
	Params []string `json:"params"`
	// Outbound worker
	Worker DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingOutboundWorker `json:"worker"`
	JSON   dispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingOutboundJSON   `json:"-"`
}

Outbound worker

func (*DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingOutbound) UnmarshalJSON

type DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingOutboundWorker

type DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingOutboundWorker struct {
	// Environment of the outbound worker
	Environment string `json:"environment"`
	// Name of the outbound worker
	Service string                                                                                     `json:"service"`
	JSON    dispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingOutboundWorkerJSON `json:"-"`
}

Outbound worker

func (*DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingOutboundWorker) UnmarshalJSON

type DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingType

type DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingTypeDispatchNamespace DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingType = "dispatch_namespace"
)

func (DispatchNamespaceScriptBindingGetResponseWorkersDispatchNamespaceBindingType) IsKnown

type DispatchNamespaceScriptBindingGetResponseWorkersDoBinding

type DispatchNamespaceScriptBindingGetResponseWorkersDoBinding struct {
	// The exported class name of the Durable Object
	ClassName string `json:"class_name,required"`
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptBindingGetResponseWorkersDoBindingType `json:"type,required"`
	// The environment of the script_name to bind to
	Environment string `json:"environment"`
	// Namespace identifier tag.
	NamespaceID string `json:"namespace_id"`
	// The script where the Durable Object is defined, if it is external to this Worker
	ScriptName string                                                        `json:"script_name"`
	JSON       dispatchNamespaceScriptBindingGetResponseWorkersDoBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptBindingGetResponseWorkersDoBinding) UnmarshalJSON

type DispatchNamespaceScriptBindingGetResponseWorkersDoBindingType

type DispatchNamespaceScriptBindingGetResponseWorkersDoBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptBindingGetResponseWorkersDoBindingTypeDurableObjectNamespace DispatchNamespaceScriptBindingGetResponseWorkersDoBindingType = "durable_object_namespace"
)

func (DispatchNamespaceScriptBindingGetResponseWorkersDoBindingType) IsKnown

type DispatchNamespaceScriptBindingGetResponseWorkersKVNamespaceBinding

type DispatchNamespaceScriptBindingGetResponseWorkersKVNamespaceBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Namespace identifier tag.
	NamespaceID string `json:"namespace_id,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptBindingGetResponseWorkersKVNamespaceBindingType `json:"type,required"`
	JSON dispatchNamespaceScriptBindingGetResponseWorkersKVNamespaceBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptBindingGetResponseWorkersKVNamespaceBinding) UnmarshalJSON

type DispatchNamespaceScriptBindingGetResponseWorkersKVNamespaceBindingType

type DispatchNamespaceScriptBindingGetResponseWorkersKVNamespaceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptBindingGetResponseWorkersKVNamespaceBindingTypeKVNamespace DispatchNamespaceScriptBindingGetResponseWorkersKVNamespaceBindingType = "kv_namespace"
)

func (DispatchNamespaceScriptBindingGetResponseWorkersKVNamespaceBindingType) IsKnown

type DispatchNamespaceScriptBindingGetResponseWorkersMTLSCERTBinding

type DispatchNamespaceScriptBindingGetResponseWorkersMTLSCERTBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptBindingGetResponseWorkersMTLSCERTBindingType `json:"type,required"`
	// ID of the certificate to bind to
	CertificateID string                                                              `json:"certificate_id"`
	JSON          dispatchNamespaceScriptBindingGetResponseWorkersMtlscertBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptBindingGetResponseWorkersMTLSCERTBinding) UnmarshalJSON

type DispatchNamespaceScriptBindingGetResponseWorkersMTLSCERTBindingType

type DispatchNamespaceScriptBindingGetResponseWorkersMTLSCERTBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptBindingGetResponseWorkersMTLSCERTBindingTypeMTLSCertificate DispatchNamespaceScriptBindingGetResponseWorkersMTLSCERTBindingType = "mtls_certificate"
)

func (DispatchNamespaceScriptBindingGetResponseWorkersMTLSCERTBindingType) IsKnown

type DispatchNamespaceScriptBindingGetResponseWorkersQueueBinding

type DispatchNamespaceScriptBindingGetResponseWorkersQueueBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Name of the Queue to bind to
	QueueName string `json:"queue_name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptBindingGetResponseWorkersQueueBindingType `json:"type,required"`
	JSON dispatchNamespaceScriptBindingGetResponseWorkersQueueBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptBindingGetResponseWorkersQueueBinding) UnmarshalJSON

type DispatchNamespaceScriptBindingGetResponseWorkersQueueBindingType

type DispatchNamespaceScriptBindingGetResponseWorkersQueueBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptBindingGetResponseWorkersQueueBindingTypeQueue DispatchNamespaceScriptBindingGetResponseWorkersQueueBindingType = "queue"
)

func (DispatchNamespaceScriptBindingGetResponseWorkersQueueBindingType) IsKnown

type DispatchNamespaceScriptBindingGetResponseWorkersR2Binding

type DispatchNamespaceScriptBindingGetResponseWorkersR2Binding struct {
	// R2 bucket to bind to
	BucketName string `json:"bucket_name,required"`
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptBindingGetResponseWorkersR2BindingType `json:"type,required"`
	JSON dispatchNamespaceScriptBindingGetResponseWorkersR2BindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptBindingGetResponseWorkersR2Binding) UnmarshalJSON

type DispatchNamespaceScriptBindingGetResponseWorkersR2BindingType

type DispatchNamespaceScriptBindingGetResponseWorkersR2BindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptBindingGetResponseWorkersR2BindingTypeR2Bucket DispatchNamespaceScriptBindingGetResponseWorkersR2BindingType = "r2_bucket"
)

func (DispatchNamespaceScriptBindingGetResponseWorkersR2BindingType) IsKnown

type DispatchNamespaceScriptBindingGetResponseWorkersServiceBinding

type DispatchNamespaceScriptBindingGetResponseWorkersServiceBinding struct {
	// Optional environment if the Worker utilizes one.
	Environment string `json:"environment,required"`
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Name of Worker to bind to
	Service string `json:"service,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptBindingGetResponseWorkersServiceBindingType `json:"type,required"`
	JSON dispatchNamespaceScriptBindingGetResponseWorkersServiceBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptBindingGetResponseWorkersServiceBinding) UnmarshalJSON

type DispatchNamespaceScriptBindingGetResponseWorkersServiceBindingType

type DispatchNamespaceScriptBindingGetResponseWorkersServiceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptBindingGetResponseWorkersServiceBindingTypeService DispatchNamespaceScriptBindingGetResponseWorkersServiceBindingType = "service"
)

func (DispatchNamespaceScriptBindingGetResponseWorkersServiceBindingType) IsKnown

type DispatchNamespaceScriptBindingService

type DispatchNamespaceScriptBindingService struct {
	Options []option.RequestOption
}

DispatchNamespaceScriptBindingService 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 NewDispatchNamespaceScriptBindingService method instead.

func NewDispatchNamespaceScriptBindingService

func NewDispatchNamespaceScriptBindingService(opts ...option.RequestOption) (r *DispatchNamespaceScriptBindingService)

NewDispatchNamespaceScriptBindingService 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 (*DispatchNamespaceScriptBindingService) Get

Fetch script bindings from a script uploaded to a Workers for Platforms namespace.

type DispatchNamespaceScriptContentGetParams

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

type DispatchNamespaceScriptContentService

type DispatchNamespaceScriptContentService struct {
	Options []option.RequestOption
}

DispatchNamespaceScriptContentService 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 NewDispatchNamespaceScriptContentService method instead.

func NewDispatchNamespaceScriptContentService

func NewDispatchNamespaceScriptContentService(opts ...option.RequestOption) (r *DispatchNamespaceScriptContentService)

NewDispatchNamespaceScriptContentService 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 (*DispatchNamespaceScriptContentService) Get

Fetch script content from a script uploaded to a Workers for Platforms namespace.

func (*DispatchNamespaceScriptContentService) Update

Put script content for a script uploaded to a Workers for Platforms namespace.

type DispatchNamespaceScriptContentUpdateParams

type DispatchNamespaceScriptContentUpdateParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// A module comprising a Worker script, often a javascript file. Multiple modules
	// may be provided as separate named parts, but at least one module must be
	// present. This should be referenced either in the metadata as `main_module`
	// (esm)/`body_part` (service worker) or as a header `CF-WORKER-MAIN-MODULE-PART`
	// (esm) /`CF-WORKER-BODY-PART` (service worker) by part name.
	AnyPartName param.Field[[]io.Reader] `json:"<any part name>" format:"binary"`
	// JSON encoded metadata about the uploaded parts and Worker configuration.
	Metadata               param.Field[DispatchNamespaceScriptContentUpdateParamsMetadata] `json:"metadata"`
	CfWorkerBodyPart       param.Field[string]                                             `header:"CF-WORKER-BODY-PART"`
	CfWorkerMainModulePart param.Field[string]                                             `header:"CF-WORKER-MAIN-MODULE-PART"`
}

func (DispatchNamespaceScriptContentUpdateParams) MarshalMultipart

func (r DispatchNamespaceScriptContentUpdateParams) MarshalMultipart() (data []byte, contentType string, err error)

type DispatchNamespaceScriptContentUpdateParamsMetadata

type DispatchNamespaceScriptContentUpdateParamsMetadata struct {
	// Name of the part in the multipart request that contains the script (e.g. the
	// file adding a listener to the `fetch` event). Indicates a
	// `service worker syntax` Worker.
	BodyPart param.Field[string] `json:"body_part"`
	// Name of the part in the multipart request that contains the main module (e.g.
	// the file exporting a `fetch` handler). Indicates a `module syntax` Worker.
	MainModule param.Field[string] `json:"main_module"`
}

JSON encoded metadata about the uploaded parts and Worker configuration.

func (DispatchNamespaceScriptContentUpdateParamsMetadata) MarshalJSON

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

type DispatchNamespaceScriptContentUpdateResponseEnvelope

type DispatchNamespaceScriptContentUpdateResponseEnvelope struct {
	Errors   []DispatchNamespaceScriptContentUpdateResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DispatchNamespaceScriptContentUpdateResponseEnvelopeMessages `json:"messages,required"`
	Result   workers.WorkersScript                                          `json:"result,required"`
	// Whether the API call was successful
	Success DispatchNamespaceScriptContentUpdateResponseEnvelopeSuccess `json:"success,required"`
	JSON    dispatchNamespaceScriptContentUpdateResponseEnvelopeJSON    `json:"-"`
}

func (*DispatchNamespaceScriptContentUpdateResponseEnvelope) UnmarshalJSON

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

type DispatchNamespaceScriptContentUpdateResponseEnvelopeErrors

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

func (*DispatchNamespaceScriptContentUpdateResponseEnvelopeErrors) UnmarshalJSON

type DispatchNamespaceScriptContentUpdateResponseEnvelopeMessages

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

func (*DispatchNamespaceScriptContentUpdateResponseEnvelopeMessages) UnmarshalJSON

type DispatchNamespaceScriptContentUpdateResponseEnvelopeSuccess

type DispatchNamespaceScriptContentUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	DispatchNamespaceScriptContentUpdateResponseEnvelopeSuccessTrue DispatchNamespaceScriptContentUpdateResponseEnvelopeSuccess = true
)

func (DispatchNamespaceScriptContentUpdateResponseEnvelopeSuccess) IsKnown

type DispatchNamespaceScriptDeleteParams

type DispatchNamespaceScriptDeleteParams struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// If set to true, delete will not be stopped by associated service binding,
	// durable object, or other binding. Any of these associated bindings/durable
	// objects will be deleted along with the script.
	Force param.Field[bool] `query:"force"`
}

func (DispatchNamespaceScriptDeleteParams) URLQuery

URLQuery serializes DispatchNamespaceScriptDeleteParams's query parameters as `url.Values`.

type DispatchNamespaceScriptGetParams

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

type DispatchNamespaceScriptGetResponseEnvelope

type DispatchNamespaceScriptGetResponseEnvelope struct {
	Errors   []DispatchNamespaceScriptGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DispatchNamespaceScriptGetResponseEnvelopeMessages `json:"messages,required"`
	// Details about a worker uploaded to a Workers for Platforms namespace.
	Result WorkersForPlatformsNamespaceScript `json:"result,required"`
	// Whether the API call was successful
	Success DispatchNamespaceScriptGetResponseEnvelopeSuccess `json:"success,required"`
	JSON    dispatchNamespaceScriptGetResponseEnvelopeJSON    `json:"-"`
}

func (*DispatchNamespaceScriptGetResponseEnvelope) UnmarshalJSON

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

type DispatchNamespaceScriptGetResponseEnvelopeErrors

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

func (*DispatchNamespaceScriptGetResponseEnvelopeErrors) UnmarshalJSON

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

type DispatchNamespaceScriptGetResponseEnvelopeMessages

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

func (*DispatchNamespaceScriptGetResponseEnvelopeMessages) UnmarshalJSON

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

type DispatchNamespaceScriptGetResponseEnvelopeSuccess

type DispatchNamespaceScriptGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	DispatchNamespaceScriptGetResponseEnvelopeSuccessTrue DispatchNamespaceScriptGetResponseEnvelopeSuccess = true
)

func (DispatchNamespaceScriptGetResponseEnvelopeSuccess) IsKnown

type DispatchNamespaceScriptService

type DispatchNamespaceScriptService struct {
	Options  []option.RequestOption
	Content  *DispatchNamespaceScriptContentService
	Settings *DispatchNamespaceScriptSettingService
	Bindings *DispatchNamespaceScriptBindingService
}

DispatchNamespaceScriptService 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 NewDispatchNamespaceScriptService method instead.

func NewDispatchNamespaceScriptService

func NewDispatchNamespaceScriptService(opts ...option.RequestOption) (r *DispatchNamespaceScriptService)

NewDispatchNamespaceScriptService 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 (*DispatchNamespaceScriptService) Delete

func (r *DispatchNamespaceScriptService) Delete(ctx context.Context, dispatchNamespace string, scriptName string, params DispatchNamespaceScriptDeleteParams, opts ...option.RequestOption) (err error)

Delete a worker from a Workers for Platforms namespace. This call has no response body on a successful delete.

func (*DispatchNamespaceScriptService) Get

Fetch information about a script uploaded to a Workers for Platforms namespace.

func (*DispatchNamespaceScriptService) Update

func (r *DispatchNamespaceScriptService) Update(ctx context.Context, dispatchNamespace string, scriptName string, params DispatchNamespaceScriptUpdateParams, opts ...option.RequestOption) (res *workers.WorkersScript, err error)

Upload a worker module to a Workers for Platforms namespace.

type DispatchNamespaceScriptSettingEditParams

type DispatchNamespaceScriptSettingEditParams struct {
	// Identifier
	AccountID param.Field[string]                                            `path:"account_id,required"`
	Errors    param.Field[[]DispatchNamespaceScriptSettingEditParamsError]   `json:"errors,required"`
	Messages  param.Field[[]DispatchNamespaceScriptSettingEditParamsMessage] `json:"messages,required"`
	Result    param.Field[DispatchNamespaceScriptSettingEditParamsResult]    `json:"result,required"`
	// Whether the API call was successful
	Success param.Field[DispatchNamespaceScriptSettingEditParamsSuccess] `json:"success,required"`
}

func (DispatchNamespaceScriptSettingEditParams) MarshalJSON

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

type DispatchNamespaceScriptSettingEditParamsError

type DispatchNamespaceScriptSettingEditParamsError struct {
	Code    param.Field[int64]  `json:"code,required"`
	Message param.Field[string] `json:"message,required"`
}

func (DispatchNamespaceScriptSettingEditParamsError) MarshalJSON

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

type DispatchNamespaceScriptSettingEditParamsMessage

type DispatchNamespaceScriptSettingEditParamsMessage struct {
	Code    param.Field[int64]  `json:"code,required"`
	Message param.Field[string] `json:"message,required"`
}

func (DispatchNamespaceScriptSettingEditParamsMessage) MarshalJSON

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

type DispatchNamespaceScriptSettingEditParamsResult

type DispatchNamespaceScriptSettingEditParamsResult struct {
	// List of bindings attached to this Worker
	Bindings param.Field[[]DispatchNamespaceScriptSettingEditParamsResultBinding] `json:"bindings"`
	// Opt your Worker into changes after this date
	CompatibilityDate param.Field[string] `json:"compatibility_date"`
	// Opt your Worker into specific changes
	CompatibilityFlags param.Field[[]string] `json:"compatibility_flags"`
	// Whether Logpush is turned on for the Worker.
	Logpush param.Field[bool] `json:"logpush"`
	// Migrations to apply for Durable Objects associated with this Worker.
	Migrations param.Field[DispatchNamespaceScriptSettingEditParamsResultMigrations] `json:"migrations"`
	Placement  param.Field[DispatchNamespaceScriptSettingEditParamsResultPlacement]  `json:"placement"`
	// Tags to help you manage your Workers
	Tags param.Field[[]string] `json:"tags"`
	// List of Workers that will consume logs from the attached Worker.
	TailConsumers param.Field[[]DispatchNamespaceScriptSettingEditParamsResultTailConsumer] `json:"tail_consumers"`
	// Specifies the usage model for the Worker (e.g. 'bundled' or 'unbound').
	UsageModel param.Field[string] `json:"usage_model"`
}

func (DispatchNamespaceScriptSettingEditParamsResult) MarshalJSON

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

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersD1Binding

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersD1Binding struct {
	// ID of the D1 database to bind to
	ID param.Field[string] `json:"id,required"`
	// The name of the D1 database associated with the 'id' provided.
	Name param.Field[string] `json:"name,required"`
	// The class of resource that the binding provides.
	Type param.Field[DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersD1BindingType] `json:"type,required"`
}

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersD1Binding) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersD1BindingType

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersD1BindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersD1BindingTypeD1 DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersD1BindingType = "d1"
)

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersD1BindingType) IsKnown

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBinding

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBinding struct {
	// Namespace to bind to
	Namespace param.Field[string] `json:"namespace,required"`
	// The class of resource that the binding provides.
	Type param.Field[DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingType] `json:"type,required"`
	// Outbound worker
	Outbound param.Field[DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingOutbound] `json:"outbound"`
}

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBinding) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingOutbound

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingOutbound struct {
	// Pass information from the Dispatch Worker to the Outbound Worker through the
	// parameters
	Params param.Field[[]string] `json:"params"`
	// Outbound worker
	Worker param.Field[DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingOutboundWorker] `json:"worker"`
}

Outbound worker

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingOutbound) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingOutboundWorker

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingOutboundWorker struct {
	// Environment of the outbound worker
	Environment param.Field[string] `json:"environment"`
	// Name of the outbound worker
	Service param.Field[string] `json:"service"`
}

Outbound worker

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingOutboundWorker) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingType

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingTypeDispatchNamespace DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingType = "dispatch_namespace"
)

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDispatchNamespaceBindingType) IsKnown

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDoBinding

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDoBinding struct {
	// The exported class name of the Durable Object
	ClassName param.Field[string] `json:"class_name,required"`
	// The class of resource that the binding provides.
	Type param.Field[DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDoBindingType] `json:"type,required"`
	// The environment of the script_name to bind to
	Environment param.Field[string] `json:"environment"`
	// The script where the Durable Object is defined, if it is external to this Worker
	ScriptName param.Field[string] `json:"script_name"`
}

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDoBinding) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDoBindingType

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDoBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDoBindingTypeDurableObjectNamespace DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDoBindingType = "durable_object_namespace"
)

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersDoBindingType) IsKnown

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersKVNamespaceBinding

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersKVNamespaceBinding struct {
	// The class of resource that the binding provides.
	Type param.Field[DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersKVNamespaceBindingType] `json:"type,required"`
}

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersKVNamespaceBinding) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersKVNamespaceBindingType

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersKVNamespaceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersKVNamespaceBindingTypeKVNamespace DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersKVNamespaceBindingType = "kv_namespace"
)

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersKVNamespaceBindingType) IsKnown

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersMTLSCERTBinding

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersMTLSCERTBinding struct {
	// The class of resource that the binding provides.
	Type param.Field[DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersMTLSCERTBindingType] `json:"type,required"`
	// ID of the certificate to bind to
	CertificateID param.Field[string] `json:"certificate_id"`
}

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersMTLSCERTBinding) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersMTLSCERTBindingType

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersMTLSCERTBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersMTLSCERTBindingTypeMTLSCertificate DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersMTLSCERTBindingType = "mtls_certificate"
)

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersMTLSCERTBindingType) IsKnown

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersQueueBinding

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersQueueBinding struct {
	// Name of the Queue to bind to
	QueueName param.Field[string] `json:"queue_name,required"`
	// The class of resource that the binding provides.
	Type param.Field[DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersQueueBindingType] `json:"type,required"`
}

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersQueueBinding) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersQueueBindingType

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersQueueBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersQueueBindingTypeQueue DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersQueueBindingType = "queue"
)

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersQueueBindingType) IsKnown

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersR2Binding

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersR2Binding struct {
	// R2 bucket to bind to
	BucketName param.Field[string] `json:"bucket_name,required"`
	// The class of resource that the binding provides.
	Type param.Field[DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersR2BindingType] `json:"type,required"`
}

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersR2Binding) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersR2BindingType

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersR2BindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersR2BindingTypeR2Bucket DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersR2BindingType = "r2_bucket"
)

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersR2BindingType) IsKnown

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersServiceBinding

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersServiceBinding struct {
	// Optional environment if the Worker utilizes one.
	Environment param.Field[string] `json:"environment,required"`
	// Name of Worker to bind to
	Service param.Field[string] `json:"service,required"`
	// The class of resource that the binding provides.
	Type param.Field[DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersServiceBindingType] `json:"type,required"`
}

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersServiceBinding) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersServiceBindingType

type DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersServiceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersServiceBindingTypeService DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersServiceBindingType = "service"
)

func (DispatchNamespaceScriptSettingEditParamsResultBindingsWorkersServiceBindingType) IsKnown

type DispatchNamespaceScriptSettingEditParamsResultMigrations

type DispatchNamespaceScriptSettingEditParamsResultMigrations interface {
	// contains filtered or unexported methods
}

Migrations to apply for Durable Objects associated with this Worker.

Satisfied by workers_for_platforms.DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrations, workers_for_platforms.DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrations.

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrations

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrations struct {
	// A list of classes to delete Durable Object namespaces from.
	DeletedClasses param.Field[[]string] `json:"deleted_classes"`
	// A list of classes to create Durable Object namespaces from.
	NewClasses param.Field[[]string] `json:"new_classes"`
	// Tag to set as the latest migration tag.
	NewTag param.Field[string] `json:"new_tag"`
	// Tag used to verify against the latest migration tag for this Worker. If they
	// don't match, the upload is rejected.
	OldTag param.Field[string] `json:"old_tag"`
	// A list of classes with Durable Object namespaces that were renamed.
	RenamedClasses param.Field[[]DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrationsRenamedClass] `json:"renamed_classes"`
	// A list of transfers for Durable Object namespaces from a different Worker and
	// class to a class defined in this Worker.
	TransferredClasses param.Field[[]DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrationsTransferredClass] `json:"transferred_classes"`
}

A single set of migrations to apply.

func (DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrations) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrationsRenamedClass

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrationsRenamedClass struct {
	From param.Field[string] `json:"from"`
	To   param.Field[string] `json:"to"`
}

func (DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrationsRenamedClass) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrationsTransferredClass

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrationsTransferredClass struct {
	From       param.Field[string] `json:"from"`
	FromScript param.Field[string] `json:"from_script"`
	To         param.Field[string] `json:"to"`
}

func (DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSingleStepMigrationsTransferredClass) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrations

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrations struct {
	// Tag to set as the latest migration tag.
	NewTag param.Field[string] `json:"new_tag"`
	// Tag used to verify against the latest migration tag for this Worker. If they
	// don't match, the upload is rejected.
	OldTag param.Field[string] `json:"old_tag"`
	// Migrations to apply in order.
	Steps param.Field[[]DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStep] `json:"steps"`
}

func (DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrations) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStep

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStep struct {
	// A list of classes to delete Durable Object namespaces from.
	DeletedClasses param.Field[[]string] `json:"deleted_classes"`
	// A list of classes to create Durable Object namespaces from.
	NewClasses param.Field[[]string] `json:"new_classes"`
	// A list of classes with Durable Object namespaces that were renamed.
	RenamedClasses param.Field[[]DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStepsRenamedClass] `json:"renamed_classes"`
	// A list of transfers for Durable Object namespaces from a different Worker and
	// class to a class defined in this Worker.
	TransferredClasses param.Field[[]DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStepsTransferredClass] `json:"transferred_classes"`
}

func (DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStep) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStepsRenamedClass

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStepsRenamedClass struct {
	From param.Field[string] `json:"from"`
	To   param.Field[string] `json:"to"`
}

func (DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStepsRenamedClass) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStepsTransferredClass

type DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStepsTransferredClass struct {
	From       param.Field[string] `json:"from"`
	FromScript param.Field[string] `json:"from_script"`
	To         param.Field[string] `json:"to"`
}

func (DispatchNamespaceScriptSettingEditParamsResultMigrationsWorkersSteppedMigrationsStepsTransferredClass) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultPlacement

type DispatchNamespaceScriptSettingEditParamsResultPlacement struct {
	// Enables
	// [Smart Placement](https://developers.cloudflare.com/workers/configuration/smart-placement).
	// Only `"smart"` is currently supported
	Mode param.Field[DispatchNamespaceScriptSettingEditParamsResultPlacementMode] `json:"mode"`
}

func (DispatchNamespaceScriptSettingEditParamsResultPlacement) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsResultPlacementMode

type DispatchNamespaceScriptSettingEditParamsResultPlacementMode string

Enables [Smart Placement](https://developers.cloudflare.com/workers/configuration/smart-placement). Only `"smart"` is currently supported

const (
	DispatchNamespaceScriptSettingEditParamsResultPlacementModeSmart DispatchNamespaceScriptSettingEditParamsResultPlacementMode = "smart"
)

func (DispatchNamespaceScriptSettingEditParamsResultPlacementMode) IsKnown

type DispatchNamespaceScriptSettingEditParamsResultTailConsumer

type DispatchNamespaceScriptSettingEditParamsResultTailConsumer struct {
	// Name of Worker that is to be the consumer.
	Service param.Field[string] `json:"service,required"`
	// Optional environment if the Worker utilizes one.
	Environment param.Field[string] `json:"environment"`
	// Optional dispatch namespace the script belongs to.
	Namespace param.Field[string] `json:"namespace"`
}

A reference to a script that will consume logs from the attached Worker.

func (DispatchNamespaceScriptSettingEditParamsResultTailConsumer) MarshalJSON

type DispatchNamespaceScriptSettingEditParamsSuccess

type DispatchNamespaceScriptSettingEditParamsSuccess bool

Whether the API call was successful

const (
	DispatchNamespaceScriptSettingEditParamsSuccessTrue DispatchNamespaceScriptSettingEditParamsSuccess = true
)

func (DispatchNamespaceScriptSettingEditParamsSuccess) IsKnown

type DispatchNamespaceScriptSettingEditResponse

type DispatchNamespaceScriptSettingEditResponse struct {
	// List of bindings attached to this Worker
	Bindings []DispatchNamespaceScriptSettingEditResponseBinding `json:"bindings"`
	// Opt your Worker into changes after this date
	CompatibilityDate string `json:"compatibility_date"`
	// Opt your Worker into specific changes
	CompatibilityFlags []string `json:"compatibility_flags"`
	// Whether Logpush is turned on for the Worker.
	Logpush bool `json:"logpush"`
	// Migrations to apply for Durable Objects associated with this Worker.
	Migrations DispatchNamespaceScriptSettingEditResponseMigrations `json:"migrations"`
	Placement  DispatchNamespaceScriptSettingEditResponsePlacement  `json:"placement"`
	// Tags to help you manage your Workers
	Tags []string `json:"tags"`
	// List of Workers that will consume logs from the attached Worker.
	TailConsumers []DispatchNamespaceScriptSettingEditResponseTailConsumer `json:"tail_consumers"`
	// Specifies the usage model for the Worker (e.g. 'bundled' or 'unbound').
	UsageModel string                                         `json:"usage_model"`
	JSON       dispatchNamespaceScriptSettingEditResponseJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponse) UnmarshalJSON

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

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersD1Binding

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersD1Binding struct {
	// ID of the D1 database to bind to
	ID string `json:"id,required"`
	// A JavaScript variable name for the binding.
	Binding string `json:"binding,required"`
	// The name of the D1 database associated with the 'id' provided.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingEditResponseBindingsWorkersD1BindingType `json:"type,required"`
	JSON dispatchNamespaceScriptSettingEditResponseBindingsWorkersD1BindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseBindingsWorkersD1Binding) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersD1BindingType

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersD1BindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditResponseBindingsWorkersD1BindingTypeD1 DispatchNamespaceScriptSettingEditResponseBindingsWorkersD1BindingType = "d1"
)

func (DispatchNamespaceScriptSettingEditResponseBindingsWorkersD1BindingType) IsKnown

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBinding

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Namespace to bind to
	Namespace string `json:"namespace,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingType `json:"type,required"`
	// Outbound worker
	Outbound DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingOutbound `json:"outbound"`
	JSON     dispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingJSON     `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingOutbound

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingOutbound struct {
	// Pass information from the Dispatch Worker to the Outbound Worker through the
	// parameters
	Params []string `json:"params"`
	// Outbound worker
	Worker DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingOutboundWorker `json:"worker"`
	JSON   dispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingOutboundJSON   `json:"-"`
}

Outbound worker

func (*DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingOutbound) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingOutboundWorker

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingOutboundWorker struct {
	// Environment of the outbound worker
	Environment string `json:"environment"`
	// Name of the outbound worker
	Service string                                                                                              `json:"service"`
	JSON    dispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingOutboundWorkerJSON `json:"-"`
}

Outbound worker

func (*DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingOutboundWorker) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingType

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingTypeDispatchNamespace DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingType = "dispatch_namespace"
)

func (DispatchNamespaceScriptSettingEditResponseBindingsWorkersDispatchNamespaceBindingType) IsKnown

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDoBinding

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDoBinding struct {
	// The exported class name of the Durable Object
	ClassName string `json:"class_name,required"`
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDoBindingType `json:"type,required"`
	// The environment of the script_name to bind to
	Environment string `json:"environment"`
	// Namespace identifier tag.
	NamespaceID string `json:"namespace_id"`
	// The script where the Durable Object is defined, if it is external to this Worker
	ScriptName string                                                                 `json:"script_name"`
	JSON       dispatchNamespaceScriptSettingEditResponseBindingsWorkersDoBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseBindingsWorkersDoBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDoBindingType

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersDoBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditResponseBindingsWorkersDoBindingTypeDurableObjectNamespace DispatchNamespaceScriptSettingEditResponseBindingsWorkersDoBindingType = "durable_object_namespace"
)

func (DispatchNamespaceScriptSettingEditResponseBindingsWorkersDoBindingType) IsKnown

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersKVNamespaceBinding

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersKVNamespaceBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Namespace identifier tag.
	NamespaceID string `json:"namespace_id,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingEditResponseBindingsWorkersKVNamespaceBindingType `json:"type,required"`
	JSON dispatchNamespaceScriptSettingEditResponseBindingsWorkersKVNamespaceBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseBindingsWorkersKVNamespaceBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersKVNamespaceBindingType

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersKVNamespaceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditResponseBindingsWorkersKVNamespaceBindingTypeKVNamespace DispatchNamespaceScriptSettingEditResponseBindingsWorkersKVNamespaceBindingType = "kv_namespace"
)

func (DispatchNamespaceScriptSettingEditResponseBindingsWorkersKVNamespaceBindingType) IsKnown

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersMTLSCERTBinding

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersMTLSCERTBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingEditResponseBindingsWorkersMTLSCERTBindingType `json:"type,required"`
	// ID of the certificate to bind to
	CertificateID string                                                                       `json:"certificate_id"`
	JSON          dispatchNamespaceScriptSettingEditResponseBindingsWorkersMtlscertBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseBindingsWorkersMTLSCERTBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersMTLSCERTBindingType

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersMTLSCERTBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditResponseBindingsWorkersMTLSCERTBindingTypeMTLSCertificate DispatchNamespaceScriptSettingEditResponseBindingsWorkersMTLSCERTBindingType = "mtls_certificate"
)

func (DispatchNamespaceScriptSettingEditResponseBindingsWorkersMTLSCERTBindingType) IsKnown

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersQueueBinding

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersQueueBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Name of the Queue to bind to
	QueueName string `json:"queue_name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingEditResponseBindingsWorkersQueueBindingType `json:"type,required"`
	JSON dispatchNamespaceScriptSettingEditResponseBindingsWorkersQueueBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseBindingsWorkersQueueBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersQueueBindingType

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersQueueBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditResponseBindingsWorkersQueueBindingTypeQueue DispatchNamespaceScriptSettingEditResponseBindingsWorkersQueueBindingType = "queue"
)

func (DispatchNamespaceScriptSettingEditResponseBindingsWorkersQueueBindingType) IsKnown

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersR2Binding

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersR2Binding struct {
	// R2 bucket to bind to
	BucketName string `json:"bucket_name,required"`
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingEditResponseBindingsWorkersR2BindingType `json:"type,required"`
	JSON dispatchNamespaceScriptSettingEditResponseBindingsWorkersR2BindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseBindingsWorkersR2Binding) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersR2BindingType

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersR2BindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditResponseBindingsWorkersR2BindingTypeR2Bucket DispatchNamespaceScriptSettingEditResponseBindingsWorkersR2BindingType = "r2_bucket"
)

func (DispatchNamespaceScriptSettingEditResponseBindingsWorkersR2BindingType) IsKnown

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersServiceBinding

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersServiceBinding struct {
	// Optional environment if the Worker utilizes one.
	Environment string `json:"environment,required"`
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Name of Worker to bind to
	Service string `json:"service,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingEditResponseBindingsWorkersServiceBindingType `json:"type,required"`
	JSON dispatchNamespaceScriptSettingEditResponseBindingsWorkersServiceBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseBindingsWorkersServiceBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersServiceBindingType

type DispatchNamespaceScriptSettingEditResponseBindingsWorkersServiceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingEditResponseBindingsWorkersServiceBindingTypeService DispatchNamespaceScriptSettingEditResponseBindingsWorkersServiceBindingType = "service"
)

func (DispatchNamespaceScriptSettingEditResponseBindingsWorkersServiceBindingType) IsKnown

type DispatchNamespaceScriptSettingEditResponseEnvelope

type DispatchNamespaceScriptSettingEditResponseEnvelope struct {
	Errors   []DispatchNamespaceScriptSettingEditResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DispatchNamespaceScriptSettingEditResponseEnvelopeMessages `json:"messages,required"`
	Result   DispatchNamespaceScriptSettingEditResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success DispatchNamespaceScriptSettingEditResponseEnvelopeSuccess `json:"success,required"`
	JSON    dispatchNamespaceScriptSettingEditResponseEnvelopeJSON    `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseEnvelope) UnmarshalJSON

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

type DispatchNamespaceScriptSettingEditResponseEnvelopeErrors

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

func (*DispatchNamespaceScriptSettingEditResponseEnvelopeErrors) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseEnvelopeMessages

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

func (*DispatchNamespaceScriptSettingEditResponseEnvelopeMessages) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseEnvelopeSuccess

type DispatchNamespaceScriptSettingEditResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	DispatchNamespaceScriptSettingEditResponseEnvelopeSuccessTrue DispatchNamespaceScriptSettingEditResponseEnvelopeSuccess = true
)

func (DispatchNamespaceScriptSettingEditResponseEnvelopeSuccess) IsKnown

type DispatchNamespaceScriptSettingEditResponseMigrations

type DispatchNamespaceScriptSettingEditResponseMigrations interface {
	// contains filtered or unexported methods
}

Migrations to apply for Durable Objects associated with this Worker.

Union satisfied by workers_for_platforms.DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrations or workers_for_platforms.DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrations.

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrations

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrations struct {
	// A list of classes to delete Durable Object namespaces from.
	DeletedClasses []string `json:"deleted_classes"`
	// A list of classes to create Durable Object namespaces from.
	NewClasses []string `json:"new_classes"`
	// Tag to set as the latest migration tag.
	NewTag string `json:"new_tag"`
	// Tag used to verify against the latest migration tag for this Worker. If they
	// don't match, the upload is rejected.
	OldTag string `json:"old_tag"`
	// A list of classes with Durable Object namespaces that were renamed.
	RenamedClasses []DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsRenamedClass `json:"renamed_classes"`
	// A list of transfers for Durable Object namespaces from a different Worker and
	// class to a class defined in this Worker.
	TransferredClasses []DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsTransferredClass `json:"transferred_classes"`
	JSON               dispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsJSON               `json:"-"`
}

A single set of migrations to apply.

func (*DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrations) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsRenamedClass

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsRenamedClass struct {
	From string                                                                                          `json:"from"`
	To   string                                                                                          `json:"to"`
	JSON dispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsRenamedClassJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsRenamedClass) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsTransferredClass

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsTransferredClass struct {
	From       string                                                                                              `json:"from"`
	FromScript string                                                                                              `json:"from_script"`
	To         string                                                                                              `json:"to"`
	JSON       dispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsTransferredClassJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSingleStepMigrationsTransferredClass) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrations

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrations struct {
	// Tag to set as the latest migration tag.
	NewTag string `json:"new_tag"`
	// Tag used to verify against the latest migration tag for this Worker. If they
	// don't match, the upload is rejected.
	OldTag string `json:"old_tag"`
	// Migrations to apply in order.
	Steps []DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStep `json:"steps"`
	JSON  dispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsJSON   `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrations) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStep

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStep struct {
	// A list of classes to delete Durable Object namespaces from.
	DeletedClasses []string `json:"deleted_classes"`
	// A list of classes to create Durable Object namespaces from.
	NewClasses []string `json:"new_classes"`
	// A list of classes with Durable Object namespaces that were renamed.
	RenamedClasses []DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepsRenamedClass `json:"renamed_classes"`
	// A list of transfers for Durable Object namespaces from a different Worker and
	// class to a class defined in this Worker.
	TransferredClasses []DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepsTransferredClass `json:"transferred_classes"`
	JSON               dispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepJSON                `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStep) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepsRenamedClass

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepsRenamedClass struct {
	From string                                                                                            `json:"from"`
	To   string                                                                                            `json:"to"`
	JSON dispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepsRenamedClassJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepsRenamedClass) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepsTransferredClass

type DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepsTransferredClass struct {
	From       string                                                                                                `json:"from"`
	FromScript string                                                                                                `json:"from_script"`
	To         string                                                                                                `json:"to"`
	JSON       dispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepsTransferredClassJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponseMigrationsWorkersSteppedMigrationsStepsTransferredClass) UnmarshalJSON

type DispatchNamespaceScriptSettingEditResponsePlacement

type DispatchNamespaceScriptSettingEditResponsePlacement struct {
	// Enables
	// [Smart Placement](https://developers.cloudflare.com/workers/configuration/smart-placement).
	// Only `"smart"` is currently supported
	Mode DispatchNamespaceScriptSettingEditResponsePlacementMode `json:"mode"`
	JSON dispatchNamespaceScriptSettingEditResponsePlacementJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingEditResponsePlacement) UnmarshalJSON

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

type DispatchNamespaceScriptSettingEditResponsePlacementMode

type DispatchNamespaceScriptSettingEditResponsePlacementMode string

Enables [Smart Placement](https://developers.cloudflare.com/workers/configuration/smart-placement). Only `"smart"` is currently supported

const (
	DispatchNamespaceScriptSettingEditResponsePlacementModeSmart DispatchNamespaceScriptSettingEditResponsePlacementMode = "smart"
)

func (DispatchNamespaceScriptSettingEditResponsePlacementMode) IsKnown

type DispatchNamespaceScriptSettingEditResponseTailConsumer

type DispatchNamespaceScriptSettingEditResponseTailConsumer struct {
	// Name of Worker that is to be the consumer.
	Service string `json:"service,required"`
	// Optional environment if the Worker utilizes one.
	Environment string `json:"environment"`
	// Optional dispatch namespace the script belongs to.
	Namespace string                                                     `json:"namespace"`
	JSON      dispatchNamespaceScriptSettingEditResponseTailConsumerJSON `json:"-"`
}

A reference to a script that will consume logs from the attached Worker.

func (*DispatchNamespaceScriptSettingEditResponseTailConsumer) UnmarshalJSON

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

type DispatchNamespaceScriptSettingGetParams

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

type DispatchNamespaceScriptSettingGetResponse

type DispatchNamespaceScriptSettingGetResponse struct {
	// List of bindings attached to this Worker
	Bindings []DispatchNamespaceScriptSettingGetResponseBinding `json:"bindings"`
	// Opt your Worker into changes after this date
	CompatibilityDate string `json:"compatibility_date"`
	// Opt your Worker into specific changes
	CompatibilityFlags []string `json:"compatibility_flags"`
	// Whether Logpush is turned on for the Worker.
	Logpush bool `json:"logpush"`
	// Migrations to apply for Durable Objects associated with this Worker.
	Migrations DispatchNamespaceScriptSettingGetResponseMigrations `json:"migrations"`
	Placement  DispatchNamespaceScriptSettingGetResponsePlacement  `json:"placement"`
	// Tags to help you manage your Workers
	Tags []string `json:"tags"`
	// List of Workers that will consume logs from the attached Worker.
	TailConsumers []DispatchNamespaceScriptSettingGetResponseTailConsumer `json:"tail_consumers"`
	// Specifies the usage model for the Worker (e.g. 'bundled' or 'unbound').
	UsageModel string                                        `json:"usage_model"`
	JSON       dispatchNamespaceScriptSettingGetResponseJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponse) UnmarshalJSON

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

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersD1Binding

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersD1Binding struct {
	// ID of the D1 database to bind to
	ID string `json:"id,required"`
	// A JavaScript variable name for the binding.
	Binding string `json:"binding,required"`
	// The name of the D1 database associated with the 'id' provided.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingGetResponseBindingsWorkersD1BindingType `json:"type,required"`
	JSON dispatchNamespaceScriptSettingGetResponseBindingsWorkersD1BindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseBindingsWorkersD1Binding) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersD1BindingType

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersD1BindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingGetResponseBindingsWorkersD1BindingTypeD1 DispatchNamespaceScriptSettingGetResponseBindingsWorkersD1BindingType = "d1"
)

func (DispatchNamespaceScriptSettingGetResponseBindingsWorkersD1BindingType) IsKnown

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBinding

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Namespace to bind to
	Namespace string `json:"namespace,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingType `json:"type,required"`
	// Outbound worker
	Outbound DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingOutbound `json:"outbound"`
	JSON     dispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingJSON     `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingOutbound

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingOutbound struct {
	// Pass information from the Dispatch Worker to the Outbound Worker through the
	// parameters
	Params []string `json:"params"`
	// Outbound worker
	Worker DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingOutboundWorker `json:"worker"`
	JSON   dispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingOutboundJSON   `json:"-"`
}

Outbound worker

func (*DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingOutbound) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingOutboundWorker

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingOutboundWorker struct {
	// Environment of the outbound worker
	Environment string `json:"environment"`
	// Name of the outbound worker
	Service string                                                                                             `json:"service"`
	JSON    dispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingOutboundWorkerJSON `json:"-"`
}

Outbound worker

func (*DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingOutboundWorker) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingType

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingTypeDispatchNamespace DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingType = "dispatch_namespace"
)

func (DispatchNamespaceScriptSettingGetResponseBindingsWorkersDispatchNamespaceBindingType) IsKnown

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDoBinding

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDoBinding struct {
	// The exported class name of the Durable Object
	ClassName string `json:"class_name,required"`
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDoBindingType `json:"type,required"`
	// The environment of the script_name to bind to
	Environment string `json:"environment"`
	// Namespace identifier tag.
	NamespaceID string `json:"namespace_id"`
	// The script where the Durable Object is defined, if it is external to this Worker
	ScriptName string                                                                `json:"script_name"`
	JSON       dispatchNamespaceScriptSettingGetResponseBindingsWorkersDoBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseBindingsWorkersDoBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDoBindingType

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersDoBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingGetResponseBindingsWorkersDoBindingTypeDurableObjectNamespace DispatchNamespaceScriptSettingGetResponseBindingsWorkersDoBindingType = "durable_object_namespace"
)

func (DispatchNamespaceScriptSettingGetResponseBindingsWorkersDoBindingType) IsKnown

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersKVNamespaceBinding

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersKVNamespaceBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Namespace identifier tag.
	NamespaceID string `json:"namespace_id,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingGetResponseBindingsWorkersKVNamespaceBindingType `json:"type,required"`
	JSON dispatchNamespaceScriptSettingGetResponseBindingsWorkersKVNamespaceBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseBindingsWorkersKVNamespaceBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersKVNamespaceBindingType

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersKVNamespaceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingGetResponseBindingsWorkersKVNamespaceBindingTypeKVNamespace DispatchNamespaceScriptSettingGetResponseBindingsWorkersKVNamespaceBindingType = "kv_namespace"
)

func (DispatchNamespaceScriptSettingGetResponseBindingsWorkersKVNamespaceBindingType) IsKnown

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersMTLSCERTBinding

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersMTLSCERTBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingGetResponseBindingsWorkersMTLSCERTBindingType `json:"type,required"`
	// ID of the certificate to bind to
	CertificateID string                                                                      `json:"certificate_id"`
	JSON          dispatchNamespaceScriptSettingGetResponseBindingsWorkersMtlscertBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseBindingsWorkersMTLSCERTBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersMTLSCERTBindingType

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersMTLSCERTBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingGetResponseBindingsWorkersMTLSCERTBindingTypeMTLSCertificate DispatchNamespaceScriptSettingGetResponseBindingsWorkersMTLSCERTBindingType = "mtls_certificate"
)

func (DispatchNamespaceScriptSettingGetResponseBindingsWorkersMTLSCERTBindingType) IsKnown

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersQueueBinding

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersQueueBinding struct {
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Name of the Queue to bind to
	QueueName string `json:"queue_name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingGetResponseBindingsWorkersQueueBindingType `json:"type,required"`
	JSON dispatchNamespaceScriptSettingGetResponseBindingsWorkersQueueBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseBindingsWorkersQueueBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersQueueBindingType

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersQueueBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingGetResponseBindingsWorkersQueueBindingTypeQueue DispatchNamespaceScriptSettingGetResponseBindingsWorkersQueueBindingType = "queue"
)

func (DispatchNamespaceScriptSettingGetResponseBindingsWorkersQueueBindingType) IsKnown

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersR2Binding

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersR2Binding struct {
	// R2 bucket to bind to
	BucketName string `json:"bucket_name,required"`
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingGetResponseBindingsWorkersR2BindingType `json:"type,required"`
	JSON dispatchNamespaceScriptSettingGetResponseBindingsWorkersR2BindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseBindingsWorkersR2Binding) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersR2BindingType

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersR2BindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingGetResponseBindingsWorkersR2BindingTypeR2Bucket DispatchNamespaceScriptSettingGetResponseBindingsWorkersR2BindingType = "r2_bucket"
)

func (DispatchNamespaceScriptSettingGetResponseBindingsWorkersR2BindingType) IsKnown

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersServiceBinding

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersServiceBinding struct {
	// Optional environment if the Worker utilizes one.
	Environment string `json:"environment,required"`
	// A JavaScript variable name for the binding.
	Name string `json:"name,required"`
	// Name of Worker to bind to
	Service string `json:"service,required"`
	// The class of resource that the binding provides.
	Type DispatchNamespaceScriptSettingGetResponseBindingsWorkersServiceBindingType `json:"type,required"`
	JSON dispatchNamespaceScriptSettingGetResponseBindingsWorkersServiceBindingJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseBindingsWorkersServiceBinding) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersServiceBindingType

type DispatchNamespaceScriptSettingGetResponseBindingsWorkersServiceBindingType string

The class of resource that the binding provides.

const (
	DispatchNamespaceScriptSettingGetResponseBindingsWorkersServiceBindingTypeService DispatchNamespaceScriptSettingGetResponseBindingsWorkersServiceBindingType = "service"
)

func (DispatchNamespaceScriptSettingGetResponseBindingsWorkersServiceBindingType) IsKnown

type DispatchNamespaceScriptSettingGetResponseEnvelope

type DispatchNamespaceScriptSettingGetResponseEnvelope struct {
	Errors   []DispatchNamespaceScriptSettingGetResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DispatchNamespaceScriptSettingGetResponseEnvelopeMessages `json:"messages,required"`
	Result   DispatchNamespaceScriptSettingGetResponse                   `json:"result,required"`
	// Whether the API call was successful
	Success DispatchNamespaceScriptSettingGetResponseEnvelopeSuccess `json:"success,required"`
	JSON    dispatchNamespaceScriptSettingGetResponseEnvelopeJSON    `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseEnvelope) UnmarshalJSON

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

type DispatchNamespaceScriptSettingGetResponseEnvelopeErrors

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

func (*DispatchNamespaceScriptSettingGetResponseEnvelopeErrors) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseEnvelopeMessages

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

func (*DispatchNamespaceScriptSettingGetResponseEnvelopeMessages) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseEnvelopeSuccess

type DispatchNamespaceScriptSettingGetResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	DispatchNamespaceScriptSettingGetResponseEnvelopeSuccessTrue DispatchNamespaceScriptSettingGetResponseEnvelopeSuccess = true
)

func (DispatchNamespaceScriptSettingGetResponseEnvelopeSuccess) IsKnown

type DispatchNamespaceScriptSettingGetResponseMigrations

type DispatchNamespaceScriptSettingGetResponseMigrations interface {
	// contains filtered or unexported methods
}

Migrations to apply for Durable Objects associated with this Worker.

Union satisfied by workers_for_platforms.DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrations or workers_for_platforms.DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrations.

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrations

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrations struct {
	// A list of classes to delete Durable Object namespaces from.
	DeletedClasses []string `json:"deleted_classes"`
	// A list of classes to create Durable Object namespaces from.
	NewClasses []string `json:"new_classes"`
	// Tag to set as the latest migration tag.
	NewTag string `json:"new_tag"`
	// Tag used to verify against the latest migration tag for this Worker. If they
	// don't match, the upload is rejected.
	OldTag string `json:"old_tag"`
	// A list of classes with Durable Object namespaces that were renamed.
	RenamedClasses []DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsRenamedClass `json:"renamed_classes"`
	// A list of transfers for Durable Object namespaces from a different Worker and
	// class to a class defined in this Worker.
	TransferredClasses []DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsTransferredClass `json:"transferred_classes"`
	JSON               dispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsJSON               `json:"-"`
}

A single set of migrations to apply.

func (*DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrations) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsRenamedClass

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsRenamedClass struct {
	From string                                                                                         `json:"from"`
	To   string                                                                                         `json:"to"`
	JSON dispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsRenamedClassJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsRenamedClass) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsTransferredClass

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsTransferredClass struct {
	From       string                                                                                             `json:"from"`
	FromScript string                                                                                             `json:"from_script"`
	To         string                                                                                             `json:"to"`
	JSON       dispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsTransferredClassJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSingleStepMigrationsTransferredClass) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrations

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrations struct {
	// Tag to set as the latest migration tag.
	NewTag string `json:"new_tag"`
	// Tag used to verify against the latest migration tag for this Worker. If they
	// don't match, the upload is rejected.
	OldTag string `json:"old_tag"`
	// Migrations to apply in order.
	Steps []DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStep `json:"steps"`
	JSON  dispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsJSON   `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrations) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStep

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStep struct {
	// A list of classes to delete Durable Object namespaces from.
	DeletedClasses []string `json:"deleted_classes"`
	// A list of classes to create Durable Object namespaces from.
	NewClasses []string `json:"new_classes"`
	// A list of classes with Durable Object namespaces that were renamed.
	RenamedClasses []DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepsRenamedClass `json:"renamed_classes"`
	// A list of transfers for Durable Object namespaces from a different Worker and
	// class to a class defined in this Worker.
	TransferredClasses []DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepsTransferredClass `json:"transferred_classes"`
	JSON               dispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepJSON                `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStep) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepsRenamedClass

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepsRenamedClass struct {
	From string                                                                                           `json:"from"`
	To   string                                                                                           `json:"to"`
	JSON dispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepsRenamedClassJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepsRenamedClass) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepsTransferredClass

type DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepsTransferredClass struct {
	From       string                                                                                               `json:"from"`
	FromScript string                                                                                               `json:"from_script"`
	To         string                                                                                               `json:"to"`
	JSON       dispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepsTransferredClassJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponseMigrationsWorkersSteppedMigrationsStepsTransferredClass) UnmarshalJSON

type DispatchNamespaceScriptSettingGetResponsePlacement

type DispatchNamespaceScriptSettingGetResponsePlacement struct {
	// Enables
	// [Smart Placement](https://developers.cloudflare.com/workers/configuration/smart-placement).
	// Only `"smart"` is currently supported
	Mode DispatchNamespaceScriptSettingGetResponsePlacementMode `json:"mode"`
	JSON dispatchNamespaceScriptSettingGetResponsePlacementJSON `json:"-"`
}

func (*DispatchNamespaceScriptSettingGetResponsePlacement) UnmarshalJSON

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

type DispatchNamespaceScriptSettingGetResponsePlacementMode

type DispatchNamespaceScriptSettingGetResponsePlacementMode string

Enables [Smart Placement](https://developers.cloudflare.com/workers/configuration/smart-placement). Only `"smart"` is currently supported

const (
	DispatchNamespaceScriptSettingGetResponsePlacementModeSmart DispatchNamespaceScriptSettingGetResponsePlacementMode = "smart"
)

func (DispatchNamespaceScriptSettingGetResponsePlacementMode) IsKnown

type DispatchNamespaceScriptSettingGetResponseTailConsumer

type DispatchNamespaceScriptSettingGetResponseTailConsumer struct {
	// Name of Worker that is to be the consumer.
	Service string `json:"service,required"`
	// Optional environment if the Worker utilizes one.
	Environment string `json:"environment"`
	// Optional dispatch namespace the script belongs to.
	Namespace string                                                    `json:"namespace"`
	JSON      dispatchNamespaceScriptSettingGetResponseTailConsumerJSON `json:"-"`
}

A reference to a script that will consume logs from the attached Worker.

func (*DispatchNamespaceScriptSettingGetResponseTailConsumer) UnmarshalJSON

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

type DispatchNamespaceScriptSettingService

type DispatchNamespaceScriptSettingService struct {
	Options []option.RequestOption
}

DispatchNamespaceScriptSettingService 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 NewDispatchNamespaceScriptSettingService method instead.

func NewDispatchNamespaceScriptSettingService

func NewDispatchNamespaceScriptSettingService(opts ...option.RequestOption) (r *DispatchNamespaceScriptSettingService)

NewDispatchNamespaceScriptSettingService 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 (*DispatchNamespaceScriptSettingService) Edit

Patch script metadata, such as bindings

func (*DispatchNamespaceScriptSettingService) Get

Get script settings from a script uploaded to a Workers for Platforms namespace.

type DispatchNamespaceScriptUpdateParams

type DispatchNamespaceScriptUpdateParams interface {
	ImplementsDispatchNamespaceScriptUpdateParams()
	// contains filtered or unexported methods
}

This interface is a union satisfied by one of the following: DispatchNamespaceScriptUpdateParamsVariant0, DispatchNamespaceScriptUpdateParamsVariant1.

type DispatchNamespaceScriptUpdateParamsVariant0

type DispatchNamespaceScriptUpdateParamsVariant0 struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// A module comprising a Worker script, often a javascript file. Multiple modules
	// may be provided as separate named parts, but at least one module must be present
	// and referenced in the metadata as `main_module` or `body_part` by part name.
	AnyPartName param.Field[[]io.Reader] `json:"<any part name>" format:"binary"`
	// JSON encoded metadata about the uploaded parts and Worker configuration.
	Metadata param.Field[DispatchNamespaceScriptUpdateParamsVariant0Metadata] `json:"metadata"`
}

func (DispatchNamespaceScriptUpdateParamsVariant0) ImplementsDispatchNamespaceScriptUpdateParams

func (DispatchNamespaceScriptUpdateParamsVariant0) ImplementsDispatchNamespaceScriptUpdateParams()

func (DispatchNamespaceScriptUpdateParamsVariant0) MarshalMultipart

func (r DispatchNamespaceScriptUpdateParamsVariant0) MarshalMultipart() (data []byte, contentType string, err error)

type DispatchNamespaceScriptUpdateParamsVariant0Metadata

type DispatchNamespaceScriptUpdateParamsVariant0Metadata struct {
	// List of bindings available to the worker.
	Bindings param.Field[[]interface{}] `json:"bindings"`
	// Name of the part in the multipart request that contains the script (e.g. the
	// file adding a listener to the `fetch` event). Indicates a
	// `service worker syntax` Worker.
	BodyPart param.Field[string] `json:"body_part"`
	// Date indicating targeted support in the Workers runtime. Backwards incompatible
	// fixes to the runtime following this date will not affect this Worker.
	CompatibilityDate param.Field[string] `json:"compatibility_date"`
	// Flags that enable or disable certain features in the Workers runtime. Used to
	// enable upcoming features or opt in or out of specific changes not included in a
	// `compatibility_date`.
	CompatibilityFlags param.Field[[]string] `json:"compatibility_flags"`
	// List of binding types to keep from previous_upload.
	KeepBindings param.Field[[]string] `json:"keep_bindings"`
	// Whether Logpush is turned on for the Worker.
	Logpush param.Field[bool] `json:"logpush"`
	// Name of the part in the multipart request that contains the main module (e.g.
	// the file exporting a `fetch` handler). Indicates a `module syntax` Worker.
	MainModule param.Field[string] `json:"main_module"`
	// Migrations to apply for Durable Objects associated with this Worker.
	Migrations param.Field[DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrations] `json:"migrations"`
	Placement  param.Field[DispatchNamespaceScriptUpdateParamsVariant0MetadataPlacement]  `json:"placement"`
	// List of strings to use as tags for this Worker
	Tags param.Field[[]string] `json:"tags"`
	// List of Workers that will consume logs from the attached Worker.
	TailConsumers param.Field[[]DispatchNamespaceScriptUpdateParamsVariant0MetadataTailConsumer] `json:"tail_consumers"`
	// Usage model to apply to invocations.
	UsageModel param.Field[DispatchNamespaceScriptUpdateParamsVariant0MetadataUsageModel] `json:"usage_model"`
	// Key-value pairs to use as tags for this version of this Worker
	VersionTags param.Field[interface{}] `json:"version_tags"`
}

JSON encoded metadata about the uploaded parts and Worker configuration.

func (DispatchNamespaceScriptUpdateParamsVariant0Metadata) MarshalJSON

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

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrations

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrations interface {
	// contains filtered or unexported methods
}

Migrations to apply for Durable Objects associated with this Worker.

Satisfied by workers_for_platforms.DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrations, workers_for_platforms.DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrations.

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrations

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrations struct {
	// A list of classes to delete Durable Object namespaces from.
	DeletedClasses param.Field[[]string] `json:"deleted_classes"`
	// A list of classes to create Durable Object namespaces from.
	NewClasses param.Field[[]string] `json:"new_classes"`
	// Tag to set as the latest migration tag.
	NewTag param.Field[string] `json:"new_tag"`
	// Tag used to verify against the latest migration tag for this Worker. If they
	// don't match, the upload is rejected.
	OldTag param.Field[string] `json:"old_tag"`
	// A list of classes with Durable Object namespaces that were renamed.
	RenamedClasses param.Field[[]DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrationsRenamedClass] `json:"renamed_classes"`
	// A list of transfers for Durable Object namespaces from a different Worker and
	// class to a class defined in this Worker.
	TransferredClasses param.Field[[]DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrationsTransferredClass] `json:"transferred_classes"`
}

A single set of migrations to apply.

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrations) MarshalJSON

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrationsRenamedClass

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrationsRenamedClass struct {
	From param.Field[string] `json:"from"`
	To   param.Field[string] `json:"to"`
}

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrationsRenamedClass) MarshalJSON

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrationsTransferredClass

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrationsTransferredClass struct {
	From       param.Field[string] `json:"from"`
	FromScript param.Field[string] `json:"from_script"`
	To         param.Field[string] `json:"to"`
}

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSingleStepMigrationsTransferredClass) MarshalJSON

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrations

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrations struct {
	// Tag to set as the latest migration tag.
	NewTag param.Field[string] `json:"new_tag"`
	// Tag used to verify against the latest migration tag for this Worker. If they
	// don't match, the upload is rejected.
	OldTag param.Field[string] `json:"old_tag"`
	// Migrations to apply in order.
	Steps param.Field[[]DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStep] `json:"steps"`
}

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrations) MarshalJSON

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStep

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStep struct {
	// A list of classes to delete Durable Object namespaces from.
	DeletedClasses param.Field[[]string] `json:"deleted_classes"`
	// A list of classes to create Durable Object namespaces from.
	NewClasses param.Field[[]string] `json:"new_classes"`
	// A list of classes with Durable Object namespaces that were renamed.
	RenamedClasses param.Field[[]DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStepsRenamedClass] `json:"renamed_classes"`
	// A list of transfers for Durable Object namespaces from a different Worker and
	// class to a class defined in this Worker.
	TransferredClasses param.Field[[]DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStepsTransferredClass] `json:"transferred_classes"`
}

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStep) MarshalJSON

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStepsRenamedClass

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStepsRenamedClass struct {
	From param.Field[string] `json:"from"`
	To   param.Field[string] `json:"to"`
}

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStepsRenamedClass) MarshalJSON

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStepsTransferredClass

type DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStepsTransferredClass struct {
	From       param.Field[string] `json:"from"`
	FromScript param.Field[string] `json:"from_script"`
	To         param.Field[string] `json:"to"`
}

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataMigrationsWorkersSteppedMigrationsStepsTransferredClass) MarshalJSON

type DispatchNamespaceScriptUpdateParamsVariant0MetadataPlacement

type DispatchNamespaceScriptUpdateParamsVariant0MetadataPlacement struct {
	// Enables
	// [Smart Placement](https://developers.cloudflare.com/workers/configuration/smart-placement).
	// Only `"smart"` is currently supported
	Mode param.Field[DispatchNamespaceScriptUpdateParamsVariant0MetadataPlacementMode] `json:"mode"`
}

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataPlacement) MarshalJSON

type DispatchNamespaceScriptUpdateParamsVariant0MetadataPlacementMode

type DispatchNamespaceScriptUpdateParamsVariant0MetadataPlacementMode string

Enables [Smart Placement](https://developers.cloudflare.com/workers/configuration/smart-placement). Only `"smart"` is currently supported

const (
	DispatchNamespaceScriptUpdateParamsVariant0MetadataPlacementModeSmart DispatchNamespaceScriptUpdateParamsVariant0MetadataPlacementMode = "smart"
)

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataPlacementMode) IsKnown

type DispatchNamespaceScriptUpdateParamsVariant0MetadataTailConsumer

type DispatchNamespaceScriptUpdateParamsVariant0MetadataTailConsumer struct {
	// Name of Worker that is to be the consumer.
	Service param.Field[string] `json:"service,required"`
	// Optional environment if the Worker utilizes one.
	Environment param.Field[string] `json:"environment"`
	// Optional dispatch namespace the script belongs to.
	Namespace param.Field[string] `json:"namespace"`
}

A reference to a script that will consume logs from the attached Worker.

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataTailConsumer) MarshalJSON

type DispatchNamespaceScriptUpdateParamsVariant0MetadataUsageModel

type DispatchNamespaceScriptUpdateParamsVariant0MetadataUsageModel string

Usage model to apply to invocations.

const (
	DispatchNamespaceScriptUpdateParamsVariant0MetadataUsageModelBundled DispatchNamespaceScriptUpdateParamsVariant0MetadataUsageModel = "bundled"
	DispatchNamespaceScriptUpdateParamsVariant0MetadataUsageModelUnbound DispatchNamespaceScriptUpdateParamsVariant0MetadataUsageModel = "unbound"
)

func (DispatchNamespaceScriptUpdateParamsVariant0MetadataUsageModel) IsKnown

type DispatchNamespaceScriptUpdateParamsVariant1

type DispatchNamespaceScriptUpdateParamsVariant1 struct {
	// Identifier
	AccountID param.Field[string] `path:"account_id,required"`
	// Rollback message to be associated with this deployment. Only parsed when query
	// param `"rollback_to"` is present.
	Message param.Field[string] `json:"message"`
}

func (DispatchNamespaceScriptUpdateParamsVariant1) ImplementsDispatchNamespaceScriptUpdateParams

func (DispatchNamespaceScriptUpdateParamsVariant1) ImplementsDispatchNamespaceScriptUpdateParams()

func (DispatchNamespaceScriptUpdateParamsVariant1) MarshalJSON

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

type DispatchNamespaceScriptUpdateResponseEnvelope

type DispatchNamespaceScriptUpdateResponseEnvelope struct {
	Errors   []DispatchNamespaceScriptUpdateResponseEnvelopeErrors   `json:"errors,required"`
	Messages []DispatchNamespaceScriptUpdateResponseEnvelopeMessages `json:"messages,required"`
	Result   workers.WorkersScript                                   `json:"result,required"`
	// Whether the API call was successful
	Success DispatchNamespaceScriptUpdateResponseEnvelopeSuccess `json:"success,required"`
	JSON    dispatchNamespaceScriptUpdateResponseEnvelopeJSON    `json:"-"`
}

func (*DispatchNamespaceScriptUpdateResponseEnvelope) UnmarshalJSON

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

type DispatchNamespaceScriptUpdateResponseEnvelopeErrors

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

func (*DispatchNamespaceScriptUpdateResponseEnvelopeErrors) UnmarshalJSON

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

type DispatchNamespaceScriptUpdateResponseEnvelopeMessages

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

func (*DispatchNamespaceScriptUpdateResponseEnvelopeMessages) UnmarshalJSON

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

type DispatchNamespaceScriptUpdateResponseEnvelopeSuccess

type DispatchNamespaceScriptUpdateResponseEnvelopeSuccess bool

Whether the API call was successful

const (
	DispatchNamespaceScriptUpdateResponseEnvelopeSuccessTrue DispatchNamespaceScriptUpdateResponseEnvelopeSuccess = true
)

func (DispatchNamespaceScriptUpdateResponseEnvelopeSuccess) IsKnown

type DispatchNamespaceService

type DispatchNamespaceService struct {
	Options []option.RequestOption
	Scripts *DispatchNamespaceScriptService
}

DispatchNamespaceService 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 NewDispatchNamespaceService method instead.

func NewDispatchNamespaceService

func NewDispatchNamespaceService(opts ...option.RequestOption) (r *DispatchNamespaceService)

NewDispatchNamespaceService 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 (*DispatchNamespaceService) Delete

Delete a Workers for Platforms namespace.

func (*DispatchNamespaceService) Get

Fetch a Workers for Platforms namespace.

func (*DispatchNamespaceService) List

Fetch a list of Workers for Platforms namespaces.

func (*DispatchNamespaceService) ListAutoPaging

Fetch a list of Workers for Platforms namespaces.

func (*DispatchNamespaceService) New

Create a new Workers for Platforms namespace.

type DispatchService

type DispatchService struct {
	Options    []option.RequestOption
	Namespaces *DispatchNamespaceService
}

DispatchService 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 NewDispatchService method instead.

func NewDispatchService

func NewDispatchService(opts ...option.RequestOption) (r *DispatchService)

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

type Error

type Error = apierror.Error

type ErrorData

type ErrorData = shared.ErrorData

This is an alias to an internal type.

type WorkersForPlatformService

type WorkersForPlatformService struct {
	Options  []option.RequestOption
	Dispatch *DispatchService
}

WorkersForPlatformService 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 NewWorkersForPlatformService method instead.

func NewWorkersForPlatformService

func NewWorkersForPlatformService(opts ...option.RequestOption) (r *WorkersForPlatformService)

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

type WorkersForPlatformsNamespaceScript

type WorkersForPlatformsNamespaceScript struct {
	// When the script was created.
	CreatedOn time.Time `json:"created_on" format:"date-time"`
	// Name of the Workers for Platforms dispatch namespace.
	DispatchNamespace string `json:"dispatch_namespace"`
	// When the script was last modified.
	ModifiedOn time.Time                              `json:"modified_on" format:"date-time"`
	Script     workers.WorkersScript                  `json:"script"`
	JSON       workersForPlatformsNamespaceScriptJSON `json:"-"`
}

Details about a worker uploaded to a Workers for Platforms namespace.

func (*WorkersForPlatformsNamespaceScript) UnmarshalJSON

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

Jump to

Keyboard shortcuts

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