Skip to content
Start here

BGP

Get BGP time series
radar.bgp.timeseries(BGPTimeseriesParams**kwargs) -> BGPTimeseriesResponse
GET/radar/bgp/timeseries
ModelsExpand Collapse
class BGPTimeseriesResponse:
meta: Meta
agg_interval: Literal["15m", "1h", "1d", "1w"]
One of the following:
"15m"
"1h"
"1d"
"1w"
confidence_info: MetaConfidenceInfo
annotations: List[MetaConfidenceInfoAnnotation]
data_source: Literal["ALL", "AI_BOTS", "AI_GATEWAY", 22 more]

Data source for annotations.

One of the following:
"ALL"
"AI_BOTS"
"AI_GATEWAY"
"BGP"
"BOTS"
"CONNECTION_ANOMALY"
"CT"
"DNS"
"DNS_MAGNITUDE"
"DNS_AS112"
"DOS"
"EMAIL_ROUTING"
"EMAIL_SECURITY"
"FW"
"FW_PG"
"HTTP"
"HTTP_CONTROL"
"HTTP_CRAWLER_REFERER"
"HTTP_ORIGINS"
"IQI"
"LEAKED_CREDENTIALS"
"NET"
"ROBOTS_TXT"
"SPEED"
"WORKERS_AI"
description: str
end_date: datetime
formatdate-time
event_type: Literal["EVENT", "GENERAL", "OUTAGE", 3 more]

Event type for annotations.

One of the following:
"EVENT"
"GENERAL"
"OUTAGE"
"PARTIAL_PROJECTION"
"PIPELINE"
"TRAFFIC_ANOMALY"
is_instantaneous: bool

Whether event is a single point in time or a time range.

linked_url: str
formaturi
start_date: datetime
formatdate-time
level: int

Provides an indication of how much confidence Cloudflare has in the data.

date_range: List[MetaDateRange]
end_time: datetime

Adjusted end of date range.

formatdate-time
start_time: datetime

Adjusted start of date range.

formatdate-time
last_updated: datetime
formatdate-time
serie_0: Serie0
timestamps: List[datetime]
values: List[str]

BGPLeaks

BGPLeaksEvents

Get BGP route leak events
radar.bgp.leaks.events.list(EventListParams**kwargs) -> SyncV4PagePagination[EventListResponse]
GET/radar/bgp/leaks/events
ModelsExpand Collapse
class EventListResponse:
asn_info: List[ASNInfo]
asn: int
country_code: str
org_name: str
events: List[Event]
id: int
countries: List[str]
detected_ts: str
finished: bool
leak_asn: int
leak_count: int
leak_seg: List[int]
leak_type: int
max_ts: str
min_ts: str
origin_count: int
peer_count: int
prefix_count: int

BGPTop

Get top prefixes by BGP updates
radar.bgp.top.prefixes(TopPrefixesParams**kwargs) -> TopPrefixesResponse
GET/radar/bgp/top/prefixes
ModelsExpand Collapse
class TopPrefixesResponse:
meta: Meta
date_range: List[MetaDateRange]
end_time: datetime

Adjusted end of date range.

formatdate-time
start_time: datetime

Adjusted start of date range.

formatdate-time
top_0: List[Top0]
prefix: str
value: str

A numeric string.

BGPTopAses

Get top ASes by BGP updates
radar.bgp.top.ases.get(AseGetParams**kwargs) -> AseGetResponse
GET/radar/bgp/top/ases
Get top ASes by prefix count
radar.bgp.top.ases.prefixes(AsePrefixesParams**kwargs) -> AsePrefixesResponse
GET/radar/bgp/top/ases/prefixes
ModelsExpand Collapse
class AseGetResponse:
meta: Meta
date_range: List[MetaDateRange]
end_time: datetime

Adjusted end of date range.

formatdate-time
start_time: datetime

Adjusted start of date range.

formatdate-time
top_0: List[Top0]
asn: int
as_name: str
value: str

Percentage of updates by this AS out of the total updates by all autonomous systems.

class AsePrefixesResponse:
asns: List[ASN]
asn: int
country: str
name: str
pfxs_count: int
meta: Meta
data_time: str
query_time: str
total_peers: int

BGPHijacks

BGPHijacksEvents

Get BGP hijack events
radar.bgp.hijacks.events.list(EventListParams**kwargs) -> SyncV4PagePagination[EventListResponse]
GET/radar/bgp/hijacks/events
ModelsExpand Collapse
class EventListResponse:
asn_info: List[ASNInfo]
asn: int
country_code: str
org_name: str
events: List[Event]
id: int
confidence_score: int
duration: int
event_type: int
hijack_msgs_count: int
hijacker_asn: int
hijacker_country: str
is_stale: bool
max_hijack_ts: str
max_msg_ts: str
min_hijack_ts: str
on_going_count: int
peer_asns: List[int]
peer_ip_count: int
prefixes: List[str]
tags: List[EventTag]
name: str
score: int
victim_asns: List[int]
victim_countries: List[str]
total_monitors: int

BGPRoutes

