{"id":26095,"date":"2024-05-30T14:10:11","date_gmt":"2024-05-30T14:10:11","guid":{"rendered":"https:\/\/blog.lacnic.net\/?p=26095"},"modified":"2024-05-30T14:15:00","modified_gmt":"2024-05-30T14:15:00","slug":"command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api","status":"publish","type":"post","link":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/","title":{"rendered":"Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API"},"content":{"rendered":"\n<p><strong>By <\/strong><a href=\"https:\/\/blog.lacnic.net\/en\/author\/mingwei-zhang\"><strong>Mingwei Zhang<\/strong><\/a><strong>, <\/strong>senior systems engineer at Cloudflare<\/p>\n\n\n\n<p><em>This was originally published on the&nbsp;<\/em><a href=\"https:\/\/blog.bgpkit.com\/monocle-cloudflare-radar\" target=\"_blank\" rel=\"noreferrer noopener\"><em>BGPKIT blog<\/em><\/a><em>.<\/em><strong><\/strong><\/p>\n\n\n\n<p>Mingwei Zhang, Ph.-D is a senior systems engineer at Cloudflare, building complex high-throughput data pipelines and conducting data analysis on significant Internet routing events. He is the founder of open source BGP data analysis toolkit BGPKIT.<\/p>\n\n\n\n<p>BGPKIT&nbsp;monocle&nbsp;is a command-line utility program that helps users quickly pull Internet routing-related information from publicly available sources and is available on&nbsp;<a href=\"https:\/\/github.com\/bgpkit\/monocle\" target=\"_blank\" rel=\"noreferrer noopener\">GitHub<\/a>.<\/p>\n\n\n\n<p>In BGPKIT&nbsp;monocle&nbsp;version V0.5, we added support for querying&nbsp;<a href=\"https:\/\/radar.cloudflare.com\/\" target=\"_blank\" rel=\"noreferrer noopener\">Cloudflare Radar<\/a>\u2018s new BGP&nbsp;<a href=\"https:\/\/developers.cloudflare.com\/api\/operations\/radar-get-bgp-routes-stats\" target=\"_blank\" rel=\"noreferrer noopener\">routing statistics<\/a>&nbsp;and&nbsp;<a href=\"https:\/\/developers.cloudflare.com\/api\/operations\/radar-get-bgp-pfx2as\" target=\"_blank\" rel=\"noreferrer noopener\">prefix-to-origin mapping<\/a>&nbsp;APIs, the same APIs that power the&nbsp;<a href=\"https:\/\/radar.cloudflare.com\/routing\" target=\"_blank\" rel=\"noreferrer noopener\">Cloudflare Radar routing section<\/a>.&nbsp;monocle&nbsp;users can now quickly glance at routing stats for any given Autonomous System Number (ASN), economy, or the whole Internet. Users can also quickly look up prefix origins and examine their RPKI validation status as well as prefix visibility on the global routing tables.<\/p>\n\n\n\n<p><strong>Using&nbsp;<\/strong><strong>monocle radar<\/strong><strong><\/strong><\/p>\n\n\n\n<p>We added a new&nbsp;monocle radar&nbsp;command group in V0.5, which contains the following subcommands:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>monocle radar stats [QUERY]: Get routing stats (like prefix count, RPKI invalid count) for a given economy or ASN.<\/li>\n\n\n\n<li>monocle radar pfx2as [QUERY] [&#8211;rpki-status valid|invalid|unknown]: Get prefix to origin mapping for a given prefix or ASN.<\/li>\n<\/ul>\n\n\n\n<pre class=\"wp-block-code\"><code>mingwei@terrier ~ % monocle radar\n\nCloudflare Radar API lookup (set CF_API_TOKEN to enable)\n\nUsage: monocle radar &lt;COMMAND&gt;\n\nCommands:\n\n&nbsp; stats&nbsp;&nbsp; get routing stats\n\n&nbsp; pfx2as&nbsp; look up prefix to origin mapping on the most recent global routing table snapshot\n\n&nbsp; help&nbsp;&nbsp;&nbsp; Print this message or the help of the given subcommand(s)\n\nOptions:\n\n&nbsp; -h, --help&nbsp;&nbsp;&nbsp;&nbsp; Print help\n\n&nbsp; -V, --version&nbsp; Print version<\/code><\/pre>\n\n\n\n<p><strong>Cloudflare API token needed<\/strong><\/p>\n\n\n\n<p>Since the&nbsp;monocle radar&nbsp;command relies on querying data using the Cloudflare Radar public API, we also need to specify a user API token as the environment variable&nbsp;CF_API_TOKEN. Obtaining an API token is free and only needs a Cloudflare account. Interested users can follow their&nbsp;<a href=\"https:\/\/developers.cloudflare.com\/radar\/get-started\/first-request\/\" target=\"_blank\" rel=\"noreferrer noopener\">official tutorial<\/a>&nbsp;to obtain a token. The environment variable can be set in a&nbsp;.env&nbsp;file in the current directory, or set in ~\/.bashrc&nbsp;or&nbsp;~\/.profile, and so on.<\/p>\n\n\n\n<p><strong>monocle radar stats<\/strong><strong><\/strong><\/p>\n\n\n\n<p>Users can query the routing statistics for a given economy or ASN. For example,&nbsp;monocle radar stats us&nbsp;returns the routing stats for the United States, while&nbsp;monocle radar stats 174&nbsp;returns the stats for Cogent (AS174) (Figure 1).<\/p>\n\n\n\n<p>The displayed table is further divided into three rows, one for overall counting, and one for IPv4 and IPv6-specific counting. For each row, we show the following fields:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>origins: The number of origins ASes registered in the given economy.<\/li>\n\n\n\n<li>prefixes: The number of prefixes originated by the given ASN or ASes registered in the given economy.<\/li>\n\n\n\n<li>rpki_valid\/invalid\/unknown: The number of RPKI valid\/invalid\/unknown prefix routes (prefix-origin mapping) on the global routing table and their percentage of the overall routes.<\/li>\n<\/ul>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"1024\" height=\"812\" src=\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig1-255272892-d83c4d5e-ee79-4342-afec-163428a799b1-1024x812.webp\" alt=\"\" class=\"wp-image-26067\" srcset=\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig1-255272892-d83c4d5e-ee79-4342-afec-163428a799b1-1024x812.webp 1024w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig1-255272892-d83c4d5e-ee79-4342-afec-163428a799b1-300x238.webp 300w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig1-255272892-d83c4d5e-ee79-4342-afec-163428a799b1-416x330.webp 416w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig1-255272892-d83c4d5e-ee79-4342-afec-163428a799b1-768x609.webp 768w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig1-255272892-d83c4d5e-ee79-4342-afec-163428a799b1.webp 1330w\" sizes=\"(max-width: 1024px) 100vw, 1024px\" \/><figcaption class=\"wp-element-caption\">Figure 1 \u2014 Routing stats from&nbsp;monocle radar.<\/figcaption><\/figure>\n\n\n\n<p><strong>monocle radar pfx2as<\/strong><strong><\/strong><\/p>\n\n\n\n<p>Users can query the prefix-to-origin API to get the mapping of origin ASes and their originated prefixes on the global routing table.<\/p>\n\n\n\n<p>In Figure 2\u2019s example,&nbsp;monocle radar pfx2as 174 &#8211;rpki-status invalid, we ask for all the prefixes originated by&nbsp;AS174&nbsp;with the RPKI validation status to be invalid. This command returns the list of RPKI invalid prefixes originated by&nbsp;AS174&nbsp;at the time of generating the dataset.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"803\" height=\"1024\" src=\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig2-255272794-30ef0f5e-056e-4070-87dd-4e7bef6d436d-803x1024.webp\" alt=\"\" class=\"wp-image-26070\" srcset=\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig2-255272794-30ef0f5e-056e-4070-87dd-4e7bef6d436d-803x1024.webp 803w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig2-255272794-30ef0f5e-056e-4070-87dd-4e7bef6d436d-235x300.webp 235w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig2-255272794-30ef0f5e-056e-4070-87dd-4e7bef6d436d-259x330.webp 259w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig2-255272794-30ef0f5e-056e-4070-87dd-4e7bef6d436d-768x979.webp 768w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig2-255272794-30ef0f5e-056e-4070-87dd-4e7bef6d436d-300x382.webp 300w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig2-255272794-30ef0f5e-056e-4070-87dd-4e7bef6d436d.webp 1164w\" sizes=\"(max-width: 803px) 100vw, 803px\" \/><figcaption class=\"wp-element-caption\">Figure 2 \u2014 Returning a list of RPKI invalid prefixes.<\/figcaption><\/figure>\n\n\n\n<p><strong>Questions it can answer now (more in the future)<\/strong><\/p>\n\n\n\n<p>Here is a selected list of questions the&nbsp;monocle radar&nbsp;command can answer you:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>How many ASes are there on the Internet that announce at least one prefix? (81,770).<\/li>\n\n\n\n<li>How many of these ASes announce only IPv6 prefixes? (6,853).<\/li>\n\n\n\n<li>How many prefixes are there on the global routing table? (1,205,218).<\/li>\n\n\n\n<li>How many prefixes do&nbsp;AS400644&nbsp;announce? (1).<\/li>\n\n\n\n<li>Which AS(es) originates&nbsp;1.1.1.0\/24? (AS13335).<\/li>\n\n\n\n<li>How many prefixes originated by AS174 are NOT covered by some RPKI ROA? (a lot, 94%+).<\/li>\n\n\n\n<li>How about the RPKI valid ratio for the Philippines? (77%, nice!).<\/li>\n<\/ul>\n\n\n\n<p><strong>Powered by Cloudflare Radar free API<\/strong><\/p>\n\n\n\n<p><em>Cloudflare Radar is a hub that showcases global Internet traffic, attack, and technology trends and insights.<\/em><\/p>\n\n\n\n<p><a href=\"https:\/\/radar.cloudflare.com\/about#:~:text=Cloudflare%20Radar%20is%20a%20hub,anonymized%20data%20from%20Cloudflare's%201.1.\" target=\"_blank\" rel=\"noreferrer noopener\">About Cloudflare Radar<\/a><em><\/em><\/p>\n\n\n\n<p>Where&nbsp;<a href=\"https:\/\/radar.cloudflare.com\/\" target=\"_blank\" rel=\"noreferrer noopener\">Cloudflare Radar<\/a>&nbsp;shines is its data openness. Everything you see on the Cloudflare Radar website is powered by their free&nbsp;<a href=\"https:\/\/developers.cloudflare.com\/api\/operations\/radar-get-bgp-pfx2as-moas\" target=\"_blank\" rel=\"noreferrer noopener\">publicly available APIs<\/a>. It\u2019s a treasure trove, and all users need is a&nbsp;<a href=\"https:\/\/developers.cloudflare.com\/radar\/get-started\/first-request\/\" target=\"_blank\" rel=\"noreferrer noopener\">free API token<\/a>&nbsp;to access everything.<\/p>\n\n\n\n<figure class=\"wp-block-image size-large\"><img decoding=\"async\" width=\"937\" height=\"1024\" src=\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig3-account-contacts-bgpkits-cloudflare-may-2024-937x1024.webp\" alt=\"\" class=\"wp-image-26073\" srcset=\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig3-account-contacts-bgpkits-cloudflare-may-2024-937x1024.webp 937w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig3-account-contacts-bgpkits-cloudflare-may-2024-275x300.webp 275w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig3-account-contacts-bgpkits-cloudflare-may-2024-302x330.webp 302w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig3-account-contacts-bgpkits-cloudflare-may-2024-768x839.webp 768w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig3-account-contacts-bgpkits-cloudflare-may-2024-300x328.webp 300w, https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/fig3-account-contacts-bgpkits-cloudflare-may-2024.webp 1396w\" sizes=\"(max-width: 937px) 100vw, 937px\" \/><figcaption class=\"wp-element-caption\">Figure 3 \u2014 Cloudflare\u2019s free BGP APIs.<\/figcaption><\/figure>\n\n\n\n<p>At BGPKIT, we think we can further improve the usability of the APIs by exposing them as a proper Rust SDK:&nbsp;<a href=\"https:\/\/github.com\/bgpkit\/radar-rs\" target=\"_blank\" rel=\"noreferrer noopener\">radar-rs<\/a>. This is our (unofficial) effort to bring Cloudflare Radar\u2019s rich data to Rust developers. For example,&nbsp;monocle radar&nbsp;is powered by this SDK.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>By Mingwei Zhang, senior systems engineer at Cloudflare This was originally published on the&nbsp;BGPKIT blog. Mingwei Zhang, Ph.-D is a senior systems engineer at Cloudflare, building complex high-throughput data pipelines and conducting data analysis on significant Internet routing events. He is the founder of open source BGP data analysis toolkit BGPKIT. BGPKIT&nbsp;monocle&nbsp;is a command-line utility [&hellip;]<\/p>\n","protected":false},"author":6,"featured_media":26093,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":"","jetpack_publicize_message":"","jetpack_publicize_feature_enabled":true,"jetpack_social_post_already_shared":true,"jetpack_social_options":{"image_generator_settings":{"template":"highway","default_image_id":0,"font":"","enabled":false},"version":2}},"categories":[919],"tags":[1280],"archivo":[1345,1451],"taxonomy-authors":[1491],"tipo_autor":[1455],"class_list":["post-26095","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-routing","tag-routing","archivo-editions","archivo-highlights-2023","taxonomy-authors-mingwei-zhang-en","tipo_autor-colaborador"],"acf":{"author":"","related_notes":""},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.0 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>LACNIC Blog | Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"LACNIC Blog | Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API\" \/>\n<meta property=\"og:description\" content=\"By Mingwei Zhang, senior systems engineer at Cloudflare This was originally published on the&nbsp;BGPKIT blog. Mingwei Zhang, Ph.-D is a senior systems engineer at Cloudflare, building complex high-throughput data pipelines and conducting data analysis on significant Internet routing events. He is the founder of open source BGP data analysis toolkit BGPKIT. BGPKIT&nbsp;monocle&nbsp;is a command-line utility [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/\" \/>\n<meta property=\"og:site_name\" content=\"LACNIC Blog\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/facebook.com\/lacnic\" \/>\n<meta property=\"article:published_time\" content=\"2024-05-30T14:10:11+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2024-05-30T14:15:00+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png\" \/>\n\t<meta property=\"og:image:width\" content=\"680\" \/>\n\t<meta property=\"og:image:height\" content=\"330\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Gianni\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@lacnic\" \/>\n<meta name=\"twitter:site\" content=\"@lacnic\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/\"},\"author\":{\"name\":\"Gianni\",\"@id\":\"https:\/\/blog.lacnic.net\/#\/schema\/person\/1338d9cfdb0137e8bc5581f3771f39ab\"},\"headline\":\"Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API\",\"datePublished\":\"2024-05-30T14:10:11+00:00\",\"dateModified\":\"2024-05-30T14:15:00+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/\"},\"wordCount\":770,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\/\/blog.lacnic.net\/#organization\"},\"image\":{\"@id\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png\",\"keywords\":[\"Routing\"],\"articleSection\":[\"Routing\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/\",\"url\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/\",\"name\":\"LACNIC Blog | Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API\",\"isPartOf\":{\"@id\":\"https:\/\/blog.lacnic.net\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png\",\"datePublished\":\"2024-05-30T14:10:11+00:00\",\"dateModified\":\"2024-05-30T14:15:00+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#primaryimage\",\"url\":\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png\",\"contentUrl\":\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png\",\"width\":680,\"height\":330},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Portada\",\"item\":\"https:\/\/blog.lacnic.net\/en\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/blog.lacnic.net\/#website\",\"url\":\"https:\/\/blog.lacnic.net\/\",\"name\":\"LACNIC Blog\",\"description\":\"En el Blog de LACNIC encontrar\u00e1s art\u00edculos t\u00e9cnicos vinculados al desarrollo de Internet en la regi\u00f3n de Am\u00e9rica Latina y el Caribe.\",\"publisher\":{\"@id\":\"https:\/\/blog.lacnic.net\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/blog.lacnic.net\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/blog.lacnic.net\/#organization\",\"name\":\"LACNIC Blog\",\"url\":\"https:\/\/blog.lacnic.net\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/blog.lacnic.net\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2023\/03\/lacnic-blog.svg\",\"contentUrl\":\"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2023\/03\/lacnic-blog.svg\",\"caption\":\"LACNIC Blog\"},\"image\":{\"@id\":\"https:\/\/blog.lacnic.net\/#\/schema\/logo\/image\/\"},\"sameAs\":[\"https:\/\/facebook.com\/lacnic\",\"https:\/\/x.com\/lacnic\",\"https:\/\/www.instagram.com\/lacnic\/?hl=es-la\",\"https:\/\/uy.linkedin.com\/company\/lacnic\",\"https:\/\/www.youtube.com\/user\/lacnicstaff\",\"https:\/\/www.lacnic.net\/podcast\"]},{\"@type\":\"Person\",\"@id\":\"https:\/\/blog.lacnic.net\/#\/schema\/person\/1338d9cfdb0137e8bc5581f3771f39ab\",\"name\":\"Gianni\",\"url\":\"https:\/\/blog.lacnic.net\/en\/author\/gianni\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"LACNIC Blog | Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/","og_locale":"en_US","og_type":"article","og_title":"LACNIC Blog | Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API","og_description":"By Mingwei Zhang, senior systems engineer at Cloudflare This was originally published on the&nbsp;BGPKIT blog. Mingwei Zhang, Ph.-D is a senior systems engineer at Cloudflare, building complex high-throughput data pipelines and conducting data analysis on significant Internet routing events. He is the founder of open source BGP data analysis toolkit BGPKIT. BGPKIT&nbsp;monocle&nbsp;is a command-line utility [&hellip;]","og_url":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/","og_site_name":"LACNIC Blog","article_publisher":"https:\/\/facebook.com\/lacnic","article_published_time":"2024-05-30T14:10:11+00:00","article_modified_time":"2024-05-30T14:15:00+00:00","og_image":[{"width":680,"height":330,"url":"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png","type":"image\/png"}],"author":"Gianni","twitter_card":"summary_large_image","twitter_creator":"@lacnic","twitter_site":"@lacnic","schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#article","isPartOf":{"@id":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/"},"author":{"name":"Gianni","@id":"https:\/\/blog.lacnic.net\/#\/schema\/person\/1338d9cfdb0137e8bc5581f3771f39ab"},"headline":"Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API","datePublished":"2024-05-30T14:10:11+00:00","dateModified":"2024-05-30T14:15:00+00:00","mainEntityOfPage":{"@id":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/"},"wordCount":770,"commentCount":0,"publisher":{"@id":"https:\/\/blog.lacnic.net\/#organization"},"image":{"@id":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#primaryimage"},"thumbnailUrl":"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png","keywords":["Routing"],"articleSection":["Routing"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/","url":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/","name":"LACNIC Blog | Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API","isPartOf":{"@id":"https:\/\/blog.lacnic.net\/#website"},"primaryImageOfPage":{"@id":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#primaryimage"},"image":{"@id":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#primaryimage"},"thumbnailUrl":"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png","datePublished":"2024-05-30T14:10:11+00:00","dateModified":"2024-05-30T14:15:00+00:00","breadcrumb":{"@id":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#primaryimage","url":"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png","contentUrl":"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png","width":680,"height":330},{"@type":"BreadcrumbList","@id":"https:\/\/blog.lacnic.net\/en\/command-line-routing-stats-with-bgpkit-monocle-and-cloudflare-radar-api\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Portada","item":"https:\/\/blog.lacnic.net\/en\/"},{"@type":"ListItem","position":2,"name":"Command-line routing stats with BGPKIT\u00a0Monocle and Cloudflare Radar API"}]},{"@type":"WebSite","@id":"https:\/\/blog.lacnic.net\/#website","url":"https:\/\/blog.lacnic.net\/","name":"LACNIC Blog","description":"En el Blog de LACNIC encontrar\u00e1s art\u00edculos t\u00e9cnicos vinculados al desarrollo de Internet en la regi\u00f3n de Am\u00e9rica Latina y el Caribe.","publisher":{"@id":"https:\/\/blog.lacnic.net\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/blog.lacnic.net\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/blog.lacnic.net\/#organization","name":"LACNIC Blog","url":"https:\/\/blog.lacnic.net\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/blog.lacnic.net\/#\/schema\/logo\/image\/","url":"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2023\/03\/lacnic-blog.svg","contentUrl":"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2023\/03\/lacnic-blog.svg","caption":"LACNIC Blog"},"image":{"@id":"https:\/\/blog.lacnic.net\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/facebook.com\/lacnic","https:\/\/x.com\/lacnic","https:\/\/www.instagram.com\/lacnic\/?hl=es-la","https:\/\/uy.linkedin.com\/company\/lacnic","https:\/\/www.youtube.com\/user\/lacnicstaff","https:\/\/www.lacnic.net\/podcast"]},{"@type":"Person","@id":"https:\/\/blog.lacnic.net\/#\/schema\/person\/1338d9cfdb0137e8bc5581f3771f39ab","name":"Gianni","url":"https:\/\/blog.lacnic.net\/en\/author\/gianni\/"}]}},"jetpack_publicize_connections":[],"jetpack_featured_media_url":"https:\/\/blog.lacnic.net\/wp-content\/uploads\/2024\/05\/bgpkit-radar-lacnic-blog.png","jetpack_sharing_enabled":true,"wpml_current_locale":"en_US","wpml_translations":[{"locale":"es_ES","id":26064,"post_title":"Estad\u00edsticas de enrutamiento desde la l\u00ednea de comandos usando BGPKIT\u00a0Monocle y la API de Cloudflare Radar","slug":"estadisticas-de-enrutamiento-desde-la-linea-de-comandos-usando-bgpkit-monocle-y-la-api-de-cloudflare-radar","href":"https:\/\/blog.lacnic.net\/estadisticas-de-enrutamiento-desde-la-linea-de-comandos-usando-bgpkit-monocle-y-la-api-de-cloudflare-radar\/"},{"locale":"pt_BR","id":26098,"post_title":"Estat\u00edsticas de roteamento desde a linha de comandos usando BGPKIT\u00a0Monocle e a API de Cloudflare Radar","slug":"estatisticas-de-roteamento-desde-a-linha-de-comandos-usando-bgpkit-monocle-e-a-api-de-cloudflare-radar","href":"https:\/\/blog.lacnic.net\/pt-br\/estatisticas-de-roteamento-desde-a-linha-de-comandos-usando-bgpkit-monocle-e-a-api-de-cloudflare-radar\/"}],"_links":{"self":[{"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/posts\/26095","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/comments?post=26095"}],"version-history":[{"count":3,"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/posts\/26095\/revisions"}],"predecessor-version":[{"id":26104,"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/posts\/26095\/revisions\/26104"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/media\/26093"}],"wp:attachment":[{"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/media?parent=26095"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/categories?post=26095"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/tags?post=26095"},{"taxonomy":"archivo","embeddable":true,"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/archivo?post=26095"},{"taxonomy":"taxonomy-authors","embeddable":true,"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/taxonomy-authors?post=26095"},{"taxonomy":"tipo_autor","embeddable":true,"href":"https:\/\/blog.lacnic.net\/en\/wp-json\/wp\/v2\/tipo_autor?post=26095"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}