fastly

package
v1.18.0 Latest Latest
Warning

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

Go to latest
Published: Oct 28, 2020 License: Apache-2.0 Imports: 23 Imported by: 11

Documentation

Index

Constants

View Source
const (
	CreateBatchOperation BatchOperation = "create"
	UpdateBatchOperation BatchOperation = "update"
	UpsertBatchOperation BatchOperation = "upsert"
	DeleteBatchOperation BatchOperation = "delete"

	// Represents the maximum number of operations that can be sent within a single batch request.
	// This is currently not documented in the API.
	BatchModifyMaximumOperations = 1000

	// Represents the maximum number of items that can be placed within an Edge Dictionary.
	MaximumDictionarySize = 10000

	// Represents the maximum number of entries that can be placed within an ACL.
	MaximumACLSize = 10000
)
View Source
const (
	S3RedundancyStandard      S3Redundancy           = "standard"
	S3RedundancyReduced       S3Redundancy           = "reduced_redundancy"
	S3ServerSideEncryptionAES S3ServerSideEncryption = "AES256"
	S3ServerSideEncryptionKMS S3ServerSideEncryption = "aws:kms"
)
View Source
const APIKeyEnvVar = "FASTLY_API_KEY"

APIKeyEnvVar is the name of the environment variable where the Fastly API key should be read from.

View Source
const APIKeyHeader = "Fastly-Key"

APIKeyHeader is the name of the header that contains the Fastly API key.

View Source
const DefaultEndpoint = "https://api.fastly.com"

DefaultEndpoint is the default endpoint for Fastly. Since Fastly does not support an on-premise solution, this is likely to always be the default.

View Source
const DefaultRealtimeStatsEndpoint = "https://rt.fastly.com"

DefaultRealtimeStatsEndpoint is the realtime stats endpoint for Fastly.

View Source
const EndpointEnvVar = "FASTLY_API_URL"

EndpointEnvVar is the name of an environment variable that can be used to change the URL of API requests.

View Source
const RealtimeStatsEndpointEnvVar = "FASTLY_RTS_URL"

RealtimeStatsEndpointEnvVar is the name of an environment variable that can be used to change the URL of realtime stats requests.

Variables

View Source
var ErrBatchUpdateMaximumOperationsExceeded = errors.New("batch modify maximum operations exceeded")

ErrBatchUpdateMaximumItemsExceeded is an error that indicates that too many batch operations are being executed. The Fastly API specifies an maximum limit.

View Source
var ErrMissingACL = errors.New("missing required field 'ACL'")

ErrMissingAcl is an error that is returned when an input struct required an "Acl" key, but one is not set

View Source
var ErrMissingAddress = errors.New("missing required field 'Address'")

ErrMissingAddress is an error that is returned when an input struct requires a "Address" key, but one was not set.

View Source
var ErrMissingBackend = errors.New("missing required field 'Backend'")

ErrMissingBackend is an error that is returned when an input struct requires a "Backend" key, but one was not set.

View Source
var ErrMissingCertBlob = errors.New("missing required field 'CertBlob'")

ErrMissingCertBlob is an error that is returned from an input struct that requires a "CertBlob" key, but one was not set.

View Source
var ErrMissingConfigSetID = errors.New("missing required field 'ConfigSetID'")

ErrMissingConfigSetID is an error that is returned was an input struct requires a "ConfigSetID" key, but one was not set

View Source
var ErrMissingContent = errors.New("missing required field 'Content'")

ErrMissingContent is an error that is returned when an input struct requires a "Content" key, but one was not set.

View Source
var ErrMissingCustomerID = errors.New("missing required field 'CustomerID'")

ErrMissingCustomerID is an error that is returned was an input struct requires a "CustomerID" key, but one was not set

View Source
var ErrMissingDictionary = errors.New("missing required field 'Dictionary'")

ErrMissingDictionary is an error that is returned when an input struct requires a "Dictionary" key, but one was not set.

View Source
var ErrMissingDirector = errors.New("missing required field 'Director'")

ErrMissingDirector is an error that is returned when an input struct requires a "From" key, but one was not set.

View Source
var ErrMissingEventID = errors.New("missing required field 'EventID'")

ErrMissingEventID is an error that is returned was an input struct requires a "EventID" key, but one was not set

View Source
var ErrMissingFrom = errors.New("missing required field 'From'")

ErrMissingFrom is an error that is returned when an input struct requires a "From" key, but one was not set.

View Source
var ErrMissingID = errors.New("missing required field 'ID'")

ErrMissingID is an error that is returned when an input struct requires an "ID" key, but one was not set.

View Source
var ErrMissingIP = errors.New("missing required field 'IP'")

ErrMissingIP is an error that is returned when an input struct required an "IP" key, but one is not set

View Source
var ErrMissingIntermediatesBlob = errors.New("missing required field 'IntermediatesBlob'")

ErrMissingIntermediatesBlob is an error that is returned from an input struct that requires a "IntermediatesBlob" key, but one was not set.

View Source
var ErrMissingItemKey = errors.New("missing required field 'ItemKey'")

ErrMissingItemKey is an error that is returned when an input struct requires a "ItemKey" key, but one was not set.

View Source
var ErrMissingKMSKeyID = errors.New("missing required field 'ServerSideEncryptionKMSKeyID'")

ErrMissingKMSKeyID is an error that is returned from an input struct that requires a "ServerSideEncryptionKMSKeyID" key, but one was not set.

View Source
var ErrMissingKey = errors.New("missing required field 'Key'")

ErrMissingKey is an error that is returned when an input struct requires a "Key" key, but one was not set.

View Source
var ErrMissingLogin = errors.New("missing required field 'Login'")

ErrMissingLogin is an error that is returned when an input struct requires a "Login" key, but one was not set.

View Source
var ErrMissingMonth = errors.New("missing required field 'Month'")

ErrMissingMonth is an error that is returned when an input struct requires a "Month" key, but one was not set.

View Source
var ErrMissingName = errors.New("missing required field 'Name'")

ErrMissingName is an error that is returned when an input struct requires a "Name" key, but one was not set.

View Source
var ErrMissingNewName = errors.New("missing required field 'NewName'")

ErrMissingNewName is an erorr that is returned when an input struct requires a "NewName" key, but one was not set

View Source
var ErrMissingOWASPID = errors.New("missing required field 'OWASPID'")

ErrMissingOWASPID is an error that is returned was an input struct requires a "OWASPID" key, but one was not set

View Source
var ErrMissingPool = errors.New("missing required field 'Pool'")

ErrMissingPool is an error that is returned when an input struct requires a "Pool" key, but one was not set.

View Source
var ErrMissingRuleID = errors.New("missing required field 'RuleID'")

ErrMissingRuleID is an error that is returned was an input struct requires a "RuleID" key, but one was not set

View Source
var ErrMissingServer = errors.New("missing required field 'Server'")

ErrMissingServer is an error that is returned when an input struct requires a "Server" key, but one was not set.

View Source
var ErrMissingService = errors.New("missing required field 'Service'")

ErrMissingService is an error that is returned when an input struct requires a "Service" key, but one was not set.

View Source
var ErrMissingStatus = errors.New("missing required field 'Status'")

ErrMissingStatus is an error that is returned when an input struct requires a "Status" key, but one was not set.

View Source
var ErrMissingTag = errors.New("missing required field 'Tag'")

ErrMissingTag is an error that is returned when an input struct requires a "Tag" key, but one was not set.

View Source
var ErrMissingTo = errors.New("missing required field 'To'")

ErrMissingTo is an error that is returned when an input struct requires a "To" key, but one was not set.

View Source
var ErrMissingURL = errors.New("missing required field 'URL'")

ErrMissingURL is an error that is returned when an input struct requires a "URL" key, but one was not set.

View Source
var ErrMissingVersion = errors.New("missing required field 'Version'")

ErrMissingVersion is an error that is returned when an input struct requires a "Version" key, but one was not set.

View Source
var ErrMissingWAFID = errors.New("missing required field 'WAFID'")

ErrMissingWafID is an error that is returned was an input struct requires a "WafID" key, but one was not set

View Source
var ErrMissingWAFList = errors.New("WAF slice is empty")

ErrMissingWAFList is an error that is returned was an input struct requires a list of WAF id's, but it is empty

View Source
var ErrMissingYear = errors.New("missing required field 'Year'")

ErrMissingYear is an error that is returned when an input struct requires a "Year" key, but one was not set.

View Source
var ErrNotOK = errors.New("not ok")

ErrNotOK is a generic error indicating that something is not okay.

View Source
var ErrStatusNotOk = errors.New("unexpected 'status' field in API response body")

ErrStatusNotOk is an error that indicates that indicates that the response body returned by the Fastly API was not `{"status": "ok"}`

View Source
var ProjectURL = "github.com/fastly/go-fastly"

ProjectURL is the url for this library.

View Source
var ProjectVersion = "1.18.0"

ProjectVersion is the version of this library.

View Source
var UserAgent = fmt.Sprintf("FastlyGo/%s (+%s; %s)",
	ProjectVersion, ProjectURL, runtime.Version())

UserAgent is the user agent for this particular client.

Functions

func Bool added in v0.16.0

func Bool(v bool) *bool

Bool is a helper that returns a pointer to the bool value passed in.

func MakePackagePath added in v0.16.0

func MakePackagePath(Service string, Version int) (string, error)

MakePackagePath ensures we create the correct REST path for referencing packages in the API.

func NullString added in v0.16.0

func NullString(v string) *string

NullString is a helper that returns a pointer to the string value passed in or nil if the string is empty.

func String added in v0.16.0

func String(v string) *string

String is a helper that returns a pointer to the string value passed in.

func Uint added in v0.16.0

func Uint(v uint) *uint

Uint is a helper that returns a pointer to the uint value passed in.

Types

type ACL added in v0.4.0

type ACL struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name      string     `mapstructure:"name"`
	ID        string     `mapstructure:"id"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
}

type ACLEntry added in v0.4.0

type ACLEntry struct {
	ServiceID string `mapstructure:"service_id"`
	ACLID     string `mapstructure:"acl_id"`

	ID        string     `mapstructure:"id"`
	IP        string     `mapstructure:"ip"`
	Subnet    string     `mapstructure:"subnet"`
	Negated   bool       `mapstructure:"negated"`
	Comment   string     `mapstructure:"comment"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
}

type ACLsByName added in v0.4.0

type ACLsByName []*ACL

ACLsByName is a sortable list of ACLs.

func (ACLsByName) Len added in v0.4.0

func (s ACLsByName) Len() int

Len, Swap, and Less implement the sortable interface.

func (ACLsByName) Less added in v0.4.0

func (s ACLsByName) Less(i, j int) bool

func (ACLsByName) Swap added in v0.4.0

func (s ACLsByName) Swap(i, j int)

type ActivateVCLInput

type ActivateVCLInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the VCL to mark as main (required).
	Name string
}

ActivateVCLInput is used as input to the ActivateVCL function.

type ActivateVersionInput

type ActivateVersionInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int
}

ActivateVersionInput is the input to the ActivateVersion function.

type Backend

type Backend struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name                string     `mapstructure:"name"`
	Comment             string     `mapstructure:"comment"`
	Address             string     `mapstructure:"address"`
	Port                uint       `mapstructure:"port"`
	OverrideHost        string     `mapstructure:"override_host"`
	ConnectTimeout      uint       `mapstructure:"connect_timeout"`
	MaxConn             uint       `mapstructure:"max_conn"`
	ErrorThreshold      uint       `mapstructure:"error_threshold"`
	FirstByteTimeout    uint       `mapstructure:"first_byte_timeout"`
	BetweenBytesTimeout uint       `mapstructure:"between_bytes_timeout"`
	AutoLoadbalance     bool       `mapstructure:"auto_loadbalance"`
	Weight              uint       `mapstructure:"weight"`
	RequestCondition    string     `mapstructure:"request_condition"`
	HealthCheck         string     `mapstructure:"healthcheck"`
	Hostname            string     `mapstructure:"hostname"`
	Shield              string     `mapstructure:"shield"`
	UseSSL              bool       `mapstructure:"use_ssl"`
	SSLCheckCert        bool       `mapstructure:"ssl_check_cert"`
	SSLCACert           string     `mapstructure:"ssl_ca_cert"`
	SSLClientCert       string     `mapstructure:"ssl_client_cert"`
	SSLClientKey        string     `mapstructure:"ssl_client_key"`
	SSLHostname         string     `mapstructure:"ssl_hostname"`
	SSLCertHostname     string     `mapstructure:"ssl_cert_hostname"`
	SSLSNIHostname      string     `mapstructure:"ssl_sni_hostname"`
	MinTLSVersion       string     `mapstructure:"min_tls_version"`
	MaxTLSVersion       string     `mapstructure:"max_tls_version"`
	SSLCiphers          []string   `mapstructure:"ssl_ciphers"`
	CreatedAt           *time.Time `mapstructure:"created_at"`
	UpdatedAt           *time.Time `mapstructure:"updated_at"`
	DeletedAt           *time.Time `mapstructure:"deleted_at"`
}

Backend represents a backend response from the Fastly API.

type BatchACLEntry added in v0.16.0

type BatchACLEntry struct {
	Operation BatchOperation `json:"op"`
	ID        string         `json:"id,omitempty"`
	IP        string         `json:"ip,omitempty"`
	Subnet    string         `json:"subnet,omitempty"`
	Negated   bool           `json:"negated,omitempty"`
	Comment   string         `json:"comment,omitempty"`
}

type BatchDictionaryItem added in v0.16.0

type BatchDictionaryItem struct {
	Operation BatchOperation `json:"op"`
	ItemKey   string         `json:"item_key"`
	ItemValue string         `json:"item_value"`
}

type BatchModifyACLEntriesInput added in v0.16.0

type BatchModifyACLEntriesInput struct {
	Service string `json:"-"`
	ACL     string `json:"-"`

	Entries []*BatchACLEntry `json:"entries"`
}

type BatchModifyDictionaryItemsInput added in v0.16.0

type BatchModifyDictionaryItemsInput struct {
	Service    string `json:"-"`
	Dictionary string `json:"-"`

	Items []*BatchDictionaryItem `json:"items"`
}

type BatchOperation added in v0.16.0

type BatchOperation string

type BigQuery added in v0.4.3

type BigQuery struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Format            string     `mapstructure:"format"`
	User              string     `mapstructure:"user"`
	ProjectID         string     `mapstructure:"project_id"`
	Dataset           string     `mapstructure:"dataset"`
	Table             string     `mapstructure:"table"`
	Template          string     `mapstructure:"template_suffix"`
	SecretKey         string     `mapstructure:"secret_key"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	FormatVersion     uint       `mapstructure:"format_version"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

BigQuery represents a BigQuery response from the Fastly API.

type Billing

type Billing struct {
	InvoiceID string         `mapstructure:"invoice_id"`
	StartTime *time.Time     `mapstructure:"start_time"`
	EndTime   *time.Time     `mapstructure:"end_time"`
	Status    *BillingStatus `mapstructure:"status"`
	Total     *BillingTotal  `mapstructure:"total"`
}

Billing is the top-level representation of a billing response from the Fastly API.

type BillingExtra

type BillingExtra struct {
	Name      string  `mapstructure:"name"`
	Setup     float64 `mapstructure:"setup"`
	Recurring float64 `mapstructure:"recurring"`
}

BillingExtra is a representation of extras (such as SSL addons) from the Fastly API.

type BillingStatus

type BillingStatus struct {
	InvoiceID string     `mapstructure:"invoice_id"`
	Status    string     `mapstructure:"status"`
	SentAt    *time.Time `mapstructure:"sent_at"`
}

BillingStatus is a representation of the status of the bill from the Fastly API.

type BillingTotal

type BillingTotal struct {
	PlanName           string          `mapstructure:"plan_name"`
	PlanCode           string          `mapstructure:"plan_code"`
	PlanMinimum        string          `mapstructure:"plan_minimum"`
	Bandwidth          float64         `mapstructure:"bandwidth"`
	BandwidthCost      float64         `mapstructure:"bandwidth_cost"`
	Requests           uint64          `mapstructure:"requests"`
	RequestsCost       float64         `mapstructure:"requests_cost"`
	IncurredCost       float64         `mapstructure:"incurred_cost"`
	Overage            float64         `mapstructure:"overage"`
	Extras             []*BillingExtra `mapstructure:"extras"`
	ExtrasCost         float64         `mapstructure:"extras_cost"`
	CostBeforeDiscount float64         `mapstructure:"cost_before_discount"`
	Discount           float64         `mapstructure:"discount"`
	Cost               float64         `mapstructure:"cost"`
	Terms              string          `mapstructure:"terms"`
}

BillingTotal is a repsentation of the status of the usage for this bill from the Fastly API.

type BlobStorage added in v0.4.3

type BlobStorage struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Path              string     `mapstructure:"path"`
	AccountName       string     `mapstructure:"account_name"`
	Container         string     `mapstructure:"container"`
	SASToken          string     `mapstructure:"sas_token"`
	Period            uint       `mapstructure:"period"`
	TimestampFormat   string     `mapstructure:"timestamp_format"`
	GzipLevel         uint       `mapstructure:"gzip_level"`
	PublicKey         string     `mapstructure:"public_key"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	MessageType       string     `mapstructure:"message_type"`
	Placement         string     `mapstructure:"placement"`
	ResponseCondition string     `mapstructure:"response_condition"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

BlobStorage represents a blob storage response from the Fastly API.

type BulkCertificate added in v0.16.0

type BulkCertificate struct {
	ID                string              `jsonapi:"primary,tls_bulk_certificate"`
	TLSConfigurations []*TLSConfiguration `jsonapi:"relation,tls_configurations,tls_configuration"`
	TLSDomains        []*TLSDomain        `jsonapi:"relation,tls_domains,tls_domain"`
	NotAfter          *time.Time          `jsonapi:"attr,not_after,iso8601"`
	NotBefore         *time.Time          `jsonapi:"attr,not_before,iso8601"`
	CreatedAt         *time.Time          `jsonapi:"attr,created_at,iso8601"`
	UpdatedAt         *time.Time          `jsonapi:"attr,updated_at,iso8601"`
	Replace           bool                `jsonapi:"attr,replace"`
}

BulkCertificate represents a bulk certificate.

type CacheSetting

type CacheSetting struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name           string             `mapstructure:"name"`
	Action         CacheSettingAction `mapstructure:"action"`
	TTL            uint               `mapstructure:"ttl"`
	StaleTTL       uint               `mapstructure:"stale_ttl"`
	CacheCondition string             `mapstructure:"cache_condition"`
	CreatedAt      *time.Time         `mapstructure:"created_at"`
	UpdatedAt      *time.Time         `mapstructure:"updated_at"`
	DeletedAt      *time.Time         `mapstructure:"deleted_at"`
}

CacheSetting represents a response from Fastly's API for cache settings.

type CacheSettingAction

type CacheSettingAction string

CacheSettingAction is the type of cache action.

const (
	// CacheSettingActionCache sets the cache to cache.
	CacheSettingActionCache CacheSettingAction = "cache"

	// CacheSettingActionPass sets the cache to pass through.
	CacheSettingActionPass CacheSettingAction = "pass"

	// CacheSettingActionRestart sets the cache to restart the request.
	CacheSettingActionRestart CacheSettingAction = "restart"
)

type Client

type Client struct {
	// Address is the address of Fastly's API endpoint.
	Address string

	// HTTPClient is the HTTP client to use. If one is not provided, a default
	// client will be used.
	HTTPClient *http.Client
	// contains filtered or unexported fields
}

Client is the main entrypoint to the Fastly golang API library.

func DefaultClient

func DefaultClient() *Client

DefaultClient instantiates a new Fastly API client. This function requires the environment variable `FASTLY_API_KEY` is set and contains a valid API key to authenticate with Fastly.

func NewClient

func NewClient(key string) (*Client, error)

NewClient creates a new API client with the given key and the default API endpoint. Because Fastly allows some requests without an API key, this function will not error if the API token is not supplied. Attempts to make a request that requires an API key will return a 403 response.

func NewClientForEndpoint

func NewClientForEndpoint(key string, endpoint string) (*Client, error)

NewClientForEndpoint creates a new API client with the given key and API endpoint. Because Fastly allows some requests without an API key, this function will not error if the API token is not supplied. Attempts to make a request that requires an API key will return a 403 response.

func (*Client) ActivateVCL

func (c *Client) ActivateVCL(i *ActivateVCLInput) (*VCL, error)

ActivateVCL creates a new Fastly VCL.

func (*Client) ActivateVersion

func (c *Client) ActivateVersion(i *ActivateVersionInput) (*Version, error)

ActivateVersion activates the given version.

func (*Client) AllDatacenters added in v1.17.0

func (c *Client) AllDatacenters() (datacenters []Datacenter, err error)

AllDatacenters returns the lists of datacenters for Fastly's network.

func (*Client) AllIPs added in v0.16.0

func (c *Client) AllIPs() (v4, v6 IPAddrs, err error)

AllIPs returns the lists of public IPv4 and IPv6 addresses for Fastly's network.

func (*Client) BatchModifyACLEntries added in v0.16.0

func (c *Client) BatchModifyACLEntries(i *BatchModifyACLEntriesInput) error

func (*Client) BatchModifyDictionaryItems added in v0.16.0

func (c *Client) BatchModifyDictionaryItems(i *BatchModifyDictionaryItemsInput) error

func (*Client) CloneVersion

func (c *Client) CloneVersion(i *CloneVersionInput) (*Version, error)

CloneVersion creates a clone of the version with and returns a new configuration version with all the same configuration options, but an incremented number.

func (*Client) CreateACL added in v0.4.0

func (c *Client) CreateACL(i *CreateACLInput) (*ACL, error)

func (*Client) CreateACLEntry added in v0.4.0

func (c *Client) CreateACLEntry(i *CreateACLEntryInput) (*ACLEntry, error)

CreateACLEntry creates and returns a new ACL entry.

func (*Client) CreateBackend

func (c *Client) CreateBackend(i *CreateBackendInput) (*Backend, error)

CreateBackend creates a new Fastly backend.

func (*Client) CreateBigQuery added in v0.4.3

func (c *Client) CreateBigQuery(i *CreateBigQueryInput) (*BigQuery, error)

CreateBigQuery creates a new Fastly BigQuery.

func (*Client) CreateBlobStorage added in v0.4.3

func (c *Client) CreateBlobStorage(i *CreateBlobStorageInput) (*BlobStorage, error)

CreateBlobStorage creates a new Fastly blob storage.

func (*Client) CreateBulkCertificate added in v0.16.0

func (c *Client) CreateBulkCertificate(i *CreateBulkCertificateInput) (*BulkCertificate, error)

CreateBulkCertificate create a TLS private key.

func (*Client) CreateCacheSetting

func (c *Client) CreateCacheSetting(i *CreateCacheSettingInput) (*CacheSetting, error)

CreateCacheSetting creates a new Fastly cache setting.

func (*Client) CreateCloudfiles added in v0.16.0

func (c *Client) CreateCloudfiles(i *CreateCloudfilesInput) (*Cloudfiles, error)

CreateCloudfiles creates a new Fastly Cloudfiles.

func (*Client) CreateCondition

func (c *Client) CreateCondition(i *CreateConditionInput) (*Condition, error)

CreateCondition creates a new Fastly condition.

func (*Client) CreateDatadog added in v0.16.0

func (c *Client) CreateDatadog(i *CreateDatadogInput) (*Datadog, error)

CreateDatadog creates a new Datadog logging endpoint on a Fastly service version.

func (*Client) CreateDictionary

func (c *Client) CreateDictionary(i *CreateDictionaryInput) (*Dictionary, error)

CreateDictionary creates a new Fastly dictionary.

func (*Client) CreateDictionaryItem

func (c *Client) CreateDictionaryItem(i *CreateDictionaryItemInput) (*DictionaryItem, error)

CreateDictionaryItem creates a new Fastly dictionary item.

func (*Client) CreateDictionaryItems added in v0.4.3

func (c *Client) CreateDictionaryItems(i []CreateDictionaryItemInput) ([]DictionaryItem, error)

CreateDictionaryItems creates new Fastly dictionary items from a slice.

func (*Client) CreateDigitalOcean added in v0.16.0

func (c *Client) CreateDigitalOcean(i *CreateDigitalOceanInput) (*DigitalOcean, error)

CreateDigitalOcean creates a new Fastly DigitalOcean.

func (*Client) CreateDirector

func (c *Client) CreateDirector(i *CreateDirectorInput) (*Director, error)

CreateDirector creates a new Fastly director.

func (*Client) CreateDirectorBackend

func (c *Client) CreateDirectorBackend(i *CreateDirectorBackendInput) (*DirectorBackend, error)

CreateDirectorBackend creates a new Fastly backend.

func (*Client) CreateDomain

func (c *Client) CreateDomain(i *CreateDomainInput) (*Domain, error)

CreateDomain creates a new domain with the given information.

func (*Client) CreateElasticsearch added in v0.16.0

func (c *Client) CreateElasticsearch(i *CreateElasticsearchInput) (*Elasticsearch, error)

CreateElasticsearch creates a new Fastly Elasticsearch logging endpoint.

func (*Client) CreateFTP

func (c *Client) CreateFTP(i *CreateFTPInput) (*FTP, error)

CreateFTP creates a new Fastly FTP.

func (*Client) CreateGCS

func (c *Client) CreateGCS(i *CreateGCSInput) (*GCS, error)

CreateGCS creates a new Fastly GCS.

func (*Client) CreateGzip

func (c *Client) CreateGzip(i *CreateGzipInput) (*Gzip, error)

CreateGzip creates a new Fastly Gzip.

func (*Client) CreateHTTPS added in v0.16.0

func (c *Client) CreateHTTPS(i *CreateHTTPSInput) (*HTTPS, error)

CreateHTTPS creates a new Fastly HTTPS logging endpoint.

func (*Client) CreateHeader

func (c *Client) CreateHeader(i *CreateHeaderInput) (*Header, error)

CreateHeader creates a new Fastly header.

func (*Client) CreateHealthCheck

func (c *Client) CreateHealthCheck(i *CreateHealthCheckInput) (*HealthCheck, error)

CreateHealthCheck creates a new Fastly health check.

func (*Client) CreateHeroku added in v0.16.0

func (c *Client) CreateHeroku(i *CreateHerokuInput) (*Heroku, error)

CreateHeroku creates a new Fastly heroku.

func (*Client) CreateHoneycomb added in v0.16.0

func (c *Client) CreateHoneycomb(i *CreateHoneycombInput) (*Honeycomb, error)

CreateHoneycomb creates a new Fastly honeycomb.

func (*Client) CreateKafka added in v0.16.0

func (c *Client) CreateKafka(i *CreateKafkaInput) (*Kafka, error)

CreateKafka creates a new Fastly kafka.

func (*Client) CreateLogentries

func (c *Client) CreateLogentries(i *CreateLogentriesInput) (*Logentries, error)

CreateLogentries creates a new Fastly logentries.

func (*Client) CreateLoggly added in v0.16.0

func (c *Client) CreateLoggly(i *CreateLogglyInput) (*Loggly, error)

CreateLoggly creates a new Fastly loggly.

func (*Client) CreateLogshuttle added in v0.16.0

func (c *Client) CreateLogshuttle(i *CreateLogshuttleInput) (*Logshuttle, error)

CreateLogshuttle creates a new Fastly logshuttle.

func (*Client) CreateNewRelic added in v0.16.0

func (c *Client) CreateNewRelic(i *CreateNewRelicInput) (*NewRelic, error)

CreateNewRelic creates a new Fastly newrelic.

func (*Client) CreateOWASP added in v0.4.3

func (c *Client) CreateOWASP(i *CreateOWASPInput) (*OWASP, error)

CreateOWASP creates an OWASP settings object for a service firewall object.

func (*Client) CreateOpenstack added in v0.16.0

func (c *Client) CreateOpenstack(i *CreateOpenstackInput) (*Openstack, error)

CreateOpenstack creates a new Fastly Openstack.

func (*Client) CreatePapertrail

func (c *Client) CreatePapertrail(i *CreatePapertrailInput) (*Papertrail, error)

CreatePapertrail creates a new Fastly papertrail.

func (*Client) CreatePool added in v0.16.0

func (c *Client) CreatePool(i *CreatePoolInput) (*Pool, error)

CreatePool creates a pool for a particular service and version.

func (*Client) CreatePrivateKey added in v0.16.0

func (c *Client) CreatePrivateKey(i *CreatePrivateKeyInput) (*PrivateKey, error)

CreatePrivateKey create a TLS private key.

func (*Client) CreatePubsub added in v0.16.0

func (c *Client) CreatePubsub(i *CreatePubsubInput) (*Pubsub, error)

CreatePubsub creates a new Fastly Pubsub.

func (*Client) CreateRequestSetting

func (c *Client) CreateRequestSetting(i *CreateRequestSettingInput) (*RequestSetting, error)

CreateRequestSetting creates a new Fastly request settings.

func (*Client) CreateResponseObject

func (c *Client) CreateResponseObject(i *CreateResponseObjectInput) (*ResponseObject, error)

CreateResponseObject creates a new Fastly response object.

func (*Client) CreateS3

func (c *Client) CreateS3(i *CreateS3Input) (*S3, error)

CreateS3 creates a new Fastly S3.

func (*Client) CreateSFTP added in v0.16.0

func (c *Client) CreateSFTP(i *CreateSFTPInput) (*SFTP, error)

CreateSFTP creates a new Fastly SFTP.

func (*Client) CreateScalyr added in v0.16.0

func (c *Client) CreateScalyr(i *CreateScalyrInput) (*Scalyr, error)

CreateScalyr creates a new Fastly scalyr.

func (*Client) CreateServer added in v0.16.0

func (c *Client) CreateServer(i *CreateServerInput) (*Server, error)

CreateServer creates a single server for a particular service and pool. Servers are versionless resources that are associated with a Pool.

func (*Client) CreateService

func (c *Client) CreateService(i *CreateServiceInput) (*Service, error)

CreateService creates a new service with the given information.

func (*Client) CreateSnippet added in v0.4.3

func (c *Client) CreateSnippet(i *CreateSnippetInput) (*Snippet, error)

CreateSnippet creates a new snippet or dynamic snippet on a unlocked version

func (*Client) CreateSplunk added in v0.4.3

func (c *Client) CreateSplunk(i *CreateSplunkInput) (*Splunk, error)

CreateSplunk creates a new Fastly splunk.

func (*Client) CreateSumologic

func (c *Client) CreateSumologic(i *CreateSumologicInput) (*Sumologic, error)

CreateSumologic creates a new Fastly sumologic.

func (*Client) CreateSyslog

func (c *Client) CreateSyslog(i *CreateSyslogInput) (*Syslog, error)

CreateSyslog creates a new Fastly syslog.

func (*Client) CreateToken added in v0.16.0

func (c *Client) CreateToken(i *CreateTokenInput) (*Token, error)

CreateToken creates a new API token with the given information.

func (*Client) CreateUser added in v0.16.0

func (c *Client) CreateUser(i *CreateUserInput) (*User, error)

CreateUser creates a new API token with the given information.

func (*Client) CreateVCL

func (c *Client) CreateVCL(i *CreateVCLInput) (*VCL, error)

CreateVCL creates a new Fastly VCL.

func (*Client) CreateVersion

func (c *Client) CreateVersion(i *CreateVersionInput) (*Version, error)

CreateVersion constructs a new version. Note that `CloneVersion` is preferred in almost all scenarios, since `Create()` creates a _blank_ configuration where `Clone()` builds off of an existing configuration.

func (*Client) CreateWAF added in v0.4.2

func (c *Client) CreateWAF(i *CreateWAFInput) (*WAF, error)

CreateWAF creates a new Fastly WAF.

func (*Client) DeactivateVersion

func (c *Client) DeactivateVersion(i *DeactivateVersionInput) (*Version, error)

DeactivateVersion deactivates the given version.

func (*Client) Delete

func (c *Client) Delete(p string, ro *RequestOptions) (*http.Response, error)

Delete issues an HTTP DELETE request.

func (*Client) DeleteACL added in v0.4.0

func (c *Client) DeleteACL(i *DeleteACLInput) error

DeleteACL deletes the given ACL version.

func (*Client) DeleteACLEntry added in v0.4.0

func (c *Client) DeleteACLEntry(i *DeleteACLEntryInput) error

DeleteACLEntry deletes an entry from an ACL based on its ID

func (*Client) DeleteBackend

func (c *Client) DeleteBackend(i *DeleteBackendInput) error

DeleteBackend deletes the given backend version.

func (*Client) DeleteBigQuery added in v0.4.3

func (c *Client) DeleteBigQuery(i *DeleteBigQueryInput) error

DeleteBigQuery deletes the given BigQuery version.

func (*Client) DeleteBlobStorage added in v0.4.3

func (c *Client) DeleteBlobStorage(i *DeleteBlobStorageInput) error

DeleteBlobStorage deletes the given blob storage version.

func (*Client) DeleteBulkCertificate added in v0.16.0

func (c *Client) DeleteBulkCertificate(i *DeleteBulkCertificateInput) error

DeleteBulkCertificate destroy a certificate. This disables TLS for all domains listed as SAN entries.

func (*Client) DeleteCacheSetting

func (c *Client) DeleteCacheSetting(i *DeleteCacheSettingInput) error

DeleteCacheSetting deletes the given cache setting version.

func (*Client) DeleteCloudfiles added in v0.16.0

func (c *Client) DeleteCloudfiles(i *DeleteCloudfilesInput) error

DeleteCloudfiles deletes the given Cloudfiles version.

func (*Client) DeleteCondition

func (c *Client) DeleteCondition(i *DeleteConditionInput) error

DeleteCondition deletes the given condition version.

func (*Client) DeleteDatadog added in v0.16.0

func (c *Client) DeleteDatadog(i *DeleteDatadogInput) error

DeleteDatadog deletes a Datadog logging endpoint on a Fastly service version.

func (*Client) DeleteDictionary

func (c *Client) DeleteDictionary(i *DeleteDictionaryInput) error

DeleteDictionary deletes the given dictionary version.

func (*Client) DeleteDictionaryItem

func (c *Client) DeleteDictionaryItem(i *DeleteDictionaryItemInput) error

DeleteDictionaryItem deletes the given dictionary item.

func (*Client) DeleteDigitalOcean added in v0.16.0

func (c *Client) DeleteDigitalOcean(i *DeleteDigitalOceanInput) error

DeleteDigitalOcean deletes the given DigitalOcean version.

func (*Client) DeleteDirector

func (c *Client) DeleteDirector(i *DeleteDirectorInput) error

DeleteDirector deletes the given director version.

func (*Client) DeleteDirectorBackend

func (c *Client) DeleteDirectorBackend(i *DeleteDirectorBackendInput) error

DeleteDirectorBackend deletes the given backend version.

func (*Client) DeleteDomain

func (c *Client) DeleteDomain(i *DeleteDomainInput) error

DeleteDomain removes a single domain by the given name.

func (*Client) DeleteElasticsearch added in v0.16.0

func (c *Client) DeleteElasticsearch(i *DeleteElasticsearchInput) error

func (*Client) DeleteFTP

func (c *Client) DeleteFTP(i *DeleteFTPInput) error

DeleteFTP deletes the given FTP version.

func (*Client) DeleteGCS

func (c *Client) DeleteGCS(i *DeleteGCSInput) error

DeleteGCS deletes the given GCS version.

func (*Client) DeleteGzip

func (c *Client) DeleteGzip(i *DeleteGzipInput) error

DeleteGzip deletes the given Gzip version.

func (*Client) DeleteHTTPS added in v0.16.0

func (c *Client) DeleteHTTPS(i *DeleteHTTPSInput) error

func (*Client) DeleteHeader

func (c *Client) DeleteHeader(i *DeleteHeaderInput) error

DeleteHeader deletes the given header version.

func (*Client) DeleteHealthCheck

func (c *Client) DeleteHealthCheck(i *DeleteHealthCheckInput) error

DeleteHealthCheck deletes the given health check.

func (*Client) DeleteHeroku added in v0.16.0

func (c *Client) DeleteHeroku(i *DeleteHerokuInput) error

DeleteHeroku deletes the given heroku version.

func (*Client) DeleteHoneycomb added in v0.16.0

func (c *Client) DeleteHoneycomb(i *DeleteHoneycombInput) error

DeleteHoneycomb deletes the given honeycomb version.

func (*Client) DeleteKafka added in v0.16.0

func (c *Client) DeleteKafka(i *DeleteKafkaInput) error

DeleteKafka deletes the given kafka version.

func (*Client) DeleteLogentries

func (c *Client) DeleteLogentries(i *DeleteLogentriesInput) error

DeleteLogentries deletes the given logentries version.

func (*Client) DeleteLoggly added in v0.16.0

func (c *Client) DeleteLoggly(i *DeleteLogglyInput) error

DeleteLoggly deletes the given loggly version.

func (*Client) DeleteLogshuttle added in v0.16.0

func (c *Client) DeleteLogshuttle(i *DeleteLogshuttleInput) error

DeleteLogshuttle deletes the given logshuttle version.

func (*Client) DeleteNewRelic added in v0.16.0

func (c *Client) DeleteNewRelic(i *DeleteNewRelicInput) error

DeleteNewRelic deletes the given newrelic version.

func (*Client) DeleteOpenstack added in v0.16.0

func (c *Client) DeleteOpenstack(i *DeleteOpenstackInput) error

DeleteOpenstack deletes the given Openstack version.

func (*Client) DeletePapertrail

func (c *Client) DeletePapertrail(i *DeletePapertrailInput) error

DeletePapertrail deletes the given papertrail version.

func (*Client) DeletePool added in v0.16.0

func (c *Client) DeletePool(i *DeletePoolInput) error

DeletePool deletes a specific pool for a particular service and version.

func (*Client) DeletePrivateKey added in v0.16.0

func (c *Client) DeletePrivateKey(i *DeletePrivateKeyInput) error

DeletePrivateKey destroy a TLS private key. Only private keys not already matched to any certificates can be deleted.

func (*Client) DeletePubsub added in v0.16.0

func (c *Client) DeletePubsub(i *DeletePubsubInput) error

DeletePubsub deletes the given Pubsub version.

func (*Client) DeleteRequestSetting

func (c *Client) DeleteRequestSetting(i *DeleteRequestSettingInput) error

DeleteRequestSetting deletes the given request settings version.

func (*Client) DeleteResponseObject

func (c *Client) DeleteResponseObject(i *DeleteResponseObjectInput) error

DeleteResponseObject deletes the given response object version.

func (*Client) DeleteS3

func (c *Client) DeleteS3(i *DeleteS3Input) error

DeleteS3 deletes the given S3 version.

func (*Client) DeleteSFTP added in v0.16.0

func (c *Client) DeleteSFTP(i *DeleteSFTPInput) error

DeleteSFTP deletes the given SFTP version.

func (*Client) DeleteScalyr added in v0.16.0

func (c *Client) DeleteScalyr(i *DeleteScalyrInput) error

DeleteScalyr deletes the given scalyr version.

func (*Client) DeleteServer added in v0.16.0

func (c *Client) DeleteServer(i *DeleteServerInput) error

DeleteServer deletes a single server for a particular service and pool.

func (*Client) DeleteService

func (c *Client) DeleteService(i *DeleteServiceInput) error

DeleteService updates the service with the given input.

func (*Client) DeleteSnippet added in v0.4.3

func (c *Client) DeleteSnippet(i *DeleteSnippetInput) error

func (*Client) DeleteSplunk added in v0.4.3

func (c *Client) DeleteSplunk(i *DeleteSplunkInput) error

DeleteSplunk deletes the given splunk version.

func (*Client) DeleteSumologic

func (c *Client) DeleteSumologic(i *DeleteSumologicInput) error

DeleteSumologic deletes the given sumologic version.

func (*Client) DeleteSyslog

func (c *Client) DeleteSyslog(i *DeleteSyslogInput) error

DeleteSyslog deletes the given syslog version.

func (*Client) DeleteToken added in v0.16.0

func (c *Client) DeleteToken(i *DeleteTokenInput) error

DeleteToken revokes a specific token by its ID.

func (*Client) DeleteTokenSelf added in v0.16.0

func (c *Client) DeleteTokenSelf() error

DeleteTokenSelf revokes the token used to authorise the request.

func (*Client) DeleteUser added in v0.16.0

func (c *Client) DeleteUser(i *DeleteUserInput) error

DeleteUser revokes a specific token by its ID.

func (*Client) DeleteVCL

func (c *Client) DeleteVCL(i *DeleteVCLInput) error

DeleteVCL deletes the given VCL version.

func (*Client) DeleteWAF added in v0.4.2

func (c *Client) DeleteWAF(i *DeleteWAFInput) error

func (*Client) EdgeCheck

func (c *Client) EdgeCheck(i *EdgeCheckInput) ([]*EdgeCheck, error)

EdgeCheck queries the edge cache for all of Fastly's servers for the given URL.

func (*Client) Get

func (c *Client) Get(p string, ro *RequestOptions) (*http.Response, error)

Get issues an HTTP GET request.

func (*Client) GetACL added in v0.4.0

func (c *Client) GetACL(i *GetACLInput) (*ACL, error)

GetACL gets the ACL configuration with the given parameters.

func (*Client) GetACLEntry added in v0.4.0

func (c *Client) GetACLEntry(i *GetACLEntryInput) (*ACLEntry, error)

GetACLEntry returns a single ACL entry based on its ID.

func (*Client) GetAPIEvent added in v0.4.3

func (c *Client) GetAPIEvent(i *GetAPIEventInput) (*Event, error)

GetAPIEvent gets a specific event

func (*Client) GetAPIEvents added in v0.4.3

GetAPIEvents lists all the events for a particular customer

func (*Client) GetBackend

func (c *Client) GetBackend(i *GetBackendInput) (*Backend, error)

GetBackend gets the backend configuration with the given parameters.

func (*Client) GetBigQuery added in v0.4.3

func (c *Client) GetBigQuery(i *GetBigQueryInput) (*BigQuery, error)

GetBigQuery gets the BigQuery configuration with the given parameters.

func (*Client) GetBilling

func (c *Client) GetBilling(i *GetBillingInput) (*Billing, error)

GetBilling returns the billing information for the current account.

func (*Client) GetBlobStorage added in v0.4.3

func (c *Client) GetBlobStorage(i *GetBlobStorageInput) (*BlobStorage, error)

GetBlobStorage gets the blob storage configuration with the given parameters.

func (*Client) GetBulkCertificate added in v0.16.0

func (c *Client) GetBulkCertificate(i *GetBulkCertificateInput) (*BulkCertificate, error)

GetBulkCertificate retrieve a single certificate.

func (*Client) GetCacheSetting

func (c *Client) GetCacheSetting(i *GetCacheSettingInput) (*CacheSetting, error)

GetCacheSetting gets the cache setting configuration with the given parameters.

func (*Client) GetCloudfiles added in v0.16.0

func (c *Client) GetCloudfiles(i *GetCloudfilesInput) (*Cloudfiles, error)

GetCloudfiles gets the Cloudfiles configuration with the given parameters.

func (*Client) GetCondition

func (c *Client) GetCondition(i *GetConditionInput) (*Condition, error)

GetCondition gets the condition configuration with the given parameters.

func (*Client) GetCurrentUser added in v0.16.0

func (c *Client) GetCurrentUser() (*User, error)

GetCurrentUser retrieves the user information for the authenticated user.

func (*Client) GetDatadog added in v0.16.0

func (c *Client) GetDatadog(i *GetDatadogInput) (*Datadog, error)

GetDatadog gets the Datadog configuration with the given parameters.

func (*Client) GetDictionary

func (c *Client) GetDictionary(i *GetDictionaryInput) (*Dictionary, error)

GetDictionary gets the dictionary configuration with the given parameters.

func (*Client) GetDictionaryInfo added in v0.16.0

func (c *Client) GetDictionaryInfo(i *GetDictionaryInfoInput) (*DictionaryInfo, error)

GetDictionaryInfo gets the dictionary metadata with the given parameters.

func (*Client) GetDictionaryItem

func (c *Client) GetDictionaryItem(i *GetDictionaryItemInput) (*DictionaryItem, error)

GetDictionaryItem gets the dictionary item with the given parameters.

func (*Client) GetDiff

func (c *Client) GetDiff(i *GetDiffInput) (*Diff, error)

GetDiff returns the diff of the given versions.

func (*Client) GetDigitalOcean added in v0.16.0

func (c *Client) GetDigitalOcean(i *GetDigitalOceanInput) (*DigitalOcean, error)

GetDigitalOcean gets the DigitalOcean configuration with the given parameters.

func (*Client) GetDirector

func (c *Client) GetDirector(i *GetDirectorInput) (*Director, error)

GetDirector gets the director configuration with the given parameters.

func (*Client) GetDirectorBackend

func (c *Client) GetDirectorBackend(i *GetDirectorBackendInput) (*DirectorBackend, error)

GetDirectorBackend gets the backend configuration with the given parameters.

func (*Client) GetDomain

func (c *Client) GetDomain(i *GetDomainInput) (*Domain, error)

GetDomain retrieves information about the given domain name.

func (*Client) GetDynamicSnippet added in v0.4.3

func (c *Client) GetDynamicSnippet(i *GetDynamicSnippetInput) (*DynamicSnippet, error)

GetDynamicSnippet gets the Snippet configuration with the given parameters. This will show the current content associated with a Dynamic Snippet.

func (*Client) GetElasticsearch added in v0.16.0

func (c *Client) GetElasticsearch(i *GetElasticsearchInput) (*Elasticsearch, error)

func (*Client) GetFTP

func (c *Client) GetFTP(i *GetFTPInput) (*FTP, error)

GetFTP gets the FTP configuration with the given parameters.

func (*Client) GetGCS

func (c *Client) GetGCS(i *GetGCSInput) (*GCS, error)

GetGCS gets the GCS configuration with the given parameters.

func (*Client) GetGeneratedVCL

func (c *Client) GetGeneratedVCL(i *GetGeneratedVCLInput) (*VCL, error)

GetGeneratedVCL gets the VCL configuration with the given parameters.

func (*Client) GetGzip

func (c *Client) GetGzip(i *GetGzipInput) (*Gzip, error)

GetGzip gets the Gzip configuration with the given parameters.

func (*Client) GetHTTPS added in v0.16.0

func (c *Client) GetHTTPS(i *GetHTTPSInput) (*HTTPS, error)

func (*Client) GetHeader

func (c *Client) GetHeader(i *GetHeaderInput) (*Header, error)

GetHeader gets the header configuration with the given parameters.

func (*Client) GetHealthCheck

func (c *Client) GetHealthCheck(i *GetHealthCheckInput) (*HealthCheck, error)

GetHealthCheck gets the health check configuration with the given parameters.

func (*Client) GetHeroku added in v0.16.0

func (c *Client) GetHeroku(i *GetHerokuInput) (*Heroku, error)

GetHeroku gets the heroku configuration with the given parameters.

func (*Client) GetHoneycomb added in v0.16.0

func (c *Client) GetHoneycomb(i *GetHoneycombInput) (*Honeycomb, error)

GetHoneycomb gets the honeycomb configuration with the given parameters.

func (*Client) GetKafka added in v0.16.0

func (c *Client) GetKafka(i *GetKafkaInput) (*Kafka, error)

GetKafka gets the kafka configuration with the given parameters.

func (*Client) GetLogentries

func (c *Client) GetLogentries(i *GetLogentriesInput) (*Logentries, error)

GetLogentries gets the logentries configuration with the given parameters.

func (*Client) GetLoggly added in v0.16.0

func (c *Client) GetLoggly(i *GetLogglyInput) (*Loggly, error)

GetLoggly gets the loggly configuration with the given parameters.

func (*Client) GetLogshuttle added in v0.16.0

func (c *Client) GetLogshuttle(i *GetLogshuttleInput) (*Logshuttle, error)

GetLogshuttle gets the logshuttle configuration with the given parameters.

func (*Client) GetNewRelic added in v0.16.0

func (c *Client) GetNewRelic(i *GetNewRelicInput) (*NewRelic, error)

GetNewRelic gets the newrelic configuration with the given parameters.

func (*Client) GetOWASP added in v0.4.3

func (c *Client) GetOWASP(i *GetOWASPInput) (*OWASP, error)

GetOWASP gets OWASP settings for a service firewall object.

func (*Client) GetOpenstack added in v0.16.0

func (c *Client) GetOpenstack(i *GetOpenstackInput) (*Openstack, error)

GetOpenstack gets the Openstack configuration with the given parameters.

func (*Client) GetPackage added in v0.16.0

func (c *Client) GetPackage(i *GetPackageInput) (*Package, error)

GetPackage retrieves package information for the given service and version.

func (*Client) GetPapertrail

func (c *Client) GetPapertrail(i *GetPapertrailInput) (*Papertrail, error)

GetPapertrail gets the papertrail configuration with the given parameters.

func (*Client) GetPool added in v0.16.0

func (c *Client) GetPool(i *GetPoolInput) (*Pool, error)

GetPool gets a single pool for a particular service and version.

func (*Client) GetPrivateKey added in v0.16.0

func (c *Client) GetPrivateKey(i *GetPrivateKeyInput) (*PrivateKey, error)

GetPrivateKey show a TLS private key.

func (*Client) GetPubsub added in v0.16.0

func (c *Client) GetPubsub(i *GetPubsubInput) (*Pubsub, error)

GetPubsub gets the Pubsub configuration with the given parameters.

func (*Client) GetRegions added in v0.4.0

func (c *Client) GetRegions() (*RegionsResponse, error)

GetRegions returns a list of Fastly regions

func (*Client) GetRequestSetting

func (c *Client) GetRequestSetting(i *GetRequestSettingInput) (*RequestSetting, error)

GetRequestSetting gets the request settings configuration with the given parameters.

func (*Client) GetResponseObject

func (c *Client) GetResponseObject(i *GetResponseObjectInput) (*ResponseObject, error)

GetResponseObject gets the response object configuration with the given parameters.

func (*Client) GetRule added in v0.4.3

func (c *Client) GetRule(i *GetRuleInput) (*Rule, error)

GetRule gets a Rule using the Rule ID.

func (*Client) GetRuleVCL added in v0.4.3

func (c *Client) GetRuleVCL(i *GetRuleInput) (*RuleVCL, error)

GetRuleVCL gets the VCL for a Rule.

func (*Client) GetRules added in v0.4.3

func (c *Client) GetRules() ([]*Rule, error)

GetRules returns the list of wafs for the configuration version.

func (*Client) GetS3

func (c *Client) GetS3(i *GetS3Input) (*S3, error)

GetS3 gets the S3 configuration with the given parameters.

func (*Client) GetSFTP added in v0.16.0

func (c *Client) GetSFTP(i *GetSFTPInput) (*SFTP, error)

GetSFTP gets the SFTP configuration with the given parameters.

func (*Client) GetScalyr added in v0.16.0

func (c *Client) GetScalyr(i *GetScalyrInput) (*Scalyr, error)

GetScalyr gets the scalyr configuration with the given parameters.

func (*Client) GetServer added in v0.16.0

func (c *Client) GetServer(i *GetServerInput) (*Server, error)

GetServer gets a single server for a particular service and pool.

func (*Client) GetService

func (c *Client) GetService(i *GetServiceInput) (*Service, error)

GetService retrieves the service information for the service with the given id. If no service exists for the given id, the API returns a 400 response (not a 404).

func (*Client) GetServiceDetails

func (c *Client) GetServiceDetails(i *GetServiceInput) (*ServiceDetail, error)

GetService retrieves the details for the service with the given id. If no service exists for the given id, the API returns a 400 response (not a 404).

func (*Client) GetSettings

func (c *Client) GetSettings(i *GetSettingsInput) (*Settings, error)

GetSettings gets the backend configuration with the given parameters.

func (*Client) GetSnippet added in v0.4.3

func (c *Client) GetSnippet(i *GetSnippetInput) (*Snippet, error)

GetSnippet gets the Snippet configuration with the given parameters. Dynamic Snippets will not show content due to them being versionless, use GetDynamicSnippet to see content.

func (*Client) GetSplunk added in v0.4.3

func (c *Client) GetSplunk(i *GetSplunkInput) (*Splunk, error)

GetSplunk gets the splunk configuration with the given parameters.

func (*Client) GetStats added in v0.4.0

func (c *Client) GetStats(i *GetStatsInput) (*StatsResponse, error)

GetStats returns stats data based on GetStatsInput

func (*Client) GetStatsJSON added in v0.16.0

func (c *Client) GetStatsJSON(i *GetStatsInput, dst interface{}) error

GetStatsJSON fetches stats and decodes the response directly to the JSON struct dst.

func (*Client) GetSumologic

func (c *Client) GetSumologic(i *GetSumologicInput) (*Sumologic, error)

GetSumologic gets the sumologic configuration with the given parameters.

func (*Client) GetSyslog

func (c *Client) GetSyslog(i *GetSyslogInput) (*Syslog, error)

GetSyslog gets the syslog configuration with the given parameters.

func (*Client) GetTokenSelf added in v0.16.0

func (c *Client) GetTokenSelf() (*Token, error)

GetTokenSelf retrieves the token information for the the access_token used used to authenticate the request. Returns a 401 if the token has expired and a 403 for invalid access token.

func (*Client) GetUsage added in v0.4.0

func (c *Client) GetUsage(i *GetUsageInput) (*UsageResponse, error)

GetUsage returns usage information aggregated across all Fastly services and grouped by region.

func (*Client) GetUsageByService added in v0.4.0

func (c *Client) GetUsageByService(i *GetUsageInput) (*UsageByServiceResponse, error)

GetUsageByService returns usage information aggregated by service and grouped by service and region.

func (*Client) GetUser added in v0.16.0

func (c *Client) GetUser(i *GetUserInput) (*User, error)

GetUser retrieves the user information for the user with the given id. If no user exists for the given id, the API returns a 404 response.

func (*Client) GetVCL

func (c *Client) GetVCL(i *GetVCLInput) (*VCL, error)

GetVCL gets the VCL configuration with the given parameters.

func (*Client) GetVersion

func (c *Client) GetVersion(i *GetVersionInput) (*Version, error)

GetVersion fetches a version with the given information.

func (*Client) GetWAF added in v0.4.2

func (c *Client) GetWAF(i *GetWAFInput) (*WAF, error)

func (*Client) GetWAFRuleRuleSets added in v0.4.3

func (c *Client) GetWAFRuleRuleSets(i *GetWAFRuleRuleSetsInput) (*Ruleset, error)

GetWAFRuleRuleSets gets the VCL for rulesets associated with a firewall WAF.

func (*Client) GetWAFRuleStatus added in v0.4.3

func (c *Client) GetWAFRuleStatus(i *GetWAFRuleStatusInput) (WAFRuleStatus, error)

GetWAFRuleStatus fetches the status of a single rule associated with a WAF.

func (*Client) GetWAFRuleStatuses added in v0.4.3

func (c *Client) GetWAFRuleStatuses(i *GetWAFRuleStatusesInput) (GetWAFRuleStatusesResponse, error)

GetWAFRuleStatuses fetches the status of a subset of rules associated with a WAF.

func (*Client) GetWAFRuleVCL added in v0.4.3

func (c *Client) GetWAFRuleVCL(i *GetWAFRuleVCLInput) (*RuleVCL, error)

GetWAFRuleVCL gets the VCL for a role associated with a firewall WAF.

func (*Client) Head

func (c *Client) Head(p string, ro *RequestOptions) (*http.Response, error)

Head issues an HTTP HEAD request.

func (*Client) IPs

func (c *Client) IPs() (IPAddrs, error)

IPs returns the list of public IPv4 addresses for Fastly's network.

func (*Client) IPsV6 added in v0.16.0

func (c *Client) IPsV6() (IPAddrs, error)

IPsV6 returns the list of public IPv6 addresses for Fastly's network.

func (*Client) LatestVersion

func (c *Client) LatestVersion(i *LatestVersionInput) (*Version, error)

LatestVersion fetches the latest version. If there are no versions, this function will return nil (but not an error).

func (*Client) ListACLEntries added in v0.4.0

func (c *Client) ListACLEntries(i *ListACLEntriesInput) ([]*ACLEntry, error)

ListACLEntries return a list of entries for an ACL

func (*Client) ListACLs added in v0.4.0

func (c *Client) ListACLs(i *ListACLsInput) ([]*ACL, error)

ListACLs returns the list of ACLs for the configuration version.

func (*Client) ListBackends

func (c *Client) ListBackends(i *ListBackendsInput) ([]*Backend, error)

ListBackends returns the list of backends for the configuration version.

func (*Client) ListBigQueries added in v0.16.0

func (c *Client) ListBigQueries(i *ListBigQueriesInput) ([]*BigQuery, error)

ListBigQueries returns the list of BigQueries for the configuration version.

func (*Client) ListBlobStorages added in v0.4.3

func (c *Client) ListBlobStorages(i *ListBlobStoragesInput) ([]*BlobStorage, error)

ListBlobStorages returns the list of blob storages for the configuration version.

func (*Client) ListBulkCertificates added in v0.16.0

func (c *Client) ListBulkCertificates(i *ListBulkCertificatesInput) ([]*BulkCertificate, error)

ListBulkCertificates list all certificates.

func (*Client) ListCacheSettings

func (c *Client) ListCacheSettings(i *ListCacheSettingsInput) ([]*CacheSetting, error)

ListCacheSettings returns the list of cache settings for the configuration version.

func (*Client) ListCloudfiles added in v0.16.0

func (c *Client) ListCloudfiles(i *ListCloudfilesInput) ([]*Cloudfiles, error)

ListCloudfiles returns the list of Cloudfiles for the configuration version.

func (*Client) ListConditions

func (c *Client) ListConditions(i *ListConditionsInput) ([]*Condition, error)

ListConditions returns the list of conditions for the configuration version.

func (*Client) ListCustomerTokens added in v0.16.0

func (c *Client) ListCustomerTokens(i *ListCustomerTokensInput) ([]*Token, error)

ListCustomerTokens returns the full list of tokens belonging to a specific customer.

func (*Client) ListCustomerUsers added in v0.16.0

func (c *Client) ListCustomerUsers(i *ListCustomerUsersInput) ([]*User, error)

ListCustomerUsers returns the full list of users belonging to a specific customer.

func (*Client) ListDatadog added in v0.16.0

func (c *Client) ListDatadog(i *ListDatadogInput) ([]*Datadog, error)

ListDatadog returns the list of Datadog for the configuration version.

func (*Client) ListDictionaries

func (c *Client) ListDictionaries(i *ListDictionariesInput) ([]*Dictionary, error)

ListDictionaries returns the list of dictionaries for the configuration version.

func (*Client) ListDictionaryItems

func (c *Client) ListDictionaryItems(i *ListDictionaryItemsInput) ([]*DictionaryItem, error)

ListDictionaryItems returns the list of dictionary items for the configuration version.

func (*Client) ListDigitalOceans added in v0.16.0

func (c *Client) ListDigitalOceans(i *ListDigitalOceansInput) ([]*DigitalOcean, error)

ListDigitalOceans returns the list of DigitalOceans for the configuration version.

func (*Client) ListDirectors

func (c *Client) ListDirectors(i *ListDirectorsInput) ([]*Director, error)

ListDirectors returns the list of directors for the configuration version.

func (*Client) ListDomains

func (c *Client) ListDomains(i *ListDomainsInput) ([]*Domain, error)

ListDomains returns the list of domains for this Service.

func (*Client) ListElasticsearch added in v0.16.0

func (c *Client) ListElasticsearch(i *ListElasticsearchInput) ([]*Elasticsearch, error)

ListElasticsearch returns the list of Elasticsearch logs for the configuration version.

func (*Client) ListFTPs

func (c *Client) ListFTPs(i *ListFTPsInput) ([]*FTP, error)

ListFTPs returns the list of ftps for the configuration version.

func (*Client) ListGCSs

func (c *Client) ListGCSs(i *ListGCSsInput) ([]*GCS, error)

ListGCSs returns the list of gcses for the configuration version.

func (*Client) ListGzips