Get Multi-Origin AS (MOAS) prefixes
radar.bgp.routes.moas(RouteMoasParams**kwargs) -> RouteMoasResponse
GET/radar/bgp/routes/moas
Get prefix-to-ASN mapping
radar.bgp.routes.pfx2as(RoutePfx2asParams**kwargs) -> RoutePfx2asResponse
GET/radar/bgp/routes/pfx2as
Get BGP routing table stats
radar.bgp.routes.stats(RouteStatsParams**kwargs) -> RouteStatsResponse
GET/radar/bgp/routes/stats
List ASes from global routing tables
radar.bgp.routes.ases(RouteAsesParams**kwargs) -> RouteAsesResponse
GET/radar/bgp/routes/ases
Get real-time BGP routes for a prefix
radar.bgp.routes.realtime(RouteRealtimeParams**kwargs) -> RouteRealtimeResponse
GET/radar/bgp/routes/realtime
ModelsExpand Collapse
class RouteMoasResponse:
meta: Meta
data_time: str
query_time: str
total_peers: int
moas: List[Moa]
origins: List[MoaOrigin]
origin: int
peer_count: int
rpki_validation: str
prefix: str
class RoutePfx2asResponse:
meta: Meta
data_time: str
query_time: str
total_peers: int
prefix_origins: List[PrefixOrigin]
origin: int
peer_count: int
prefix: str
rpki_validation: str
class RouteStatsResponse:
meta: Meta
data_time: str
query_time: str
total_peers: int
stats: Stats
distinct_origins: int
distinct_origins_ipv4: int
distinct_origins_ipv6: int
distinct_prefixes: int
distinct_prefixes_ipv4: int
distinct_prefixes_ipv6: int
routes_invalid: int
routes_invalid_ipv4: int
routes_invalid_ipv6: int
routes_total: int
routes_total_ipv4: int
routes_total_ipv6: int
routes_unknown: int
routes_unknown_ipv4: int
routes_unknown_ipv6: int
routes_valid: int
routes_valid_ipv4: int
routes_valid_ipv6: int
class RouteAsesResponse:
asns: List[ASN]
asn: int
cone_size: int

AS's customer cone size.

country: str

Alpha-2 code for the AS's registration country.

ipv4_count: int

Number of IPv4 addresses originated by the AS.

ipv6_count: str

Number of IPv6 addresses originated by the AS.

name: str

Name of the AS.

pfxs_count: int

Number of total IP prefixes originated by the AS.

rpki_invalid: int

Number of RPKI invalid prefixes originated by the AS.

rpki_unknown: int

Number of RPKI unknown prefixes originated by the AS.

rpki_valid: int

Number of RPKI valid prefixes originated by the AS.

meta: Meta
data_time: str

The timestamp of when the data is generated.

query_time: str

The timestamp of the query.

total_peers: int

Total number of route collector peers used to generate this data.

class RouteRealtimeResponse:
meta: Meta
asn_info: List[MetaASNInfo]
as_name: str

Name of the autonomous system.

asn: int

AS number.

country_code: str

Alpha-2 code for the AS's registration country.

org_id: str

Organization ID.

org_name: str

Organization name.

collectors: List[MetaCollector]
collector: str

Public route collector ID.

latest_realtime_ts: str

Latest real-time stream timestamp for this collector.

latest_rib_ts: str

Latest RIB dump MRT file timestamp for this collector.

latest_updates_ts: str

Latest BGP updates MRT file timestamp for this collector.

peers_count: int

Total number of collector peers used from this collector.

peers_v4_count: int

Total number of collector peers used from this collector for IPv4 prefixes.

peers_v6_count: int

Total number of collector peers used from this collector for IPv6 prefixes.

data_time: str

The most recent data timestamp for from the real-time sources.

prefix_origins: List[MetaPrefixOrigin]
origin: int

Origin ASN.

prefix: str

IP prefix of this query.

rpki_validation: str

Prefix-origin RPKI validation: valid, invalid, unknown.

total_peers: int

Total number of peers.

total_visible: int

Total number of peers seeing this prefix.

visibility: float

Ratio of peers seeing this prefix to total number of peers.

query_time: str

The timestamp of this query.

routes: List[Route]
as_path: List[int]

AS-level path for this route, from collector to origin.

collector: str

Public collector ID for this route.

communities: List[str]

BGP community values.

prefix: str

IP prefix of this query.

timestamp: str

Latest timestamp of change for this route.

BGPIPs

Get announced IP address space time series
radar.bgp.ips.timeseries(IPTimeseriesParams**kwargs) -> IPTimeseriesResponse
GET/radar/bgp/ips/timeseries
ModelsExpand Collapse
class IPTimeseriesResponse:
meta: Meta

Metadata for the results.

agg_interval: Literal["FIFTEEN_MINUTES", "ONE_HOUR", "ONE_DAY", 2 more]

Aggregation interval of the results (e.g., in 15 minutes or 1 hour intervals). Refer to Aggregation intervals.

One of the following:
"FIFTEEN_MINUTES"
"ONE_HOUR"
"ONE_DAY"
"ONE_WEEK"
"ONE_MONTH"
confidence_info: MetaConfidenceInfo
annotations: List[MetaConfidenceInfoAnnotation]
data_source: Literal["ALL", "AI_BOTS", "AI_GATEWAY", 22 more]

