---
title: "[USES 50 UNITS PER NAME PAIR] Infer several classifications for up to 100 cross border interaction between names (ex. remit, travel, intl com)"
method: POST
path: "/api2/json/corridorBatch"
tags: ["personal"]
---

# \[USES 50 UNITS PER NAME PAIR\] Infer several classifications for up to 100 cross border interaction between names (ex. remit, travel, intl com)

`POST /api2/json/corridorBatch`

## Request body

- BatchCorridorIn
  - `corridorFromTo` CorridorIn[]
    - `id` string
    - `personalNameGeoFrom` PersonalNameGeoIn
      - `id` string
      - `name` string
      - `countryIso2` string
    - `personalNameGeoTo` PersonalNameGeoIn
      - `id` string
      - `name` string
      - `countryIso2` string

## Response `200`

A list of classified name pairs.

- BatchCorridorOut
  - `corridorFromTo` CorridorOut[] — Classified corridors
    - `id` string
    - `FirstLastNameGenderedOut` FirstLastNameGenderedOut — Represents the output of inferring the LIKELY gender from a personal name.
      - `script` string
      - `id` string
      - `explanation` string
      - `firstName` string — The first name (also known as given name)
      - `lastName` string — The last name (also known as family name, or surname)
      - `likelyGender` 'male' | 'female' | 'unknown' — Most likely gender
      - `genderScale` number, double — Compatibility to NamSor_v1 Gender Scale M[-1..U..+1]F value.
      - `score` number, double — Compatibility to NamSor_v1 Gender score value. Higher score is better, but score is not normalized. Use calibratedProbability if available.
      - `probabilityCalibrated` number, double — The calibrated probability for inferred gender to have been guessed correctly. -1 = still calibrating.
    - `FirstLastNameOriginedOut` FirstLastNameOriginedOut — Represents the output of inferring the LIKELY country of Origin from a personal name.
      - `script` string
      - `id` string
      - `explanation` string
      - `firstName` string — The first name (also known as given name)
      - `lastName` string — The last name (also known as family name, or surname)
      - `countryOrigin` string — Most likely country of Origin
      - `countryOriginAlt` string — Second best alternative : country of Origin
      - `countriesOriginTop` string[] — List countries of Origin (top 10)
      - `score` number, double — Compatibility to NamSor_v1 Origin score value. Higher score is better, but score is not normalized. Use calibratedProbability if available.
      - `regionOrigin` string — Most likely region of Origin (based on countryOrigin ISO2 code)
      - `topRegionOrigin` string — Most likely top region of Origin (based on countryOrigin ISO2 code)
      - `subRegionOrigin` string — Most likely sub region of Origin (based on countryOrigin ISO2 code)
      - `probabilityCalibrated` number, double — The calibrated probability for countryOrigin to have been guessed correctly. -1 = still calibrating.
      - `probabilityAltCalibrated` number, double — The calibrated probability for countryOrigin OR countryOriginAlt to have been guessed correctly. -1 = still calibrating.
      - `religionStats` ReligionStatOut[] — Geographic religious statistics, assuming country of origin is correctly predicted.
        - `religion` string
        - `pct` number, double
      - `religionStatsAlt` ReligionStatOut[] — Geographic religious statistics, for origin best alternative.
        - `religion` string
        - `pct` number, double
    - `FirstLastNameGeoOut` FirstLastNameGeoOut — Represents the output of inferring the LIKELY country of Origin from a personal name.
      - `script` string
      - `id` string
      - `explanation` string
      - `firstName` string — The first name (also known as given name)
      - `lastName` string — The last name (also known as family name, or surname)
      - `score` number, double — Higher score is better, but score is not normalized. Use calibratedProbability if available.
      - `country` string — Most likely country
      - `countryAlt` string — Second best alternative : country
      - `region` string — Most likely region (based on country ISO2 code)
      - `topRegion` string — Most likely top region (based on country ISO2 code)
      - `subRegion` string — Most likely sub region (based on country ISO2 code)
      - `countriesTop` string[] — List countries (top 10)
      - `probabilityCalibrated` number, double — The calibrated probability for country to have been guessed correctly. -1 = still calibrating.
      - `probabilityAltCalibrated` number, double — The calibrated probability for country OR countryAlt to have been guessed correctly. -1 = still calibrating.
      - `religionStats` ReligionStatOut[] — Geographic religious statistics, assuming country is correctly predicted.
        - `religion` string
        - `pct` number, double
      - `religionStatsAlt` ReligionStatOut[] — Geographic religious statistics, for country best alternative.
        - `religion` string
        - `pct` number, double
    - `FirstLastNameDiasporaedOut` FirstLastNameDiasporaedOut — Represents the output of inferring the LIKELY ethnicity from a personal name, given an country of residence.
      - `script` string
      - `id` string
      - `explanation` string
      - `firstName` string — The first name (also known as given name)
      - `lastName` string — The last name (also known as family name, or surname)
      - `score` number, double — Compatibility to NamSor_v1 Diaspora score value. Higher score is better, but score is not normalized. Use calibratedProbability if available.
      - `ethnicityAlt` string — The second best alternative ethnicity
      - `ethnicity` string — The most likely ethnicity
      - `lifted` boolean — Indicates if the output ethnicity is based on machine learning only, or further lifted as a known fact by a country-specific rule. Let us know if you believe ethnicity is incorrect on a specific case where lifted is true.
      - `countryIso2` string — From input data, the countryIso2 of geographic context (US,CA etc.)
      - `ethnicitiesTop` string[] — List most likely ethnicities (top 10)
      - `probabilityCalibrated` number, double — The calibrated probability for ethnicity to have been guessed correctly. -1 = still calibrating.
      - `probabilityAltCalibrated` number, double — The calibrated probability for ethnicity OR ethnicityAlt to have been guessed correctly. -1 = still calibrating.
      - `religionStats` ReligionStatOut[] — Geographic religious statistics, assuming ethnicity is correctly predicted.
        - `religion` string
        - `pct` number, double
      - `religionStatsAlt` ReligionStatOut[] — Geographic religious statistics, for country best alternative.
        - `religion` string
        - `pct` number, double
    - `script` string

## Other responses

- `400` — Bad request (ex. too many names)
- `401` — Missing or incorrect API Key
- `403` — Email not Verified, or API Limit Reached, or API Key Disabled
- `429` — Too Many Requests

---

[API](https://skmtc.dev/namsor/apis/namsor-api-v2.md) · [All operations](https://skmtc.dev/namsor/apis/namsor-api-v2/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/namsor/namsor-api-v2/revisions/305e4f6eeaf5/schema)