func (c *Client) ListGzips(i *ListGzipsInput) ([]*Gzip, error)

ListGzips returns the list of gzips for the configuration version.

func (*Client) ListHTTPS added in v0.16.0

func (c *Client) ListHTTPS(i *ListHTTPSInput) ([]*HTTPS, error)

ListHTTPS returns the list of HTTPS logs for the configuration version.

func (*Client) ListHeaders

func (c *Client) ListHeaders(i *ListHeadersInput) ([]*Header, error)

ListHeaders returns the list of headers for the configuration version.

func (*Client) ListHealthChecks

func (c *Client) ListHealthChecks(i *ListHealthChecksInput) ([]*HealthCheck, error)

ListHealthChecks returns the list of health checks for the configuration version.

func (*Client) ListHerokus added in v0.16.0

func (c *Client) ListHerokus(i *ListHerokusInput) ([]*Heroku, error)

ListHerokus returns the list of herokus for the configuration version.

func (*Client) ListHoneycombs added in v0.16.0

func (c *Client) ListHoneycombs(i *ListHoneycombsInput) ([]*Honeycomb, error)

ListHoneycombs returns the list of honeycombs for the configuration version.

func (*Client) ListKafkas added in v0.16.0

func (c *Client) ListKafkas(i *ListKafkasInput) ([]*Kafka, error)

ListKafkas returns the list of kafkas for the configuration version.

func (*Client) ListLogentries

func (c *Client) ListLogentries(i *ListLogentriesInput) ([]*Logentries, error)

ListLogentries returns the list of logentries for the configuration version.

func (*Client) ListLoggly added in v0.16.0

func (c *Client) ListLoggly(i *ListLogglyInput) ([]*Loggly, error)

ListLoggly returns the list of loggly for the configuration version.

func (*Client) ListLogshuttles added in v0.16.0

func (c *Client) ListLogshuttles(i *ListLogshuttlesInput) ([]*Logshuttle, error)

ListLogshuttles returns the list of logshuttles for the configuration version.

func (*Client) ListNewRelic added in v0.16.0

func (c *Client) ListNewRelic(i *ListNewRelicInput) ([]*NewRelic, error)

ListNewRelic returns the list of newrelic for the configuration version.

func (*Client) ListOpenstack added in v0.16.0

func (c *Client) ListOpenstack(i *ListOpenstackInput) ([]*Openstack, error)

ListOpenstack returns the list of Openstack for the configuration version.

func (*Client) ListPapertrails

func (c *Client) ListPapertrails(i *ListPapertrailsInput) ([]*Papertrail, error)

ListPapertrails returns the list of papertrails for the configuration version.

func (*Client) ListPools added in v0.16.0

func (c *Client) ListPools(i *ListPoolsInput) ([]*Pool, error)

ListPools lists all pools for a particular service and version.

func (*Client) ListPrivateKeys added in v0.16.0

func (c *Client) ListPrivateKeys(i *ListPrivateKeysInput) ([]*PrivateKey, error)

ListPrivateKeys list all TLS private keys.

func (*Client) ListPubsubs added in v0.16.0

func (c *Client) ListPubsubs(i *ListPubsubsInput) ([]*Pubsub, error)

ListPubsubs returns the list of pubsubs for the configuration version.

func (*Client) ListRequestSettings

func (c *Client) ListRequestSettings(i *ListRequestSettingsInput) ([]*RequestSetting, error)

ListRequestSettings returns the list of request settings for the configuration version.

func (*Client) ListResponseObjects

func (c *Client) ListResponseObjects(i *ListResponseObjectsInput) ([]*ResponseObject, error)

ListResponseObjects returns the list of response objects for the configuration version.

func (*Client) ListS3s

func (c *Client) ListS3s(i *ListS3sInput) ([]*S3, error)

ListS3s returns the list of S3s for the configuration version.

func (*Client) ListSFTPs added in v0.16.0

func (c *Client) ListSFTPs(i *ListSFTPsInput) ([]*SFTP, error)

ListSFTPs returns the list of sftps for the configuration version.

func (*Client) ListScalyrs added in v0.16.0

func (c *Client) ListScalyrs(i *ListScalyrsInput) ([]*Scalyr, error)

ListScalyrs returns the list of scalyrs for the configuration version.

func (*Client) ListServers added in v0.16.0

func (c *Client) ListServers(i *ListServersInput) ([]*Server, error)

ListServers lists all servers for a particular service and pool.

func (*Client) ListServiceDomains added in v0.4.3

func (c *Client) ListServiceDomains(i *ListServiceDomainInput) (ServiceDomainsList, error)

ListServiceDomains lists all domains associated with a given service

func (*Client) ListServices

func (c *Client) ListServices(i *ListServicesInput) ([]*Service, error)

ListServices returns the full list of services for the current account.

func (*Client) ListSnippets added in v0.4.3

func (c *Client) ListSnippets(i *ListSnippetsInput) ([]*Snippet, error)

ListSnippets returns the list of Snippets for the configuration version. Content is not displayed for Dynmanic Snippets due to them being versionless, use the GetDynamicSnippet function to show current content.

func (*Client) ListSplunks added in v0.4.3

func (c *Client) ListSplunks(i *ListSplunksInput) ([]*Splunk, error)

ListSplunks returns the list of splunks for the configuration version.

func (*Client) ListSumologics

func (c *Client) ListSumologics(i *ListSumologicsInput) ([]*Sumologic, error)

ListSumologics returns the list of sumologics for the configuration version.

func (*Client) ListSyslogs

func (c *Client) ListSyslogs(i *ListSyslogsInput) ([]*Syslog, error)

ListSyslogs returns the list of syslogs for the configuration version.

func (*Client) ListTokens added in v0.16.0

func (c *Client) ListTokens() ([]*Token, error)

ListTokens returns the full list of tokens belonging to the currently authenticated user.

func (*Client) ListVCLs

func (c *Client) ListVCLs(i *ListVCLsInput) ([]*VCL, error)

ListVCLs returns the list of VCLs for the configuration version.

func (*Client) ListVersions

func (c *Client) ListVersions(i *ListVersionsInput) ([]*Version, error)

ListVersions returns the full list of all versions of the given service.

func (*Client) ListWAFs added in v0.4.2

func (c *Client) ListWAFs(i *ListWAFsInput) ([]*WAF, error)

ListWAFs returns the list of wafs for the configuration version.

func (*Client) LockVersion

func (c *Client) LockVersion(i *LockVersionInput) (*Version, error)

LockVersion locks the specified version.

func (*Client) Patch added in v0.4.2

func (c *Client) Patch(p string, ro *RequestOptions) (*http.Response, error)

Patch issues an HTTP PATCH request.

func (*Client) PatchForm added in v0.4.2

func (c *Client) PatchForm(p string, i interface{}, ro *RequestOptions) (*http.Response, error)

PatchForm issues an HTTP PUT request with the given interface form-encoded.

func (*Client) PatchJSON added in v0.4.2

func (c *Client) PatchJSON(p string, i interface{}, ro *RequestOptions) (*http.Response, error)

PatchJSON issues an HTTP PUT request with the given interface json-encoded.

func (*Client) PatchJSONAPI added in v0.4.2

func (c *Client) PatchJSONAPI(p string, i interface{}, ro *RequestOptions) (*http.Response, error)

PatchJSONAPI issues an HTTP PUT request with the given interface json-encoded.

func (*Client) Post

func (c *Client) Post(p string, ro *RequestOptions) (*http.Response, error)

Post issues an HTTP POST request.

func (*Client) PostForm

func (c *Client) PostForm(p string, i interface{}, ro *RequestOptions) (*http.Response, error)

PostForm issues an HTTP POST request with the given interface form-encoded.

func (*Client) PostJSON added in v0.4.2

func (c *Client) PostJSON(p string, i interface{}, ro *RequestOptions) (*http.Response, error)

PostJSON issues an HTTP POST request with the given interface json-encoded.

func (*Client) PostJSONAPI added in v0.4.2

func (c *Client) PostJSONAPI(p string, i interface{}, ro *RequestOptions) (*http.Response, error)

PostJSONAPI issues an HTTP POST request with the given interface json-encoded.

func (*Client) Purge

func (c *Client) Purge(i *PurgeInput) (*Purge, error)

Purge instantly purges an individual URL.

func (*Client) PurgeAll

func (c *Client) PurgeAll(i *PurgeAllInput) (*Purge, error)

PurgeAll instantly purges everything from a service.

func (*Client) PurgeKey

func (c *Client) PurgeKey(i *PurgeKeyInput) (*Purge, error)

PurgeKey instantly purges a particular service of items tagged with a key.

func (*Client) Put

func (c *Client) Put(p string, ro *RequestOptions) (*http.Response, error)

Put issues an HTTP PUT request.

func (*Client) PutForm

func (c *Client) PutForm(p string, i interface{}, ro *RequestOptions) (*http.Response, error)

PutForm issues an HTTP PUT request with the given interface form-encoded.

func (*Client) PutFormFile added in v0.16.0

func (c *Client) PutFormFile(urlPath string, filePath string, fieldName string, ro *RequestOptions) (*http.Response, error)

PutFormFile issues an HTTP PUT request (multipart/form-encoded) to put a file to an endpoint.

func (*Client) PutJSON added in v0.4.2

func (c *Client) PutJSON(p string, i interface{}, ro *RequestOptions) (*http.Response, error)

PutJSON issues an HTTP PUT request with the given interface json-encoded.

func (*Client) PutJSONAPI added in v0.4.2

func (c *Client) PutJSONAPI(p string, i interface{}, ro *RequestOptions) (*http.Response, error)

PutJSONAPI issues an HTTP PUT request with the given interface json-encoded.

func (*Client) RawRequest

func (c *Client) RawRequest(verb, p string, ro *RequestOptions) (*http.Request, error)

RawRequest accepts a verb, URL, and RequestOptions struct and returns the constructed http.Request and any errors that occurred

func (*Client) Request

func (c *Client) Request(verb, p string, ro *RequestOptions) (*http.Response, error)

Request makes an HTTP request against the HTTPClient using the given verb, Path, and request options.

func (*Client) RequestForm

func (c *Client) RequestForm(verb, p string, i interface{}, ro *RequestOptions) (*http.Response, error)

RequestForm makes an HTTP request with the given interface being encoded as form data.

func (*Client) RequestFormFile added in v0.16.0

func (c *Client) RequestFormFile(verb, urlPath string, filePath string, fieldName string, ro *RequestOptions) (*http.Response, error)

RequestFormFile makes an HTTP request to upload a file to an endpoint.

func (*Client) RequestJSON added in v0.4.2

func (c *Client) RequestJSON(verb, p string, i interface{}, ro *RequestOptions) (*http.Response, error)

func (*Client) RequestJSONAPI added in v0.4.2

func (c *Client) RequestJSONAPI(verb, p string, i interface{}, ro *RequestOptions) (*http.Response, error)

func (*Client) SearchService

func (c *Client) SearchService(i *SearchServiceInput) (*Service, error)

SearchService gets a specific service by name. If no service exists by that name, the API returns a 400 response (not a 404).

func (*Client) SimpleGet added in v0.4.3

func (c *Client) SimpleGet(target string) (*http.Response, error)

SimpleGet combines the RawRequest and Request methods, but doesn't add any parameters or change any encoding in the URL passed to it. It's mostly for calling the URLs given to us directly from Fastly without mangling them.

func (*Client) UpdateACL added in v0.4.0

func (c *Client) UpdateACL(i *UpdateACLInput) (*ACL, error)

UpdateACL updates the name of the ACL with the given parameters.

func (*Client) UpdateACLEntry added in v0.4.0

func (c *Client) UpdateACLEntry(i *UpdateACLEntryInput) (*ACLEntry, error)

UpdateACLEntry updates an ACL entry

func (*Client) UpdateBackend

func (c *Client) UpdateBackend(i *UpdateBackendInput) (*Backend, error)

UpdateBackend updates a specific backend.

func (*Client) UpdateBigQuery added in v0.4.3

func (c *Client) UpdateBigQuery(i *UpdateBigQueryInput) (*BigQuery, error)

UpdateBigQuery updates a specific BigQuery.

func (*Client) UpdateBlobStorage added in v0.4.3

func (c *Client) UpdateBlobStorage(i *UpdateBlobStorageInput) (*BlobStorage, error)

UpdateBlobStorage updates a specific blob storage.

func (*Client) UpdateBulkCertificate added in v0.16.0

func (c *Client) UpdateBulkCertificate(i *UpdateBulkCertificateInput) (*BulkCertificate, error)

UpdateBulkCertificate replace a certificate with a newly reissued certificate. By using this endpoint, the original certificate will cease to be used for future TLS handshakes. Thus, only SAN entries that appear in the replacement certificate will become TLS enabled. Any SAN entries that are missing in the replacement certificate will become disabled.

func (*Client) UpdateCacheSetting

func (c *Client) UpdateCacheSetting(i *UpdateCacheSettingInput) (*CacheSetting, error)

UpdateCacheSetting updates a specific cache setting.

func (*Client) UpdateCloudfiles added in v0.16.0

func (c *Client) UpdateCloudfiles(i *UpdateCloudfilesInput) (*Cloudfiles, error)

UpdateCloudfiles updates a specific Cloudfiles.

func (*Client) UpdateCondition

func (c *Client) UpdateCondition(i *UpdateConditionInput) (*Condition, error)

UpdateCondition updates a specific condition.

func (*Client) UpdateDatadog added in v0.16.0

func (c *Client) UpdateDatadog(i *UpdateDatadogInput) (*Datadog, error)

UpdateDatadog updates a Datadog logging endpoint on a Fastly service version.

func (*Client) UpdateDictionary

func (c *Client) UpdateDictionary(i *UpdateDictionaryInput) (*Dictionary, error)

UpdateDictionary updates a specific dictionary.

func (*Client) UpdateDictionaryItem

func (c *Client) UpdateDictionaryItem(i *UpdateDictionaryItemInput) (*DictionaryItem, error)

UpdateDictionaryItem updates a specific dictionary item.

func (*Client) UpdateDigitalOcean added in v0.16.0

func (c *Client) UpdateDigitalOcean(i *UpdateDigitalOceanInput) (*DigitalOcean, error)

UpdateDigitalOcean updates a specific DigitalOcean.

func (*Client) UpdateDirector

func (c *Client) UpdateDirector(i *UpdateDirectorInput) (*Director, error)

UpdateDirector updates a specific director.

func (*Client) UpdateDomain

func (c *Client) UpdateDomain(i *UpdateDomainInput) (*Domain, error)

UpdateDomain updates a single domain for the current service. The only allowed parameters are `Name` and `Comment`.

func (*Client) UpdateDynamicSnippet added in v0.4.3

func (c *Client) UpdateDynamicSnippet(i *UpdateDynamicSnippetInput) (*DynamicSnippet, error)

UpdateDynamicSnippet replaces the content of a Dynamic Snippet

func (*Client) UpdateElasticsearch added in v0.16.0

func (c *Client) UpdateElasticsearch(i *UpdateElasticsearchInput) (*Elasticsearch, error)

func (*Client) UpdateFTP

func (c *Client) UpdateFTP(i *UpdateFTPInput) (*FTP, error)

UpdateFTP updates a specific FTP.

func (*Client) UpdateGCS

func (c *Client) UpdateGCS(i *UpdateGCSInput) (*GCS, error)

UpdateGCS updates a specific GCS.

func (*Client) UpdateGzip

func (c *Client) UpdateGzip(i *UpdateGzipInput) (*Gzip, error)

UpdateGzip updates a specific Gzip.

func (*Client) UpdateHTTPS added in v0.16.0

func (c *Client) UpdateHTTPS(i *UpdateHTTPSInput) (*HTTPS, error)

func (*Client) UpdateHeader

func (c *Client) UpdateHeader(i *UpdateHeaderInput) (*Header, error)

UpdateHeader updates a specific header.

func (*Client) UpdateHealthCheck

func (c *Client) UpdateHealthCheck(i *UpdateHealthCheckInput) (*HealthCheck, error)

UpdateHealthCheck updates a specific health check.

func (*Client) UpdateHeroku added in v0.16.0

func (c *Client) UpdateHeroku(i *UpdateHerokuInput) (*Heroku, error)

UpdateHeroku updates a specific heroku.

func (*Client) UpdateHoneycomb added in v0.16.0

func (c *Client) UpdateHoneycomb(i *UpdateHoneycombInput) (*Honeycomb, error)

UpdateHoneycomb updates a specific honeycomb.

func (*Client) UpdateKafka added in v0.16.0

func (c *Client) UpdateKafka(i *UpdateKafkaInput) (*Kafka, error)

UpdateKafka updates a specific kafka.

func (*Client) UpdateLogentries

func (c *Client) UpdateLogentries(i *UpdateLogentriesInput) (*Logentries, error)

UpdateLogentries updates a specific logentries.

func (*Client) UpdateLoggly added in v0.16.0

func (c *Client) UpdateLoggly(i *UpdateLogglyInput) (*Loggly, error)

UpdateLoggly updates a specific loggly.

func (*Client) UpdateLogshuttle added in v0.16.0

func (c *Client) UpdateLogshuttle(i *UpdateLogshuttleInput) (*Logshuttle, error)

UpdateLogshuttle updates a specific logshuttle.

func (*Client) UpdateNewRelic added in v0.16.0

func (c *Client) UpdateNewRelic(i *UpdateNewRelicInput) (*NewRelic, error)

UpdateNewRelic updates a specific newrelic.

func (*Client) UpdateOWASP added in v0.4.3

func (c *Client) UpdateOWASP(i *UpdateOWASPInput) (*OWASP, error)

CreateOWASP creates an OWASP settings object for a service firewall object.

func (*Client) UpdateOpenstack added in v0.16.0

func (c *Client) UpdateOpenstack(i *UpdateOpenstackInput) (*Openstack, error)

UpdateOpenstack updates a specific Openstack.

func (*Client) UpdatePackage added in v0.16.0

func (c *Client) UpdatePackage(i *UpdatePackageInput) (*Package, error)

UpdatePackage updates a package for a specific version.

func (*Client) UpdatePapertrail

func (c *Client) UpdatePapertrail(i *UpdatePapertrailInput) (*Papertrail, error)

UpdatePapertrail updates a specific papertrail.

func (*Client) UpdatePool added in v0.16.0

func (c *Client) UpdatePool(i *UpdatePoolInput) (*Pool, error)

UpdatePool updates a specufic pool for a particular service and version.

func (*Client) UpdatePubsub added in v0.16.0

func (c *Client) UpdatePubsub(i *UpdatePubsubInput) (*Pubsub, error)

UpdatePubsub updates a specific Pubsub.

func (*Client) UpdateRequestSetting

func (c *Client) UpdateRequestSetting(i *UpdateRequestSettingInput) (*RequestSetting, error)

UpdateRequestSetting updates a specific request settings.

func (*Client) UpdateResponseObject

func (c *Client) UpdateResponseObject(i *UpdateResponseObjectInput) (*ResponseObject, error)

UpdateResponseObject updates a specific response object.

func (*Client) UpdateS3

func (c *Client) UpdateS3(i *UpdateS3Input) (*S3, error)

UpdateS3 updates a specific S3.

func (*Client) UpdateSFTP added in v0.16.0

func (c *Client) UpdateSFTP(i *UpdateSFTPInput) (*SFTP, error)

UpdateSFTP updates a specific SFTP.

func (*Client) UpdateScalyr added in v0.16.0

func (c *Client) UpdateScalyr(i *UpdateScalyrInput) (*Scalyr, error)

UpdateScalyr updates a specific scalyr.

func (*Client) UpdateServer added in v0.16.0

func (c *Client) UpdateServer(i *UpdateServerInput) (*Server, error)

UpdateServer updates a single server for a particular service and pool.

func (*Client) UpdateService

func (c *Client) UpdateService(i *UpdateServiceInput) (*Service, error)

UpdateService updates the service with the given input.

func (*Client) UpdateSettings

func (c *Client) UpdateSettings(i *UpdateSettingsInput) (*Settings, error)

UpdateSettings updates a specific backend.

func (*Client) UpdateSnippet added in v0.4.3

func (c *Client) UpdateSnippet(i *UpdateSnippetInput) (*Snippet, error)

UpdateSnippet updates a snippet on a unlocked version

func (*Client) UpdateSplunk added in v0.4.3

func (c *Client) UpdateSplunk(i *UpdateSplunkInput) (*Splunk, error)

UpdateSplunk updates a specific splunk.

func (*Client) UpdateSumologic

func (c *Client) UpdateSumologic(i *UpdateSumologicInput) (*Sumologic, error)

UpdateSumologic updates a specific sumologic.

func (*Client) UpdateSyslog

func (c *Client) UpdateSyslog(i *UpdateSyslogInput) (*Syslog, error)

UpdateSyslog updates a specific syslog.

func (*Client) UpdateUser added in v0.16.0

func (c *Client) UpdateUser(i *UpdateUserInput) (*User, error)

UpdateUser updates the user with the given input.

func (*Client) UpdateVCL

func (c *Client) UpdateVCL(i *UpdateVCLInput) (*VCL, error)

UpdateVCL creates a new Fastly VCL.

func (*Client) UpdateVersion

func (c *Client) UpdateVersion(i *UpdateVersionInput) (*Version, error)

UpdateVersion updates the given version

func (*Client) UpdateWAF added in v0.4.2

func (c *Client) UpdateWAF(i *UpdateWAFInput) (*WAF, error)

UpdateWAF updates a specific WAF.

func (*Client) UpdateWAFConfigSet added in v0.4.3

func (c *Client) UpdateWAFConfigSet(i *UpdateWAFConfigSetInput) (UpdateWAFConfigSetResponse, error)

UpdateWAFConfigSet updates a list of WAFs with the given configset

func (*Client) UpdateWAFRuleSets added in v0.4.3

func (c *Client) UpdateWAFRuleSets(i *UpdateWAFRuleRuleSetsInput) (*Ruleset, error)

UpdateWAFRuleSets updates the rulesets for a role associated with a firewall WAF.

func (*Client) UpdateWAFRuleStatus added in v0.4.3

func (c *Client) UpdateWAFRuleStatus(i *UpdateWAFRuleStatusInput) (WAFRuleStatus, error)

UpdateWAFRuleStatus changes the status of a single rule associated with a WAF.

func (*Client) UpdateWAFRuleTagStatus added in v0.4.3

func (c *Client) UpdateWAFRuleTagStatus(input *UpdateWAFRuleTagStatusInput) (GetWAFRuleStatusesResponse, error)

UpdateWAFRuleTagStatus changes the status of a single rule associated with a WAF. NOTE: This call currently appears to return *all* rules attached to the WAF, rather than just the ones that were modified by the call.

func (*Client) ValidateVersion

func (c *Client) ValidateVersion(i *ValidateVersionInput) (bool, string, error)

ValidateVersion validates if the given version is okay.

type CloneVersionInput

type CloneVersionInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int
}

CloneVersionInput is the input to the CloneVersion function.

type Cloudfiles added in v0.16.0

type Cloudfiles struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	User              string     `mapstructure:"user"`
	AccessKey         string     `mapstructure:"access_key"`
	BucketName        string     `mapstructure:"bucket_name"`
	Path              string     `mapstructure:"path"`
	Region            string     `mapstructure:"region"`
	Placement         string     `mapstructure:"placement"`
	Period            uint       `mapstructure:"period"`
	GzipLevel         uint       `mapstructure:"gzip_level"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	MessageType       string     `mapstructure:"message_type"`
	TimestampFormat   string     `mapstructure:"timestamp_format"`
	PublicKey         string     `mapstructure:"public_key"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Cloudfiles represents a Cloudfiles response from the Fastly API.

type Compatibool

type Compatibool bool

Compatibool is a boolean value that marshalls to 0/1 instead of true/false for compatibility with Fastly's API.

func CBool

func CBool(b bool) *Compatibool

Helper function to get a pointer to bool

func (Compatibool) MarshalText

func (b Compatibool) MarshalText() ([]byte, error)

MarshalText implements the encoding.TextMarshaler interface.

func (*Compatibool) UnmarshalText

func (b *Compatibool) UnmarshalText(t []byte) error

UnmarshalText implements the encoding.TextUnmarshaler interface.

type Condition

type Condition struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name      string     `mapstructure:"name"`
	Comment   string     `mapstructure:"comment"`
	Statement string     `mapstructure:"statement"`
	Type      string     `mapstructure:"type"`
	Priority  int        `mapstructure:"priority"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
}

Condition represents a condition response from the Fastly API.

type ConfigSetWAFs added in v0.4.3

type ConfigSetWAFs struct {
	ID string `jsonapi:"primary,waf"`
}

ConfigSetWAFs used to store the ID of a WAF needed to update config set relationships

type Coordinates added in v1.17.0

type Coordinates struct {
	Latitude   float64 `mapstructure:"latitude"`
	Longtitude float64 `mapstructure:"longitude"`
	X          float64 `mapstructure:"x"`
	Y          float64 `mapstructure:"y"`
}

Coordinates represent the location of a datacenter.

type CreateACLEntryInput added in v0.4.0

type CreateACLEntryInput struct {
	// Required fields
	Service string
	ACL     string
	IP      string `form:"ip"`

	// Optional fields
	Subnet  string `form:"subnet,omitempty"`
	Negated bool   `form:"negated,omitempty"`
	Comment string `form:"comment,omitempty"`
}

CreateACLEntryInput the input parameter to CreateACLEntry function.

type CreateACLInput added in v0.4.0

type CreateACLInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the ACL to create (required)
	Name string `form:"name"`
}

CreateACLInput is used as input to the CreateACL function.

type CreateBackendInput

type CreateBackendInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name                string       `form:"name,omitempty"`
	Comment             string       `form:"comment,omitempty"`
	Address             string       `form:"address,omitempty"`
	Port                uint         `form:"port,omitempty"`
	OverrideHost        string       `form:"override_host,omitempty"`
	ConnectTimeout      uint         `form:"connect_timeout,omitempty"`
	MaxConn             uint         `form:"max_conn,omitempty"`
	ErrorThreshold      uint         `form:"error_threshold,omitempty"`
	FirstByteTimeout    uint         `form:"first_byte_timeout,omitempty"`
	BetweenBytesTimeout uint         `form:"between_bytes_timeout,omitempty"`
	AutoLoadbalance     *Compatibool `form:"auto_loadbalance,omitempty"`
	Weight              uint         `form:"weight,omitempty"`
	RequestCondition    string       `form:"request_condition,omitempty"`
	HealthCheck         string       `form:"healthcheck,omitempty"`
	Shield              string       `form:"shield,omitempty"`
	UseSSL              *Compatibool `form:"use_ssl,omitempty"`
	SSLCheckCert        *Compatibool `form:"ssl_check_cert,omitempty"`
	SSLCACert           string       `form:"ssl_ca_cert,omitempty"`
	SSLClientCert       string       `form:"ssl_client_cert,omitempty"`
	SSLClientKey        string       `form:"ssl_client_key,omitempty"`
	SSLHostname         string       `form:"ssl_hostname,omitempty"`
	SSLCertHostname     string       `form:"ssl_cert_hostname,omitempty"`
	SSLSNIHostname      string       `form:"ssl_sni_hostname,omitempty"`
	MinTLSVersion       string       `form:"min_tls_version,omitempty"`
	MaxTLSVersion       string       `form:"max_tls_version,omitempty"`
	SSLCiphers          []string     `form:"ssl_ciphers,omitempty"`
}

CreateBackendInput is used as input to the CreateBackend function.

type CreateBigQueryInput added in v0.4.3

type CreateBigQueryInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string `form:"name,omitempty"`
	ProjectID         string `form:"project_id,omitempty"`
	Dataset           string `form:"dataset,omitempty"`
	Table             string `form:"table,omitempty"`
	Template          string `form:"template_suffix,omitempty"`
	User              string `form:"user,omitempty"`
	SecretKey         string `form:"secret_key,omitempty"`
	Format            string `form:"format,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	Placement         string `form:"placement,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
}

CreateBigQueryInput is used as input to the CreateBigQuery function.

type CreateBlobStorageInput added in v0.4.3

type CreateBlobStorageInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string `form:"name,omitempty"`
	Path              string `form:"path,omitempty"`
	AccountName       string `form:"account_name,omitempty"`
	Container         string `form:"container,omitempty"`
	SASToken          string `form:"sas_token,omitempty"`
	Period            uint   `form:"period,omitempty"`
	TimestampFormat   string `form:"timestamp_format,omitempty"`
	GzipLevel         uint   `form:"gzip_level,omitempty"`
	PublicKey         string `form:"public_key,omitempty"`
	Format            string `form:"format,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
	MessageType       string `form:"message_type,omitempty"`
	Placement         string `form:"placement,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
}

CreateBlobStorageInput is used as input to the CreateBlobStorage function.

type CreateBulkCertificateInput added in v0.16.0

type CreateBulkCertificateInput struct {
	CertBlob          string              `jsonapi:"attr,cert_blob"`
	IntermediatesBlob string              `jsonapi:"attr,intermediates_blob"`
	TLSConfigurations []*TLSConfiguration `jsonapi:"relation,tls_configurations,tls_configuration"`
}

CreateBulkCertificateInput is used as input to the CreateBulkCertificate function.

type CreateCacheSettingInput

type CreateCacheSettingInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name           string             `form:"name,omitempty"`
	Action         CacheSettingAction `form:"action,omitempty"`
	TTL            uint               `form:"ttl,omitempty"`
	StaleTTL       uint               `form:"stale_ttl,omitempty"`
	CacheCondition string             `form:"cache_condition,omitempty"`
}

CreateCacheSettingInput is used as input to the CreateCacheSetting function.

type CreateCloudfilesInput added in v0.16.0

type CreateCloudfilesInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	User              *string `form:"user,omitempty"`
	AccessKey         *string `form:"access_key,omitempty"`
	BucketName        *string `form:"bucket_name,omitempty"`
	Path              *string `form:"path,omitempty"`
	Region            *string `form:"region,omitempty"`
	Placement         *string `form:"placement,omitempty"`
	Period            *uint   `form:"period,omitempty"`
	GzipLevel         *uint   `form:"gzip_level,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	MessageType       *string `form:"message_type,omitempty"`
	TimestampFormat   *string `form:"timestamp_format,omitempty"`
	PublicKey         *string `form:"public_key,omitempty"`
}

CreateCloudfilesInput is used as input to the CreateCloudfiles function.

type CreateConditionInput

type CreateConditionInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name      string `form:"name,omitempty"`
	Statement string `form:"statement,omitempty"`
	Type      string `form:"type,omitempty"`
	Priority  int    `form:"priority,omitempty"`
}

CreateConditionInput is used as input to the CreateCondition function.

type CreateDatadogInput added in v0.16.0

type CreateDatadogInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	Token             *string `form:"token,omitempty"`
	Region            *string `form:"region,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

CreateDatadogInput is used as input to the CreateDatadog function.

type CreateDictionaryInput

type CreateDictionaryInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name      string       `form:"name,omitempty"`
	WriteOnly *Compatibool `form:"write_only,omitempty"`
}

CreateDictionaryInput is used as input to the CreateDictionary function.

type CreateDictionaryItemInput

type CreateDictionaryItemInput struct {
	// Service is the ID of the service. Dictionary is the ID of the dictionary.
	// Both fields are required.
	Service    string
	Dictionary string

	ItemKey   string `form:"item_key,omitempty"`
	ItemValue string `form:"item_value,omitempty"`
}

CreateDictionaryItemInput is used as input to the CreateDictionaryItem function.

type CreateDigitalOceanInput added in v0.16.0

type CreateDigitalOceanInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	BucketName        *string `form:"bucket_name,omitempty"`
	Domain            *string `form:"domain,omitempty"`
	AccessKey         *string `form:"access_key,omitempty"`
	SecretKey         *string `form:"secret_key,omitempty"`
	Path              *string `form:"path,omitempty"`
	Period            *uint   `form:"period,omitempty"`
	GzipLevel         *uint   `form:"gzip_level,omitempty"`
	Format            *string `form:"format,omitempty"`
	MessageType       *string `form:"message_type,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	TimestampFormat   *string `form:"timestamp_format,omitempty"`
	Placement         *string `form:"placement,omitempty"`
	PublicKey         *string `form:"public_key,omitempty"`
}

CreateDigitalOceanInput is used as input to the CreateDigitalOcean function.

type CreateDirectorBackendInput

type CreateDirectorBackendInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Director is the name of the director (required).
	Director string

	// Backend is the name of the backend (required).
	Backend string
}

CreateDirectorBackendInput is used as input to the CreateDirectorBackend function.

type CreateDirectorInput

type CreateDirectorInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name     string       `form:"name,omitempty"`
	Comment  string       `form:"comment,omitempty"`
	Shield   string       `form:"shield,omitempty"`
	Quorum   uint         `form:"quorum,omitempty"`
	Type     DirectorType `form:"type,omitempty"`
	Retries  uint         `form:"retries,omitempty"`
	Capacity uint         `form:"capacity,omitempty"`
}

CreateDirectorInput is used as input to the CreateDirector function.

type CreateDomainInput

type CreateDomainInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the domain that the service will respond to (required).
	Name string `form:"name"`

	// Comment is a personal, freeform descriptive note.
	Comment string `form:"comment,omitempty"`
}

CreateDomainInput is used as input to the CreateDomain function.

type CreateElasticsearchInput added in v0.16.0

type CreateElasticsearchInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Format            *string `form:"format,omitempty"`
	Index             *string `form:"index,omitempty"`
	URL               *string `form:"url,omitempty"`
	Pipeline          *string `form:"pipeline,omitempty"`
	User              *string `form:"user,omitempty"`
	Password          *string `form:"password,omitempty"`
	RequestMaxEntries *uint   `form:"request_max_entries,omitempty"`
	RequestMaxBytes   *uint   `form:"request_max_bytes,omitempty"`
	Placement         *string `form:"placement,omitempty"`
	TLSCACert         *string `form:"tls_ca_cert,omitempty"`
	TLSClientCert     *string `form:"tls_client_cert,omitempty"`
	TLSClientKey      *string `form:"tls_client_key,omitempty"`
	TLSHostname       *string `form:"tls_hostname,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
}

CreateElasticsearchInput is used as input to the CreateElasticsearch function.

type CreateFTPInput

type CreateFTPInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string `form:"name,omitempty"`
	Address           string `form:"address,omitempty"`
	Port              uint   `form:"port,omitempty"`
	Username          string `form:"user,omitempty"`
	Password          string `form:"password,omitempty"`
	PublicKey         string `form:"public_key,omitempty"`
	Path              string `form:"path,omitempty"`
	Period            uint   `form:"period,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
	GzipLevel         uint8  `form:"gzip_level,omitempty"`
	Format            string `form:"format,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	MessageType       string `form:"message_type,omitempty"`
	TimestampFormat   string `form:"timestamp_format,omitempty"`
	Placement         string `form:"placement,omitempty"`
}

CreateFTPInput is used as input to the CreateFTP function.

type CreateGCSInput

type CreateGCSInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string `form:"name,omitempty"`
	Bucket            string `form:"bucket_name,omitempty"`
	User              string `form:"user,omitempty"`
	SecretKey         string `form:"secret_key,omitempty"`
	Path              string `form:"path,omitempty"`
	Period            uint   `form:"period,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
	GzipLevel         uint8  `form:"gzip_level,omitempty"`
	Format            string `form:"format,omitempty"`
	MessageType       string `form:"message_type,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	TimestampFormat   string `form:"timestamp_format,omitempty"`
	Placement         string `form:"placement,omitempty"`
}

CreateGCSInput is used as input to the CreateGCS function.

type CreateGzipInput

type CreateGzipInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name           string `form:"name,omitempty"`
	ContentTypes   string `form:"content_types"`
	Extensions     string `form:"extensions"`
	CacheCondition string `form:"cache_condition,omitempty"`
}

CreateGzipInput is used as input to the CreateGzip function.

type CreateHTTPSInput added in v0.16.0

type CreateHTTPSInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string `form:"name,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	Format            string `form:"format,omitempty"`
	URL               string `form:"url,omitempty"`
	RequestMaxEntries uint   `form:"request_max_entries,omitempty"`
	RequestMaxBytes   uint   `form:"request_max_bytes,omitempty"`
	ContentType       string `form:"content_type,omitempty"`
	HeaderName        string `form:"header_name,omitempty"`
	HeaderValue       string `form:"header_value,omitempty"`
	Method            string `form:"method,omitempty"`
	JSONFormat        string `form:"json_format,omitempty"`
	Placement         string `form:"placement,omitempty"`
	TLSCACert         string `form:"tls_ca_cert,omitempty"`
	TLSClientCert     string `form:"tls_client_cert,omitempty"`
	TLSClientKey      string `form:"tls_client_key,omitempty"`
	TLSHostname       string `form:"tls_hostname,omitempty"`
	MessageType       string `form:"message_type,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
}

CreateHTTPSInput is used as input to the CreateHTTPS function.

type CreateHeaderInput

type CreateHeaderInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string       `form:"name,omitempty"`
	Action            HeaderAction `form:"action,omitempty"`
	IgnoreIfSet       *Compatibool `form:"ignore_if_set,omitempty"`
	Type              HeaderType   `form:"type,omitempty"`
	Destination       string       `form:"dst,omitempty"`
	Source            string       `form:"src,omitempty"`
	Regex             string       `form:"regex,omitempty"`
	Substitution      string       `form:"substitution,omitempty"`
	Priority          uint         `form:"priority,omitempty"`
	RequestCondition  string       `form:"request_condition,omitempty"`
	CacheCondition    string       `form:"cache_condition,omitempty"`
	ResponseCondition string       `form:"response_condition,omitempty"`
}

CreateHeaderInput is used as input to the CreateHeader function.

type CreateHealthCheckInput

type CreateHealthCheckInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name             string `form:"name,omitempty"`
	Comment          string `form:"comment,omitempty"`
	Method           string `form:"method,omitempty"`
	Host             string `form:"host,omitempty"`
	Path             string `form:"path,omitempty"`
	HTTPVersion      string `form:"http_version,omitempty"`
	Timeout          uint   `form:"timeout,omitempty"`
	CheckInterval    uint   `form:"check_interval,omitempty"`
	ExpectedResponse uint   `form:"expected_response,omitempty"`
	Window           uint   `form:"window,omitempty"`
	Threshold        uint   `form:"threshold,omitempty"`
	Initial          uint   `form:"initial,omitempty"`
}

CreateHealthCheckInput is used as input to the CreateHealthCheck function.

type CreateHerokuInput added in v0.16.0

type CreateHerokuInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	URL               *string `form:"url,omitempty"`
	Token             *string `form:"token,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

CreateHerokuInput is used as input to the CreateHeroku function.

type CreateHoneycombInput added in v0.16.0

type CreateHoneycombInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	Dataset           *string `form:"dataset,omitempty"`
	Token             *string `form:"token,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

CreateHoneycombInput is used as input to the CreateHoneycomb function.

type CreateKafkaInput added in v0.16.0

type CreateKafkaInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string      `form:"name,omitempty"`
	Brokers           *string      `form:"brokers,omitempty"`
	Topic             *string      `form:"topic,omitempty"`
	RequiredACKs      *string      `form:"required_acks,omitempty"`
	UseTLS            *Compatibool `form:"use_tls,omitempty"`
	CompressionCodec  *string      `form:"compression_codec,omitempty"`
	Format            *string      `form:"format,omitempty"`
	FormatVersion     *uint        `form:"format_version,omitempty"`
	ResponseCondition *string      `form:"response_condition,omitempty"`
	Placement         *string      `form:"placement,omitempty"`
	TLSCACert         *string      `form:"tls_ca_cert,omitempty"`
	TLSHostname       *string      `form:"tls_hostname,omitempty"`
	TLSClientCert     *string      `form:"tls_client_cert,omitempty"`
	TLSClientKey      *string      `form:"tls_client_key,omitempty"`
	ParseLogKeyvals   *Compatibool `form:"parse_log_keyvals,omitempty"`
	RequestMaxBytes   *uint        `form:"request_max_bytes,omitempty"`
	AuthMethod        *string      `form:"auth_method,omitempty"`
	User              *string      `form:"user,omitempty"`
	Password          *string      `form:"password,omitempty"`
}

CreateKafkaInput is used as input to the CreateKafka function.

type CreateLogentriesInput

type CreateLogentriesInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string       `form:"name,omitempty"`
	Port              uint         `form:"port,omitempty"`
	UseTLS            *Compatibool `form:"use_tls,omitempty"`
	Token             string       `form:"token,omitempty"`
	Format            string       `form:"format,omitempty"`
	FormatVersion     uint         `form:"format_version,omitempty"`
	ResponseCondition string       `form:"response_condition,omitempty"`
	Placement         string       `form:"placement,omitempty"`
}

CreateLogentriesInput is used as input to the CreateLogentries function.

type CreateLogglyInput added in v0.16.0

type CreateLogglyInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	Token             *string `form:"token,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

CreateLogglyInput is used as input to the CreateLoggly function.

type CreateLogshuttleInput added in v0.16.0

type CreateLogshuttleInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	URL               *string `form:"url,omitempty"`
	Token             *string `form:"token,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

CreateLogshuttleInput is used as input to the CreateLogshuttle function.

type CreateNewRelicInput added in v0.16.0

type CreateNewRelicInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	Token             *string `form:"token,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

CreateNewRelicInput is used as input to the CreateNewRelic function.

type CreateOWASPInput added in v0.4.3

type CreateOWASPInput struct {
	// Service is the ID of the service. ID is the ID of the firewall.
	// Both fields are required.
	Service string
	ID      string `jsonapi:"primary,owasp"`
	Type    string `jsonapi:"attr,type"`
}

CreateOWASPInput is used as input to the CreateOWASP function.

type CreateOpenstackInput added in v0.16.0

type CreateOpenstackInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	User              *string `form:"user,omitempty"`
	AccessKey         *string `form:"access_key,omitempty"`
	BucketName        *string `form:"bucket_name,omitempty"`
	URL               *string `form:"url,omitempty"`
	Path              *string `form:"path,omitempty"`
	Placement         *string `form:"placement,omitempty"`
	Period            *uint   `form:"period,omitempty"`
	GzipLevel         *uint   `form:"gzip_level,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	MessageType       *string `form:"message_type,omitempty"`
	TimestampFormat   *string `form:"timestamp_format,omitempty"`
	PublicKey         *string `form:"public_key,omitempty"`
}

CreateOpenstackInput is used as input to the CreateOpenstack function.

type CreatePapertrailInput

type CreatePapertrailInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string     `form:"name,omitempty"`
	Address           string     `form:"address,omitempty"`
	Port              uint       `form:"port,omitempty"`
	FormatVersion     uint       `form:"format_version,omitempty"`
	Format            string     `form:"format,omitempty"`
	ResponseCondition string     `form:"response_condition,omitempty"`
	CreatedAt         *time.Time `form:"created_at,omitempty"`
	UpdatedAt         *time.Time `form:"updated_at,omitempty"`
	DeletedAt         *time.Time `form:"deleted_at,omitempty"`
	Placement         string     `form:"placement,omitempty"`
}

CreatePapertrailInput is used as input to the CreatePapertrail function.

type CreatePoolInput added in v0.16.0

type CreatePoolInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the pool to create (required).
	Name string `form:"name"`

	// Optional fields.
	Comment          *string      `form:"comment,omitempty"`
	Shield           *string      `form:"shield,omitempty"`
	RequestCondition *string      `form:"request_condition,omitempty"`
	MaxConnDefault   *uint        `form:"max_conn_default,omitempty"`
	ConnectTimeout   *uint        `form:"connect_timeout,omitempty"`
	FirstByteTimeout *uint        `form:"first_byte_timeout,omitempty"`
	Quorum           *uint        `form:"quorum,omitempty"`
	UseTLS           *Compatibool `form:"use_tls,omitempty"`
	TLSCACert        *string      `form:"tls_ca_cert,omitempty"`
	TLSCiphers       *string      `form:"tls_ciphers,omitempty"`
	TLSClientKey     *string      `form:"tls_client_key,omitempty"`
	TLSClientCert    *string      `form:"tls_client_cert,omitempty"`
	TLSSNIHostname   *string      `form:"tls_sni_hostname,omitempty"`
	TLSCheckCert     *Compatibool `form:"tls_check_cert,omitempty"`
	TLSCertHostname  *string      `form:"tls_cert_hostname,omitempty"`
	MinTLSVersion    *string      `form:"min_tls_version,omitempty"`
	MaxTLSVersion    *string      `form:"max_tls_version,omitempty"`
	Healthcheck      *string      `form:"healthcheck,omitempty"`
	Type             PoolType     `form:"type,omitempty"`
	OverrideHost     *string      `form:"override_host,omitempty"`
}

CreatePoolInput is used as input to the CreatePool function.

type CreatePrivateKeyInput added in v0.16.0

type CreatePrivateKeyInput struct {
	Key  string `jsonapi:"attr,key,omitempty"`
	Name string `jsonapi:"attr,name,omitempty"`
}

CreatePrivateKeyInput is used as input to the CreatePrivateKey function.

type CreatePubsubInput added in v0.16.0

type CreatePubsubInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	Topic             *string `form:"topic,omitempty"`
	User              *string `form:"user,omitempty"`
	SecretKey         *string `form:"secret_key,omitempty"`
	ProjectID         *string `form:"project_id,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	Format            *string `form:"format,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

CreatePubsubInput is used as input to the CreatePubsub function.

type CreateRequestSettingInput

type CreateRequestSettingInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name             string               `form:"name,omitempty"`
	ForceMiss        *Compatibool         `form:"force_miss,omitempty"`
	ForceSSL         *Compatibool         `form:"force_ssl,omitempty"`
	Action           RequestSettingAction `form:"action,omitempty"`
	BypassBusyWait   *Compatibool         `form:"bypass_busy_wait,omitempty"`
	MaxStaleAge      uint                 `form:"max_stale_age,omitempty"`
	HashKeys         string               `form:"hash_keys,omitempty"`
	XForwardedFor    RequestSettingXFF    `form:"xff,omitempty"`
	TimerSupport     *Compatibool         `form:"timer_support,omitempty"`
	GeoHeaders       *Compatibool         `form:"geo_headers,omitempty"`
	DefaultHost      string               `form:"default_host,omitempty"`
	RequestCondition string               `form:"request_condition,omitempty"`
}

CreateRequestSettingInput is used as input to the CreateRequestSetting function.

type CreateResponseObjectInput

type CreateResponseObjectInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name             string `form:"name,omitempty"`
	Status           uint   `form:"status,omitempty"`
	Response         string `form:"response,omitempty"`
	Content          string `form:"content,omitempty"`
	ContentType      string `form:"content_type,omitempty"`
	RequestCondition string `form:"request_condition,omitempty"`
	CacheCondition   string `form:"cache_condition,omitempty"`
}

CreateResponseObjectInput is used as input to the CreateResponseObject function.

type CreateS3Input

type CreateS3Input struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name                         string                 `form:"name,omitempty"`
	BucketName                   string                 `form:"bucket_name,omitempty"`
	Domain                       string                 `form:"domain,omitempty"`
	AccessKey                    string                 `form:"access_key,omitempty"`
	SecretKey                    string                 `form:"secret_key,omitempty"`
	Path                         string                 `form:"path,omitempty"`
	Period                       uint                   `form:"period,omitempty"`
	GzipLevel                    uint                   `form:"gzip_level,omitempty"`
	Format                       string                 `form:"format,omitempty"`
	MessageType                  string                 `form:"message_type,omitempty"`
	FormatVersion                uint                   `form:"format_version,omitempty"`
	ResponseCondition            string                 `form:"response_condition,omitempty"`
	TimestampFormat              string                 `form:"timestamp_format,omitempty"`
	Redundancy                   S3Redundancy           `form:"redundancy,omitempty"`
	Placement                    string                 `form:"placement,omitempty"`
	PublicKey                    string                 `form:"public_key,omitempty"`
	ServerSideEncryptionKMSKeyID string                 `form:"server_side_encryption_kms_key_id,omitempty"`
	ServerSideEncryption         S3ServerSideEncryption `form:"server_side_encryption,omitempty"`
}

CreateS3Input is used as input to the CreateS3 function.

type CreateSFTPInput added in v0.16.0

type CreateSFTPInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	Address           *string `form:"address,omitempty"`
	Port              *uint   `form:"port,omitempty"`
	User              *string `form:"user,omitempty"`
	Password          *string `form:"password,omitempty"`
	PublicKey         *string `form:"public_key,omitempty"`
	SecretKey         *string `form:"secret_key,omitempty"`
	SSHKnownHosts     *string `form:"ssh_known_hosts,omitempty"`
	Path              *string `form:"path,omitempty"`
	Period            *uint   `form:"period,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	GzipLevel         *uint   `form:"gzip_level,omitempty"`
	Format            *string `form:"format,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	TimestampFormat   *string `form:"timestamp_format,omitempty"`
	MessageType       *string `form:"message_type,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

CreateSFTPInput is used as input to the CreateSFTP function.

type CreateScalyrInput added in v0.16.0

type CreateScalyrInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              *string `form:"name,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	Token             *string `form:"token,omitempty"`
	Region            *string `form:"region,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

CreateScalyrInput is used as input to the CreateScalyr function.

type CreateServerInput added in v0.16.0

type CreateServerInput struct {
	// Service is the ID of the service. Pool is the ID of the pool. Both
	// fields are required.
	Service string
	Pool    string

	// Address is the hostname or IP of the origin server (required).
	Address string `form:"address"`

	// Optional fields.
	Comment      *string `form:"comment,omitempty"`
	Weight       *uint   `form:"weight,omitempty"`
	MaxConn      *uint   `form:"max_conn,omitempty"`
	Port         *uint   `form:"port,omitempty"`
	Disabled     *bool   `form:"disabled,omitempty"`
	OverrideHost *string `form:"override_host,omitempty"`
}

CreateServerInput is used as input to the CreateServer function.

type CreateServiceInput

type CreateServiceInput struct {
	Name    string `form:"name,omitempty"`
	Type    string `form:"type,omitempty"`
	Comment string `form:"comment,omitempty"`
}

CreateServiceInput is used as input to the CreateService function.

type CreateSnippetInput added in v0.4.3

type CreateSnippetInput struct {
	// Service is the ID of the Service to add the snippet to.
	Service string

	// Version is the editable version of the service
	Version int

	// Name is the name for the snippet.
	Name string `form:"name"`

	// Priority determines the ordering for multiple snippets. Lower numbers execute first.
	Priority int `form:"priority"`

	// Dynamic sets the snippet version to regular (0) or dynamic (1).
	Dynamic int `form:"dynamic"`

	// Content is the VCL code that specifies exactly what the snippet does.
	Content string `form:"content"`

	// Type is the location in generated VCL where the snippet should be placed.
	Type SnippetType `form:"type"`
}

CreateSnippetInput is the input for CreateSnippet

type CreateSplunkInput added in v0.4.3

type CreateSplunkInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string `form:"name,omitempty"`
	URL               string `form:"url,omitempty"`
	Format            string `form:"format,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	Placement         string `form:"placement,omitempty"`
	Token             string `form:"token,omitempty"`
	TLSCACert         string `form:"tls_ca_cert,omitempty"`
	TLSHostname       string `form:"tls_hostname,omitempty"`
}

CreateSplunkInput is used as input to the CreateSplunk function.

type CreateSumologicInput

type CreateSumologicInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string `form:"name,omitempty"`
	Address           string `form:"address,omitempty"`
	URL               string `form:"url,omitempty"`
	Format            string `form:"format,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	MessageType       string `form:"message_type,omitempty"`
	FormatVersion     int    `form:"format_version,omitempty"`
	Placement         string `form:"placement,omitempty"`
}

CreateSumologicInput is used as input to the CreateSumologic function.

type CreateSyslogInput

type CreateSyslogInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name              string       `form:"name,omitempty"`
	Address           string       `form:"address,omitempty"`
	Hostname          string       `form:"hostname,omitempty"`
	Port              uint         `form:"port,omitempty"`
	UseTLS            *Compatibool `form:"use_tls,omitempty"`
	IPV4              string       `form:"ipv4,omitempty"`
	TLSCACert         string       `form:"tls_ca_cert,omitempty"`
	TLSHostname       string       `form:"tls_hostname,omitempty"`
	TLSClientCert     string       `form:"tls_client_cert,omitempty"`
	TLSClientKey      string       `form:"tls_client_key,omitempty"`
	Token             string       `form:"token,omitempty"`
	Format            string       `form:"format,omitempty"`
	FormatVersion     uint         `form:"format_version,omitempty"`
	MessageType       string       `form:"message_type,omitempty"`
	ResponseCondition string       `form:"response_condition,omitempty"`
	Placement         string       `form:"placement,omitempty"`
}

CreateSyslogInput is used as input to the CreateSyslog function.

type CreateTokenInput added in v0.16.0

type CreateTokenInput struct {
	Name      string     `form:"name,omitempty"`
	Scope     TokenScope `form:"scope,omitempty"`
	Username  string     `form:"username,omitempty"`
	Password  string     `form:"password,omitempty"`
	Services  []string   `form:"services,omitempty"`
	ExpiresAt *time.Time `form:"expires_at,omitempty"`
}

CreateTokenInput is used as input to the Token function.

type CreateUserInput added in v0.16.0

type CreateUserInput struct {
	Login string `form:"login"`
	Name  string `form:"name"`

	Role string `form:"role,omitempty"`
}

CreateUserInput is used as input to the CreateUser function.

type CreateVCLInput

type CreateVCLInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	Name    string `form:"name,omitempty"`
	Content string `form:"content,omitempty"`
	Main    bool   `form:"main,omitempty"`
}

CreateVCLInput is used as input to the CreateVCL function.

type CreateVersionInput

type CreateVersionInput struct {
	// Service is the ID of the service (required).
	Service string

	// A personal freeform descriptive note.
	Comment string `form:"comment,omitempty"`
}

CreateVersionInput is the input to the CreateVersion function.

type CreateWAFInput added in v0.4.2

type CreateWAFInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	ID                string `jsonapi:"primary,waf"`
	PrefetchCondition string `jsonapi:"attr,prefetch_condition,omitempty"`
	Response          string `jsonapi:"attr,response,omitempty"`
}

CreateWAFInput is used as input to the CreateWAF function.

type Datacenter added in v1.17.0

type Datacenter struct {
	Code        string      `mapstructure:"code"`
	Coordinates Coordinates `mapstructure:"coordinates"`
	Group       string      `mapstructure:"group"`
	Name        string      `mapstructure:"name"`
	Shield      string      `mapstructure:"shield"`
}

Datacenter is a list of Datacenters returned by the Fastly API.

type Datadog added in v0.16.0

type Datadog struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Token             string     `mapstructure:"token"`
	Region            string     `mapstructure:"region"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Datadog represents a Datadog response from the Fastly API.

type DeactivateVersionInput

type DeactivateVersionInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int
}

DeactivateVersionInput is the input to the DeactivateVersion function.

type DeleteACLEntryInput added in v0.4.0

type DeleteACLEntryInput struct {
	Service string
	ACL     string
	ID      string
}

DeleteACLEntryInput the input parameter to DeleteACLEntry function.

type DeleteACLInput added in v0.4.0

type DeleteACLInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the ACL to delete (required).
	Name string
}

DeleteACLInput is the input parameter to DeleteACL function.

type DeleteBackendInput

type DeleteBackendInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the backend to delete (required).
	Name string
}

DeleteBackendInput is the input parameter to DeleteBackend.

type DeleteBigQueryInput added in v0.4.3

type DeleteBigQueryInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the BigQuery to delete (required).
	Name string
}

DeleteBigQueryInput is the input parameter to DeleteBigQuery.

type DeleteBlobStorageInput added in v0.4.3

type DeleteBlobStorageInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the blob storage to delete (required).
	Name string
}

DeleteBlobStorageInput is the input parameter to DeleteBlobStorage.

type DeleteBulkCertificateInput added in v0.16.0

type DeleteBulkCertificateInput struct {
	ID string
}

DeleteBulkCertificateInput used for deleting a certificate.

type DeleteCacheSettingInput

type DeleteCacheSettingInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the cache setting to delete (required).
	Name string
}

DeleteCacheSettingInput is the input parameter to DeleteCacheSetting.

type DeleteCloudfilesInput added in v0.16.0

type DeleteCloudfilesInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Cloudfiles to delete (required).
	Name string
}

DeleteCloudfilesInput is the input parameter to DeleteCloudfiles.

type DeleteConditionInput

type DeleteConditionInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the condition to delete (required).
	Name string
}

DeleteConditionInput is the input parameter to DeleteCondition.

type DeleteDatadogInput added in v0.16.0

type DeleteDatadogInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Datadog to delete (required).
	Name string
}

DeleteDatadogInput is the input parameter to DeleteDatadog.

type DeleteDictionaryInput

type DeleteDictionaryInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the dictionary to delete (required).
	Name string
}

DeleteDictionaryInput is the input parameter to DeleteDictionary.

type DeleteDictionaryItemInput

type DeleteDictionaryItemInput struct {
	// Service is the ID of the service. Dictionary is the ID of the dictionary.
	// Both fields are required.
	Service    string
	Dictionary string

	// ItemKey is the name of the dictionary item to delete.
	ItemKey string
}

DeleteDictionaryItemInput is the input parameter to DeleteDictionaryItem.

type DeleteDigitalOceanInput added in v0.16.0

type DeleteDigitalOceanInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the DigitalOcean to delete (required).
	Name string
}

DeleteDigitalOceanInput is the input parameter to DeleteDigitalOcean.

type DeleteDirectorBackendInput

type DeleteDirectorBackendInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Director is the name of the director (required).
	Director string

	// Backend is the name of the backend (required).
	Backend string
}

DeleteDirectorBackendInput is the input parameter to DeleteDirectorBackend.

type DeleteDirectorInput

type DeleteDirectorInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the director to delete (required).
	Name string
}

DeleteDirectorInput is the input parameter to DeleteDirector.

type DeleteDomainInput

type DeleteDomainInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the domain that the service will respond to (required).
	Name string `form:"name"`
}

DeleteDomainInput is used as input to the DeleteDomain function.

type DeleteElasticsearchInput added in v0.16.0

type DeleteElasticsearchInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Elasticsearch endpoint to fetch.
	Name string
}

type DeleteFTPInput

type DeleteFTPInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the FTP to delete (required).
	Name string
}

DeleteFTPInput is the input parameter to DeleteFTP.

type DeleteGCSInput

type DeleteGCSInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the GCS to delete (required).
	Name string
}

DeleteGCSInput is the input parameter to DeleteGCS.

type DeleteGzipInput

type DeleteGzipInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Gzip to delete (required).
	Name string
}

DeleteGzipInput is the input parameter to DeleteGzip.

type DeleteHTTPSInput added in v0.16.0

type DeleteHTTPSInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the HTTPS endpoint to fetch.
	Name string
}

type DeleteHeaderInput

type DeleteHeaderInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the header to delete (required).
	Name string
}

DeleteHeaderInput is the input parameter to DeleteHeader.

type DeleteHealthCheckInput

type DeleteHealthCheckInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the health check to delete (required).
	Name string
}

DeleteHealthCheckInput is the input parameter to DeleteHealthCheck.

type DeleteHerokuInput added in v0.16.0

type DeleteHerokuInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the heroku to delete (required).
	Name string
}

DeleteHerokuInput is the input parameter to DeleteHeroku.

type DeleteHoneycombInput added in v0.16.0

type DeleteHoneycombInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the honeycomb to delete (required).
	Name string
}

DeleteHoneycombInput is the input parameter to DeleteHoneycomb.

type DeleteKafkaInput added in v0.16.0

type DeleteKafkaInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the kafka to delete (required).
	Name string
}

DeleteKafkaInput is the input parameter to DeleteKafka.

type DeleteLogentriesInput

type DeleteLogentriesInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the logentries to delete (required).
	Name string
}

