Skip to content
Start here

Snippets

List zone snippets
snippets.list(SnippetListParams**kwargs) -> SyncV4PagePaginationArray[SnippetListResponse]
GET/zones/{zone_id}/snippets
Get a zone snippet
snippets.get(strsnippet_name, SnippetGetParams**kwargs) -> SnippetGetResponse
GET/zones/{zone_id}/snippets/{snippet_name}
Update a zone snippet
snippets.update(strsnippet_name, SnippetUpdateParams**kwargs) -> SnippetUpdateResponse
PUT/zones/{zone_id}/snippets/{snippet_name}
Delete a zone snippet
snippets.delete(strsnippet_name, SnippetDeleteParams**kwargs) -> object
DELETE/zones/{zone_id}/snippets/{snippet_name}
ModelsExpand Collapse
class SnippetListResponse: …

Define a snippet.

created_on: datetime

Indicates when the snippet was created.

formatdate-time
snippet_name: str

Identify the snippet.

modified_on: Optional[datetime]

Indicates when the snippet was last modified.

formatdate-time
class SnippetGetResponse: …

Define a snippet.

created_on: datetime

Indicates when the snippet was created.

formatdate-time
snippet_name: str

Identify the snippet.

modified_on: Optional[datetime]

Indicates when the snippet was last modified.

formatdate-time
class SnippetUpdateResponse: …

Define a snippet.

created_on: datetime

Indicates when the snippet was created.

formatdate-time
snippet_name: str

Identify the snippet.

modified_on: Optional[datetime]

Indicates when the snippet was last modified.

formatdate-time

SnippetsContent

Get a zone snippet content
snippets.content.get(strsnippet_name, ContentGetParams**kwargs) -> BinaryResponseContent
GET/zones/{zone_id}/snippets/{snippet_name}/content

SnippetsRules

List zone snippet rules
snippets.rules.get(RuleGetParams**kwargs) -> SyncSinglePage[RuleGetResponse]
GET/zones/{zone_id}/snippets/snippet_rules
List zone snippet rules
snippets.rules.list(RuleListParams**kwargs) -> SyncSinglePage[RuleListResponse]
GET/zones/{zone_id}/snippets/snippet_rules
Update zone snippet rules
snippets.rules.update(RuleUpdateParams**kwargs) -> SyncSinglePage[RuleUpdateResponse]
PUT/zones/{zone_id}/snippets/snippet_rules
Delete zone snippet rules
snippets.rules.delete(RuleDeleteParams**kwargs) -> SyncSinglePage[RuleDeleteResponse]
DELETE/zones/{zone_id}/snippets/snippet_rules
ModelsExpand Collapse
class RuleGetResponse: …

Define a snippet rule.

id: str

Specify the unique ID of the rule.

expression: str

Define the expression that determines which traffic matches the rule.

minLength1
last_updated: datetime

Specify the timestamp of when the rule was last modified.

formatdate-time
snippet_name: str

Identify the snippet.

description: Optional[str]

Provide an informative description of the rule.

enabled: Optional[bool]

Indicate whether to execute the rule.

class RuleListResponse: …

Define a snippet rule.

id: str

Specify the unique ID of the rule.

expression: str

Define the expression that determines which traffic matches the rule.

minLength1
last_updated: datetime

Specify the timestamp of when the rule was last modified.

formatdate-time
snippet_name: str

Identify the snippet.

description: Optional[str]

Provide an informative description of the rule.

enabled: Optional[bool]

Indicate whether to execute the rule.

class RuleUpdateResponse: …

Define a snippet rule.

id: str

Specify the unique ID of the rule.

expression: str

Define the expression that determines which traffic matches the rule.

minLength1
last_updated: datetime

Specify the timestamp of when the rule was last modified.

formatdate-time
snippet_name: str

Identify the snippet.

description: Optional[str]

Provide an informative description of the rule.

enabled: Optional[bool]

Indicate whether to execute the rule.

class RuleDeleteResponse: …

Define a snippet rule.

id: str

Specify the unique ID of the rule.

expression: str

Define the expression that determines which traffic matches the rule.

minLength1
last_updated: datetime

Specify the timestamp of when the rule was last modified.

formatdate-time
snippet_name: str

Identify the snippet.

description: Optional[str]

Provide an informative description of the rule.

enabled: Optional[bool]

Indicate whether to execute the rule.