Skip to main content

Retrieving the Courier Service Pickup Point Directory

If the courier service has its own pickup points that are covered by the signed agreement, the Gold Apple IS needs to have such a directory in order to provide customers with information about available pickup points. The endpoint must be published over the secure HTTPS protocol. Before the integration is fully launched into production, the Gold Apple IS executes a request to the courier service's IS to obtain the full list of all available PPs in the format required by the Gold Apple IS. This request may also be executed by the Gold Apple IS after the integration is launched, as needed to keep the pickup point directory up to date. The directory maintained in the Gold Apple IS, and its individual elements, may be changed at the courier service's request using the following methods:

Basic Information​

Request method typeGET
Path / URL/api/v1/pickpoints
DescriptionMethod used to retrieve the list of PPs provided by the courier service
DirectionThe request is executed by the Gold Apple IS. The response is provided by the courier service.

Request​

Header Parameters​

ParameterData typeRequiredDescriptionComment
Authorizationstring1Access token obtained during authorization. Passed in the format Bearer <access_token>The format is defined by the courier service (see Authorization in the ECS Service)
content-typestring1Request content typeFilled in as "application/json"

Request example​

curl --location 'https://api.example-cs.com/api/v1/pickpoints' \
-H "Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.
eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiaWF0IjoxNTE2MjM5MDIyfQ.
SflKxwRJSMeKKF2QT4fwpMeJf36POk6yJV_adQssw5c" \
-H "Content-Type: application/json"

Response​

Response Codes and Messages​

CodeStatusMessageReason
200OKSuccessEverything completed successfully. The PP directory is provided in the response payload
400Bad RequestMissing or inappropriate required parametersRequired parameters are missing or invalid
401UnauthorizedToken is invalidAuthentication error at the courier service
403ForbiddenHas no permissionInsufficient permissions
500Internal Server ErrorServer unavailableThe server is unavailable

Successful Response Parameters​

№ParameterData typeRequiredDescriptionComment
1countryISOCodestring (2)1Country code for the directoryPer the "ISO 3166-1, alpha-2" standard
2deliveryServiceCodestring (100)1Courier service codeAgreed upon during system integration.
3pickpointsListarray of objects1Array of pickup point objects
4idstring (100)1Courier service PP identifierPassed by the courier service
5typestring (20)1Pick-up point typeSee "Format Tables" → "Table 1"
6addressaddress object1Object containing address data
7Address object typeobject1Object containing address information.Address object (see Appendix: Address Data Types)
8openingHoursarray of objects1Array of PP working-hours objects
9dayOfWeekenum1Identifier of the day for which the working schedule is setSee "Format Tables" → "Table 3"
10workingDaybool1Working-day flagIf on, the PP operates on this day of the week
11opensstring (15)0PP opening timePer the "ISO 8601" standard (hh:mm:ss)
12closesstring (15)0PP closing timePer the "ISO 8601" standard (hh:mm:ss)
13phoneNumberstring (20)0PP phone numberNo special characters, digits only (country code and area code)
14isAvailableboolean1PP availability statusIf the flag is on, the PP is active; if off, it is not
15orderStoragePeriodint1Order storage period, in calendar daysExample: 5
16optionsobject1Object with options available at the PP
17orderIssuingbool1Order issuing availableIf on, the PP can hand out orders
18orderReturningbool1Order return availableIf on, the PP can accept returns
19haveTryOnbool1Fitting rooms and try-on availableIf on, the PP has fitting rooms
20havePartialBuybool1Partial purchase availableI.e. the PP can carry out a partial hand-out
21packageMinWeightint1Minimum parcel weight for this PP, in grams
22packageMaxWeightint1Maximum parcel weight for this PP, in grams
23packageMaxLengthdecimal1Maximum parcel length for the PP, in centimeters.Along the X axis. Precise to two decimal places
24packageMaxHeightdecimal1Maximum parcel height for the PP, in centimeters.Along the Y axis. Precise to two decimal places
25packageMaxWidthdecimal1Maximum parcel width for the PP, in centimeters.Along the Z axis. Precise to two decimal places
26paymentOptionsobject1Object with payment-on-receipt options
27haveCashPaymentbool1Cash payment available (register)If on, cash payment is possible at the PP
28haveCardPaymentbool1Card payment available (terminal)If on, the PP accepts card payment
29haveQrCodePaymentbool1QR-code payment available (terminal, PP software)If on, the PP has QR-code payment

Successful response example​

