This API enables precise lookup and retrieval of parcel shop locations within the City Express courier network. Developed and maintained by AntSoft, the City Express Parcel Shop API offers a reliable RESTful interface to query all active parcel shops, retrieve detailed information for a specific location, or find the nearest parcel shops based on address, postal code, and city. Responses are delivered in structured JSON, with geographic coordinates represented in standard GeoJSON format for easy integration with mapping and logistics systems. Whether you are powering customer checkout features, delivery selection workflows, or internal routing tools, this API provides accurate, real‑world parcel shop data optimized for seamless integration.
Parcel shop location is given in commonly used World Geodetic System 1984 (WGS84, EPSG:4326) as longitude/latitude pair. In API response parcel shop location is represented in GeoJSON format as geometry of type 'Point'.
Reference info:
City Express Parcel Shop API base URL is https://api.antsoft.eu/ce/parcelshop/
{
"address": "Resavska 35",
"city": "BEOGRAD-VRAČAR",
"postalCode": 11000,
"description": null,
"geometry": {
"type": "Point",
"coordinates": [
20.4646529,
44.80678445
]
"id": 251,
"company": "TRAFIKA",
"shortName": "Trafika 05"
},
"workingHours": [
{
"day": "MON",
"from": "0800",
"to": "2100"
},
{
"day": "TUE",
"from": "0800",
"to": "2100"
},
{
"day": "WED",
"from": "0800",
"to": "2100"
},
{
"day": "THU",
"from": "0800",
"to": "2100"
},
{
"day": "FRI",
"from": "0800",
"to": "2100"
},
{
"day": "SAT",
"from": "0900",
"to": "2000"
},
{
"day": "SUN",
"from": "0900",
"to": "2000"
}
]
}
| Endpoint | Parameters description |
|---|---|
|
HTTP GET / HTTP POST Returns a summary list of all active parcel shops. |
No parameters. |
|
HTTP GET / HTTP POST Returns detailed information about requested parcel shop. |
|
|
HTTP GET / HTTP POST Returns a list of parcel shops nearest to given location (address/city/postal code), within the distance defined. Results include parcel shop ID, geometry, address info and distance from given location. Distance is returned in meters as well as pre-formatted value. |
|
The API implements both URI path form and query parameter form. For example, last endpoint listed above can be called in the URI path form:
/getNearestParcelShops/{address}/{postalCode}/{city}/{maxDistance}
/getNearestParcelShops/{address}/{postalCode}/{city}
or in query parameter form:
/getNearestParcelShops?address={address}&postalCode={postalCode}&city={city}&maxDistance={maxDistance}
/getNearestParcelShops?address={address}&postalCode={postalCode}&city={city}
Parameter values must be URL-encoded according to IETF URI Specification (RFC 3986). Caution: The same specification defines slash symbol "/" as a path separator, so in URI path form parameter values cannot contain slash symbols. One example is address "Dragise Petrovica 15/2". With such parameter values URI path form would result in error. If your parameter value contains slash symbols, either replace them by other symbol (minus, underscore) or use query parameter form.
In all list representations there is a node 'entriesCount' that shows the number of result entries provided.
/getNearestParcelShops:{
"entriesCount": 5,
"entries": [
{
{
"parcelShop": {
"address": "Izvorski put bb",
"city": "BOLJEVAC",
"postalCode": 19370,
"geometry": {
"type": "Point",
"coordinates": [
21.947158,
43.829795
]
},
"id": 19,
"company": "OMV",
"shortName": "OMV - BOLJEVAC"
},
"distance": 696,
"distanceFormatted": "696 m"
},
"parcelShop": {
"address": "Obilićeva bb",
"city": "BOLJEVAC",
"postalCode": 19370,
"geometry": {
"type": "Point",
"coordinates": [
21.956209,
43.834764
]
},
"id": 187,
"company": "Mihajlović BS",
"shortName": null
},
"distance": 514,
"distanceFormatted": "514 m"
},
{
"parcelShop": {
"address": "Selište bb",
"city": "BOR",
"postalCode": 19210,
"geometry": {
"type": "Point",
"coordinates": [
22.092282,
43.922426
]
},
"id": 156,
"company": "Mihajlović BS",
"shortName": null
},
"distance": 15215,
"distanceFormatted": "15,2 km"
},
{
"parcelShop": {
"address": "Nikole Pašića 320",
"city": "ZAJEČAR",
"postalCode": 19000,
"geometry": {
"type": "Point",
"coordinates": [
22.244835,
43.892343
]
},
"id": 143,
"company": "Mihajlović BS",
"shortName": null
},
"distance": 24243,
"distanceFormatted": "24,2 km"
}
]
}
In order to use this API, requests must contain authentication header i.e. user must provide valid authentication token. Please contact AntSoft for getting the authentication token.
| Header-Name | Description |
|---|---|
api-auth-key |
Your authentication token |
Rate limit is API key-dependent. By default, authenticated users are allowed to send up to 1000 requests per minute. If rate limit is exceeded, error response is returned.
Examples are given for plain HTTP, PHP and Java. Of course, request can be sent using other programming/script languages or tools for APIs testing such as Postman.
/getNearestParcelShops call, URI path formGET /ce/parcelshop/getNearestParcelShops/Dragise Petrovica 15/19370/Boljevac HTTP/1.1
Host: api.antsoft.eu
api-auth-key: YOUR-AUTHENTICATION-TOKEN
Cache-Control: no-cache
/getNearestParcelShops call, query parameters form<?php
$uri = 'https://api.antsoft.eu/ce/parcelshop/getNearestParcelShops';
$query_data = array(
'address' => 'Dragise Petrovica 15',
'postalCode' => 19370,
'city' => 'Boljevac',
'maxDistance' => 1500
);
$stream_context = stream_context_create(array(
'http' => array(
'header' => 'api-auth-key: YOUR-AUTHENTICATION-TOKEN',
'method' => 'GET',
'content' => http_build_query($query_data)
)
));
$response = file_get_contents($uri, false, $stream_context);
$data = json_decode($response);
?>
/getNearestParcelShops call, URI path formString urlString = "https://api.antsoft.eu/ce/parcelshop/getNearestParcelShops/Dragise+Petrovica+15/19370/Boljevac";
URL url = new URL(urlString);
HttpURLConnection conn = (HttpsURLConnection) url.openConnection();
conn.setRequestProperty("api-auth-key", "YOUR-AUTHENTICATION-TOKEN");
conn.setRequestMethod("POST");
BufferedReader reader = new BufferedReader(new InputStreamReader(conn.getInputStream(), StandardCharsets.UTF_8.toString()));
// reader processing ommited
reader.close();
conn.disconnect();
If an error occurs, the API will return one of the following HTTP status codes. If the error is caused by the user the API will try to give a hint with a JSON encoded error message.
{
"status": "403 Forbidden",
"message": "Not authorized. Please provide valid credentials. More info at: https://api.antsoft.eu/documentation/ce/"
}
{
"status": "429 Too Many Requests",
"message": "Requests limit reached. Try again in 6 seconds."
}