This guide outlines the process of retrieving BIN bank and market details for your own local database using Pagos BIN Data Batch API. With the Batch BIN file, you can easily integrate BIN data into any bank or customer analysis you conduct. Batch is an in-house alternative to requesting directly from our database via the BIN Data API.
If you prefer a no-code method for downloading the Batch file, navigate to the Batch tab in the BIN Data section of your Pagos Service Panel.

How it works

  1. Every Tuesday at 00:00 UTC, Pagos generates and publishes a new batch file with the most up-to-date BIN data from the card networks.
  2. Pagos will pre-load the weekly database file for you.
  3. You will call /batch/files to fetch a link to the pre-generated weekly Batch file—including one file for standard BIN data and one file for standard and enhanced BIN data—for download. Within minutes, you’ll have a brand new Batch file.
Pagos will generate a new batch file every week so you can come back and get a new file as often as you’d like.

File Changes

When calling /batch/files, the response will include a changes object, outlining stats on how much the Batch file changed since the previous week. These changes include bins_removed, bins_updated, and bins_added, which provide the number of BIN ranges (rows in the file) that were removed, updated, or added by the card brands Pagos includes data for. For each card brand, we’ll also state what percentage of that brand’s BIN ranges changed (removed, updated, or added).

BIN Data Batch IP Addresses

The following static IP addresses can be used to allowlist API traffic to BIN Data Batch:
  • 99.83.189.213
  • 75.2.25.63

BIN Data Batch Ranges

When networks issue cards, they generate BINs in ranges. All BINs issued within a set range will share flags indicating card currency, card type (e.g. prepaid, reloadable, etc.), local only, gambling enabled/not supported, etc. Because these flags are set at the range level—not the individual BIN level—Batch BIN Data similarly shares BIN details in ranges between a min and max value. Design your search logic to search for a BIN value within a given range. For example, if you want to review details for BIN 464565, you’d generate the 19-digit value for a card number, padded with zeros; you’d then search for all the rows where the card number 4645650000000000000 is between the bin_min and the bin_max.

Overlapping BIN Ranges

In the Batch file, it’s possible for a BIN to appear in two overlapping BIN ranges. This typically indicates one of the following:
  • The provided BIN is too wide of a range and more digits are required to narrow the results (e.g. the six-digit BIN is in two BIN ranges, but the eight-digit BIN is only in one)
  • The given BIN has both a primary and secondary card brand associated with it. The primary card brand for the BIN will be one of the main card brands—Visa, Mastercard, Amex, and Discover; the secondary is typically a pinless debit network or a regional brand (e.g. ETPOS, Dankort, Carte Bancaire).
If a BIN appears in two overlapping ranges—where one range is smaller and fully contained within a larger one—use the details from the more specific (smaller) range.
Larger Range (overlapping): 6229330000000000000 - 6237969999999999999, UNIONPAY, CN Smaller Range (single): 6233550000000000000 - 6233559999999999999, UNIONPAY, TH

Identical BIN Ranges

It’s possible for two networks to have identical BIN ranges. When this happens, you’ll see two rows in the Batch file with identical bin_min and bin_max values. The responses in other fields, such as card_brand and product_name will be different.

BIN Data Batch FAQ