{
"countryISOCode": "RU",
"deliveryServiceCode": "EXAMPLE_CS",
"pickpointsList": [
{
"id": "PP-SPB-001",
"type": "PICKPOINT",
"address": {
"addressType": "gar",
"fullAddress": "190000, Saint Petersburg, Nevsky Ave., 28",
"regionFias": "c2deb16a-0330-4f05-821f-1d12d16a218a",
"cityFias": "f1a154e5-7982-4d4b-a70d-5e9a01350320",
"houseFias": "a1b2c3d4-5678-90ef-1234-567890abcdef",
"flat": "",
"latitude": 58.0167,
"longitude": 56.235,
"addressComment": "2nd floor, near the escalator"
},
"openingHours": [
{
"dayOfWeek": 1,
"workingDay": true,
"opens": "09:00:00",
"closes": "21:00:00"
},
{
"dayOfWeek": 2,
"workingDay": true,
"opens": "09:00:00",
"closes": "21:00:00"
},
{
"dayOfWeek": 3,
"workingDay": true,
"opens": "09:00:00",
"closes": "21:00:00"
},
{
"dayOfWeek": 4,
"workingDay": true,
"opens": "09:00:00",
"closes": "21:00:00"
},
{
"dayOfWeek": 5,
"workingDay": true,
"opens": "09:00:00",
"closes": "21:00:00"
},
{
"dayOfWeek": 6,
"workingDay": true,
"opens": "10:00:00",
"closes": "20:00:00"
},
{
"dayOfWeek": 7,
"workingDay": false,
"opens": null,
"closes": null
}
],
"phoneNumber": "78121234567",
"isAvailable": true,
"orderStoragePeriod": 5,
"options": {
"orderIssuing": true,
"orderReturning": true,
"haveTryOn": true,
"havePartialBuy": true,
"packageMinWeight": 150,
"packageMaxWeight": 10000,
"packageMaxLength": 100,
"packageMaxHeight": 100,
"packageMaxWidth": 100
},
"paymentOptions": {
"haveCashPayment": true,
"haveCardPayment": true,
"haveQrCodePayment": true
}
},
{
"id": "PP-MOS-005",
"type": "POSTOMAT",
"address": {
"addressType": "coord",
"fullAddress": "125009, Moscow, Tverskaya St., 7",
"cityFias": "2763c110-cb8b-416a-9dac-ad28a55b4402",
"latitude": 55.755816,
"longitude": 37.617633,
"flat": "",
"addressComment": "Parcel locker 'Meridian', 1st floor, near the main entrance"
},
"openingHours": [
{
"dayOfWeek": 1,
"workingDay": true,
"opens": "10:00:00",
"closes": "22:00:00"
},
{
"dayOfWeek": 2,
"workingDay": true,
"opens": "10:00:00",
"closes": "22:00:00"
},
{
"dayOfWeek": 3,
"workingDay": true,
"opens": "10:00:00",
"closes": "22:00:00"
},
{
"dayOfWeek": 4,
"workingDay": true,
"opens": "10:00:00",
"closes": "22:00:00"
},
{
"dayOfWeek": 5,
"workingDay": true,
"opens": "10:00:00",
"closes": "22:00:00"
},
{
"dayOfWeek": 6,
"workingDay": true,
"opens": "10:00:00",
"closes": "22:00:00"
},
{
"dayOfWeek": 7,
"workingDay": true,
"opens": "11:00:00",
"closes": "21:00:00"
}
],
"phoneNumber": null,
"isAvailable": false,
"orderStoragePeriod": 7,
"options": {
"orderIssuing": true,
"orderReturning": false,
"haveTryOn": false,
"havePartialBuy": false,
"packageMinWeight": 50,
"packageMaxWeight": 3000,
"packageMaxLength": 45,
"packageMaxHeight": 27.9,
"packageMaxWidth": 30
},
"paymentOptions": {
"haveCashPayment": false,
"haveCardPayment": true,
"haveQrCodePayment": true
}
}
]
}

Unsuccessful Response Parameters​

ParameterData typeRequiredDescriptionComment
errorstring1Human-readable description of the errorsee the "Response Codes and Messages" section

Unsuccessful response example​

{
"error": "Token is invalid"
}

Format Tables​

Table 1: Valid Pick-up Point Types​

TypeCodeDescription
PPPICKPOINTAn order pickup point with an on-site operator, register, fitting rooms, etc.
Parcel lockerPOSTOMATAn order pickup terminal at a retail location or shopping mall — a parcel locker

Table 2: Address Information Types​

TypeCodeDescription
Russian Federation State Address RegistergarAn address object using GAR and FIAS identifiers
Coordinate system (latitude, longitude, address)coordAn address object using coordinates and a free-form address
Free-form addresscustomAn address object using a free-form address and clarifying fields

Table 3: Days of the Week​

Day of the weekIdentifier
Monday1
Tuesday2
Wednesday3
Thursday4
Friday5
Saturday6
Sunday7