This feature is under active development. Behavior, supported fields, and limits may change before General Availability (GA). This guide is provided as forward-looking context for evaluation and feedback.
API Filtering is now available in Early Access.
API Filtering is now available in Early Access.
filter query parameter to GET requests to return only those results which match a provided criteria. This makes automated management of resources easier while eliminating the need to download large collections and filter client-side.
To use API Filtering, you pass a subset of CEL expressions to the filter query parameter, as demonstrated in the following example.
This example request fetches a list of all your Cloud and Agent endpoints.
Request shape
cURL usage
Supported CEL (subset)
These core operators and helpers are supported:- Logical operators:
!,&&,|| - Comparative operators:
<,<=,==,!=,>=,> - Parentheses for grouping
- List membership using the
inkeyword - String substring checks:
startsWith(),contains(),endsWith() - Length / emptiness checks:
size(),== "",== null - Date and time helpers:
timestamp(RFC-3339),timestamp(time.now),timestamp(time.now).subtract(<duration>),timestamp(time.now).add(<duration>)
Instance inspection (versus list comprehension)
Expressions are evaluated against a single resource instance exposed asobj. Compare fields on the instance rather than attempting list-wise checks on fields.
✅ Valid
Dates and time helpers
- Treat timestamps as numerics by using
<,<=,==,>=,>directly ontimestamp()fields, for example: - Relative helpers based on the current time: Use
timestamp(time.now)for the current time, then chain.subtract(<duration>)or.add(<duration>)with a duration string such as"7d","24h", or"15m". For example:
Query restrictions and limitations
Unsupported CEL features
To keep filter evaluation small and predictable, the following CEL features are not supported.- No index access (for example,
a[0]) - No arithmetic (for example,
a + b) - No ternary (for example,
cond ? x : y) - No type checks (for example,
type(a) == string) - No regexes
- No fuzzy matching
High-entropy fields and substring checks
High entropy fields are fields with values that are effectively random, usually because they’re generated. Theid field on a response object, such as obj.id, is a common example.
Substring functions, such as startsWith(), contains(), and endsWith(), are disallowed on high entropy fields. Check for equality on these fields instead. For example:
Query complexity (budgeting/limits)
Very large expressions can stress the query engine. The service may enforce limits on the number of conditions per query or similar throttles in the future.Filterable resources and fields
The initial release prioritizes the resource types and fields below. CEL filtering is not supported on deprecated endpoints. Field coverage is evolving and may change before GA.| Resource Type | Filterable Fields | Available for Early Access Testing |
|---|---|---|
| Endpoints | - id- created_at- description- metadata- principal.id- type- binding- url- pooling_enabled- scheme- region | Coming soon |
| Reserved Addresses | - id- created_at- description- metadata- addr- region | Coming soon |
| Reserved Domains | - id- created_at- description- metadata- domain- region- cname_target- certificate.id- acme_challenge_cname_target | Coming soon |
| TLS Certificates | - id- created_at- description- metadata- subject_common_name- not_after- not_before- serial_number | Coming soon |
| Certificate Authorities | - id- created_at- description- metadata- subject_common_name- not_before- not_after | Coming soon |
| IP Policies | - id- created_at- description- metadata | Coming soon |
| IP Policy Rules | - id- created_at- description- metadata- ip_policy- cidr- action | Coming soon |
| Agent Ingress | - id- created_at- description- metadata- domain | Coming soon |
| Tunnel Sessions | - id- metadata- agent_version- ip- os- region- started_at- credential | Coming soon |
| Event Destinations | - id- created_at- description- metadata | Coming soon |
| Event Subscriptions | - id- created_at- description- metadata | Coming soon |
| IP Restrictions | - id- created_at- description- metadata | Coming soon |
| API Keys | - id- created_at- description- metadata- owner_id | Coming soon |
| SSH Credentials | - id- created_at- description- metadata- owner_id- acl | Coming soon |
| Credentials | - id- created_at- description- metadata- owner_id- acl | Coming soon |
| Service Users | - id- created_at | Coming soon |
| SSH Certificate Authorities | - id- created_at- description- metadata | Coming soon |
| Vaults | - id- created_at- description- metadata- name | Coming soon |
| Secrets | - id- created_at- description- metadata- name | Coming soon |
Usage examples
Filter endpoints by type and creation time
Reserved domains by prefix
IP policy rules by CIDR and action
Credentials by owner with optional empty ACL
Complex nesting
Error handling
Invalid filters return HTTP 400 with a structured error body (category, status_code, message, details). Example: