Geolocation by Name API
Retrieve a specific geolocation by searching with its name
Geolocation by Name API
Look up a specific geolocation using the country name. Retrieve country codes, geo discounts, and other location details.
Name Search
Find by country name.
Location Details
Complete geo information.
Quick Lookup
Single result response.
Endpoint Overview
/graphqlRetrieve details for a specific geolocation by searching with its country name.
Request Parameters
nameString!RequiredThe name of the country to search for (e.g., "United States", "Germany").
GraphQL Query
query geolocationByName($name: String!) {
geolocationByName(name: $name) {
id
name
code
threeCharCode
geoDiscount
}
}Variables:
{
"name": "Netherlands"
}HTTP Request:
curl -X POST https://api.orbnet.com/graphql \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_TOKEN" \
-d '{
"query": "query geolocationByName($name: String!) { geolocationByName(name: $name) { id name code threeCharCode geoDiscount } }",
"variables": {
"name": "Netherlands"
}
}'Response
{
"data": {
"geolocationByName": {
"id": "4",
"name": "Netherlands",
"code": "NL",
"threeCharCode": "NLD",
"geoDiscount": 0
}
}
}{
"errors": [
{
"message": "Geolocation not found",
"path": ["geolocationByName"],
"extensions": {
"code": "NOT_FOUND"
}
}
],
"data": null
}Response Fields
idID!Unique identifier for the geolocation.
nameString!Full country name.
codeString!ISO 2-character country code.
threeCharCodeString!ISO 3-character country code.
geoDiscountInt!Regional discount percentage.
Use Cases
Validation
Verify country name exists.
Code Lookup
Get ISO codes from name.
Discount Check
Verify regional pricing.
Server Filter
Find servers by country.
Related Endpoints
Case Sensitivity
The name search is case-insensitive. "netherlands", "Netherlands", and "NETHERLANDS" will all return the same result.
Browse All Locations
View the complete list of available geolocations.