Data source for annotations.

One of the following:
"ALL"
"AI_BOTS"
"AI_GATEWAY"
"BGP"
"BOTS"
"CONNECTION_ANOMALY"
"CT"
"DNS"
"DNS_MAGNITUDE"
"DNS_AS112"
"DOS"
"EMAIL_ROUTING"
"EMAIL_SECURITY"
"FW"
"FW_PG"
"HTTP"
"HTTP_CONTROL"
"HTTP_CRAWLER_REFERER"
"HTTP_ORIGINS"
"IQI"
"LEAKED_CREDENTIALS"
"NET"
"ROBOTS_TXT"
"SPEED"
"WORKERS_AI"
description: str
end_date: datetime
formatdate-time
event_type: Literal["EVENT", "GENERAL", "OUTAGE", 3 more]

Event type for annotations.

One of the following:
"EVENT"
"GENERAL"
"OUTAGE"
"PARTIAL_PROJECTION"
"PIPELINE"
"TRAFFIC_ANOMALY"
is_instantaneous: bool

Whether event is a single point in time or a time range.

linked_url: str
formaturi
start_date: datetime
formatdate-time
level: int

Provides an indication of how much confidence Cloudflare has in the data.

date_range: List[MetaDateRange]
end_time: datetime

Adjusted end of date range.

formatdate-time
start_time: datetime

Adjusted start of date range.

formatdate-time
last_updated: datetime

Timestamp of the last dataset update.

formatdate-time
normalization: Literal["PERCENTAGE", "MIN0_MAX", "MIN_MAX", 5 more]

Normalization method applied to the results. Refer to Normalization methods.

One of the following:
"PERCENTAGE"
"MIN0_MAX"
"MIN_MAX"
"RAW_VALUES"
"PERCENTAGE_CHANGE"
"ROLLING_AVERAGE"
"OVERLAPPED_PERCENTAGE"
"RATIO"
units: List[MetaUnit]

Measurement units for the results.

name: str
value: str
delay: Optional[MetaDelay]
asn_data: MetaDelayASNData
delay_secs: float
delay_str: str
healthy: bool
latest: MetaDelayASNDataLatest
entries_count: float
path: str
timestamp: float
country_data: MetaDelayCountryData
delay_secs: float
delay_str: str
healthy: bool
latest: MetaDelayCountryDataLatest
count: float
timestamp: float
healthy: bool
now_ts: float
serie_0: Serie0
ipv4: List[str]
ipv6: List[str]
timestamps: List[datetime]

BGPRPKI

BGPRPKIASPA

Get ASPA objects snapshot
radar.bgp.rpki.aspa.snapshot(ASPASnapshotParams**kwargs) -> ASPASnapshotResponse
GET/radar/bgp/rpki/aspa/snapshot
Get ASPA changes over time
radar.bgp.rpki.aspa.changes(ASPAChangesParams**kwargs) -> ASPAChangesResponse
GET/radar/bgp/rpki/aspa/changes
Get ASPA count time series
radar.bgp.rpki.aspa.timeseries(ASPATimeseriesParams**kwargs) -> ASPATimeseriesResponse
GET/radar/bgp/rpki/aspa/timeseries
ModelsExpand Collapse
class ASPASnapshotResponse:
asn_info: ASNInfo
_13335: ASNInfo_13335
asn: int

ASN number.

country: str

Alpha-2 country code.

name: str

AS name.

aspa_objects: List[ASPAObject]
customer_asn: int

The customer ASN publishing the ASPA object.

providers: List[int]
meta: Meta
data_time: datetime

Timestamp of the underlying data.

formatdate-time
query_time: datetime

Timestamp when the query was executed.

formatdate-time
total_count: int

Total number of ASPA objects.

class ASPAChangesResponse:
asn_info: ASNInfo
_13335: ASNInfo_13335
asn: int

ASN number.

country: str

Alpha-2 country code.

name: str

AS name.

changes: List[Change]
customers_added: int

Number of new ASPA objects created.

customers_removed: int

Number of ASPA objects deleted.

date: datetime

Date of the changes in ISO 8601 format.

formatdate-time
entries: List[ChangeEntry]
customer_asn: int

The customer ASN affected.

providers: List[int]
type: Literal["CustomerAdded", "CustomerRemoved", "ProvidersAdded", "ProvidersRemoved"]
One of the following:
"CustomerAdded"
"CustomerRemoved"
"ProvidersAdded"
"ProvidersRemoved"
providers_added: int

Number of providers added to existing objects.

providers_removed: int

Number of providers removed from existing objects.

total_count: int

Running total of active ASPA objects after this day.

meta: Meta
data_time: datetime

Timestamp of the underlying data.

formatdate-time
query_time: datetime

Timestamp when the query was executed.

formatdate-time
class ASPATimeseriesResponse:
meta: Meta
data_time: datetime

Timestamp of the underlying data.

formatdate-time
query_time: datetime

Timestamp when the query was executed.

formatdate-time
serie_0: Serie0
timestamps: List[datetime]
values: List[str]