DeleteLogentriesInput is the input parameter to DeleteLogentries.

type DeleteLogglyInput added in v0.16.0

type DeleteLogglyInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the loggly to delete (required).
	Name string
}

DeleteLogglyInput is the input parameter to DeleteLoggly.

type DeleteLogshuttleInput added in v0.16.0

type DeleteLogshuttleInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the logshuttle to delete (required).
	Name string
}

DeleteLogshuttleInput is the input parameter to DeleteLogshuttle.

type DeleteNewRelicInput added in v0.16.0

type DeleteNewRelicInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the newrelic to delete (required).
	Name string
}

DeleteNewRelicInput is the input parameter to DeleteNewRelic.

type DeleteOpenstackInput added in v0.16.0

type DeleteOpenstackInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Openstack to delete (required).
	Name string
}

DeleteOpenstackInput is the input parameter to DeleteOpenstack.

type DeletePapertrailInput

type DeletePapertrailInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the papertrail to delete (required).
	Name string
}

DeletePapertrailInput is the input parameter to DeletePapertrail.

type DeletePoolInput added in v0.16.0

type DeletePoolInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Name is the name of the pool to delete. All three fields
	// are required.
	Service string
	Version int
	Name    string
}

DeletePoolInput is used as input to the DeletePool function.

type DeletePrivateKeyInput added in v0.16.0

type DeletePrivateKeyInput struct {
	ID string
}

DeletePrivateKeyInput used for deleting a private key.

type DeletePubsubInput added in v0.16.0

type DeletePubsubInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Pubsub to delete (required).
	Name string
}

DeletePubsubInput is the input parameter to DeletePubsub.

type DeleteRequestSettingInput

type DeleteRequestSettingInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the request settings to delete (required).
	Name string
}

DeleteRequestSettingInput is the input parameter to DeleteRequestSetting.

type DeleteResponseObjectInput

type DeleteResponseObjectInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the response object to delete (required).
	Name string
}

DeleteResponseObjectInput is the input parameter to DeleteResponseObject.

type DeleteS3Input

type DeleteS3Input struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the S3 to delete (required).
	Name string
}

DeleteS3Input is the input parameter to DeleteS3.

type DeleteSFTPInput added in v0.16.0

type DeleteSFTPInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the SFTP to delete (required).
	Name string
}

DeleteSFTPInput is the input parameter to DeleteSFTP.

type DeleteScalyrInput added in v0.16.0

type DeleteScalyrInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the scalyr to delete (required).
	Name string
}

DeleteScalyrInput is the input parameter to DeleteScalyr.

type DeleteServerInput added in v0.16.0

type DeleteServerInput struct {
	// Service is the ID of the service. Pool is the ID of the pool. Server is
	// the ID of the server in the Pool. These are required fields.
	Service string
	Pool    string
	Server  string
}

DeleteServerInput is used as input to the DeleteServer function.

type DeleteServiceInput

type DeleteServiceInput struct {
	ID string
}

DeleteServiceInput is used as input to the DeleteService function.

type DeleteSnippetInput added in v0.4.3

type DeleteSnippetInput struct {
	// Service is the ID of the Service to add the snippet to.
	Service string

	// Name is the Name of the Snippet to Delete
	Name string

	// Version is the editable version of the service
	Version int
}

type DeleteSplunkInput added in v0.4.3

type DeleteSplunkInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the splunk to delete (required).
	Name string
}

DeleteSplunkInput is the input parameter to DeleteSplunk.

type DeleteSumologicInput

type DeleteSumologicInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the sumologic to delete (required).
	Name string
}

DeleteSumologicInput is the input parameter to DeleteSumologic.

type DeleteSyslogInput

type DeleteSyslogInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the syslog to delete (required).
	Name string
}

DeleteSyslogInput is the input parameter to DeleteSyslog.

type DeleteTokenInput added in v0.16.0

type DeleteTokenInput struct {
	ID string
}

DeleteTokenInput is used as input to the DeleteToken function.

type DeleteUserInput added in v0.16.0

type DeleteUserInput struct {
	ID string
}

DeleteUserInput is used as input to the DeleteUser function.

type DeleteVCLInput

type DeleteVCLInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the VCL to delete (required).
	Name string
}

DeleteVCLInput is the input parameter to DeleteVCL.

type DeleteWAFInput added in v0.4.2

type DeleteWAFInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// ID is the id of the WAF to delete.
	ID string
}

DeleteWAFInput is used as input to the DeleteWAFInput function.

type Dictionary

type Dictionary struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	ID        string     `mapstructure:"id"`
	Name      string     `mapstructure:"name"`
	WriteOnly bool       `mapstructure:"write_only"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
}

Dictionary represents a dictionary response from the Fastly API.

type DictionaryInfo added in v0.16.0

type DictionaryInfo struct {
	// LastUpdated is the Time-stamp (GMT) when the dictionary was last updated.
	LastUpdated *time.Time `mapstructure:"last_updated"`

	// Digest is the hash of the dictionary content.
	Digest string `mapstructure:"digest"`

	// ItemCount is the number of items belonging to the dictionary.
	ItemCount int `mapstructure:"item_count"`
}

DictionaryInfo represents a dictionary metadata response from the Fastly API.

type DictionaryItem

type DictionaryItem struct {
	ServiceID    string `mapstructure:"service_id"`
	DictionaryID string `mapstructure:"dictionary_id"`
	ItemKey      string `mapstructure:"item_key"`

	ItemValue string     `mapstructure:"item_value"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
}

DictionaryItem represents a dictionary item response from the Fastly API.

type Diff

type Diff struct {
	Format string `mapstructure:"format"`
	From   int    `mapstructure:"from"`
	To     int    `mapstructure:"to"`
	Diff   string `mapstructure:"diff"`
}

Diff represents a diff of two versions as a response from the Fastly API.

type DigitalOcean added in v0.16.0

type DigitalOcean struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	BucketName        string     `mapstructure:"bucket_name"`
	Domain            string     `mapstructure:"domain"`
	AccessKey         string     `mapstructure:"access_key"`
	SecretKey         string     `mapstructure:"secret_key"`
	Path              string     `mapstructure:"path"`
	Period            uint       `mapstructure:"period"`
	GzipLevel         uint       `mapstructure:"gzip_level"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	MessageType       string     `mapstructure:"message_type"`
	TimestampFormat   string     `mapstructure:"timestamp_format"`
	Placement         string     `mapstructure:"placement"`
	PublicKey         string     `mapstructure:"public_key"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

DigitalOcean represents a DigitalOcean response from the Fastly API.

type Director

type Director struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name      string       `mapstructure:"name"`
	Comment   string       `mapstructure:"comment"`
	Shield    string       `mapstructure:"shield"`
	Quorum    uint         `mapstructure:"quorum"`
	Type      DirectorType `mapstructure:"type"`
	Retries   uint         `mapstructure:"retries"`
	Capacity  uint         `mapstructure:"capacity"`
	CreatedAt *time.Time   `mapstructure:"created_at"`
	UpdatedAt *time.Time   `mapstructure:"updated_at"`
	DeletedAt *time.Time   `mapstructure:"deleted_at"`
}

Director represents a director response from the Fastly API.

type DirectorBackend

type DirectorBackend struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Director  string     `mapstructure:"director_name"`
	Backend   string     `mapstructure:"backend_name"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
}

DirectorBackend is the relationship between a director and a backend in the Fastly API.

type DirectorType

type DirectorType uint8

DirectorType is a type of director.

const (
	// DirectorTypeRandom is a director that does random direction.
	DirectorTypeRandom DirectorType = 1

	// DirectorTypeRoundRobin is a director that does round-robin direction.
	DirectorTypeRoundRobin DirectorType = 2

	// DirectorTypeHash is a director that does hash direction.
	DirectorTypeHash DirectorType = 3

	// DirectorTypeClient is a director that does client direction.
	DirectorTypeClient DirectorType = 4
)

type Domain

type Domain struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name      string     `mapstructure:"name"`
	Comment   string     `mapstructure:"comment"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
}

Domain represents the the domain name Fastly will serve content for.

type DynamicSnippet added in v0.4.3

type DynamicSnippet struct {
	ServiceID string `mapstructure:"service_id"`
	ID        string `mapstructure:"snippet_id"`

	Content   string     `mapstructure:"content"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
}

DynamicSnippet is the object returned when updating or retrieving a Dynamic Snippet

type EdgeCheck

type EdgeCheck struct {
	Hash         string             `mapstructure:"hash"`
	Server       string             `mapstructure:"server"`
	ResponseTime float64            `mapstructure:"response_time"`
	Request      *EdgeCheckRequest  `mapstructure:"request"`
	Response     *EdgeCheckResponse `mapstructure:"response"`
}

EdgeCheck represents an edge check response from the Fastly API.

type EdgeCheckInput

type EdgeCheckInput struct {
	URL string `form:"url,omitempty"`
}

EdgeCheckInput is used as input to the EdgeCheck function.

type EdgeCheckRequest

type EdgeCheckRequest struct {
	URL     string       `mapstructure:"url"`
	Method  string       `mapstructure:"method"`
	Headers *http.Header `mapstructure:"headers"`
}

EdgeCheckRequest is the request part of an EdgeCheck response.

type EdgeCheckResponse

type EdgeCheckResponse struct {
	Status  uint         `mapstructure:"status"`
	Headers *http.Header `mapstructure:"headers"`
}

EdgeCheckResponse is the response part of an EdgeCheck response.

type Elasticsearch added in v0.16.0

type Elasticsearch struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Format            string     `mapstructure:"format"`
	Index             string     `mapstructure:"index"`
	URL               string     `mapstructure:"url"`
	Pipeline          string     `mapstructure:"pipeline"`
	User              string     `mapstructure:"user"`
	Password          string     `mapstructure:"password"`
	RequestMaxEntries uint       `mapstructure:"request_max_entries"`
	RequestMaxBytes   uint       `mapstructure:"request_max_bytes"`
	Placement         string     `mapstructure:"placement"`
	TLSCACert         string     `mapstructure:"tls_ca_cert"`
	TLSClientCert     string     `mapstructure:"tls_client_cert"`
	TLSClientKey      string     `mapstructure:"tls_client_key"`
	TLSHostname       string     `mapstructure:"tls_hostname"`
	FormatVersion     uint       `mapstructure:"format_version"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Elasticsearch represents an Elasticsearch Logging response from the Fastly API.

type ErrorObject added in v0.4.2

type ErrorObject struct {
	ID     string `mapstructure:"id"`
	Title  string `mapstructure:"title"`
	Detail string `mapstructure:"detail"`
	Status string `mapstructure:"status"`
	Code   string `mapstructure:"code"`

	Meta *map[string]interface{} `mapstructure:"meta"`
}

ErrorObject is a single error.

type Event added in v0.4.3

type Event struct {
	ID          string                 `jsonapi:"primary,event"`
	CustomerID  string                 `jsonapi:"attr,customer_id"`
	Description string                 `jsonapi:"attr,description"`
	EventType   string                 `jsonapi:"attr,event_type"`
	IP          string                 `jsonapi:"attr,ip"`
	Metadata    map[string]interface{} `jsonapi:"attr,metadata,omitempty"`
	ServiceID   string                 `jsonapi:"attr,service_id"`
	UserID      string                 `jsonapi:"attr,user_id"`
	CreatedAt   *time.Time             `jsonapi:"attr,created_at,iso8601"`
	Admin       bool                   `jsonapi:"attr,admin"`
}

Events represents an event_logs item response from the Fastly API.

type EventsPaginationInfo added in v0.4.3

type EventsPaginationInfo struct {
	First string `json:"first,omitempty"`
	Last  string `json:"last,omitempty"`
	Next  string `json:"next,omitempty"`
}

EventsPaginationInfo stores links to searches related to the current one, showing any information about additional results being stored on another page

type FTP

type FTP struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Address           string     `mapstructure:"address"`
	Port              uint       `mapstructure:"port"`
	Username          string     `mapstructure:"user"`
	Password          string     `mapstructure:"password"`
	PublicKey         string     `mapstructure:"public_key"`
	Path              string     `mapstructure:"path"`
	Period            uint       `mapstructure:"period"`
	GzipLevel         uint8      `mapstructure:"gzip_level"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	TimestampFormat   string     `mapstructure:"timestamp_format"`
	MessageType       string     `mapstructure:"message_type"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

FTP represents an FTP logging response from the Fastly API.

type GCS

type GCS struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Bucket            string     `mapstructure:"bucket_name"`
	User              string     `mapstructure:"user"`
	SecretKey         string     `mapstructure:"secret_key"`
	Path              string     `mapstructure:"path"`
	Period            uint       `mapstructure:"period"`
	GzipLevel         uint8      `mapstructure:"gzip_level"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	MessageType       string     `mapstructure:"message_type"`
	ResponseCondition string     `mapstructure:"response_condition"`
	TimestampFormat   string     `mapstructure:"timestamp_format"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

GCS represents an GCS logging response from the Fastly API.

type GetACLEntryInput added in v0.4.0

type GetACLEntryInput struct {
	Service string
	ACL     string
	ID      string
}

GetACLEntryInput is the input parameter to GetACLEntry function.

type GetACLInput added in v0.4.0

type GetACLInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the ACL to get (required).
	Name string
}

GetACLInput is the input parameter to GetACL function.

type GetAPIEventInput added in v0.4.3

type GetAPIEventInput struct {
	// EventID is the ID of the event and is required.
	EventID string
}

GetAPIEventInput is used as input to the GetAPIEvent function.

type GetAPIEventsFilterInput added in v0.4.3

type GetAPIEventsFilterInput struct {
	// CustomerID to Limit the returned events to a specific customer.
	CustomerID string

	// ServiceID to Limit the returned events to a specific service.
	ServiceID string

	// EventType to Limit the returned events to a specific event type. See above for event codes.
	EventType string

	// UserID to Limit the returned events to a specific user.
	UserID string

	// Number is the Pagination page number.
	PageNumber int

	// Size is the Number of items to return on each paginated page.
	MaxResults int
}

GetAPIEventsFilter is used as input to the GetAPIEvents function.

type GetAPIEventsResponse added in v0.4.3

type GetAPIEventsResponse struct {
	Events []*Event
	Links  EventsPaginationInfo `json:"links"`
}

GetAPIEventsResponse is the data returned to the user from a GetAPIEvents call

type GetBackendInput

type GetBackendInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the backend to fetch.
	Name string
}

GetBackendInput is used as input to the GetBackend function.

type GetBigQueryInput added in v0.4.3

type GetBigQueryInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the BigQuery to fetch.
	Name string
}

GetBigQueryInput is used as input to the GetBigQuery function.

type GetBillingInput

type GetBillingInput struct {
	Year  uint16
	Month uint8
}

GetBillingInput is used as input to the GetBilling function.

type GetBlobStorageInput added in v0.4.3

type GetBlobStorageInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the blob storage to fetch.
	Name string
}

GetBlobStorageInput is used as input to the GetBlobStorage function.

type GetBulkCertificateInput added in v0.16.0

type GetBulkCertificateInput struct {
	ID string
}

GetBulkCertificateInput is used as input to the GetBulkCertificate function.

type GetCacheSettingInput

type GetCacheSettingInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the cache setting to fetch.
	Name string
}

GetCacheSettingInput is used as input to the GetCacheSetting function.

type GetCloudfilesInput added in v0.16.0

type GetCloudfilesInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Cloudfiles to fetch.
	Name string
}

GetCloudfilesInput is used as input to the GetCloudfiles function.

type GetConditionInput

type GetConditionInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the condition to fetch.
	Name string
}

GetConditionInput is used as input to the GetCondition function.

type GetDatadogInput added in v0.16.0

type GetDatadogInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Datadog to fetch.
	Name string
}

GetDatadogInput is used as input to the GetDatadog function.

type GetDictionaryInfoInput added in v0.16.0

type GetDictionaryInfoInput struct {
	// ServiceID is the ID of the service Dictionary belongs to (required).
	ServiceID string

	// Version is the specific configuration version (required).
	Version int

	// ID is the alphanumeric string identifying a dictionary.
	ID string
}

GetDictionaryInfoInput is used as input to the GetDictionary function.

type GetDictionaryInput

type GetDictionaryInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the dictionary to fetch.
	Name string
}

GetDictionaryInput is used as input to the GetDictionary function.

type GetDictionaryItemInput

type GetDictionaryItemInput struct {
	// Service is the ID of the service. Dictionary is the ID of the dictionary.
	// Both fields are required.
	Service    string
	Dictionary string

	// ItemKey is the name of the dictionary item to fetch.
	ItemKey string
}

GetDictionaryItemInput is used as input to the GetDictionaryItem function.

type GetDiffInput

type GetDiffInput struct {
	// Service is the ID of the service (required).
	Service string

	// From is the version to diff from. This can either be a string indicating a
	// positive number (e.g. "1") or a negative number from "-1" down ("-1" is the
	// latest version).
	From int

	// To is the version to diff up to. The same rules for From apply.
	To int

	// Format is an optional field to specify the format with which the diff will
	// be returned. Acceptable values are "text" (default), "html", or
	// "html_simple".
	Format string
}

GetDiffInput is used as input to the GetDiff function.

type GetDigitalOceanInput added in v0.16.0

type GetDigitalOceanInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the DigitalOcean to fetch.
	Name string
}

GetDigitalOceanInput is used as input to the GetDigitalOcean function.

type GetDirectorBackendInput

type GetDirectorBackendInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Director is the name of the director (required).
	Director string

	// Backend is the name of the backend (required).
	Backend string
}

GetDirectorBackendInput is used as input to the GetDirectorBackend function.

type GetDirectorInput

type GetDirectorInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the director to fetch.
	Name string
}

GetDirectorInput is used as input to the GetDirector function.

type GetDomainInput

type GetDomainInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the domain to fetch.
	Name string `form:"name"`
}

GetDomainInput is used as input to the GetDomain function.

type GetDynamicSnippetInput added in v0.4.3

type GetDynamicSnippetInput struct {
	// Service is the ID of the service.
	Service string

	// ID is the ID of the Snippet to fetch.
	ID string
}

GetDynamicSnippetInput is used as input to the GetDynamicSnippet function.

type GetElasticsearchInput added in v0.16.0

type GetElasticsearchInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Elasticsearch endpoint to fetch.
	Name string
}

GetElasticsearchInput is used as input to the GetElasticsearch function.

type GetFTPInput

type GetFTPInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the FTP to fetch.
	Name string
}

GetFTPInput is used as input to the GetFTP function.

type GetGCSInput

type GetGCSInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the GCS to fetch.
	Name string
}

GetGCSInput is used as input to the GetGCS function.

type GetGeneratedVCLInput

type GetGeneratedVCLInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int
}

GetGeneratedVCLInput is used as input to the GetGeneratedVCL function.

type GetGzipInput

type GetGzipInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Gzip to fetch.
	Name string
}

GetGzipInput is used as input to the GetGzip function.

type GetHTTPSInput added in v0.16.0

type GetHTTPSInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the HTTPS endpoint to fetch.
	Name string
}

GetHTTPSInput is used as input to the GetHTTPS function.

type GetHeaderInput

type GetHeaderInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the header to fetch.
	Name string
}

GetHeaderInput is used as input to the GetHeader function.

type GetHealthCheckInput

type GetHealthCheckInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the health check to fetch.
	Name string
}

GetHealthCheckInput is used as input to the GetHealthCheck function.

type GetHerokuInput added in v0.16.0

type GetHerokuInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the heroku to fetch.
	Name string
}

GetHerokuInput is used as input to the GetHeroku function.

type GetHoneycombInput added in v0.16.0

type GetHoneycombInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the honeycomb to fetch.
	Name string
}

GetHoneycombInput is used as input to the GetHoneycomb function.

type GetKafkaInput added in v0.16.0

type GetKafkaInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the kafka to fetch.
	Name string
}

GetKafkaInput is used as input to the GetKafka function.

type GetLogentriesInput

type GetLogentriesInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the logentries to fetch.
	Name string
}

GetLogentriesInput is used as input to the GetLogentries function.

type GetLogglyInput added in v0.16.0

type GetLogglyInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the loggly to fetch.
	Name string
}

GetLogglyInput is used as input to the GetLoggly function.

type GetLogshuttleInput added in v0.16.0

type GetLogshuttleInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the logshuttle to fetch.
	Name string
}

GetLogshuttleInput is used as input to the GetLogshuttle function.

type GetNewRelicInput added in v0.16.0

type GetNewRelicInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the newrelic to fetch.
	Name string
}

GetNewRelicInput is used as input to the GetNewRelic function.

type GetOWASPInput added in v0.4.3

type GetOWASPInput struct {
	// Service is the ID of the service. ID is the ID of the firewall.
	// Both fields are required.
	Service string
	ID      string
}

GetOWASPInput is used as input to the GetOWASP function.

type GetOpenstackInput added in v0.16.0

type GetOpenstackInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Openstack to fetch.
	Name string
}

GetOpenstackInput is used as input to the GetOpenstack function.

type GetPackageInput added in v0.16.0

type GetPackageInput struct {
	// Service is the ID of the service.
	// Version is the specific configuration version.
	// Both fields are required.
	Service string `mapstructure:"service_id"`
	Version int    `mapstructure:"version"`
}

GetPackageInput is used as input to the GetPackage function.

type GetPapertrailInput

type GetPapertrailInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the papertrail to fetch.
	Name string
}

GetPapertrailInput is used as input to the GetPapertrail function.

type GetPoolInput added in v0.16.0

type GetPoolInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int

	// Name is the name of the pool of interest (required).
	Name string
}

GetPoolInput is used as input to the GetPool function.

type GetPrivateKeyInput added in v0.16.0

type GetPrivateKeyInput struct {
	ID string
}

GetPrivateKeyInput is an input to the GetPrivateKey function. Allowed values for the fields are described at https://developer.fastly.com/reference/api/tls/platform/.

type GetPubsubInput added in v0.16.0

type GetPubsubInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Pubsub to fetch.
	Name string
}

GetPubsubInput is used as input to the GetPubsub function.

type GetRealtimeStatsInput added in v0.4.0

type GetRealtimeStatsInput struct {
	Service   string
	Timestamp uint64
	Limit     uint32
}

GetRealtimeStatsInput is an input parameter to GetRealtimeStats function

type GetRequestSettingInput

type GetRequestSettingInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the request settings to fetch.
	Name string
}

GetRequestSettingInput is used as input to the GetRequestSetting function.

type GetResponseObjectInput

type GetResponseObjectInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the response object to fetch.
	Name string
}

GetResponseObjectInput is used as input to the GetResponseObject function.

type GetRuleInput added in v0.4.3

type GetRuleInput struct {
	// RuleID is the ID of the rule and is required.
	RuleID string
}

GetRuleVCLInput is used as input to the GetRuleVCL function.

type GetS3Input

type GetS3Input struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the S3 to fetch.
	Name string
}

GetS3Input is used as input to the GetS3 function.

type GetSFTPInput added in v0.16.0

type GetSFTPInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the SFTP to fetch.
	Name string
}

GetSFTPInput is used as input to the GetSFTP function.

type GetScalyrInput added in v0.16.0

type GetScalyrInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the scalyr to fetch.
	Name string
}

GetScalyrInput is used as input to the GetScalyr function.

type GetServerInput added in v0.16.0

type GetServerInput struct {
	// Service is the ID of the service. Pool is the ID of the pool. Server is
	// the ID of the server in the Pool. These are required fields.
	Service string
	Pool    string
	Server  string
}

GetServerInput is used as input to the GetServer function.

type GetServiceInput

type GetServiceInput struct {
	ID string
}

GetServiceInput is used as input to the GetService function.

type GetSettingsInput

type GetSettingsInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int
}

GetSettingsInput is used as input to the GetSettings function.

type GetSnippetInput added in v0.4.3

type GetSnippetInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Snippet to fetch.
	Name string
}

GetSnippetInput is used as input to the GetSnippet function.

type GetSplunkInput added in v0.4.3

type GetSplunkInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the splunk to fetch.
	Name string
}

GetSplunkInput is used as input to the GetSplunk function.

type GetStatsInput added in v0.4.0

type GetStatsInput struct {
	Service string
	Field   string
	From    string
	To      string
	By      string
	Region  string
}

GetStatsInput is an input to the GetStats function. Stats can be filtered by a Service ID, an individual stats field, time range (From and To), sampling rate (By) and/or Fastly region (Region) Allowed values for the fields are described at https://developer.fastly.com/reference/api/metrics-stats/

type GetSumologicInput

type GetSumologicInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the sumologic to fetch.
	Name string
}

GetSumologicInput is used as input to the GetSumologic function.

type GetSyslogInput

type GetSyslogInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the syslog to fetch.
	Name string
}

GetSyslogInput is used as input to the GetSyslog function.

type GetUsageInput added in v0.4.0

type GetUsageInput struct {
	From   string
	To     string
	By     string
	Region string
}

GetUsageInput is used as an input to the GetUsage function Value for the input are described at https://developer.fastly.com/reference/api/metrics-stats/

type GetUserInput added in v0.16.0

type GetUserInput struct {
	ID string
}

GetUserInput is used as input to the GetUser function.

type GetVCLInput

type GetVCLInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the VCL to fetch.
	Name string
}

GetVCLInput is used as input to the GetVCL function.

type GetVersionInput

type GetVersionInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the version number to fetch (required).
	Version int
}

GetVersionInput is the input to the GetVersion function.

type GetWAFInput added in v0.4.2

type GetWAFInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// ID is the id of the WAF to get.
	ID string
}

GetWAFInput is used as input to the GetWAF function.

type GetWAFRuleRuleSetsInput added in v0.4.3

type GetWAFRuleRuleSetsInput struct {
	// Service is the ID of the service. ID is the ID of the firewall.
	// Both fields are required.
	Service string
	ID      string
}

GetWAFRuleRuleSetsInput is used as input to the GetWAFRuleRuleSets function.

type GetWAFRuleStatusInput added in v0.4.3

type GetWAFRuleStatusInput struct {
	ID      int
	Service string
	WAF     string
}

GetWAFRuleStatusInput specifies the parameters for the GetWAFRuleStatus call.

type GetWAFRuleStatusesFilters added in v0.4.3

type GetWAFRuleStatusesFilters struct {
	Status     string
	Accuracy   int
	Maturity   int
	Message    string
	Revision   int
	RuleID     string
	TagID      int    // Filter by a single tag ID.
	TagName    string // Filter by single tag name.
	Version    string
	Tags       []int // Return all rules with any of the specified tag IDs.
	MaxResults int   // Max number of returned results per request.
	Page       int   // Which page of results to return.
}

GetWAFRuleStatusesFilters provides a set of parameters for filtering the results of the call to get the rules associated with a WAF.

type GetWAFRuleStatusesInput added in v0.4.3

type GetWAFRuleStatusesInput struct {
	Service string
	WAF     string
	Filters GetWAFRuleStatusesFilters
}

GetWAFRuleStatusesInput specifies the parameters for the GetWAFRuleStatuses call

type GetWAFRuleStatusesResponse added in v0.4.3

type GetWAFRuleStatusesResponse struct {
	Rules []*WAFRuleStatus
}

GetWAFRuleStatusesResponse is the data returned to the user from a GetWAFRuleStatus call

type GetWAFRuleVCLInput added in v0.4.3

type GetWAFRuleVCLInput struct {
	// ID is the ID of the firewall. RuleID is the ID of the rule.
	// Both are required.
	ID     string
	RuleID string
}

GetWAFRuleVCLInput is used as input to the GetWAFRuleVCL function.

type Gzip

type Gzip struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name           string     `mapstructure:"name"`
	ContentTypes   string     `mapstructure:"content_types"`
	Extensions     string     `mapstructure:"extensions"`
	CacheCondition string     `mapstructure:"cache_condition"`
	CreatedAt      *time.Time `mapstructure:"created_at"`
	UpdatedAt      *time.Time `mapstructure:"updated_at"`
	DeletedAt      *time.Time `mapstructure:"deleted_at"`
}

Gzip represents an Gzip logging response from the Fastly API.

type HTTPError

type HTTPError struct {
	// StatusCode is the HTTP status code (2xx-5xx).
	StatusCode int

	Errors []*ErrorObject `mapstructure:"errors"`
}

HTTPError is a custom error type that wraps an HTTP status code with some helper functions.

func NewHTTPError

func NewHTTPError(resp *http.Response) *HTTPError

NewHTTPError creates a new HTTP error from the given code.

func (*HTTPError) Error

func (e *HTTPError) Error() string

Error implements the error interface and returns the string representing the error text that includes the status code and the corresponding status text.

func (*HTTPError) IsNotFound

func (e *HTTPError) IsNotFound() bool

IsNotFound returns true if the HTTP error code is a 404, false otherwise.

func (*HTTPError) String

func (e *HTTPError) String() string

String implements the stringer interface and returns the string representing the string text that includes the status code and corresponding status text.

type HTTPS added in v0.16.0

type HTTPS struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Format            string     `mapstructure:"format"`
	URL               string     `mapstructure:"url"`
	RequestMaxEntries uint       `mapstructure:"request_max_entries"`
	RequestMaxBytes   uint       `mapstructure:"request_max_bytes"`
	ContentType       string     `mapstructure:"content_type"`
	HeaderName        string     `mapstructure:"header_name"`
	HeaderValue       string     `mapstructure:"header_value"`
	Method            string     `mapstructure:"method"`
	JSONFormat        string     `mapstructure:"json_format"`
	Placement         string     `mapstructure:"placement"`
	TLSCACert         string     `mapstructure:"tls_ca_cert"`
	TLSClientCert     string     `mapstructure:"tls_client_cert"`
	TLSClientKey      string     `mapstructure:"tls_client_key"`
	TLSHostname       string     `mapstructure:"tls_hostname"`
	MessageType       string     `mapstructure:"message_type"`
	FormatVersion     uint       `mapstructure:"format_version"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

HTTPS represents an HTTPS Logging response from the Fastly API.

type Header struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string       `mapstructure:"name"`
	Action            HeaderAction `mapstructure:"action"`
	IgnoreIfSet       bool         `mapstructure:"ignore_if_set"`
	Type              HeaderType   `mapstructure:"type"`
	Destination       string       `mapstructure:"dst"`
	Source            string       `mapstructure:"src"`
	Regex             string       `mapstructure:"regex"`
	Substitution      string       `mapstructure:"substitution"`
	Priority          uint         `mapstructure:"priority"`
	RequestCondition  string       `mapstructure:"request_condition"`
	CacheCondition    string       `mapstructure:"cache_condition"`
	ResponseCondition string       `mapstructure:"response_condition"`
	CreatedAt         *time.Time   `mapstructure:"created_at"`
	UpdatedAt         *time.Time   `mapstructure:"updated_at"`
	DeletedAt         *time.Time   `mapstructure:"deleted_at"`
}

Header represents a header response from the Fastly API.

type HeaderAction

type HeaderAction string

HeaderAction is a type of header action.

const (
	// HeaderActionSet is a header action that sets or resets a header.
	HeaderActionSet HeaderAction = "set"

	// HeaderActionAppend is a header action that appends to an existing header.
	HeaderActionAppend HeaderAction = "append"

	// HeaderActionDelete is a header action that deletes a header.
	HeaderActionDelete HeaderAction = "delete"

	// HeaderActionRegex is a header action that performs a single regex
	// replacement on a header.
	HeaderActionRegex HeaderAction = "regex"

	// HeaderActionRegexRepeat is a header action that performs a global regex
	// replacement on a header.
	HeaderActionRegexRepeat HeaderAction = "regex_repeat"
)

type HeaderType

type HeaderType string

HeaderType is a type of header.

const (
	// HeaderTypeRequest is a header type that performs on the request before
	// lookups.
	HeaderTypeRequest HeaderType = "request"

	// HeaderTypeFetch is a header type that performs on the request to the origin
	// server.
	HeaderTypeFetch HeaderType = "fetch"

	// HeaderTypeCache is a header type that performs on the response before it's
	// store in the cache.
	HeaderTypeCache HeaderType = "cache"

	// HeaderTypeResponse is a header type that performs on the response before
	// delivering to the client.
	HeaderTypeResponse HeaderType = "response"
)

type HealthCheck

type HealthCheck struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name             string     `mapstructure:"name"`
	Comment          string     `mapstructure:"comment"`
	Method           string     `mapstructure:"method"`
	Host             string     `mapstructure:"host"`
	Path             string     `mapstructure:"path"`
	HTTPVersion      string     `mapstructure:"http_version"`
	Timeout          uint       `mapstructure:"timeout"`
	CheckInterval    uint       `mapstructure:"check_interval"`
	ExpectedResponse uint       `mapstructure:"expected_response"`
	Window           uint       `mapstructure:"window"`
	Threshold        uint       `mapstructure:"threshold"`
	Initial          uint       `mapstructure:"initial"`
	CreatedAt        *time.Time `mapstructure:"created_at"`
	UpdatedAt        *time.Time `mapstructure:"updated_at"`
	DeletedAt        *time.Time `mapstructure:"deleted_at"`
}

HealthCheck represents a health check response from the Fastly API.

type Heroku added in v0.16.0

type Heroku struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	URL               string     `mapstructure:"url"`
	Token             string     `mapstructure:"token"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Heroku represents a heroku response from the Fastly API.

type Honeycomb added in v0.16.0

type Honeycomb struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	Dataset           string     `mapstructure:"dataset"`
	Token             string     `mapstructure:"token"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Honeycomb represents a honeycomb response from the Fastly API.

type IPAddrs

type IPAddrs []string

IPAddrs is a sortable list of IP addresses returned by the Fastly API.

type Kafka added in v0.16.0

type Kafka struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Brokers           string     `mapstructure:"brokers"`
	Topic             string     `mapstructure:"topic"`
	RequiredACKs      string     `mapstructure:"required_acks"`
	UseTLS            bool       `mapstructure:"use_tls"`
	CompressionCodec  string     `mapstructure:"compression_codec"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	TLSCACert         string     `mapstructure:"tls_ca_cert"`
	TLSHostname       string     `mapstructure:"tls_hostname"`
	TLSClientCert     string     `mapstructure:"tls_client_cert"`
	TLSClientKey      string     `mapstructure:"tls_client_key"`
	ParseLogKeyvals   bool       `mapstructure:"parse_log_keyvals"`
	RequestMaxBytes   uint       `mapstructure:"request_max_bytes"`
	AuthMethod        string     `mapstructure:"auth_method"`
	User              string     `mapstructure:"user"`
	Password          string     `mapstructure:"password"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Kafka represents a kafka response from the Fastly API.

type LatestVersionInput

type LatestVersionInput struct {
	// Service is the ID of the service (required).
	Service string
}

LatestVersionInput is the input to the LatestVersion function.

type ListACLEntriesInput added in v0.4.0

type ListACLEntriesInput struct {
	Service string
	ACL     string
}

ListACLEntriesInput is the input parameter to ListACLEntries function.

type ListACLsInput added in v0.4.0

type ListACLsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListACLsInput is used as input to the ListACLs function.

type ListBackendsInput

type ListBackendsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListBackendsInput is used as input to the ListBackends function.

type ListBigQueriesInput added in v0.16.0

type ListBigQueriesInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListBigQueriesInput is used as input to the ListBigQueries function.

type ListBlobStoragesInput added in v0.4.3

type ListBlobStoragesInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListBlobStoragesInput is used as input to the ListBlobStorages function.

type ListBulkCertificatesInput added in v0.16.0

type ListBulkCertificatesInput struct {
	PageNumber              *uint   // The page index for pagination.
	PageSize                *uint   // The number of keys per page.
	FilterTLSDomainsIDMatch *string // Filter certificates by their matching, fully-qualified domain name. Returns all partial matches. Must provide a value longer than 3 characters.
	Sort                    *string // The order in which to list certificates. Valid values are created_at, not_before, not_after. May precede any value with a - for descending.
}

ListBulkCertificatesInput is used as input to the ListBulkCertificates function.

type ListCacheSettingsInput

type ListCacheSettingsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListCacheSettingsInput is used as input to the ListCacheSettings function.

type ListCloudfilesInput added in v0.16.0

type ListCloudfilesInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListCloudfilesInput is used as input to the ListCloudfiles function.

type ListConditionsInput

type ListConditionsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListConditionsInput is used as input to the ListConditions function.

type ListCustomerTokensInput added in v0.16.0

type ListCustomerTokensInput struct {
	ID string
}

ListCustomerTokensInput is used as input to the ListCustomerTokens function.

type ListCustomerUsersInput added in v0.16.0

type ListCustomerUsersInput struct {
	CustomerID string
}

ListCustomerUsersInput is used as input to the ListCustomerUsers function.

type ListDatadogInput added in v0.16.0

type ListDatadogInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListDatadogInput is used as input to the ListDatadog function.

type ListDictionariesInput

type ListDictionariesInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListDictionariesInput is used as input to the ListDictionaries function.

type ListDictionaryItemsInput

type ListDictionaryItemsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Dictionary is the ID of the dictionary to retrieve items for (required).
	Dictionary string
}

ListDictionaryItemsInput is used as input to the ListDictionaryItems function.

type ListDigitalOceansInput added in v0.16.0

type ListDigitalOceansInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListDigitalOceansInput is used as input to the ListDigitalOceans function.

type ListDirectorsInput

type ListDirectorsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListDirectorsInput is used as input to the ListDirectors function.

type ListDomainsInput

type ListDomainsInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int
}

ListDomainsInput is used as input to the ListDomains function.

type ListElasticsearchInput added in v0.16.0

type ListElasticsearchInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListElasticsearchInput is used as input to the ListElasticsearch function.

type ListFTPsInput

type ListFTPsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListFTPsInput is used as input to the ListFTPs function.

type ListGCSsInput

type ListGCSsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListGCSsInput is used as input to the ListGCSs function.

type ListGzipsInput

type ListGzipsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListGzipsInput is used as input to the ListGzips function.

type ListHTTPSInput added in v0.16.0

type ListHTTPSInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListHTTPSInput is used as input to the ListHTTPS function.

type ListHeadersInput

type ListHeadersInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListHeadersInput is used as input to the ListHeaders function.

type ListHealthChecksInput

type ListHealthChecksInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListHealthChecksInput is used as input to the ListHealthChecks function.

type ListHerokusInput added in v0.16.0

type ListHerokusInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListHerokusInput is used as input to the ListHerokus function.

type ListHoneycombsInput added in v0.16.0

type ListHoneycombsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListHoneycombsInput is used as input to the ListHoneycombs function.

type ListKafkasInput added in v0.16.0

type ListKafkasInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListKafkasInput is used as input to the ListKafkas function.

type ListLogentriesInput

type ListLogentriesInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListLogentriesInput is used as input to the ListLogentries function.

type ListLogglyInput added in v0.16.0

type ListLogglyInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListLogglyInput is used as input to the ListLoggly function.

type ListLogshuttlesInput added in v0.16.0

type ListLogshuttlesInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListLogshuttlesInput is used as input to the ListLogshuttles function.

type ListNewRelicInput added in v0.16.0

type ListNewRelicInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListNewRelicInput is used as input to the ListNewRelic function.

type ListOpenstackInput added in v0.16.0

type ListOpenstackInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListOpenstackInput is used as input to the ListOpenstack function.

type ListPapertrailsInput

type ListPapertrailsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListPapertrailsInput is used as input to the ListPapertrails function.

type ListPoolsInput added in v0.16.0

type ListPoolsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListPoolsInput is used as input to the ListPools function.

type ListPrivateKeysInput added in v0.16.0

type ListPrivateKeysInput struct {
	PageNumber  *uint   // The page index for pagination.
	PageSize    *uint   // The number of keys per page.
	FilterInUse *string // Limit the returned keys to those without any matching TLS certificates.
}

ListPrivateKeysInput is used as input to the ListPrivateKeys function.

type ListPubsubsInput added in v0.16.0

type ListPubsubsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListPubsubsInput is used as input to the ListPubsubs function.

type ListRequestSettingsInput

type ListRequestSettingsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListRequestSettingsInput is used as input to the ListRequestSettings function.

type ListResponseObjectsInput

type ListResponseObjectsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListResponseObjectsInput is used as input to the ListResponseObjects function.

type ListS3sInput

type ListS3sInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListS3sInput is used as input to the ListS3s function.

type ListSFTPsInput added in v0.16.0

type ListSFTPsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListSFTPsInput is used as input to the ListSFTPs function.

type ListScalyrsInput added in v0.16.0

type ListScalyrsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListScalyrsInput is used as input to the ListScalyrs function.

type ListServersInput added in v0.16.0

type ListServersInput struct {
	// Service is the ID of the service (required).
	Service string

	// Pool is the ID of the pool (required).
	Pool string
}

ListServersInput is used as input to the ListServers function.

type ListServiceDomainInput added in v0.4.3

type ListServiceDomainInput struct {
	ID string
}

type ListServicesInput

type ListServicesInput struct{}

ListServicesInput is used as input to the ListServices function.

type ListSnippetsInput added in v0.4.3

type ListSnippetsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListSnippetsInput is used as input to the ListSnippets function.

type ListSplunksInput added in v0.4.3

type ListSplunksInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListSplunksInput is used as input to the ListSplunks function.

type ListSumologicsInput

type ListSumologicsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListSumologicsInput is used as input to the ListSumologics function.

type ListSyslogsInput

type ListSyslogsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListSyslogsInput is used as input to the ListSyslogs function.

type ListVCLsInput

type ListVCLsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListVCLsInput is used as input to the ListVCLs function.

type ListVersionsInput

type ListVersionsInput struct {
	// Service is the ID of the service (required).
	Service string
}

ListVersionsInput is the input to the ListVersions function.

type ListWAFsInput added in v0.4.2

type ListWAFsInput struct {
	// Service is the ID of the service (required).
	Service string

	// Version is the specific configuration version (required).
	Version int
}

ListWAFsInput is used as input to the ListWAFs function.

type LockVersionInput

type LockVersionInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int
}

LockVersionInput is the input to the LockVersion function.

type Logentries

type Logentries struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Port              uint       `mapstructure:"port"`
	UseTLS            bool       `mapstructure:"use_tls"`
	Token             string     `mapstructure:"token"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
	Placement         string     `mapstructure:"placement"`
}

Logentries represents a logentries response from the Fastly API.

type Loggly added in v0.16.0

type Loggly struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Token             string     `mapstructure:"token"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Loggly represents a loggly response from the Fastly API.

type Logshuttle added in v0.16.0

type Logshuttle struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	URL               string     `mapstructure:"url"`
	Token             string     `mapstructure:"token"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Logshuttle represents a logshuttle response from the Fastly API.

type NewRelic added in v0.16.0

type NewRelic struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Token             string     `mapstructure:"token"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

NewRelic represents a newrelic response from the Fastly API.

type OWASP added in v0.4.3

type OWASP struct {
	ID                               string     `jsonapi:"primary,owasp"`
	AllowedHTTPVersions              string     `jsonapi:"attr,allowed_http_versions"`
	AllowedMethods                   string     `jsonapi:"attr,allowed_methods"`
	AllowedRequestContentType        string     `jsonapi:"attr,allowed_request_content_type"`
	AllowedRequestContentTypeCharset string     `jsonapi:"attr,allowed_request_content_type_charset"`
	ArgLength                        int        `jsonapi:"attr,arg_length"`
	ArgNameLength                    int        `jsonapi:"attr,arg_name_length"`
	CombinedFileSizes                int        `jsonapi:"attr,combined_file_sizes"`
	CreatedAt                        *time.Time `jsonapi:"attr,created_at,iso8601"`
	CriticalAnomalyScore             int        `jsonapi:"attr,critical_anomaly_score"`
	CRSValidateUTF8Encoding          bool       `jsonapi:"attr,crs_validate_utf8_encoding"`
	ErrorAnomalyScore                int        `jsonapi:"attr,error_anomaly_score"`
	HighRiskCountryCodes             string     `jsonapi:"attr,high_risk_country_codes"`
	HTTPViolationScoreThreshold      int        `jsonapi:"attr,http_violation_score_threshold"`
	InboundAnomalyScoreThreshold     int        `jsonapi:"attr,inbound_anomaly_score_threshold"`
	LFIScoreThreshold                int        `jsonapi:"attr,lfi_score_threshold"`
	MaxFileSize                      int        `jsonapi:"attr,max_file_size"`
	MaxNumArgs                       int        `jsonapi:"attr,max_num_args"`
	NoticeAnomalyScore               int        `jsonapi:"attr,notice_anomaly_score"`
	ParanoiaLevel                    int        `jsonapi:"attr,paranoia_level"`
	PHPInjectionScoreThreshold       int        `jsonapi:"attr,php_injection_score_threshold"`
	RCEScoreThreshold                int        `jsonapi:"attr,rce_score_threshold"`
	RestrictedExtensions             string     `jsonapi:"attr,restricted_extensions"`
	RestrictedHeaders                string     `jsonapi:"attr,restricted_headers"`
	RFIScoreThreshold                int        `jsonapi:"attr,rfi_score_threshold"`
	SessionFixationScoreThreshold    int        `jsonapi:"attr,session_fixation_score_threshold"`
	SQLInjectionScoreThreshold       int        `jsonapi:"attr,sql_injection_score_threshold"`
	TotalArgLength                   int        `jsonapi:"attr,total_arg_length"`
	UpdatedAt                        *time.Time `jsonapi:"attr,updated_at,iso8601"`
	WarningAnomalyScore              int        `jsonapi:"attr,warning_anomaly_score"`
	XSSScoreThreshold                int        `jsonapi:"attr,xss_score_threshold"`
}

OWASP is the information about an OWASP object.

type Openstack added in v0.16.0

type Openstack struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	User              string     `mapstructure:"user"`
	AccessKey         string     `mapstructure:"access_key"`
	BucketName        string     `mapstructure:"bucket_name"`
	URL               string     `mapstructure:"url"`
	Path              string     `mapstructure:"path"`
	Placement         string     `mapstructure:"placement"`
	Period            uint       `mapstructure:"period"`
	GzipLevel         uint       `mapstructure:"gzip_level"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	MessageType       string     `mapstructure:"message_type"`
	TimestampFormat   string     `mapstructure:"timestamp_format"`
	PublicKey         string     `mapstructure:"public_key"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Openstack represents a Openstack response from the Fastly API.

type Package added in v0.16.0

type Package struct {
	ID        string
	ServiceID string `mapstructure:"service_id"`
	Version   int
	Metadata  PackageMetadata
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
}

Package is a container for data returned about a package.

func PopulatePackage added in v0.16.0

func PopulatePackage(body io.ReadCloser) (*Package, error)

PopulatePackage encapsulates the decoding of returned package data.

type PackageMetadata added in v0.16.0

type PackageMetadata struct {
	Name        string
	Description string
	Authors     []string
	Language    string
	Size        int64
	HashSum     string
}

Package is a container for metadata returned about a package. It is a separate struct to allow correct serialisation by mapstructure - the raw data is returned as a json sub-block.

type Papertrail

type Papertrail struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Address           string     `mapstructure:"address"`
	Port              uint       `mapstructure:"port"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
	Placement         string     `mapstructure:"placement"`
}

Papertrail represents a papertrail response from the Fastly API.

type Pool added in v0.16.0

type Pool struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	ID               string     `mapstructure:"id"`
	Name             string     `mapstructure:"name"`
	Comment          string     `mapstructure:"comment"`
	Shield           string     `mapstructure:"shield"`
	RequestCondition string     `mapstructure:"request_condition"`
	MaxConnDefault   uint       `mapstructure:"max_conn_default"`
	ConnectTimeout   uint       `mapstructure:"connect_timeout"`
	FirstByteTimeout uint       `mapstructure:"first_byte_timeout"`
	Quorum           uint       `mapstructure:"quorum"`
	UseTLS           bool       `mapstructure:"use_tls"`
	TLSCACert        string     `mapstructure:"tls_ca_cert"`
	TLSCiphers       string     `mapstructure:"tls_ciphers"`
	TLSClientKey     string     `mapstructure:"tls_client_key"`
	TLSClientCert    string     `mapstructure:"tls_client_cert"`
	TLSSNIHostname   string     `mapstructure:"tls_sni_hostname"`
	TLSCheckCert     bool       `mapstructure:"tls_check_cert"`
	TLSCertHostname  string     `mapstructure:"tls_cert_hostname"`
	MinTLSVersion    string     `mapstructure:"min_tls_version"`
	MaxTLSVersion    string     `mapstructure:"max_tls_version"`
	Healthcheck      string     `mapstructure:"healthcheck"`
	Type             PoolType   `mapstructure:"type"`
	OverrideHost     string     `mapstructure:"override_host"`
	CreatedAt        *time.Time `mapstructure:"created_at"`
	DeletedAt        *time.Time `mapstructure:"deleted_at"`
	UpdatedAt        *time.Time `mapstructure:"updated_at"`
}

Pool represents a pool response from the Fastly API.

type PoolType added in v0.16.0

type PoolType string

PoolType is a type of pool.

const (
	// PoolTypeRandom is a pool that does random direction.
	PoolTypeRandom PoolType = "random"

	// PoolTypeHash is a pool that does hash direction.
	PoolTypeHash PoolType = "hash"

	// PoolTypeClient ins a pool that does client direction.
	PoolTypeClient PoolType = "client"
)

type PrivateKey added in v0.16.0

type PrivateKey struct {
	ID            string     `jsonapi:"primary,tls_private_key"`
	Name          string     `jsonapi:"attr,name"`
	KeyLength     int        `jsonapi:"attr,key_length"`
	KeyType       string     `jsonapi:"attr,key_type"`
	PublicKeySHA1 string     `jsonapi:"attr,public_key_sha1"`
	CreatedAt     *time.Time `jsonapi:"attr,created_at,iso8601"`
	Replace       bool       `jsonapi:"attr,replace"`
}

PrivateKey represents a private key is used to sign a Certificate.

type Pubsub added in v0.16.0

type Pubsub struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Topic             string     `mapstructure:"topic"`
	User              string     `mapstructure:"user"`
	SecretKey         string     `mapstructure:"secret_key"`
	ProjectID         string     `mapstructure:"project_id"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Pubsub represents an Pubsub logging response from the Fastly API.

type Purge

type Purge struct {
	// Status is the status of the purge, usually "ok".
	Status string `mapstructure:"status"`

	// ID is the unique ID of the purge request.
	ID string `mapstructure:"id"`
}

Purge is a response from a purge request.

type PurgeAllInput

type PurgeAllInput struct {
	// Service is the ID of the service (required).
	Service string

	// Soft performs a soft purge.
	Soft bool
}

PurgeAllInput is used as input to the Purge function.

type PurgeInput

type PurgeInput struct {
	// URL is the URL to purge (required).
	URL string

	// Soft performs a soft purge.
	Soft bool
}

PurgeInput is used as input to the Purge function.

type PurgeKeyInput

type PurgeKeyInput struct {
	// Service is the ID of the service (required).
	Service string

	// Key is the key to purge (required).
	Key string

	// Soft performs a soft purge.
	Soft bool
}

PurgeKeyInput is used as input to the Purge function.

type RTSClient added in v0.4.0

type RTSClient struct {
	// contains filtered or unexported fields
}

RTSClient is the entrypoint to the Fastly's Realtime Stats API.

func NewRealtimeStatsClient added in v0.4.0

func NewRealtimeStatsClient() *RTSClient

NewRealtimeStatsClient instantiates a new Fastly API client for the realtime stats. This function requires the environment variable `FASTLY_API_KEY` is set and contains a valid API key to authenticate with Fastly.

func NewRealtimeStatsClientForEndpoint added in v0.16.0

func NewRealtimeStatsClientForEndpoint(token, endpoint string) (*RTSClient, error)

NewRealtimeStatsClientForEndpoint creates an RTSClient from a token and endpoint url. `token` is a Fastly API token and `endpoint` is RealtimeStatsEndpoint for the production realtime stats API.

func (*RTSClient) GetRealtimeStats added in v0.4.0

func (c *RTSClient) GetRealtimeStats(i *GetRealtimeStatsInput) (*RealtimeStatsResponse, error)

GetRealtimeStats returns realtime stats for a service based on the GetRealtimeStatsInput parameter. The realtime stats work in a rolling fashion where first request will return a timestamp which should be passed to the next call and so on. More details at https://developer.fastly.com/reference/api/metrics-stats/realtime/

func (*RTSClient) GetRealtimeStatsJSON added in v0.16.0

func (c *RTSClient) GetRealtimeStatsJSON(i *GetRealtimeStatsInput, dst interface{}) error

GetRealtimeStatsJSON fetches stats and decodes the response directly to the JSON struct dst.

type RealtimeData added in v0.4.0

type RealtimeData struct {
	Datacenter map[string]*Stats `mapstructure:"datacenter"`
	Aggregated *Stats            `mapstructure:"aggregated"`
	Recorded   uint64            `mapstructure:"recorded"`
}

RealtimeData represents combined stats for all Fastly's POPs and aggregate of them. It also includes a timestamp of when the stats were recorded

type RealtimeStatsResponse added in v0.4.0

type RealtimeStatsResponse struct {
	Timestamp      uint64          `mapstructure:"Timestamp"`
	Data           []*RealtimeData `mapstructure:"Data"`
	Error          string          `mapstructure:"Error"`
	AggregateDelay uint32          `mapstructure:"AggregateDelay"`
}

RealtimeStatsResponse is a response from Fastly's real-time analytics endpoint

type RegionsResponse added in v0.4.0

type RegionsResponse struct {
	Status  string            `mapstructure:"status"`
	Meta    map[string]string `mapstructure:"meta"`
	Message string            `mapstructure:"msg"`
	Data    []string          `mapstructure:"data"`
}

RegionsResponse is a response from Fastly regions API endpoint

type RegionsUsage added in v0.4.0

type RegionsUsage map[string]*Usage

RegionsUsage is a list of aggregated usage data by Fastly's region

type RequestOptions

type RequestOptions struct {
	// Params is a map of key-value pairs that will be added to the Request.
	Params map[string]string

	// Headers is a map of key-value pairs that will be added to the Request.
	Headers map[string]string

	// Body is an io.Reader object that will be streamed or uploaded with the
	// Request. BodyLength is the final size of the Body.
	Body       io.Reader
	BodyLength int64

	// Can this request run in parallel
	Parallel bool
}

RequestOptions is the list of options to pass to the request.

type RequestSetting

type RequestSetting struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name             string               `mapstructure:"name"`
	ForceMiss        bool                 `mapstructure:"force_miss"`
	ForceSSL         bool                 `mapstructure:"force_ssl"`
	Action           RequestSettingAction `mapstructure:"action"`
	BypassBusyWait   bool                 `mapstructure:"bypass_busy_wait"`
	MaxStaleAge      uint                 `mapstructure:"max_stale_age"`
	HashKeys         string               `mapstructure:"hash_keys"`
	XForwardedFor    RequestSettingXFF    `mapstructure:"xff"`
	TimerSupport     bool                 `mapstructure:"timer_support"`
	GeoHeaders       bool                 `mapstructure:"geo_headers"`
	DefaultHost      string               `mapstructure:"default_host"`
	RequestCondition string               `mapstructure:"request_condition"`
	CreatedAt        *time.Time           `mapstructure:"created_at"`
	UpdatedAt        *time.Time           `mapstructure:"updated_at"`
	DeletedAt        *time.Time           `mapstructure:"deleted_at"`
}

RequestSetting represents a request setting response from the Fastly API.

type RequestSettingAction

type RequestSettingAction string

RequestSettingAction is a type of request setting action.

const (
	// RequestSettingActionLookup sets request handling to lookup via the cache.
	RequestSettingActionLookup RequestSettingAction = "lookup"

	// RequestSettingActionPass sets request handling to pass the cache.
	RequestSettingActionPass RequestSettingAction = "pass"
)

type RequestSettingXFF

type RequestSettingXFF string

RequestSettingXFF is a type of X-Forwarded-For value to set.

const (
	// RequestSettingXFFClear clears any X-Forwarded-For headers.
	RequestSettingXFFClear RequestSettingXFF = "clear"

	// RequestSettingXFFLeave leaves any X-Forwarded-For headers untouched.
	RequestSettingXFFLeave RequestSettingXFF = "leave"

	// RequestSettingXFFAppend adds Fastly X-Forwarded-For headers.
	RequestSettingXFFAppend RequestSettingXFF = "append"

	// RequestSettingXFFAppendAll appends all Fastly X-Forwarded-For headers.
	RequestSettingXFFAppendAll RequestSettingXFF = "append_all"

	// RequestSettingXFFOverwrite clears any X-Forwarded-For headers and replaces
	// with Fastly ones.
	RequestSettingXFFOverwrite RequestSettingXFF = "overwrite"
)

type ResponseObject

type ResponseObject struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name             string     `mapstructure:"name"`
	Status           uint       `mapstructure:"status"`
	Response         string     `mapstructure:"response"`
	Content          string     `mapstructure:"content"`
	ContentType      string     `mapstructure:"content_type"`
	RequestCondition string     `mapstructure:"request_condition"`
	CacheCondition   string     `mapstructure:"cache_condition"`
	CreatedAt        *time.Time `mapstructure:"created_at"`
	UpdatedAt        *time.Time `mapstructure:"updated_at"`
	DeletedAt        *time.Time `mapstructure:"deleted_at"`
}

ResponseObject represents a response object response from the Fastly API.

type Rule added in v0.4.3

type Rule struct {
	ID       string `jsonapi:"primary,rule"`
	RuleID   string `jsonapi:"attr,rule_id,omitempty"`
	Severity int    `jsonapi:"attr,severity,omitempty"`
	Message  string `jsonapi:"attr,message,omitempty"`
}

Rule is the information about a WAF rule.

type RuleVCL added in v0.4.3

type RuleVCL struct {
	ID  string `jsonapi:"primary,rule_vcl"`
	VCL string `jsonapi:"attr,vcl,omitempty"`
}

RuleVCL is the information about a Rule's VCL.

type Ruleset added in v0.4.3

type Ruleset struct {
	ID       string     `jsonapi:"primary,ruleset"`
	VCL      string     `jsonapi:"attr,vcl,omitempty"`
	LastPush *time.Time `jsonapi:"attr,last_push,omitempty,iso8601"`
	Link     string
}

Ruleset is the information about a firewall object's ruleset.

type S3

type S3 struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name                         string                 `mapstructure:"name"`
	BucketName                   string                 `mapstructure:"bucket_name"`
	Domain                       string                 `mapstructure:"domain"`
	AccessKey                    string                 `mapstructure:"access_key"`
	SecretKey                    string                 `mapstructure:"secret_key"`
	Path                         string                 `mapstructure:"path"`
	Period                       uint                   `mapstructure:"period"`
	GzipLevel                    uint                   `mapstructure:"gzip_level"`
	Format                       string                 `mapstructure:"format"`
	FormatVersion                uint                   `mapstructure:"format_version"`
	ResponseCondition            string                 `mapstructure:"response_condition"`
	MessageType                  string                 `mapstructure:"message_type"`
	TimestampFormat              string                 `mapstructure:"timestamp_format"`
	Placement                    string                 `mapstructure:"placement"`
	PublicKey                    string                 `mapstructure:"public_key"`
	Redundancy                   S3Redundancy           `mapstructure:"redundancy"`
	ServerSideEncryptionKMSKeyID string                 `mapstructure:"server_side_encryption_kms_key_id"`
	ServerSideEncryption         S3ServerSideEncryption `mapstructure:"server_side_encryption"`
	CreatedAt                    *time.Time             `mapstructure:"created_at"`
	UpdatedAt                    *time.Time             `mapstructure:"updated_at"`
	DeletedAt                    *time.Time             `mapstructure:"deleted_at"`
}

S3 represents a S3 response from the Fastly API.

type S3Redundancy

type S3Redundancy string

type S3ServerSideEncryption added in v0.16.0

type S3ServerSideEncryption string

type SFTP added in v0.16.0

type SFTP struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Address           string     `mapstructure:"address"`
	Port              uint       `mapstructure:"port"`
	User              string     `mapstructure:"user"`
	Password          string     `mapstructure:"password"`
	PublicKey         string     `mapstructure:"public_key"`
	SecretKey         string     `mapstructure:"secret_key"`
	SSHKnownHosts     string     `mapstructure:"ssh_known_hosts"`
	Path              string     `mapstructure:"path"`
	Period            uint       `mapstructure:"period"`
	GzipLevel         uint8      `mapstructure:"gzip_level"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	TimestampFormat   string     `mapstructure:"timestamp_format"`
	MessageType       string     `mapstructure:"message_type"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

SFTP represents an SFTP logging response from the Fastly API.

type Scalyr added in v0.16.0

type Scalyr struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	Token             string     `mapstructure:"token"`
	Region            string     `mapstructure:"region"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Scalyr represents a scalyr response from the Fastly API.

