ASN Upstreams & Peers API

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.

$0.50 per 1,000 records

You pay only for the records you get. Zero records cost zero. 10,000 free records of this API to start (5,000 at the base price of $1 per 1,000), no card.

Try it
Ready-made, maintained by usRecords, 11 fieldsv1.0

Data from stat.ripe.net/docs/data-api/api-endpoints/asn-neighbours

Get this data

Try it here with a few records, download the sample, fill a Google Sheet, or call it from your own code.

Try it

Asns
Network numbers (ASNs) to look up, written AS577 or 577. Up to 100 per run. One per line, or separated by commas.
Example: AS577, 13335
Dateoptional
Day to look at, as YYYY-MM-DD (such as 2026-12-01). Leave empty for the newest snapshot.
Example: 2026-12-01
Relationshipoptional
Which neighbours to return: all, upstream_or_peer (left side), downstream (right side) or uncertain.
Include namesoptional
Add the registered name of every network. Turn it off for a faster run with numbers only.

Run it on this page, or call it from your code with the endpoint in the developer section. A free key covers 10,000 records of this API, no card. Create a free key

For developers: the API and MCPThe endpoint, code in curl, JavaScript and Python, every input, and files for your tools
Endpoint
POSThttps://pullrow.dev/v1/apis/bgp-asn-upstreams/run
  • Small runs answer in the same request; longer ones answer 202 with a run to poll.
  • fields returns only the fields you name. The examples send the ones picked on this page.
  • Idempotency-Key is optional. A retry with it is never charged twice.
  • You pay for records returned. Zero records cost zero.

Every run option, explained

Calling it needs a key
10,000 free records of this API to start. No card.
curl
curl -X POST "https://pullrow.dev/v1/apis/bgp-asn-upstreams/run" \
  -H "Authorization: Bearer $PULLROW_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"input":{"asns":["AS577","13335"]},"max_items":50}'

Inputs

Send them as input in the request body. Leave one out to use its default.

asnslistrequired
Network numbers (ASNs) to look up, written AS577 or 577. Up to 100 per run.
example: AS577, 13335
datetext
Day to look at, as YYYY-MM-DD (such as 2026-12-01). Leave empty for the newest snapshot.
example: 2026-12-01
relationshiptext
Which neighbours to return: all, upstream_or_peer (left side), downstream (right side) or uncertain.
default: allexample: allone of: all, upstream_or_peer, downstream, uncertain
include_namesyes/no
Add the registered name of every network. Turn it off for a faster run with numbers only.
default: trueexample: true

What's in each record

11 fields.

Basics

  • Asn

    The network number (ASN) you asked about, such as 577.

    Example 577

  • Asn name

    Registered name of that network, such as BACOM - Bell Canada.

    Example BACOM - Bell Canada

  • Neighbour asn

    Network number (ASN) of the neighbour.

    Example 1,299

  • Neighbour name

    Registered name of the neighbour network, such as TWELVE99 Arelion Sweden AB.

    Example TWELVE99 Arelion Sweden AB

  • Side

    Where the neighbour sits in routes: left (toward the core), right (away from it) or uncertain.

    Example left

  • Relationship

    Plain label made from side: upstream_or_peer (left), downstream (right) or uncertain.

    Example upstream_or_peer

  • Path count

    Number of distinct routing paths that show this link (RIPEstat calls it power); higher means a busier link.

    Example 19,332

  • Ipv 4 routes seen

    IPv4 routes that use this link, counted once for every RIS peer that sees them: a sign of how widely the link is used.

    Example 366,496

  • Ipv 6 routes seen

    IPv6 routes that use this link, counted the same way.

    Example 6,381

Dates

  • Snapshot at

    Time of the routing snapshot the link was seen in (UTC).

    Example Dec 5, 2026

Technical detailsField names and types for developers

Field names and types

The names your code reads in each record. "Filled" counts how many of the 3 sample records carry the field.

Field nameTypeShown on this page asFilled
asnnumberAsn3 of 3
asn_nametextAsn name3 of 3
neighbour_asnnumberNeighbour asn3 of 3
neighbour_nametextNeighbour name3 of 3
sidetextSide3 of 3
relationshiptextRelationship3 of 3
path_countnumberPath count3 of 3
ipv4_routes_seennumberIpv 4 routes seen3 of 3
ipv6_routes_seennumberIpv 6 routes seen3 of 3
neighbour_urllinkNeighbour link3 of 3
snapshot_atdate and timeSnapshot at3 of 3

How it reads the site

Runs on a reader we built and maintain by hand for this site.

Sample records

Sample records
RecordAsnAsn nameNeighbour asnNeighbour nameSideRelationshipPath countIpv 4 routes seenIpv 6 routes seenSnapshot atNeighbour link
1577BACOM - Bell Canada1,299TWELVE99 Arelion Sweden ABleftupstream_or_peer19,332366,4966,381Dec 5, 2026stat.ripe.net/resource/AS1299
2577BACOM - Bell Canada6,939HURRICANE - Hurricane Electric LLCleftupstream_or_peer13,60950,46549,494Dec 5, 2026stat.ripe.net/resource/AS6939
3577BACOM - Bell Canada174COGENT-174 - Cogent Communications, LLCleftupstream_or_peer10,830168,3501,985Dec 5, 2026stat.ripe.net/resource/AS174

Sample records from the example output this API publishes. Email addresses and phone numbers in them are masked. Hover over a column name to see the field name your code reads.

Reliability

Counted from real runs. Our own health checks are left out. A run succeeded when it finished and the site neither blocked it nor broke it.

Incidents and repairs

How it is kept working What a repair can't do

A ready-made API, maintained by us. It is not part of the daily check or the automatic rebuild yet.

  • You pay only for records returned. A run that returns none costs nothing.
Known limits
  • 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.

Version history

A run uses the live version unless the request names another one with version.