{"api":{"id":"api_dd0f5a1e997dea41cfc301fc","slug":"bgp-asn-upstreams","name":"ASN Upstreams & Peers API","description":"The network neighbours of any ASN as seen in global internet routing (RIPEstat): one row per neighbour with its name, its side in routes, a plain upstream-or-peer or downstream label, how many routing paths show the link and the snapshot time.","kind":"ready_made","visibility":"public","domain":"stat.ripe.net","source_url":"https://stat.ripe.net/docs/data-api/api-endpoints/asn-neighbours","category":"developer","record_type":"generic","active_version":"1.0","units_per_1k":500,"health":"unknown","auto_repair":false,"last_checked_at":null,"last_run_at":null,"fields_count":11,"created_at":"2026-12-06T03:33:09.184Z","updated_at":"2026-12-06T03:33:09.184Z","runnable":true,"egress":null,"repairs":[],"repairs_total":0,"how":"Runs on a reader we built and maintain by hand for this site.","fields":[{"name":"asn","type":"integer","description":"The network number (ASN) you asked about, such as 577.","required":true,"coverage":1,"example":577},{"name":"asn_name","type":"string","description":"Registered name of that network, such as BACOM - Bell Canada.","required":false,"coverage":1,"example":"BACOM - Bell Canada"},{"name":"neighbour_asn","type":"integer","description":"Network number (ASN) of the neighbour.","required":true,"coverage":1,"example":1299},{"name":"neighbour_name","type":"string","description":"Registered name of the neighbour network, such as TWELVE99 Arelion Sweden AB.","required":false,"coverage":1,"example":"TWELVE99 Arelion Sweden AB"},{"name":"side","type":"string","description":"Where the neighbour sits in routes: left (toward the core), right (away from it) or uncertain.","required":false,"coverage":1,"example":"left"},{"name":"relationship","type":"string","description":"Plain label made from side: upstream_or_peer (left), downstream (right) or uncertain.","required":false,"coverage":1,"example":"upstream_or_peer"},{"name":"path_count","type":"integer","description":"Number of distinct routing paths that show this link (RIPEstat calls it power); higher means a busier link.","required":false,"coverage":1,"example":19332},{"name":"ipv4_routes_seen","type":"integer","description":"IPv4 routes that use this link, counted once for every RIS peer that sees them: a sign of how widely the link is used.","required":false,"coverage":1,"example":366496},{"name":"ipv6_routes_seen","type":"integer","description":"IPv6 routes that use this link, counted the same way.","required":false,"coverage":1,"example":6381},{"name":"neighbour_url","type":"url","description":"The neighbour network's page on RIPEstat.","required":false,"coverage":1,"example":"https://stat.ripe.net/resource/AS1299"},{"name":"snapshot_at","type":"datetime","description":"Time of the routing snapshot the link was seen in (UTC).","required":false,"coverage":1,"example":"2026-12-05T00:00:00.000Z"}],"inputs":[{"name":"asns","type":"array","description":"Network numbers (ASNs) to look up, written AS577 or 577. Up to 100 per run.","example":["AS577","13335"],"required":true},{"name":"date","type":"string","description":"Day to look at, as YYYY-MM-DD (such as 2026-12-01). Leave empty for the newest snapshot.","example":"2026-12-01"},{"name":"relationship","type":"string","description":"Which neighbours to return: all, upstream_or_peer (left side), downstream (right side) or uncertain.","default":"all","example":"all","enum":["all","upstream_or_peer","downstream","uncertain"]},{"name":"include_names","type":"boolean","description":"Add the registered name of every network. Turn it off for a faster run with numbers only.","default":true,"example":true}],"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","additionalProperties":true,"properties":{"asn":{"description":"The network number (ASN) you asked about, such as 577.","type":"integer"},"asn_name":{"description":"Registered name of that network, such as BACOM - Bell Canada.","type":"string"},"ipv4_routes_seen":{"description":"IPv4 routes that use this link, counted once for every RIS peer that sees them: a sign of how widely the link is used.","type":"integer"},"ipv6_routes_seen":{"description":"IPv6 routes that use this link, counted the same way.","type":"integer"},"neighbour_asn":{"description":"Network number (ASN) of the neighbour.","type":"integer"},"neighbour_name":{"description":"Registered name of the neighbour network, such as TWELVE99 Arelion Sweden AB.","type":"string"},"neighbour_url":{"description":"The neighbour network's page on RIPEstat.","format":"uri","type":"string"},"path_count":{"description":"Number of distinct routing paths that show this link (RIPEstat calls it power); higher means a busier link.","type":"integer"},"relationship":{"description":"Plain label made from side: upstream_or_peer (left), downstream (right) or uncertain.","type":"string"},"side":{"description":"Where the neighbour sits in routes: left (toward the core), right (away from it) or uncertain.","type":"string"},"snapshot_at":{"description":"Time of the routing snapshot the link was seen in (UTC).","format":"date-time","type":"string"}},"required":["asn","neighbour_asn"],"title":"ASN Upstreams & Peers API","type":"object"},"samples":[{"asn":577,"asn_name":"BACOM - Bell Canada","neighbour_asn":1299,"neighbour_name":"TWELVE99 Arelion Sweden AB","side":"left","relationship":"upstream_or_peer","path_count":19332,"ipv4_routes_seen":366496,"ipv6_routes_seen":6381,"neighbour_url":"https://stat.ripe.net/resource/AS1299","snapshot_at":"2026-12-05T00:00:00.000Z"},{"asn":577,"asn_name":"BACOM - Bell Canada","neighbour_asn":6939,"neighbour_name":"HURRICANE - Hurricane Electric LLC","side":"left","relationship":"upstream_or_peer","path_count":13609,"ipv4_routes_seen":50465,"ipv6_routes_seen":49494,"neighbour_url":"https://stat.ripe.net/resource/AS6939","snapshot_at":"2026-12-05T00:00:00.000Z"},{"asn":577,"asn_name":"BACOM - Bell Canada","neighbour_asn":174,"neighbour_name":"COGENT-174 - Cogent Communications, LLC","side":"left","relationship":"upstream_or_peer","path_count":10830,"ipv4_routes_seen":168350,"ipv6_routes_seen":1985,"neighbour_url":"https://stat.ripe.net/resource/AS174","snapshot_at":"2026-12-05T00:00:00.000Z"}],"validation":{"checked_at":"2026-12-06T03:33:09.177Z","field_coverage":{"asn":1,"asn_name":1,"ipv4_routes_seen":1,"ipv6_routes_seen":1,"neighbour_asn":1,"neighbour_name":1,"neighbour_url":1,"path_count":1,"relationship":1,"side":1,"snapshot_at":1},"fresh_read":false,"identity_unique":true,"issues":["Imported from a hand-built source. Field names and types come from its published schema; no live read was made for this check."],"level":"preview","pages_checked":0,"passed":true,"records_checked":3},"links":{"run":"https://pullrow.dev/v1/apis/api_dd0f5a1e997dea41cfc301fc/run","openapi":"https://pullrow.dev/v1/apis/api_dd0f5a1e997dea41cfc301fc/openapi.json","contract":"https://pullrow.dev/v1/apis/api_dd0f5a1e997dea41cfc301fc/contract.json","page":"https://pullrow.dev/catalog/bgp-asn-upstreams"},"runs_30d":0,"success_rate_30d":null,"price_per_1k_usd":0.5,"featured":false,"reliability":{"window_days":30,"runs":0,"completed":0,"succeeded":0,"failed":0,"success_rate":null,"last_run_at":null},"demo":{"available":false,"max_records":0,"reason":"Every run of this API costs us money, so it has no free live demo. The sample records on its page show what it returns.","code":"demo_not_available"},"meta":{"limitations":["Links come from the routes that RIPE NCC's RIS route collectors receive. A link that never shows up in those routes, such as a private peering, is missing: this is a public view of a network's neighbours, never a complete list.","side is RIPEstat's position in routes: left means closer to the internet core (usually an upstream provider or a peer), right means further away (usually a customer). relationship is a label made from side, not a contract fact.","A neighbour seen on both sides comes back once per side. uncertain marks neighbours seen on the left only as direct peers of a route collector, which can be caused by RIPE NCC's own peering.","Without a date you get the newest snapshot, which is usually about a day old. With a date you get the snapshot at 00:00 UTC that day; a date after the newest snapshot gives the newest one.","neighbour_name and asn_name stay empty for numbers with no registered name (private, reserved or unused numbers) and when names are turned off.","Big transit networks have thousands of neighbours (Cloudflare about 2,500 rows, Bell Canada about 350): set the record limit to match. At most 100 networks and 10,000 rows per run; rows come upstreams first, busiest links first.","Data from RIPEstat by RIPE NCC under the RIPEstat Service Terms and Conditions: credit RIPEstat when you publish it."]},"plain":{"summary":null,"source":"rules","fields":[{"name":"asn","label":"Asn","description":"The network number (ASN) you asked about, such as 577.","group":"Basics","shown":true,"written":false},{"name":"asn_name","label":"Asn name","description":"Registered name of that network, such as BACOM - Bell Canada.","group":"Basics","shown":true,"written":false},{"name":"neighbour_asn","label":"Neighbour asn","description":"Network number (ASN) of the neighbour.","group":"Basics","shown":true,"written":false},{"name":"neighbour_name","label":"Neighbour name","description":"Registered name of the neighbour network, such as TWELVE99 Arelion Sweden AB.","group":"Basics","shown":true,"written":false},{"name":"side","label":"Side","description":"Where the neighbour sits in routes: left (toward the core), right (away from it) or uncertain.","group":"Basics","shown":true,"written":false},{"name":"relationship","label":"Relationship","description":"Plain label made from side: upstream_or_peer (left), downstream (right) or uncertain.","group":"Basics","shown":true,"written":false},{"name":"path_count","label":"Path count","description":"Number of distinct routing paths that show this link (RIPEstat calls it power); higher means a busier link.","group":"Basics","shown":true,"written":false},{"name":"ipv4_routes_seen","label":"Ipv 4 routes seen","description":"IPv4 routes that use this link, counted once for every RIS peer that sees them: a sign of how widely the link is used.","group":"Basics","shown":true,"written":false},{"name":"ipv6_routes_seen","label":"Ipv 6 routes seen","description":"IPv6 routes that use this link, counted the same way.","group":"Basics","shown":true,"written":false},{"name":"neighbour_url","label":"Neighbour link","description":"The neighbour network's page on RIPEstat.","group":"Links","shown":true,"written":false},{"name":"snapshot_at","label":"Snapshot at","description":"Time of the routing snapshot the link was seen in (UTC).","group":"Dates","shown":true,"written":false}],"inputs":[{"name":"asns","label":"Asns","help":"Network numbers (ASNs) to look up, written AS577 or 577. Up to 100 per run.","example":"AS577, 13335","written":false},{"name":"date","label":"Date","help":"Day to look at, as YYYY-MM-DD (such as 2026-12-01). Leave empty for the newest snapshot.","example":"2026-12-01","written":false},{"name":"relationship","label":"Relationship","help":"Which neighbours to return: all, upstream_or_peer (left side), downstream (right side) or uncertain.","example":"all","written":false},{"name":"include_names","label":"Include names","help":"Add the registered name of every network. Turn it off for a faster run with numbers only.","example":"true","written":false}]}},"incidents":[]}