type SearchServiceInput

type SearchServiceInput struct {
	Name string
}

SearchServiceInput is used as input to the SearchService function.

type Server added in v0.16.0

type Server struct {
	ServiceID string `mapstructure:"service_id"`
	PoolID    string `mapstructure:"pool_id"`
	ID        string `mapstructure:"id"`

	Address      string     `mapstructure:"address"`
	Comment      string     `mapstructure:"comment"`
	Weight       uint       `mapstructure:"weight"`
	MaxConn      uint       `mapstructure:"max_conn"`
	Port         uint       `mapstructure:"port"`
	Disabled     bool       `mapstructure:"disabled"`
	OverrideHost string     `mapstructure:"override_host"`
	CreatedAt    *time.Time `mapstructure:"created_at"`
	DeletedAt    *time.Time `mapstructure:"deleted_at"`
	UpdatedAt    *time.Time `mapstructure:"updated_at"`
}

ServerType represents a server response from the Fastly API.

type Service

type Service struct {
	ID            string     `mapstructure:"id"`
	Name          string     `mapstructure:"name"`
	Type          string     `mapstructure:"type"`
	Comment       string     `mapstructure:"comment"`
	CustomerID    string     `mapstructure:"customer_id"`
	CreatedAt     *time.Time `mapstructure:"created_at"`
	UpdatedAt     *time.Time `mapstructure:"updated_at"`
	DeletedAt     *time.Time `mapstructure:"deleted_at"`
	ActiveVersion uint       `mapstructure:"version"`
	Versions      []*Version `mapstructure:"versions"`
}

Service represents a single service for the Fastly account.

type ServiceDetail

type ServiceDetail struct {
	ID            string     `mapstructure:"id"`
	Name          string     `mapstructure:"name"`
	Type          string     `mapstructure:"type"`
	Comment       string     `mapstructure:"comment"`
	CustomerID    string     `mapstructure:"customer_id"`
	ActiveVersion Version    `mapstructure:"active_version"`
	Version       Version    `mapstructure:"version"`
	Versions      []*Version `mapstructure:"versions"`
	CreatedAt     *time.Time `mapstructure:"created_at"`
	UpdatedAt     *time.Time `mapstructure:"updated_at"`
	DeletedAt     *time.Time `mapstructure:"deleted_at"`
}

type ServiceDomain added in v0.4.3

type ServiceDomain struct {
	Locked    bool       `mapstructure:"locked"`
	Version   int64      `mapstructure:"version"`
	Name      string     `mapstructure:"name"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
	ServiceID string     `mapstructure:"service_id"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	Comment   string     `mapstructure:"comment"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
}

type ServiceDomainsList added in v0.4.3

type ServiceDomainsList []*ServiceDomain

type ServicesByRegionsUsage added in v0.4.0

type ServicesByRegionsUsage map[string]*ServicesUsage

ServicesByRegionsUsage is a list of ServicesUsage by Fastly's region

type ServicesUsage added in v0.4.0

type ServicesUsage map[string]*Usage

ServicesUsage is a list of usage data by a service

type Settings

type Settings struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	DefaultTTL      uint   `mapstructure:"general.default_ttl"`
	DefaultHost     string `mapstructure:"general.default_host"`
	StaleIfError    bool   `mapstructure:"general.stale_if_error"`
	StaleIfErrorTTL uint   `mapstructure:"general.stale_if_error_ttl"`
}

Settings represents a backend response from the Fastly API.

type Snippet added in v0.4.3

type Snippet struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name      string      `mapstructure:"name"`
	ID        string      `mapstructure:"id"`
	Priority  int         `mapstructure:"priority"`
	Dynamic   int         `mapstructure:"dynamic"`
	Content   string      `mapstructure:"content"`
	Type      SnippetType `mapstructure:"type"`
	CreatedAt *time.Time  `mapstructure:"created_at"`
	UpdatedAt *time.Time  `mapstructure:"updated_at"`
	DeletedAt *time.Time  `mapstructure:"deleted_at"`
}

Snippet is the Fastly Snippet object

type SnippetType added in v0.4.3

type SnippetType string

SnippetType is the type of VCL Snippet

const (
	// SnippetTypeInit sets the type to init
	SnippetTypeInit SnippetType = "init"

	// SnippetTypeRecv sets the type to recv
	SnippetTypeRecv SnippetType = "recv"

	// SnippetTypeHash sets the type to hash
	SnippetTypeHash SnippetType = "hash"

	// SnippetTypeHit sets the type to hit
	SnippetTypeHit SnippetType = "hit"

	// SnippetTypeMiss sets the type to miss
	SnippetTypeMiss SnippetType = "miss"

	// SnippetTypePass sets the type to pass
	SnippetTypePass SnippetType = "pass"

	// SnippetTypeFetch sets the type to fetch
	SnippetTypeFetch SnippetType = "fetch"

	// SnippetTypeError sets the type to error
	SnippetTypeError SnippetType = "error"

	// SnippetTypeDeliver sets the type to deliver
	SnippetTypeDeliver SnippetType = "deliver"

	// SnippetTypeLog sets the type to log
	SnippetTypeLog SnippetType = "log"

	// SnippetTypeNone sets the type to none
	SnippetTypeNone SnippetType = "none"
)

type Splunk added in v0.4.3

type Splunk struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	URL               string     `mapstructure:"url"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	Token             string     `mapstructure:"token"`
	TLSCACert         string     `mapstructure:"tls_ca_cert"`
	TLSHostname       string     `mapstructure:"tls_hostname"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Splunk represents a splunk response from the Fastly API.

type Stats added in v0.4.0

type Stats struct {
	Requests                  uint64      `mapstructure:"requests"`                 // Number of requests processed.
	Hits                      uint64      `mapstructure:"hits"`                     // Number of cache hits.
	HitsTime                  float64     `mapstructure:"hits_time"`                // Total amount of time spent processing cache hits (in seconds).
	Miss                      uint64      `mapstructure:"miss"`                     // Number of cache misses.
	MissTime                  float64     `mapstructure:"miss_time"`                // Amount of time spent processing cache misses (in seconds).
	Pass                      uint64      `mapstructure:"pass"`                     // Number of requests that passed through the CDN without being cached.
	PassTime                  float64     `mapstructure:"pass_time"`                // Amount of time spent processing cache passes (in seconds).
	Synth                     uint64      `mapstructure:"synth"`                    // Number of requests that returned synth response.
	Errors                    uint64      `mapstructure:"errors"`                   // Number of cache errors.
	Restarts                  uint64      `mapstructure:"restarts"`                 // Number of restarts performed.
	HitRatio                  float64     `mapstructure:"hit_ratio"`                // Ratio of cache hits to cache misses (between 0 and 1).
	Bandwidth                 uint64      `mapstructure:"bandwidth"`                // Total bytes delivered (body_size + header_size).
	RequestBodyBytes          uint64      `mapstructure:"req_body_bytes"`           // Total body bytes received.
	RequestHeaderBytes        uint64      `mapstructure:"req_header_bytes"`         // Total header bytes received.
	ResponseBodyBytes         uint64      `mapstructure:"resp_body_bytes"`          // Total body bytes delivered.
	ResponseHeaderBytes       uint64      `mapstructure:"resp_header_bytes"`        // Total header bytes delivered.
	BERequestBodyBytes        uint64      `mapstructure:"bereq_body_bytes"`         // Total body bytes sent to origin.
	BERequestHeaderbytes      uint64      `mapstructure:"bereq_header_bytes"`       // Total header bytes sent to origin.
	Uncachable                uint64      `mapstructure:"uncachable"`               // Number of requests that were designated uncachable.
	Pipe                      uint64      `mapstructure:"pipe"`                     // Optional. Pipe operations performed (legacy feature).
	TLS                       uint64      `mapstructure:"tls"`                      // Number of requests that were received over TLS.
	TLSv10                    uint64      `mapstructure:"tls_v10"`                  // Number of requests received over TLS 1.0.
	TLSv11                    uint64      `mapstructure:"tls_v11"`                  // Number of requests received over TLS 1.`.
	TLSv12                    uint64      `mapstructure:"tls_v12"`                  // Number of requests received over TLS 1.2.
	TLSv13                    uint64      `mapstructure:"tls_v13"`                  // Number of requests received over TLS 1.3.
	Shield                    uint64      `mapstructure:"shield"`                   // Number of requests from shield to origin.
	ShieldResponseBodyBytes   uint64      `mapstructure:"shield_resp_body_bytes"`   // Total body bytes delivered via a shield.
	ShieldResponseHeaderBytes uint64      `mapstructure:"shield_resp_header_bytes"` // Total header bytes delivered via a shield.
	IPv6                      uint64      `mapstructure:"ipv6"`                     // Number of requests that were received over IPv6.
	OTFP                      uint64      `mapstructure:"otfp"`                     // Number of responses that came from the Fastly On-the-Fly Packager for On Demand Streaming service for video-on-demand.
	Video                     uint64      `mapstructure:"video"`                    // Number of responses with the video segment or video manifest MIME type (i.e., application/x-mpegurl, application/vnd.apple.mpegurl, application/f4m, application/dash+xml, application/vnd.ms-sstr+xml, ideo/mp2t, audio/aac, video/f4f, video/x-flv, video/mp4, audio/mp4).
	PCI                       uint64      `mapstructure:"pci"`                      // Number of responses with the PCI flag turned on.
	Log                       uint64      `mapstructure:"log"`                      // Number of log lines sent.
	HTTP2                     uint64      `mapstructure:"http2"`                    // Number of requests received over HTTP2.
	WAFLogged                 uint64      `mapstructure:"waf_logged"`               // Number of requests that triggered a WAF rule and were logged.
	WAFBlocked                uint64      `mapstructure:"waf_blocked"`              // Number of requests that triggered a WAF rule and were blocked.
	WAFPassed                 uint64      `mapstructure:"waf_passed"`               // Number of requests that triggered a WAF rule and were passed.
	AttackRequestBodyBytes    uint64      `mapstructure:"attack_req_body_bytes"`    // Total body bytes received from requests that triggered a WAF rule.
	AttachRequestHeaderBytes  uint64      `mapstructure:"attack_req_header_bytes"`  // Total header bytes received from requests that triggered a WAF rule.
	AttackResponseSynthBytes  uint64      `mapstructure:"attack_resp_synth_bytes"`  // Total bytes delivered for requests that triggered a WAF rule and returned a synthetic response.
	ImageOptimizer            uint64      `mapstructure:"imgopto"`                  // Number of responses that came from the Fastly Image Optimizer service.
	Status200                 uint64      `mapstructure:"status_200"`               // Number of responses sent with status code 200 (Success).
	Status204                 uint64      `mapstructure:"status_204"`               // Number of responses sent with status code 204 (No Content).
	Status301                 uint64      `mapstructure:"status_301"`               // Number of responses sent with status code 301 (Moved Permanently).
	Status302                 uint64      `mapstructure:"status_302"`               // Number of responses sent with status code 302 (Found).
	Status304                 uint64      `mapstructure:"status_304"`               // Number of responses sent with status code 304 (Not Modified).
	Status400                 uint64      `mapstructure:"status_400"`               // Number of responses sent with status code 400 (Bad Request).
	Status401                 uint64      `mapstructure:"status_401"`               // Number of responses sent with status code 401 (Unauthorized).
	Status403                 uint64      `mapstructure:"status_403"`               // Number of responses sent with status code 403 (Forbidden).
	Status404                 uint64      `mapstructure:"status_404"`               // Number of responses sent with status code 404 (Not Found).
	Status416                 uint64      `mapstructure:"status_416"`               // Number of responses sent with status code 416 (Range Not Satisfiable).
	Status500                 uint64      `mapstructure:"status_500"`               // Number of responses sent with status code 500 (Internal Server Error).
	Status501                 uint64      `mapstructure:"status_501"`               // Number of responses sent with status code 501 (Not Implemented).
	Status502                 uint64      `mapstructure:"status_502"`               // Number of responses sent with status code 502 (Bad Gateway).
	Status503                 uint64      `mapstructure:"status_503"`               // Number of responses sent with status code 503 (Service Unavailable).
	Status504                 uint64      `mapstructure:"status_504"`               // Number of responses sent with status code 504 (Gateway Timeout).
	Status505                 uint64      `mapstructure:"status_505"`               // Number of responses sent with status code 505 (HTTP Version Not Supported).
	Status1xx                 uint64      `mapstructure:"status_1xx"`               // Number of "Informational" category status codes delivered.
	Status2xx                 uint64      `mapstructure:"status_2xx"`               // Number of "Success" status codes delivered.
	Status3xx                 uint64      `mapstructure:"status_3xx"`               // Number of "Redirection" codes delivered.
	Status4xx                 uint64      `mapstructure:"status_4xx"`               // Number of "Client Error" codes delivered.
	Status5xx                 uint64      `mapstructure:"status_5xx"`               // Number of "Server Error" codes delivered.
	ObjectSize1k              uint64      `mapstructure:"object_size_1k"`           // Number of objects served that were under 1KB in size.
	ObjectSize10k             uint64      `mapstructure:"object_size_10k"`          // Number of objects served that were between 1KB and 10KB in size.
	ObjectSize100k            uint64      `mapstructure:"object_size_100k"`         // Number of objects served that were between 10KB and 100KB in size.
	ObjectSize1m              uint64      `mapstructure:"object_size_1m"`           // Number of objects served that were between 100KB and 1MB in size.
	ObjectSize10m             uint64      `mapstructure:"object_size_10m"`          // Number of objects served that were between 1MB and 10MB in size.
	ObjectSize100m            uint64      `mapstructure:"object_size_100m"`         // Number of objects served that were between 10MB and 100MB in size.
	ObjectSize1g              uint64      `mapstructure:"object_size_1g"`           // Number of objects served that were between 100MB and 1GB in size.
	MissHistogram             map[int]int `mapstructure:"miss_histogram"`           // Number of requests to origin in time buckets of 10s of milliseconds
	BilledHeaderBytes         uint64      `mapstructure:"billed_header_bytes"`
	BilledBodyBytes           uint64      `mapstructure:"billed_body_bytes"`
}

Stats represent metrics of a Fastly service

type StatsResponse added in v0.4.0

type StatsResponse struct {
	Status  string            `mapstructure:"status"`
	Meta    map[string]string `mapstructure:"meta"`
	Message string            `mapstructure:"msg"`
	Data    []*Stats          `mapstructure:"data"`
}

StatsResponse is a response from the service stats API endpoint

type Sumologic

type Sumologic struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Address           string     `mapstructure:"address"`
	URL               string     `mapstructure:"url"`
	Format            string     `mapstructure:"format"`
	ResponseCondition string     `mapstructure:"response_condition"`
	MessageType       string     `mapstructure:"message_type"`
	FormatVersion     int        `mapstructure:"format_version"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
	Placement         string     `mapstructure:"placement"`
}

Sumologic represents a sumologic response from the Fastly API.

type Syslog

type Syslog struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name              string     `mapstructure:"name"`
	Address           string     `mapstructure:"address"`
	Hostname          string     `mapstructure:"hostname"`
	Port              uint       `mapstructure:"port"`
	UseTLS            bool       `mapstructure:"use_tls"`
	IPV4              string     `mapstructure:"ipv4"`
	TLSCACert         string     `mapstructure:"tls_ca_cert"`
	TLSHostname       string     `mapstructure:"tls_hostname"`
	TLSClientCert     string     `mapstructure:"tls_client_cert"`
	TLSClientKey      string     `mapstructure:"tls_client_key"`
	Token             string     `mapstructure:"token"`
	Format            string     `mapstructure:"format"`
	FormatVersion     uint       `mapstructure:"format_version"`
	MessageType       string     `mapstructure:"message_type"`
	ResponseCondition string     `mapstructure:"response_condition"`
	Placement         string     `mapstructure:"placement"`
	CreatedAt         *time.Time `mapstructure:"created_at"`
	UpdatedAt         *time.Time `mapstructure:"updated_at"`
	DeletedAt         *time.Time `mapstructure:"deleted_at"`
}

Syslog represents a syslog response from the Fastly API.

type TLSConfiguration added in v0.16.0

type TLSConfiguration struct {
	ID   string `jsonapi:"primary,tls_configuration"`
	Type string `jsonapi:"attr,type"`
}

TLSConfiguration represents the dedicated IP address pool that will be used to route traffic from the TLSDomain.

type TLSDomain added in v0.16.0

type TLSDomain struct {
	ID   string `jsonapi:"primary,tls_domain"`
	Type string `jsonapi:"attr,type"`
}

TLSDomain represents a domain (including wildcard domains) that is listed on a certificate's Subject Alternative Names (SAN) list.

type Token added in v0.16.0

type Token struct {
	ID          string     `mapstructure:"id"`
	Name        string     `mapstructure:"name"`
	UserID      string     `mapstructure:"user_id"`
	Services    []string   `mapstructure:"services"`
	AccessToken string     `mapstructure:"access_token"`
	Scope       TokenScope `mapstructure:"scope"`
	IP          string     `mapstructure:"ip"`
	CreatedAt   *time.Time `mapstructure:"created_at"`
	LastUsedAt  *time.Time `mapstructure:"last_used_at"`
	ExpiresAt   *time.Time `mapstructure:"expires_at"`
}

Token represents an API token which are used to authenticate requests to the Fastly API.

type TokenScope added in v0.16.0

type TokenScope string

TokenScope is used to match possible authorization scopes

const (
	// GlobalScope is the default scope covering all supported capabilities.
	GlobalScope TokenScope = "global"
	// PurgeSelectScope allows purging with surrogate key and URL, disallows purging with purge all.
	PurgeSelectScope TokenScope = "purge_select"
	// PurgeAllScope allows purging an entire service via purge_all.
	PurgeAllScope TokenScope = "purge_all"
	// GlobalReadScope allows read-only access to account information, configuration, and stats.
	GlobalReadScope TokenScope = "global:read"
)

type UpdateACLEntryInput added in v0.4.0

type UpdateACLEntryInput struct {
	// Required fields
	Service string
	ACL     string
	ID      string

	// Optional fields
	IP      string `form:"ip,omitempty"`
	Subnet  string `form:"subnet,omitempty"`
	Negated bool   `form:"negated,omitempty"`
	Comment string `form:"comment,omitempty"`
}

UpdateACLEntryInput is the input parameter to UpdateACLEntry function.

type UpdateACLInput added in v0.4.0

type UpdateACLInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the ACL to update (required).
	Name string

	// NewName is the new name of the ACL to update (required).
	NewName string `form:"name"`
}

UpdateACLInput is the input parameter to UpdateACL function.

type UpdateBackendInput

type UpdateBackendInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the backend to update.
	Name string

	NewName             string       `form:"name,omitempty"`
	Comment             string       `form:"comment,omitempty"`
	Address             string       `form:"address,omitempty"`
	Port                uint         `form:"port,omitempty"`
	OverrideHost        string       `form:"override_host,omitempty"`
	ConnectTimeout      uint         `form:"connect_timeout,omitempty"`
	MaxConn             uint         `form:"max_conn,omitempty"`
	ErrorThreshold      uint         `form:"error_threshold,omitempty"`
	FirstByteTimeout    uint         `form:"first_byte_timeout,omitempty"`
	BetweenBytesTimeout uint         `form:"between_bytes_timeout,omitempty"`
	AutoLoadbalance     *Compatibool `form:"auto_loadbalance,omitempty"`
	Weight              uint         `form:"weight,omitempty"`
	RequestCondition    string       `form:"request_condition,omitempty"`
	HealthCheck         string       `form:"healthcheck,omitempty"`
	Shield              string       `form:"shield,omitempty"`
	UseSSL              *Compatibool `form:"use_ssl,omitempty"`
	SSLCheckCert        *Compatibool `form:"ssl_check_cert,omitempty"`
	SSLCACert           string       `form:"ssl_ca_cert,omitempty"`
	SSLClientCert       string       `form:"ssl_client_cert,omitempty"`
	SSLClientKey        string       `form:"ssl_client_key,omitempty"`
	SSLHostname         string       `form:"ssl_hostname,omitempty"`
	SSLCertHostname     string       `form:"ssl_cert_hostname,omitempty"`
	SSLSNIHostname      string       `form:"ssl_sni_hostname,omitempty"`
	MinTLSVersion       string       `form:"min_tls_version,omitempty"`
	MaxTLSVersion       string       `form:"max_tls_version,omitempty"`
	SSLCiphers          []string     `form:"ssl_ciphers,omitempty"`
}

UpdateBackendInput is used as input to the UpdateBackend function.

type UpdateBigQueryInput added in v0.4.3

type UpdateBigQueryInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the BigQuery to update.
	Name string

	NewName           string `form:"name,omitempty"`
	ProjectID         string `form:"project_id,omitempty"`
	Dataset           string `form:"dataset,omitempty"`
	Table             string `form:"table,omitempty"`
	Template          string `form:"template_suffix,omitempty"`
	User              string `form:"user,omitempty"`
	SecretKey         string `form:"secret_key,omitempty"`
	Format            string `form:"format,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	Placement         string `form:"placement,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
}

UpdateBigQueryInput is used as input to the UpdateBigQuery function.

type UpdateBlobStorageInput added in v0.4.3

type UpdateBlobStorageInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the blob storage to update.
	Name string

	NewName           string `form:"name,omitempty"`
	Path              string `form:"path,omitempty"`
	AccountName       string `form:"account_name,omitempty"`
	Container         string `form:"container,omitempty"`
	SASToken          string `form:"sas_token,omitempty"`
	Period            uint   `form:"period,omitempty"`
	TimestampFormat   string `form:"timestamp_format,omitempty"`
	GzipLevel         uint   `form:"gzip_level,omitempty"`
	PublicKey         string `form:"public_key,omitempty"`
	Format            string `form:"format,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
	MessageType       string `form:"message_type,omitempty"`
	Placement         string `form:"placement,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
}

UpdateBlobStorageInput is used as input to the UpdateBlobStorage function.

type UpdateBulkCertificateInput added in v0.16.0

type UpdateBulkCertificateInput struct {
	ID                string `jsonapi:"attr,id"`
	CertBlob          string `jsonapi:"attr,cert_blob"`
	IntermediatesBlob string `jsonapi:"attr,intermediates_blob"`
}

UpdateBulkCertificateInput is used as input to the UpdateBulkCertificate function.

type UpdateCacheSettingInput

type UpdateCacheSettingInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the cache setting to update.
	Name string

	NewName        string             `form:"name,omitempty"`
	Action         CacheSettingAction `form:"action,omitempty"`
	TTL            uint               `form:"ttl,omitempty"`
	StaleTTL       uint               `form:"stale_ttl,omitempty"`
	CacheCondition string             `form:"cache_condition,omitempty"`
}

UpdateCacheSettingInput is used as input to the UpdateCacheSetting function.

type UpdateCloudfilesInput added in v0.16.0

type UpdateCloudfilesInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Cloudfiles to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	User              *string `form:"user,omitempty"`
	AccessKey         *string `form:"access_key,omitempty"`
	BucketName        *string `form:"bucket_name,omitempty"`
	Path              *string `form:"path,omitempty"`
	Region            *string `form:"region,omitempty"`
	Placement         *string `form:"placement,omitempty"`
	Period            *uint   `form:"period,omitempty"`
	GzipLevel         *uint   `form:"gzip_level,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	MessageType       *string `form:"message_type,omitempty"`
	TimestampFormat   *string `form:"timestamp_format,omitempty"`
	PublicKey         *string `form:"public_key,omitempty"`
}

UpdateCloudfilesInput is used as input to the UpdateCloudfiles function.

type UpdateConditionInput

type UpdateConditionInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the condition to update.
	Name string

	Comment   string `form:"comment,omitempty"`
	Statement string `form:"statement,omitempty"`
	Type      string `form:"type,omitempty"`
	Priority  int    `form:"priority,omitempty"`
}

UpdateConditionInput is used as input to the UpdateCondition function.

type UpdateDatadogInput added in v0.16.0

type UpdateDatadogInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Datadog to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	Token             *string `form:"token,omitempty"`
	Region            *string `form:"region,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

UpdateDatadogInput is used as input to the UpdateDatadog function.

type UpdateDictionaryInput

type UpdateDictionaryInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the dictionary to update.
	Name string

	NewName   string       `form:"name,omitempty"`
	WriteOnly *Compatibool `form:"write_only,omitempty"`
}

UpdateDictionaryInput is used as input to the UpdateDictionary function.

type UpdateDictionaryItemInput

type UpdateDictionaryItemInput struct {
	// Service is the ID of the service. Dictionary is the ID of the dictionary.
	// Both fields are required.
	Service    string
	Dictionary string

	// ItemKey is the name of the dictionary item to fetch.
	ItemKey string

	ItemValue string `form:"item_value,omitempty"`
}

UpdateDictionaryItemInput is used as input to the UpdateDictionaryItem function.

type UpdateDigitalOceanInput added in v0.16.0

type UpdateDigitalOceanInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the DigitalOcean to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	BucketName        *string `form:"bucket_name,omitempty"`
	Domain            *string `form:"domain,omitempty"`
	AccessKey         *string `form:"access_key,omitempty"`
	SecretKey         *string `form:"secret_key,omitempty"`
	Path              *string `form:"path,omitempty"`
	Period            *uint   `form:"period,omitempty"`
	GzipLevel         *uint   `form:"gzip_level,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	MessageType       *string `form:"message_type,omitempty"`
	TimestampFormat   *string `form:"timestamp_format,omitempty"`
	Placement         *string `form:"placement,omitempty"`
	PublicKey         *string `form:"public_key,omitempty"`
}

UpdateDigitalOceanInput is used as input to the UpdateDigitalOcean function.

type UpdateDirectorInput

type UpdateDirectorInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the director to update.
	Name string

	NewName  string       `form:"name,omitempty"`
	Comment  string       `form:"comment,omitempty"`
	Shield   string       `form:"shield,omitempty"`
	Quorum   uint         `form:"quorum,omitempty"`
	Type     DirectorType `form:"type,omitempty"`
	Retries  uint         `form:"retries,omitempty"`
	Capacity uint         `form:"capacity,omitempty"`
}

UpdateDirectorInput is used as input to the UpdateDirector function.

type UpdateDomainInput

type UpdateDomainInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the domain that the service will respond to (required).
	Name string

	// NewName is the updated name of the domain
	NewName string `form:"name"`

	// Comment is a personal, freeform descriptive note.
	Comment string `form:"comment,omitempty"`
}

UpdateDomainInput is used as input to the UpdateDomain function.

type UpdateDynamicSnippetInput added in v0.4.3

type UpdateDynamicSnippetInput struct {
	// Service is the ID of the Service to add the snippet to.
	Service string

	// ID is the ID of the Snippet to modify
	ID string

	// Content is the VCL code that specifies exactly what the snippet does.
	Content string `form:"content"`
}

UpdateDynamicSnippetInput is the input for UpdateDynamicSnippet

type UpdateElasticsearchInput added in v0.16.0

type UpdateElasticsearchInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Elasticsearch endpoint to fetch.
	Name string

	NewName           *string `form:"name,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Format            *string `form:"format,omitempty"`
	Index             *string `form:"index,omitempty"`
	URL               *string `form:"url,omitempty"`
	Pipeline          *string `form:"pipeline,omitempty"`
	User              *string `form:"user,omitempty"`
	Password          *string `form:"password,omitempty"`
	RequestMaxEntries *uint   `form:"request_max_entries,omitempty"`
	RequestMaxBytes   *uint   `form:"request_max_bytes,omitempty"`
	Placement         *string `form:"placement,omitempty"`
	TLSCACert         *string `form:"tls_ca_cert,omitempty"`
	TLSClientCert     *string `form:"tls_client_cert,omitempty"`
	TLSClientKey      *string `form:"tls_client_key,omitempty"`
	TLSHostname       *string `form:"tls_hostname,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
}

type UpdateFTPInput

type UpdateFTPInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the FTP to update.
	Name string

	NewName           string `form:"name,omitempty"`
	Address           string `form:"address,omitempty"`
	Port              uint   `form:"port,omitempty"`
	PublicKey         string `form:"public_key,omitempty"`
	Username          string `form:"user,omitempty"`
	Password          string `form:"password,omitempty"`
	Path              string `form:"path,omitempty"`
	Period            uint   `form:"period,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
	GzipLevel         uint8  `form:"gzip_level,omitempty"`
	Format            string `form:"format,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	MessageType       string `form:"message_type,omitempty"`
	TimestampFormat   string `form:"timestamp_format,omitempty"`
	Placement         string `form:"placement,omitempty"`
}

UpdateFTPInput is used as input to the UpdateFTP function.

type UpdateGCSInput

type UpdateGCSInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the GCS to update.
	Name string

	NewName           string `form:"name,omitempty"`
	Bucket            string `form:"bucket_name,omitempty"`
	User              string `form:"user,omitempty"`
	SecretKey         string `form:"secret_key,omitempty"`
	Path              string `form:"path,omitempty"`
	Period            uint   `form:"period,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
	GzipLevel         uint8  `form:"gzip_level,omitempty"`
	Format            string `form:"format,omitempty"`
	MessageType       string `form:"message_type,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	TimestampFormat   string `form:"timestamp_format,omitempty"`
	Placement         string `form:"placement,omitempty"`
}

UpdateGCSInput is used as input to the UpdateGCS function.

type UpdateGzipInput

type UpdateGzipInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Gzip to update.
	Name string

	NewName        string `form:"name,omitempty"`
	ContentTypes   string `form:"content_types,omitempty"`
	Extensions     string `form:"extensions,omitempty"`
	CacheCondition string `form:"cache_condition,omitempty"`
}

UpdateGzipInput is used as input to the UpdateGzip function.

type UpdateHTTPSInput added in v0.16.0

type UpdateHTTPSInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the HTTPS endpoint to fetch.
	Name string

	NewName           string `form:"name,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	Format            string `form:"format,omitempty"`
	URL               string `form:"url,omitempty"`
	RequestMaxEntries uint   `form:"request_max_entries,omitempty"`
	RequestMaxBytes   uint   `form:"request_max_bytes,omitempty"`
	ContentType       string `form:"content_type,omitempty"`
	HeaderName        string `form:"header_name,omitempty"`
	HeaderValue       string `form:"header_value,omitempty"`
	Method            string `form:"method,omitempty"`
	JSONFormat        string `form:"json_format,omitempty"`
	Placement         string `form:"placement,omitempty"`
	TLSCACert         string `form:"tls_ca_cert,omitempty"`
	TLSClientCert     string `form:"tls_client_cert,omitempty"`
	TLSClientKey      string `form:"tls_client_key,omitempty"`
	TLSHostname       string `form:"tls_hostname,omitempty"`
	MessageType       string `form:"message_type,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
}

type UpdateHeaderInput

type UpdateHeaderInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the header to update.
	Name string

	NewName           string       `form:"name,omitempty"`
	Action            HeaderAction `form:"action,omitempty"`
	IgnoreIfSet       *Compatibool `form:"ignore_if_set,omitempty"`
	Type              HeaderType   `form:"type,omitempty"`
	Destination       string       `form:"dst,omitempty"`
	Source            string       `form:"src,omitempty"`
	Regex             string       `form:"regex,omitempty"`
	Substitution      string       `form:"substitution,omitempty"`
	Priority          uint         `form:"priority,omitempty"`
	RequestCondition  string       `form:"request_condition,omitempty"`
	CacheCondition    string       `form:"cache_condition,omitempty"`
	ResponseCondition string       `form:"response_condition,omitempty"`
}

UpdateHeaderInput is used as input to the UpdateHeader function.

type UpdateHealthCheckInput

type UpdateHealthCheckInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the health check to update.
	Name string

	NewName          string `form:"name,omitempty"`
	Comment          string `form:"comment,omitempty"`
	Method           string `form:"method,omitempty"`
	Host             string `form:"host,omitempty"`
	Path             string `form:"path,omitempty"`
	HTTPVersion      string `form:"http_version,omitempty"`
	Timeout          uint   `form:"timeout,omitempty"`
	CheckInterval    uint   `form:"check_interval,omitempty"`
	ExpectedResponse uint   `form:"expected_response,omitempty"`
	Window           uint   `form:"window,omitempty"`
	Threshold        uint   `form:"threshold,omitempty"`
	Initial          uint   `form:"initial,omitempty"`
}

UpdateHealthCheckInput is used as input to the UpdateHealthCheck function.

type UpdateHerokuInput added in v0.16.0

type UpdateHerokuInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the heroku to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	URL               *string `form:"url,omitempty"`
	Token             *string `form:"token,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

