Skip to content
Start here

Discovery

Retrieve discovered operations on a zone rendered as OpenAPI schemas
api_gateway.discovery.get(DiscoveryGetParams**kwargs) -> DiscoveryGetResponse
GET/zones/{zone_id}/api_gateway/discovery
ModelsExpand Collapse
class DiscoveryOperation:
id: str

UUID.

maxLength36
minLength36
endpoint: str

The endpoint which can contain path parameter templates in curly braces, each will be replaced from left to right with {varN}, starting with {var1}, during insertion. This will further be Cloudflare-normalized upon insertion. See: https://developers.cloudflare.com/rules/normalization/how-it-works/.

formaturi-template
maxLength4096
host: str

RFC3986-compliant host.

formathostname
maxLength255
last_updated: datetime
formatdate-time
method: Literal["GET", "POST", "HEAD", 6 more]

The HTTP method used to access the endpoint.

One of the following:
"GET"
"POST"
"HEAD"
"OPTIONS"
"PUT"
"DELETE"
"CONNECT"
"PATCH"
"TRACE"
origin: List[Literal["ML", "SessionIdentifier", "LabelDiscovery"]]

API discovery engine(s) that discovered this operation

One of the following:
"ML"
"SessionIdentifier"
"LabelDiscovery"
state: Literal["review", "saved", "ignored"]

State of operation in API Discovery

  • review - Operation is not saved into API Shield Endpoint Management
  • saved - Operation is saved into API Shield Endpoint Management
  • ignored - Operation is marked as ignored
One of the following:
"review"
"saved"
"ignored"
features: Optional[Features]
traffic_stats: Optional[FeaturesTrafficStats]
last_updated: datetime
formatdate-time
period_seconds: int

The period in seconds these statistics were computed over

requests: float

The average number of requests seen during this period

formatfloat
class DiscoveryGetResponse:
schemas: List[object]
timestamp: datetime
formatdate-time

DiscoveryOperations

Retrieve discovered operations on a zone
api_gateway.discovery.operations.list(OperationListParams**kwargs) -> SyncV4PagePaginationArray[DiscoveryOperation]
GET/zones/{zone_id}/api_gateway/discovery/operations
Patch discovered operation
api_gateway.discovery.operations.edit(stroperation_id, OperationEditParams**kwargs) -> OperationEditResponse
PATCH/zones/{zone_id}/api_gateway/discovery/operations/{operation_id}
Patch discovered operations
api_gateway.discovery.operations.bulk_edit(OperationBulkEditParams**kwargs) -> OperationBulkEditResponse
PATCH/zones/{zone_id}/api_gateway/discovery/operations
ModelsExpand Collapse
class OperationEditResponse:
state: Optional[Literal["review", "saved", "ignored"]]

State of operation in API Discovery

  • review - Operation is not saved into API Shield Endpoint Management
  • saved - Operation is saved into API Shield Endpoint Management
  • ignored - Operation is marked as ignored
One of the following:
"review"
"saved"
"ignored"
Dict[str, OperationBulkEditResponseItem]
state: Optional[Literal["review", "ignored"]]

Mark state of operation in API Discovery

  • review - Mark operation as for review
  • ignored - Mark operation as ignored
One of the following:
"review"
"ignored"