UpdateHerokuInput is used as input to the UpdateHeroku function.

type UpdateHoneycombInput added in v0.16.0

type UpdateHoneycombInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the honeycomb to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	Dataset           *string `form:"dataset,omitempty"`
	Token             *string `form:"token,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

UpdateHoneycombInput is used as input to the UpdateHoneycomb function.

type UpdateKafkaInput added in v0.16.0

type UpdateKafkaInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the kafka to update.
	Name string

	NewName           *string      `form:"name,omitempty"`
	Brokers           *string      `form:"brokers,omitempty"`
	Topic             *string      `form:"topic,omitempty"`
	RequiredACKs      *string      `form:"required_acks,omitempty"`
	UseTLS            *Compatibool `form:"use_tls,omitempty"`
	CompressionCodec  *string      `form:"compression_codec,omitempty"`
	Format            *string      `form:"format,omitempty"`
	FormatVersion     *uint        `form:"format_version,omitempty"`
	ResponseCondition *string      `form:"response_condition,omitempty"`
	Placement         *string      `form:"placement,omitempty"`
	TLSCACert         *string      `form:"tls_ca_cert,omitempty"`
	TLSHostname       *string      `form:"tls_hostname,omitempty"`
	TLSClientCert     *string      `form:"tls_client_cert,omitempty"`
	TLSClientKey      *string      `form:"tls_client_key,omitempty"`
	ParseLogKeyvals   *Compatibool `form:"parse_log_keyvals,omitempty"`
	RequestMaxBytes   *uint        `form:"request_max_bytes,omitempty"`
	AuthMethod        *string      `form:"auth_method,omitempty"`
	User              *string      `form:"user,omitempty"`
	Password          *string      `form:"password,omitempty"`
}

UpdateKafkaInput is used as input to the UpdateKafka function.

type UpdateLogentriesInput

type UpdateLogentriesInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the logentries to update.
	Name string

	NewName           string       `form:"name,omitempty"`
	Port              uint         `form:"port,omitempty"`
	UseTLS            *Compatibool `form:"use_tls,omitempty"`
	Token             string       `form:"token,omitempty"`
	Format            string       `form:"format,omitempty"`
	FormatVersion     uint         `form:"format_version,omitempty"`
	ResponseCondition string       `form:"response_condition,omitempty"`
	Placement         string       `form:"placement,omitempty"`
}

UpdateLogentriesInput is used as input to the UpdateLogentries function.

type UpdateLogglyInput added in v0.16.0

type UpdateLogglyInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the loggly to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	Token             *string `form:"token,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

UpdateLogglyInput is used as input to the UpdateLoggly function.

type UpdateLogshuttleInput added in v0.16.0

type UpdateLogshuttleInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the logshuttle to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	URL               *string `form:"url,omitempty"`
	Token             *string `form:"token,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

UpdateLogshuttleInput is used as input to the UpdateLogshuttle function.

type UpdateNewRelicInput added in v0.16.0

type UpdateNewRelicInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the newrelic to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	Token             *string `form:"token,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

UpdateNewRelicInput is used as input to the UpdateNewRelic function.

type UpdateOWASPInput added in v0.4.3

type UpdateOWASPInput struct {
	// Service is the ID of the service. ID is the ID of the firewall.
	// Both fields are required.
	Service string
	ID      string
	OWASPID string `jsonapi:"primary,owasp,omitempty"`

	Type                             string     `jsonapi:"attr,type"`
	AllowedHTTPVersions              string     `jsonapi:"attr,allowed_http_versions,omitempty"`
	AllowedMethods                   string     `jsonapi:"attr,allowed_methods,omitempty"`
	AllowedRequestContentType        string     `jsonapi:"attr,allowed_request_content_type,omitempty"`
	AllowedRequestContentTypeCharset string     `jsonapi:"attr,allowed_request_content_type_charset,omitempty"`
	ArgLength                        int        `jsonapi:"attr,arg_length,omitempty"`
	ArgNameLength                    int        `jsonapi:"attr,arg_name_length,omitempty"`
	CombinedFileSizes                int        `jsonapi:"attr,combined_file_sizes,omitempty"`
	CreatedAt                        *time.Time `jsonapi:"attr,created_at,omitempty,iso8601"`
	CriticalAnomalyScore             int        `jsonapi:"attr,critical_anomaly_score,omitempty"`
	CRSValidateUTF8Encoding          bool       `jsonapi:"attr,crs_validate_utf8_encoding,omitempty"`
	ErrorAnomalyScore                int        `jsonapi:"attr,error_anomaly_score,omitempty"`
	HighRiskCountryCodes             string     `jsonapi:"attr,high_risk_country_codes,omitempty"`
	HTTPViolationScoreThreshold      int        `jsonapi:"attr,http_violation_score_threshold,omitempty"`
	InboundAnomalyScoreThreshold     int        `jsonapi:"attr,inbound_anomaly_score_threshold,omitempty"`
	LFIScoreThreshold                int        `jsonapi:"attr,lfi_score_threshold,omitempty"`
	MaxFileSize                      int        `jsonapi:"attr,max_file_size,omitempty"`
	MaxNumArgs                       int        `jsonapi:"attr,max_num_args,omitempty"`
	NoticeAnomalyScore               int        `jsonapi:"attr,notice_anomaly_score,omitempty"`
	ParanoiaLevel                    int        `jsonapi:"attr,paranoia_level,omitempty"`
	PHPInjectionScoreThreshold       int        `jsonapi:"attr,php_injection_score_threshold,omitempty"`
	RCEScoreThreshold                int        `jsonapi:"attr,rce_score_threshold,omitempty"`
	RestrictedExtensions             string     `jsonapi:"attr,restricted_extensions,omitempty"`
	RestrictedHeaders                string     `jsonapi:"attr,restricted_headers,omitempty"`
	RFIScoreThreshold                int        `jsonapi:"attr,rfi_score_threshold,omitempty"`
	SessionFixationScoreThreshold    int        `jsonapi:"attr,session_fixation_score_threshold,omitempty"`
	SQLInjectionScoreThreshold       int        `jsonapi:"attr,sql_injection_score_threshold,omitempty"`
	TotalArgLength                   int        `jsonapi:"attr,total_arg_length,omitempty"`
	UpdatedAt                        *time.Time `jsonapi:"attr,updated_at,omitempty,iso8601"`
	WarningAnomalyScore              int        `jsonapi:"attr,warning_anomaly_score,omitempty"`
	XSSScoreThreshold                int        `jsonapi:"attr,xss_score_threshold,omitempty"`
}

UpdateOWASPInput is used as input to the CreateOWASP function.

type UpdateOpenstackInput added in v0.16.0

type UpdateOpenstackInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Openstack to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	AccessKey         *string `form:"access_key,omitempty"`
	BucketName        *string `form:"bucket_name,omitempty"`
	URL               *string `form:"url,omitempty"`
	User              *string `form:"user,omitempty"`
	Path              *string `form:"path,omitempty"`
	Placement         *string `form:"placement,omitempty"`
	Period            *uint   `form:"period,omitempty"`
	GzipLevel         *uint   `form:"gzip_level,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	MessageType       *string `form:"message_type,omitempty"`
	TimestampFormat   *string `form:"timestamp_format,omitempty"`
	PublicKey         *string `form:"public_key,omitempty"`
}

UpdateOpenstackInput is used as input to the UpdateOpenstack function.

type UpdatePackageInput added in v0.16.0

type UpdatePackageInput struct {
	// Service is the ID of the service.
	// Version is the specific configuration version.
	// Both fields are required.
	Service string `mapstructure:"service_id"`
	Version int    `mapstructure:"version"`

	// PackagePath is the local filesystem path to the package to upload.
	PackagePath string
}

UpdatePackageInput is used as input to the UpdatePackage function.

type UpdatePapertrailInput

type UpdatePapertrailInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the papertrail to update.
	Name string

	NewName           string     `form:"name,omitempty"`
	Address           string     `form:"address,omitempty"`
	Port              uint       `form:"port,omitempty"`
	FormatVersion     uint       `form:"format_version,omitempty"`
	Format            string     `form:"format,omitempty"`
	ResponseCondition string     `form:"response_condition,omitempty"`
	CreatedAt         *time.Time `form:"created_at,omitempty"`
	UpdatedAt         *time.Time `form:"updated_at,omitempty"`
	DeletedAt         *time.Time `form:"deleted_at,omitempty"`
	Placement         string     `form:"placement,omitempty"`
}

UpdatePapertrailInput is used as input to the UpdatePapertrail function.

type UpdatePoolInput added in v0.16.0

type UpdatePoolInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Name is the name of the pool to update. All three fields
	// are required.
	Service string
	Version int
	Name    string

	// Optional fields.
	NewName          *string      `form:"name,omitempty"`
	Comment          *string      `form:"comment,omitempty"`
	Shield           *string      `form:"shield,omitempty"`
	RequestCondition *string      `form:"request_condition,omitempty"`
	MaxConnDefault   *uint        `form:"max_conn_default,omitempty"`
	ConnectTimeout   *uint        `form:"connect_timeout,omitempty"`
	FirstByteTimeout *uint        `form:"first_byte_timeout,omitempty"`
	Quorum           *uint        `form:"quorum,omitempty"`
	UseTLS           *Compatibool `form:"use_tls,omitempty"`
	TLSCACert        *string      `form:"tls_ca_cert,omitempty"`
	TLSCiphers       *string      `form:"tls_ciphers,omitempty"`
	TLSClientKey     *string      `form:"tls_client_key,omitempty"`
	TLSClientCert    *string      `form:"tls_client_cert,omitempty"`
	TLSSNIHostname   *string      `form:"tls_sni_hostname,omitempty"`
	TLSCheckCert     *Compatibool `form:"tls_check_cert,omitempty"`
	TLSCertHostname  *string      `form:"tls_cert_hostname,omitempty"`
	MinTLSVersion    *string      `form:"min_tls_version,omitempty"`
	MaxTLSVersion    *string      `form:"max_tls_version,omitempty"`
	Healthcheck      *string      `form:"healthcheck,omitempty"`
	Type             PoolType     `form:"type,omitempty"`
	OverrideHost     *string      `form:"override_host,omitempty"`
}

UpdatePoolInput is used as input to the UpdatePool function.

type UpdatePubsubInput added in v0.16.0

type UpdatePubsubInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the Pubsub to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	Topic             *string `form:"topic,omitempty"`
	User              *string `form:"user,omitempty"`
	SecretKey         *string `form:"secret_key,omitempty"`
	ProjectID         *string `form:"project_id,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	Format            *string `form:"format,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

UpdatePubsubInput is used as input to the UpdatePubsub function.

type UpdateRequestSettingInput

type UpdateRequestSettingInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the request settings to update.
	Name string

	NewName          string               `form:"name,omitempty"`
	ForceMiss        *Compatibool         `form:"force_miss,omitempty"`
	ForceSSL         *Compatibool         `form:"force_ssl,omitempty"`
	Action           RequestSettingAction `form:"action,omitempty"`
	BypassBusyWait   *Compatibool         `form:"bypass_busy_wait,omitempty"`
	MaxStaleAge      uint                 `form:"max_stale_age,omitempty"`
	HashKeys         string               `form:"hash_keys,omitempty"`
	XForwardedFor    RequestSettingXFF    `form:"xff,omitempty"`
	TimerSupport     *Compatibool         `form:"timer_support,omitempty"`
	GeoHeaders       *Compatibool         `form:"geo_headers,omitempty"`
	DefaultHost      string               `form:"default_host,omitempty"`
	RequestCondition string               `form:"request_condition,omitempty"`
}

UpdateRequestSettingInput is used as input to the UpdateRequestSetting function.

type UpdateResponseObjectInput

type UpdateResponseObjectInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the response object to update.
	Name string

	NewName          string `form:"name,omitempty"`
	Status           uint   `form:"status,omitempty"`
	Response         string `form:"response,omitempty"`
	Content          string `form:"content,omitempty"`
	ContentType      string `form:"content_type,omitempty"`
	RequestCondition string `form:"request_condition,omitempty"`
	CacheCondition   string `form:"cache_condition,omitempty"`
}

UpdateResponseObjectInput is used as input to the UpdateResponseObject function.

type UpdateS3Input

type UpdateS3Input struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the S3 to update.
	Name string

	NewName                      string                 `form:"name,omitempty"`
	BucketName                   string                 `form:"bucket_name,omitempty"`
	Domain                       string                 `form:"domain,omitempty"`
	AccessKey                    string                 `form:"access_key,omitempty"`
	SecretKey                    string                 `form:"secret_key,omitempty"`
	Path                         string                 `form:"path,omitempty"`
	Period                       uint                   `form:"period,omitempty"`
	GzipLevel                    uint                   `form:"gzip_level,omitempty"`
	Format                       string                 `form:"format,omitempty"`
	FormatVersion                uint                   `form:"format_version,omitempty"`
	ResponseCondition            string                 `form:"response_condition,omitempty"`
	MessageType                  string                 `form:"message_type,omitempty"`
	TimestampFormat              string                 `form:"timestamp_format,omitempty"`
	Redundancy                   S3Redundancy           `form:"redundancy,omitempty"`
	Placement                    string                 `form:"placement,omitempty"`
	PublicKey                    string                 `form:"public_key,omitempty"`
	ServerSideEncryptionKMSKeyID string                 `form:"server_side_encryption_kms_key_id,omitempty"`
	ServerSideEncryption         S3ServerSideEncryption `form:"server_side_encryption,omitempty"`
}

UpdateS3Input is used as input to the UpdateS3 function.

type UpdateSFTPInput added in v0.16.0

type UpdateSFTPInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the SFTP to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	Address           *string `form:"address,omitempty"`
	Port              *uint   `form:"port,omitempty"`
	PublicKey         *string `form:"public_key,omitempty"`
	SecretKey         *string `form:"secret_key,omitempty"`
	SSHKnownHosts     *string `form:"ssh_known_hosts,omitempty"`
	User              *string `form:"user,omitempty"`
	Password          *string `form:"password,omitempty"`
	Path              *string `form:"path,omitempty"`
	Period            *uint   `form:"period,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	GzipLevel         *uint   `form:"gzip_level,omitempty"`
	Format            *string `form:"format,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	TimestampFormat   *string `form:"timestamp_format,omitempty"`
	MessageType       *string `form:"message_type,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

UpdateSFTPInput is used as input to the UpdateSFTP function.

type UpdateScalyrInput added in v0.16.0

type UpdateScalyrInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the scalyr to update.
	Name string

	NewName           *string `form:"name,omitempty"`
	Format            *string `form:"format,omitempty"`
	FormatVersion     *uint   `form:"format_version,omitempty"`
	Token             *string `form:"token,omitempty"`
	Region            *string `form:"region,omitempty"`
	ResponseCondition *string `form:"response_condition,omitempty"`
	Placement         *string `form:"placement,omitempty"`
}

UpdateScalyrInput is used as input to the UpdateScalyr function.

type UpdateServerInput added in v0.16.0

type UpdateServerInput struct {
	// Service is the ID of the service. Pool is the ID of the pool. Server is
	// the ID of the server in the Pool. These are required fields.
	Service string
	Pool    string
	Server  string

	// Optional fields.
	Address      *string `form:"address,omitempty"`
	Comment      *string `form:"comment,omitempty"`
	Weight       *uint   `form:"weight,omitempty"`
	MaxConn      *uint   `form:"max_conn,omitempty"`
	Port         *uint   `form:"port,omitempty"`
	Disabled     *bool   `form:"disabled,omitempty"`
	OverrideHost *string `form:"override_host,omitempty"`
}

UpdateServerInput is used as input to the UpdateServer function.

type UpdateServiceInput

type UpdateServiceInput struct {
	ID string

	Name    string `form:"name,omitempty"`
	Comment string `form:"comment,omitempty"`
}

UpdateServiceInput is used as input to the UpdateService function.

type UpdateSettingsInput

type UpdateSettingsInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	DefaultTTL      uint   `form:"general.default_ttl"`
	DefaultHost     string `form:"general.default_host,omitempty"`
	StaleIfError    bool   `form:"general.stale_if_error,omitempty"`
	StaleIfErrorTTL uint   `form:"general.stale_if_error_ttl,omitempty"`
}

UpdateSettingsInput is used as input to the UpdateSettings function.

type UpdateSnippetInput added in v0.4.3

type UpdateSnippetInput struct {
	// Service is the ID of the Service to add the snippet to.
	Service string

	// Version is the editable version of the service
	Version int

	Name string

	// Name is the name for the snippet.
	NewName string `form:"name"`

	// Priority determines the ordering for multiple snippets. Lower numbers execute first.
	Priority int `form:"priority"`

	// Dynamic sets the snippet version to regular (0) or dynamic (1).
	Dynamic int `form:"dynamic"`

	// Content is the VCL code that specifies exactly what the snippet does.
	Content string `form:"content"`

	// Type is the location in generated VCL where the snippet should be placed.
	Type SnippetType `form:"type"`
}

UpdateSnippetInput is the input for UpdateSnippet

type UpdateSplunkInput added in v0.4.3

type UpdateSplunkInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the splunk to update.
	Name string

	NewName           string `form:"name,omitempty"`
	URL               string `form:"url,omitempty"`
	Format            string `form:"format,omitempty"`
	FormatVersion     uint   `form:"format_version,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	Placement         string `form:"placement,omitempty"`
	Token             string `form:"token,omitempty"`
	TLSCACert         string `form:"tls_ca_cert,omitempty"`
	TLSHostname       string `form:"tls_hostname,omitempty"`
}

UpdateSplunkInput is used as input to the UpdateSplunk function.

type UpdateSumologicInput

type UpdateSumologicInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the sumologic to update.
	Name string

	NewName           string `form:"name,omitempty"`
	Address           string `form:"address,omitempty"`
	URL               string `form:"url,omitempty"`
	Format            string `form:"format,omitempty"`
	ResponseCondition string `form:"response_condition,omitempty"`
	MessageType       string `form:"message_type,omitempty"`
	FormatVersion     int    `form:"format_version,omitempty"`
	Placement         string `form:"placement,omitempty"`
}

UpdateSumologicInput is used as input to the UpdateSumologic function.

type UpdateSyslogInput

type UpdateSyslogInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the syslog to update.
	Name string

	NewName           string       `form:"name,omitempty"`
	Address           string       `form:"address,omitempty"`
	Hostname          string       `form:"hostname,omitempty"`
	Port              uint         `form:"port,omitempty"`
	UseTLS            *Compatibool `form:"use_tls,omitempty"`
	IPV4              string       `form:"ipv4,omitempty"`
	TLSCACert         string       `form:"tls_ca_cert,omitempty"`
	TLSHostname       string       `form:"tls_hostname,omitempty"`
	TLSClientCert     string       `form:"tls_client_cert,omitempty"`
	TLSClientKey      string       `form:"tls_client_key,omitempty"`
	Token             string       `form:"token,omitempty"`
	Format            string       `form:"format,omitempty"`
	FormatVersion     uint         `form:"format_version,omitempty"`
	MessageType       string       `form:"message_type,omitempty"`
	ResponseCondition string       `form:"response_condition,omitempty"`
	Placement         string       `form:"placement,omitempty"`
}

UpdateSyslogInput is used as input to the UpdateSyslog function.

type UpdateUserInput added in v0.16.0

type UpdateUserInput struct {
	ID string `form:"-"`

	Name string `form:"name,omitempty"`
	Role string `form:"role,omitempty"`
}

UpdateUserInput is used as input to the UpdateUser function.

type UpdateVCLInput

type UpdateVCLInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// Name is the name of the VCL to update (required).
	Name string

	NewName string `form:"name,omitempty"`
	Content string `form:"content,omitempty"`
}

UpdateVCLInput is used as input to the UpdateVCL function.

type UpdateVersionInput

type UpdateVersionInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	// A personal freeform descriptive note.
	Comment string `form:"comment,omitempty"`
}

UpdateVersionInput is the input to the UpdateVersion function.

type UpdateWAFConfigSetInput added in v0.4.3

type UpdateWAFConfigSetInput struct {
	WAFList     []ConfigSetWAFs
	ConfigSetID string
}

UpdateWAFConfigSetInput is used as input to the UpdateWAFConfigSet function.

type UpdateWAFConfigSetResponse added in v0.4.3

type UpdateWAFConfigSetResponse struct {
	IDs []ConfigSetWAFs `jsonapi:"primary,waf"`
}

UpdateWAFConfigSetResponse stores the list of WAFs returned from the call to update its config set

type UpdateWAFInput added in v0.4.2

type UpdateWAFInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int

	ID                string `jsonapi:"primary,waf"`
	PrefetchCondition string `jsonapi:"attr,prefetch_condition,omitempty"`
	Response          string `jsonapi:"attr,response,omitempty"`
}

UpdateWAFInput is used as input to the UpdateWAF function.

type UpdateWAFRuleRuleSetsInput added in v0.4.3

type UpdateWAFRuleRuleSetsInput struct {
	// Service is the ID of the service. ID is the ID of the firewall.
	// Both fields are required.
	Service string
	ID      string `jsonapi:"primary,ruleset"`
}

UpdateWAFRuleRuleSetsInput is used as input to the UpdateWAFRuleSets function.

type UpdateWAFRuleStatusInput added in v0.4.3

type UpdateWAFRuleStatusInput struct {
	ID      string `jsonapi:"primary,rule_status"` // The ID of the rule status. Currently in the format ${WAF_ID}-${rule_ID}.
	RuleID  int
	Service string
	WAF     string
	Status  string `jsonapi:"attr,status"`
}

UpdateWAFRuleStatusInput specifies the parameters for the UpdateWAFRuleStatus call.

type UpdateWAFRuleTagStatusInput added in v0.4.3

type UpdateWAFRuleTagStatusInput struct {
	Service string
	WAF     string
	Status  string `json:"status"` // `jsonapi:"attr,status"`
	Tag     string `json:"name"`   // `jsonapi:"attr,name"`
	Force   bool   `json:"force"`  // `jsonapi:"attr,force"`

}

UpdateWAFRuleTagStatusInput specifies the parameters for the UpdateWAFRuleStatus call.

type Usage added in v0.4.0

type Usage struct {
	Requests  uint64 `mapstructure:"requests"`
	Bandwidth uint64 `mapstructure:"bandwidth"`
}

Usage represents usage data of a single service or region

type UsageByServiceResponse added in v0.4.0

type UsageByServiceResponse struct {
	Status  string                  `mapstructure:"status"`
	Meta    map[string]string       `mapstructure:"meta"`
	Message string                  `mapstructure:"msg"`
	Data    *ServicesByRegionsUsage `mapstructure:"data"`
}

UsageStatsResponse is a response from the account usage API endpoint

type UsageResponse added in v0.4.0

type UsageResponse struct {
	Status  string            `mapstructure:"status"`
	Meta    map[string]string `mapstructure:"meta"`
	Message string            `mapstructure:"msg"`
	Data    *RegionsUsage     `mapstructure:"data"`
}

UsageStatsResponse is a response from the account usage API endpoint

type UsageStatsResponse added in v0.4.0

type UsageStatsResponse struct {
	Status  string            `mapstructure:"status"`
	Meta    map[string]string `mapstructure:"meta"`
	Message string            `mapstructure:"msg"`
	Data    map[string]*Usage `mapstructure:"data"`
}

UsageStatsResponse is a response from the account usage API endpoint

type User added in v0.16.0

type User struct {
	ID                     string     `mapstructure:"id"`
	Login                  string     `mapstructure:"login"`
	Name                   string     `mapstructure:"name"`
	Role                   string     `mapstructure:"role"`
	CustomerID             string     `mapstructure:"customer_id"`
	EmailHash              string     `mapstructure:"email_hash"`
	LimitServices          bool       `mapstructure:"limit_services"`
	Locked                 bool       `mapstructure:"locked"`
	RequireNewPassword     bool       `mapstructure:"require_new_password"`
	TwoFactorAuthEnabled   bool       `mapstructure:"two_factor_auth_enabled"`
	TwoFactorSetupRequired bool       `mapstructure:"two_factor_setup_required"`
	CreatedAt              *time.Time `mapstructure:"created_at"`
	UpdatedAt              *time.Time `mapstructure:"updated_at"`
	DeletedAt              *time.Time `mapstructure:"deleted_at"`
}

User represents a user of the Fastly API and web interface.

type VCL

type VCL struct {
	ServiceID string `mapstructure:"service_id"`
	Version   int    `mapstructure:"version"`

	Name      string     `mapstructure:"name"`
	Main      bool       `mapstructure:"main"`
	Content   string     `mapstructure:"content"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
}

VCL represents a response about VCL from the Fastly API.

type ValidateVersionInput

type ValidateVersionInput struct {
	// Service is the ID of the service. Version is the specific configuration
	// version. Both fields are required.
	Service string
	Version int
}

ValidateVersionInput is the input to the ValidateVersion function.

type Version

type Version struct {
	Number    int        `mapstructure:"number"`
	Comment   string     `mapstructure:"comment"`
	ServiceID string     `mapstructure:"service_id"`
	Active    bool       `mapstructure:"active"`
	Locked    bool       `mapstructure:"locked"`
	Deployed  bool       `mapstructure:"deployed"`
	Staging   bool       `mapstructure:"staging"`
	Testing   bool       `mapstructure:"testing"`
	CreatedAt *time.Time `mapstructure:"created_at"`
	UpdatedAt *time.Time `mapstructure:"updated_at"`
	DeletedAt *time.Time `mapstructure:"deleted_at"`
}

Version represents a distinct configuration version.

type WAF added in v0.4.2

type WAF struct {
	ID                string     `jsonapi:"primary,waf"`
	Version           int        `jsonapi:"attr,version"`
	PrefetchCondition string     `jsonapi:"attr,prefetch_condition"`
	Response          string     `jsonapi:"attr,response"`
	LastPush          *time.Time `jsonapi:"attr,last_push,iso8601"`

	ConfigurationSet *WAFConfigurationSet `jsonapi:"relation,configuration_set"`
}

WAF is the information about a firewall object.

type WAFConfigurationSet added in v0.4.2

type WAFConfigurationSet struct {
	ID string `jsonapi:"primary,configuration_set"`
}

WAFConfigurationSet represents information about a configuration_set.

type WAFRuleStatus added in v0.4.3

type WAFRuleStatus struct {
	ID     string `jsonapi:"primary,rule_status"` // This is the ID of the status, not the ID of the rule. Currently, it is of the format ${WAF_ID}-${rule_ID}, if you want to infer those based on this field.
	Status string `jsonapi:"attr,status"`

	Tag string `jsonapi:"attr,name,omitempty"` // This will only be set in a response for modifying rules based on tag.

}

WAFRuleStatus stores the information about a rule received from Fastly

Jump to

Keyboard shortcuts

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