Neoship Api (1.0.0)

This API documentation describes the individual integration options with the Neoship

Production API: https://apiserver.neoship.sk/api
Test API: https://apiserver.nshptest.sk/api

Login

Login

Login to Neoship to obtain a token

Authorizations:
bearerAuth
Request Body schema: application/json
required
username
string non-empty

Name of user for log into application (usually email)

password
string non-empty

The user password used for login

Responses

Request samples

Content type
application/json
{
  • "username": "username@login.com",
  • "password": "AC123456"
}

Response samples

Content type
application/json
{
  • "token": "eyjiioajsiodj...",
  • "refresh_token": "23165c5..."
}

Refresh token

Refresh token

Refresh JWT token after expriation

Authorizations:
bearerAuth
Request Body schema: application/json
required
refresh_token
string non-empty

Refresh token returned in succesfull login action

Responses

Request samples

Content type
application/json
{
  • "refresh_token": "85fc4162fa3195bfa662b9bd759b3dae2e3a..."
}

Response samples

Content type
application/json
{
  • "token": "eyjiioajsiodj...",
  • "refresh_token": "23165c5..."
}

Package

New package

Create new package

Authorizations:
bearerAuth
path Parameters
shipper_id
required
integer

The id of shipper:
GLS - 1
SPS - 2
Packeta - 3
DPD - 5
Slovenská pošta - 7
SDS - 8

Request Body schema: application/json
required

Echo payload

reference_number
string non-empty

Reference number of package

sender_name
string non-empty

Full name of the sender

sender_company
string

Company of the sender

sender_street
string non-empty

Street of the sender (house number can be INCLUDED depends on situation)

sender_house_number
string

House number of the sender

sender_city
string non-empty

City of the sender

sender_zip
string non-empty

Postal code of the sender

sender_state_code
string non-empty

State code of the sender

sender_email
string non-empty

Email of the sender

sender_phone
string non-empty

Phone of the sender

receiver_name
string non-empty

Full name of the receiver

receiver_company
string

Company of the receiver

receiver_street
string non-empty

Street of the receiver (house number can be INCLUDED depends of situation)

receiver_house_number
string

House number of the receiver

receiver_city
string non-empty

City of the receiver

receiver_zip
string non-empty

Postal code of the receiver

receiver_state_code
string non-empty

State code of the receiver

receiver_email
string non-empty

Email of the receiver

receiver_phone
string non-empty

Phone of the receiver

cod_price
number

Amount of cash on delivery (In the currency of the destination country)

cod_currency_code
string

Currency of cash on delivery

cod_reference
string

Reference of cash on delivery (REQUIRED in DPD if defined, optional in GLS)

insurance
number

Amount of insurance (EUR)

reverse
boolean non-empty

Reverse shipment

parcelshop
string

ID of parcelshop (Required for parcelshop package)

count_of_packages
number

The number of packages to be created.

weight
number

Weight of package in kilograms (for Packeta and DPD only).

carrier_type
number

ID of carrier type for address delivery (for Packeta only).

Responses

Request samples

Content type
application/json
{
  • "reference_number": "AC123456",
  • "sender_name": "John Doe",
  • "sender_company": "John Doe",
  • "sender_street": "Charles street",
  • "sender_house_number": "3852/9",
  • "sender_city": "Bratislava",
  • "sender_zip": 81101,
  • "sender_state_code": "SK",
  • "sender_email": "test@neoship.sk",
  • "sender_phone": 900123456,
  • "receiver_name": "John Doe",
  • "receiver_company": "John Doe",
  • "receiver_street": "Charles street",
  • "receiver_house_number": "3852/9",
  • "receiver_city": "Bratislava",
  • "receiver_zip": 81101,
  • "receiver_state_code": "SK",
  • "receiver_email": "test@neoship.sk",
  • "receiver_phone": 900123456,
  • "cod_price": 55.25,
  • "cod_currency_code": "EUR",
  • "cod_reference": 984686,
  • "insurance": 230.2,
  • "reverse": false,
  • "parcelshop": "PS-BBMK0269",
  • "count_of_packages": 2,
  • "weight": 1,
  • "carrier_type": 131
}

Response samples

Content type
application/json
{
  • "id": 42,
  • "reference_number": "AC123456"
}

New package bulk

Bulk action to create new packages. Packages are created only if all values are valid. If one package is invalid no one package is created

Authorizations:
bearerAuth
path Parameters
shipper_id
required
integer

The id of shipper:
GLS - 1
SPS - 2
Packeta - 3
DPD - 5
Slovenská pošta - 7
SDS - 8

Request Body schema: application/json
required

Echo payload

Array
reference_number
string non-empty

Reference number of package

sender_name
string non-empty

Full name of the sender

sender_company
string

Company of the sender

sender_street
string non-empty

Street of the sender (house number can be INCLUDED depends on situation)

sender_house_number
string

House number of the sender

sender_city
string non-empty

City of the sender

sender_zip
string non-empty

Postal code of the sender

sender_state_code
string non-empty

State code of the sender

sender_email
string non-empty

Email of the sender

sender_phone
string non-empty

Phone of the sender

receiver_name
string non-empty

Full name of the receiver

receiver_company
string

Company of the receiver

receiver_street
string non-empty

Street of the receiver (house number can be INCLUDED depends of situation)

receiver_house_number
string

House number of the receiver

receiver_city
string non-empty

City of the receiver

receiver_zip
string non-empty

Postal code of the receiver

receiver_state_code
string non-empty

State code of the receiver

receiver_email
string non-empty

Email of the receiver

receiver_phone
string non-empty

Phone of the receiver

cod_price
number

Amount of cash on delivery (In the currency of the destination country)

cod_currency_code
string

Currency of cash on delivery

cod_reference
string

Reference of cash on delivery (REQUIRED in DPD if defined, optional in GLS)

insurance
number

Amount of insurance (EUR)

reverse
boolean non-empty

Reverse shipment

parcelshop
string

ID of parcelshop (Required for parcelshop package)

count_of_packages
number

The number of packages to be created.

weight
number

Weight of package in kilograms (for Packeta and DPD only).

carrier_type
number

ID of carrier type for address delivery (for Packeta only).

Responses

Request samples

Content type
application/json
[
  • {
    • "reference_number": "AC123456",
    • "sender_name": "John Doe",
    • "sender_company": "John Doe",
    • "sender_street": "Charles street",
    • "sender_house_number": "3852/9",
    • "sender_city": "Bratislava",
    • "sender_zip": 81101,
    • "sender_state_code": "SK",
    • "sender_email": "test@neoship.sk",
    • "sender_phone": 900123456,
    • "receiver_name": "John Doe",
    • "receiver_company": "John Doe",
    • "receiver_street": "Charles street",
    • "receiver_house_number": "3852/9",
    • "receiver_city": "Bratislava",
    • "receiver_zip": 81101,
    • "receiver_state_code": "SK",
    • "receiver_email": "test@neoship.sk",
    • "receiver_phone": 900123456,
    • "cod_price": 55.25,
    • "cod_currency_code": "EUR",
    • "cod_reference": 984686,
    • "insurance": 230.2,
    • "reverse": false,
    • "parcelshop": "PS-BBMK0269",
    • "count_of_packages": 2,
    • "weight": 1,
    • "carrier_type": 131
    }
]

Response samples

Content type
application/json
[
  • {
    • "id": 42,
    • "reference_number": "AC123456"
    }
]

Bulk create and print

Combined endpoint that creates packages and immediately prints stickers in a single call. The label PDF is saved to storage (accessible via GET /package/{id}/label) and is not returned in the response.

This endpoint combines the functionality of POST /package/bulk/{shipper_id} (package creation) and POST /package/bulk/ with action=send_print_sticker (sticker printing) into one atomic operation.

Authorizations:
bearerAuth
path Parameters
shipper_id
required
integer

The id of shipper:
GLS - 1
SPS - 2
Packeta - 3
DPD - 5
Slovenská pošta - 7
SDS - 8

Request Body schema: application/json
required

Packages to create with printing options

required
Array of objects (Package_new)

Array of packages to create and print

object

Sticker printing options

Responses

Request samples

Content type
application/json
Example
{
  • "packages": [
    • {
      • "reference_number": "AC123456",
      • "sender_name": "John Doe",
      • "sender_company": "ACME s.r.o.",
      • "sender_street": "Prievozská",
      • "sender_house_number": "14",
      • "sender_city": "Bratislava",
      • "sender_zip": "82109",
      • "sender_state_code": "SK",
      • "sender_email": "sender@example.sk",
      • "sender_phone": "0905123456",
      • "receiver_name": "Jane Smith",
      • "receiver_company": "",
      • "receiver_street": "Hlavná",
      • "receiver_house_number": "28/A",
      • "receiver_city": "Košice",
      • "receiver_zip": "04001",
      • "receiver_state_code": "SK",
      • "receiver_email": "receiver@example.sk",
      • "receiver_phone": "0911234567",
      • "cod_price": 89.9,
      • "cod_currency_code": "EUR",
      • "cod_reference": "COD-001",
      • "insurance": 350,
      • "reverse": false,
      • "count_of_packages": 1,
      • "weight": 2.5
      }
    ],
  • "options": {
    • "sticker_position": "1",
    • "print_type": "A4_2x2"
    }
}

Response samples

Content type
application/json
[
  • {
    • "id": 42,
    • "reference_number": "AC123456",
    • "tracking_number": "TX87VKD5000002BL3Y"
    }
]

Info package

Info package

Authorizations:
bearerAuth
path Parameters
package_id
required
string

Id of package

Responses

Response samples

Content type
application/json
{
  • "id": 42,
  • "reference_number": "AC123456",
  • "sender_name": "John Doe",
  • "sender_company": "John Doe",
  • "sender_street": "Charles street",
  • "sender_house_number": "3852/9",
  • "sender_city": "Bratislava",
  • "sender_zip": 81101,
  • "sender_state_code": "SK",
  • "sender_email": "test@neoship.sk",
  • "sender_phone": 900123456,
  • "receiver_name": "John Doe",
  • "receiver_company": "John Doe",
  • "receiver_street": "Charles street",
  • "receiver_house_number": "3852/9",
  • "receiver_city": "Bratislava",
  • "receiver_zip": 81101,
  • "receiver_state_code": "SK",
  • "receiver_email": "test@neoship.sk",
  • "receiver_phone": 900123456,
  • "cod_price": 55.25,
  • "cod_currency_code": "EUR",
  • "cod_reference": 984686,
  • "insurance": 230.2,
  • "reverse": false,
  • "parcelshop": "PS-BBMK0269",
  • "weight": 3.8,
  • "tracking_number": "Z123654987",
  • "cod_payment": 1,
  • "shipper": {
    • "id": 2,
    • "name": "Slovak Parcel Service",
    • "shortcut": "SPS"
    },
  • "statuses": [
    • {
      • "status_type": {
        • "id": 251,
        • "name": "Exportovaná"
        }
      }
    ],
  • "is_service": false,
  • "price_vat": 4.59,
  • "invoice_number": 4110075779,
  • "invoice_date": "2021-08-04"
}

Edit package

Edit package which has not been exported

Authorizations:
bearerAuth
path Parameters
package_id
required
string

Id of package

Request Body schema: application/json
required

Echo payload

reference_number
string non-empty

Reference number of package

sender_name
string non-empty

Full name of the sender

sender_company
string

Company of the sender

sender_street
string non-empty

Street of the sender

sender_house_number
string

House number of the sender

sender_city
string non-empty

City of the sender

sender_zip
string non-empty

Postal code of the sender

sender_state_code
string non-empty

State code of the sender

sender_email
string non-empty

Email of the sender

sender_phone
string non-empty

Phone of the sender

receiver_name
string non-empty

Full name of the receiver

receiver_company
string

Company of the receiver

receiver_street
string non-empty

Street of the receiver

receiver_house_number
string

House number of the receiver

receiver_city
string non-empty

City of the receiver

receiver_zip
string non-empty

Postal code of the receiver

receiver_state_code
string non-empty

State code of the receiver

receiver_email
string non-empty

Email of the receiver

receiver_phone
string non-empty

Phone of the receiver

cod_price
number

Amount of cash on delivery (In the currency of the destination country)

cod_currency_code
string

Currency of cash on delivery

cod_reference
string

Reference of cash on delivery (REQUIRED in DPD if defined, optional in GLS)

insurance
number

Amount of insurance (EUR)

reverse
boolean non-empty

Reverse shipment

parcelshop
string

ID of parcelshop (Required for parcelshop package)

count_of_packages
number

The number of packages to be created.

weight
number

Weight of package in kilograms (for Packeta and DPD only).

carrier_type
number

ID of carrier type for address delivery (for Packeta only).

Responses

Request samples

Content type
application/json
{
  • "reference_number": "AC123456",
  • "sender_name": "John Doe",
  • "sender_company": "John Doe",
  • "sender_street": "Charles street",
  • "sender_house_number": "3852/9",
  • "sender_city": "Bratislava",
  • "sender_zip": 81101,
  • "sender_state_code": "SK",
  • "sender_email": "test@neoship.sk",
  • "sender_phone": 900123456,
  • "receiver_name": "John Doe",
  • "receiver_company": "John Doe",
  • "receiver_street": "Charles street",
  • "receiver_house_number": "3852/9",
  • "receiver_city": "Bratislava",
  • "receiver_zip": 81101,
  • "receiver_state_code": "SK",
  • "receiver_email": "test@neoship.sk",
  • "receiver_phone": 900123456,
  • "cod_price": 55.25,
  • "cod_currency_code": "EUR",
  • "cod_reference": 984686,
  • "insurance": 230.2,
  • "reverse": false,
  • "parcelshop": "PS-BBMK0269",
  • "count_of_packages": 2,
  • "weight": 1,
  • "carrier_type": 131
}

Response samples

Content type
application/json
{
  • "cod_price": [
    • "Cannot be blank"
    ],
  • "sender_zip": [
    • "Not valid postal code"
    ],
  • "...": [ ]
}

Delete package

Delete package which has not been exported

Authorizations:
bearerAuth
path Parameters
package_id
required
string

Id of package

Responses

Download label

Downloads the label PDF for a package that has been exported (sticker printed). The label must have been previously generated via POST /package/bulk/ with action=send_print_sticker or via POST /package/bulk-create-and-print/{shipper_id}.

Authorizations:
bearerAuth
path Parameters
package_id
required
integer
Example: 42

Id of the package

Responses

Response samples

Content type
application/json
{
  • "error": "Label not found"
}

Cancel package

Cancel package. Cancels the shipment at the shipper and marks the package as cancelled. Reference number is prefixed with X. Only packages in shipping (not yet exported) or service packages can be cancelled.

Authorizations:
bearerAuth
path Parameters
package_id
required
integer
Example: 42

Id of package

Request Body schema: application/json
optional
source
string

Request source (e.g. WEB, API)

Responses

Request samples

Content type
application/json
{
  • "source": "API"
}

Response samples

Content type
application/json
{
  • "error": "string",
  • "shipper": "string",
  • "requestId": "string"
}

List of packages

List of packages

Authorizations:
bearerAuth
query Parameters
page
integer

The number of page

rows_per_page
integer

The numbers of items to return

reference_number
string

Packages with the specified reference number

tracking_number
string

Packages with the specified tracking number

Responses

Response samples

Content type
application/json
{
  • "rows": [
    • {
      • "id": 42,
      • "reference_number": "AC123456",
      • "sender_name": "John Doe",
      • "sender_company": "John Doe",
      • "sender_street": "Charles street",
      • "sender_house_number": "3852/9",
      • "sender_city": "Bratislava",
      • "sender_zip": 81101,
      • "sender_state_code": "SK",
      • "sender_email": "test@neoship.sk",
      • "sender_phone": 900123456,
      • "receiver_name": "John Doe",
      • "receiver_company": "John Doe",
      • "receiver_street": "Charles street",
      • "receiver_house_number": "3852/9",
      • "receiver_city": "Bratislava",
      • "receiver_zip": 81101,
      • "receiver_state_code": "SK",
      • "receiver_email": "test@neoship.sk",
      • "receiver_phone": 900123456,
      • "cod_price": 55.25,
      • "cod_currency_code": "EUR",
      • "cod_reference": 984686,
      • "insurance": 230.2,
      • "reverse": false,
      • "parcelshop": "PS-BBMK0269",
      • "weight": 3.8,
      • "tracking_number": "Z123654987",
      • "cod_payment": 1,
      • "shipper": {
        • "id": 2,
        • "name": "Slovak Parcel Service",
        • "shortcut": "SPS"
        },
      • "statuses": [
        • {
          • "status_type": {
            • "id": 251,
            • "name": "Exportovaná"
            }
          }
        ],
      • "is_service": false
      }
    ],
  • "count": 22
}

List of packages by reference numbers

List of packages by the list of reference numbers. If the list of reference numbers contains invalid reference numbers, the packages corresponding to invalid reference numbers are not included in response content.

Authorizations:
bearerAuth
Request Body schema: application/json
required

Echo payload

reference_numbers
Array of arrays

List of reference numbers.

Responses

Request samples

Content type
application/json
{
  • "reference_numbers": [
    • "AB123456",
    • "BC987654",
    • "..."
    ]
}

Response samples

Content type
application/json
[
  • {
    • "id": 42,
    • "reference_number": "AC123456",
    • "sender_name": "John Doe",
    • "sender_company": "John Doe",
    • "sender_street": "Charles street",
    • "sender_house_number": "3852/9",
    • "sender_city": "Bratislava",
    • "sender_zip": 81101,
    • "sender_state_code": "SK",
    • "sender_email": "test@neoship.sk",
    • "sender_phone": 900123456,
    • "receiver_name": "John Doe",
    • "receiver_company": "John Doe",
    • "receiver_street": "Charles street",
    • "receiver_house_number": "3852/9",
    • "receiver_city": "Bratislava",
    • "receiver_zip": 81101,
    • "receiver_state_code": "SK",
    • "receiver_email": "test@neoship.sk",
    • "receiver_phone": 900123456,
    • "cod_price": 55.25,
    • "cod_currency_code": "EUR",
    • "cod_reference": 984686,
    • "insurance": 230.2,
    • "reverse": false,
    • "parcelshop": "PS-BBMK0269",
    • "weight": 3.8,
    • "tracking_number": "Z123654987",
    • "cod_payment": 1,
    • "shipper": {
      • "id": 2,
      • "name": "Slovak Parcel Service",
      • "shortcut": "SPS"
      },
    • "statuses": [
      • {
        • "status_type": {
          • "id": 251,
          • "name": "Exportovaná"
          }
        }
      ],
    • "is_service": false
    }
]

Stickers, Acceptance protocol

Bulk action for getting stickers or acceptance protocol.

Authorizations:
bearerAuth
Request Body schema: application/json

Echo payload

action
string non-empty


send_print_sticker - for get stickers

GLS (string) or SPS (string) or Packeta (string) or Packeta HD (string) or DPD (string) or Slovenská pošta (string) or SDS (string)

Type of format sticker to print

sticker_position
number or null
Enum: 1 2 3 4

Sticker position if shipper support this option

reference_numbers
Array of arrays non-empty

Array of packages reference numbers to print

Responses

Request samples

Content type
application/json
Example
{
  • "action": "send_print_sticker",
  • "print_type": "A4_2x2",
  • "sticker_position": 1,
  • "reference_numbers": [
    • "ASD1354"
    ]
}

Response samples

Content type
application/json
Example
{
  • "labels": "JVBERi0xLjUKJfLz9PX2CjEgMCBvYmoKPD...",
  • "errors": [
    • {
      • "reference_number": "AC123456",
      • "package_id": 42,
      • "shipper_id": 1,
      • "errors": [
        • "Cod not allowed for 'Client Id'",
        • "..."
        ]
      }
    ],
  • "tracking": {
    • "<package_id>": {
      • "reference_number": "ASD1354",
      • "tracking_number": "Z1234567890"
      }
    }
}

Package quotes

Calculate available package shipping quotes for the authenticated user.

Authorizations:
bearerAuth
Request Body schema: application/json
required

Quote calculation payload

sender_state_code
required
string

State code of the sender.

receiver_state_code
required
string

State code of the receiver.

weight
required
number >= 0

Package weight in kilograms.

cod_price
number >= 0
Default: 0

Amount of cash on delivery.

cod_currency_code
string
Default: "EUR"

Currency of cash on delivery.

payment_type
integer
Default: 0
Enum: 0 1

Cash on delivery payment type.
0 - cash
1 - card

insurance
number >= 0
Default: 0

Insurance amount.

parcelshop
boolean
Default: false

Whether to calculate parcelshop delivery quotes.

reverse
boolean
Default: false

Whether to calculate reverse shipment quotes.

Array of integers or string

Optional shipper IDs to limit quote calculation. Can be sent as an array or comma-separated string.
The id of shipper:
GLS - 1
SPS - 2
Packeta - 3
DPD - 5
Slovenská pošta - 7
SDS - 8

Responses

Request samples

Content type
application/json
{
  • "sender_state_code": "SK",
  • "receiver_state_code": "CZ",
  • "weight": 1.5,
  • "cod_price": 55.25,
  • "cod_currency_code": "EUR",
  • "payment_type": 0,
  • "insurance": 230.2,
  • "parcelshop": false,
  • "reverse": false,
  • "shipper_ids": [
    • 1,
    • 3,
    • 5
    ]
}

Response samples

Content type
application/json
{
  • "quotes": [
    • {
      • "carrier": {
        • "shipper_id": "3",
        • "shipper_shortcut": "Packeta",
        • "shipper_name": "Packeta",
        • "carrier_type": 131,
        • "carrier_name": "Packeta Home HD"
        },
      • "price": {
        • "currency": "EUR",
        • "amount_without_vat": "4.20",
        • "amount_with_vat": "5.17",
        • "vat_rate": "0.23"
        },
      • "breakdown": [
        • {
          • "code": "shipping",
          • "label": "Základná cena dopravy",
          • "amount_without_vat": "3.50",
          • "amount_with_vat": "4.31"
          }
        ],
      • "purchase": {
        • "price": {
          • "currency": "EUR",
          • "amount_without_vat": "4.20",
          • "amount_with_vat": "5.17",
          • "vat_rate": "0.23"
          },
        • "breakdown": [
          • {
            • "code": "shipping",
            • "label": "Základná cena dopravy",
            • "amount_without_vat": "3.50",
            • "amount_with_vat": "4.31"
            }
          ]
        },
      • "purchase_error": {
        • "code": "missing_shipping_price",
        • "message": "Chýba cena dopravy",
        • "carrier": {
          • "shipper_id": "3",
          • "shipper_shortcut": "Packeta",
          • "shipper_name": "Packeta",
          • "carrier_type": 131,
          • "carrier_name": "Packeta Home HD"
          }
        }
      }
    ],
  • "errors": [
    • {
      • "code": "missing_shipping_price",
      • "message": "Chýba cena dopravy",
      • "carrier": {
        • "shipper_id": "3",
        • "shipper_shortcut": "Packeta",
        • "shipper_name": "Packeta",
        • "carrier_type": 131,
        • "carrier_name": "Packeta Home HD"
        }
      }
    ]
}

Admin package

Package quotes for user

Calculate available package shipping quotes for a selected user. The response includes purchase prices when available.

Authorizations:
bearerAuth
path Parameters
user_id
required
integer

User ID for quote calculation

Request Body schema: application/json
required

Quote calculation payload

sender_state_code
required
string

State code of the sender.

receiver_state_code
required
string

State code of the receiver.

weight
required
number >= 0

Package weight in kilograms.

cod_price
number >= 0
Default: 0

Amount of cash on delivery.

cod_currency_code
string
Default: "EUR"

Currency of cash on delivery.

payment_type
integer
Default: 0
Enum: 0 1

Cash on delivery payment type.
0 - cash
1 - card

insurance
number >= 0
Default: 0

Insurance amount.

parcelshop
boolean
Default: false

Whether to calculate parcelshop delivery quotes.

reverse
boolean
Default: false

Whether to calculate reverse shipment quotes.

Array of integers or string

Optional shipper IDs to limit quote calculation. Can be sent as an array or comma-separated string.
The id of shipper:
GLS - 1
SPS - 2
Packeta - 3
DPD - 5
Slovenská pošta - 7
SDS - 8

Responses

Request samples

Content type
application/json
{
  • "sender_state_code": "SK",
  • "receiver_state_code": "CZ",
  • "weight": 1.5,
  • "cod_price": 55.25,
  • "cod_currency_code": "EUR",
  • "payment_type": 0,
  • "insurance": 230.2,
  • "parcelshop": false,
  • "reverse": false,
  • "shipper_ids": [
    • 1,
    • 3,
    • 5
    ]
}

Response samples

Content type
application/json
{
  • "quotes": [
    • {
      • "carrier": {
        • "shipper_id": "3",
        • "shipper_shortcut": "Packeta",
        • "shipper_name": "Packeta",
        • "carrier_type": 131,
        • "carrier_name": "Packeta Home HD"
        },
      • "price": {
        • "currency": "EUR",
        • "amount_without_vat": "4.20",
        • "amount_with_vat": "5.17",
        • "vat_rate": "0.23"
        },
      • "breakdown": [
        • {
          • "code": "shipping",
          • "label": "Základná cena dopravy",
          • "amount_without_vat": "3.50",
          • "amount_with_vat": "4.31"
          }
        ],
      • "purchase": {
        • "price": {
          • "currency": "EUR",
          • "amount_without_vat": "4.20",
          • "amount_with_vat": "5.17",
          • "vat_rate": "0.23"
          },
        • "breakdown": [
          • {
            • "code": "shipping",
            • "label": "Základná cena dopravy",
            • "amount_without_vat": "3.50",
            • "amount_with_vat": "4.31"
            }
          ]
        },
      • "purchase_error": {
        • "code": "missing_shipping_price",
        • "message": "Chýba cena dopravy",
        • "carrier": {
          • "shipper_id": "3",
          • "shipper_shortcut": "Packeta",
          • "shipper_name": "Packeta",
          • "carrier_type": 131,
          • "carrier_name": "Packeta Home HD"
          }
        }
      }
    ],
  • "errors": [
    • {
      • "code": "missing_shipping_price",
      • "message": "Chýba cena dopravy",
      • "carrier": {
        • "shipper_id": "3",
        • "shipper_shortcut": "Packeta",
        • "shipper_name": "Packeta",
        • "carrier_type": 131,
        • "carrier_name": "Packeta Home HD"
        }
      }
    ]
}

User

User detail

Detail about user

Authorizations:
bearerAuth

Responses

Response samples

Content type
application/json
{
  • "id": 4,
  • "username": "AC123456",
  • "roles": [ ],
  • "credit": 1234.95,
  • "variable_number": 2236345,
  • "address": {
    • "name": "John Doe",
    • "company": "John Doe",
    • "street": "Charles street",
    • "city": "Bratislava",
    • "zip": 81101,
    • "email": "test@neoship.sk",
    • "phone": 900123456,
    • "tin": 534353,
    • "oin": 448164,
    • "vatin": 146846
    },
  • "invoice_address": {
    • "name": "John Doe",
    • "company": "John Doe",
    • "street": "Charles street",
    • "city": "Bratislava",
    • "zip": 81101,
    • "email": "test@neoship.sk",
    • "phone": 900123456,
    • "tin": 534353,
    • "oin": 448164,
    • "vatin": 146846
    }
}

Parcelshop

List of parcelshops

List of parcelshop

Authorizations:
bearerAuth
path Parameters
shipper_id
required
integer

The id of shipper:
GLS - 1
SPS - 2
Packeta - 3
DPD - 5
Slovenská pošta - 7
SDS - 8

Responses

Response samples

Content type
application/json
[
  • {
    • "id": 42,
    • "parcelshop_id": "AC123456",
    • "name": "Tesco Galanta (TABAK PRESS)",
    • "street": "Galanta street",
    • "city": "Galanta",
    • "zip": 81101,
    • "state_code": "SK",
    • "shipper": "GLS",
    • "shipper_id": 2
    }
]

Parcelshop detail

Detail of parcelshop

Authorizations:
bearerAuth
path Parameters
id
required
integer

Id of parcelshop

Responses

Response samples

Content type
application/json
{
  • "id": 42,
  • "parcelshop_id": "AC123456",
  • "name": "Tesco Galanta (TABAK PRESS)",
  • "street": "Galanta street",
  • "city": "Galanta",
  • "zip": 81101,
  • "state_code": "SK",
  • "shipper": "GLS",
  • "shipper_id": 2
}

Tracking

By tracking number

Tracking of packages by tracking number. This is usefull, if you want to show the information in your app.

Authorizations:
bearerAuth
path Parameters
tracking_number
required
string

Tracking number of package

Responses

Response samples

Content type
application/json
{
  • "logo": "https:storage.cloud.com/app/logo.png",
  • "weight": 2,
  • "sender": "SK 02901 Martin",
  • "receiver": "SK 03601 Martin",
  • "reference_number": 2236345,
  • "statuses": {
    • "created_at": "2021-09-09",
    • "center": "SPS Hub",
    • "name": "Doruceny"
    }
}

By reference number

Tracking of packages by reference number and user id. This tracking is returning the page with the styles, not needed parsing response or anything else.

Authorizations:
bearerAuth
path Parameters
user_id
required
number

Id of user

reference_number
required
string

Reference number of package

Responses

Tracking public

By tracking number

Tracking of packages by tracking number. This tracking is returning the page with the styles, not needed parsing response or anything else.

Authorizations:
bearerAuth
path Parameters
tracking_number
required
string

Tracking number of package

Responses

Parcelshops

Parcelshop picker

The parcelshop picker is an embeddable map UI for selecting a delivery point. It is intended for checkout or shipment forms where the customer chooses a parcelshop.

For usage on your own domain, create a parcelshop picker API key in Neoship and store the exact parent page origin for that key, for example https://eshop.example. One key can have multiple allowed origins in Neoship.

Use https://aplikacia.neoship.sk for production and https://t-we-nshp-webapp-01-app.azurewebsites.net for testing.

JavaScript integration

Load the versioned JavaScript library on your page:

<script src="https://aplikacia.neoship.sk/parcelshop-picker/v1/library.js"></script>

Open the picker:

<button type="button" id="open-picker">Choose parcelshop</button>

<script>
  const apiKey = "XXXXXXXXXXXXX";

  document.getElementById("open-picker").addEventListener("click", () => {
    window.NeoshipParcelshopPicker.pick(apiKey, (parcelshop) => {
      if (parcelshop === null) {
        // Picker was closed without selection.
        return;
      }

      // Save parcelshop.parcelshopId into your order/package parcelshop field.
      console.log(parcelshop);
    });
  });
</script>

pick() opens the picker in a full-screen iframe dialog, validates messages from the iframe origin, dispatches the neoship:parcelshop-picker:selected browser event, and closes the previous picker before opening a new one.

Selection payload

The selected parcelshop payload has this shape:

{
  "shipperId": "3",
  "ownPlace": false,
  "parcelshopId": "12345",
  "name": "Parcelshop name",
  "street": "Main street 1",
  "zip": "81101",
  "city": "Bratislava",
  "stateCode": "SK",
  "lat": 48.1486,
  "lng": 17.1077,
  "openingHours": "Pondelok: 08:30 - 18:30; Utorok: 08:30 - 18:30; Streda: 08:30 - 18:30",
  "kind": "parcelshop",
  "boxType": "PS",
  "price": "2,90 €"
}
Field Description
shipperId Neoship shipper id of the carrier, or own for one of your own pickup places (see Own pickup places below).
ownPlace true when the customer picked one of your own pickup places instead of a carrier parcelshop.
parcelshopId The carrier's parcelshop id, or the place code you gave your own pickup place.
openingHours Opening hours flattened into one string, label: hours pairs joined with ; . Labels are localised weekday names; SPS publishes hours per calendar date instead, so its labels also carry the date, for example Pondelok 24. 8.. null when the carrier reports no hours.
kind Type of place, normalised across carriers: box for a parcel locker, parcelshop for a staffed pickup point, post_office for a Slovak Post branch. null when the carrier gives no signal. Own pickup places are always parcelshop. Branch on this, not on boxType.
boxType The carrier's own raw value behind kind, kept for backwards compatibility. It is carrier-specific and not comparable across carriers: PT/PS for SPS, zbox/point for Packeta, bbox/point/office for Slovak Post, and null for GLS and DPD, which report the place type in a different field, and for own pickup places.
price The price text shown to the customer for this place, exactly as it was shown: the price set on your own pickup place in Neoship, otherwise the one your page attached through the prices option. null when neither applies.

Use parcelshopId as the parcelshop value when creating a parcelshop package. For persisting the selected parcelshop on an order so a Neoship connector can create the shipment later, see the Storing a selected parcelshop guide.

JavaScript API

const picker = window.NeoshipParcelshopPicker.pick(apiKey, callback, options);
picker.setPrices(rules);
picker.close();
window.NeoshipParcelshopPicker.close();

You can also use object-style arguments:

window.NeoshipParcelshopPicker.pick({
  apiKey: "XXXXXXXXXXXXX",
  selectedShipper: "GLS",
  availableShippers: ["GLS", "Packeta"],
  countries: ["SK", "CZ"],
  language: "sk-SK",
  autoZoomToUser: true,
  markerIcons: "alt",
  prices: [
    { price: "3,90 €" },
    { kind: "box", price: "2,90 €" },
    { shipper: "Packeta", country: "CZ", price: "89 Kč" },
    { shipper: "SPS", price: "Zdarma" },
  ],
  onSelect: (parcelshop) => {},
  onClose: () => {},
});

The callback receives the selected parcelshop payload. If the picker is closed without selection, the callback receives null. close() closes the currently open picker, which is useful for single-page applications and host-page modal cleanup. pick() returns a handle with close() and setPrices(rules); the latter replaces the price rules while the picker is open, for example when the cart total crosses a free-shipping threshold.

Options

These options can be passed in the options object, or in the object-style pick({...}) call.

Option Description
apiKey API key assigned to your Neoship account for this picker origin. Required when embedding the picker from an external origin.
theme Visual theme. Allowed values are light and dark. When omitted, the library uses the host document data-theme or browser dark-mode preference.
selectedShipper Initially selected shipper shortcut, or own for your own pickup places. If no shipper subset is provided, this also limits the picker to this shipper.
availableShippers Array or comma-separated list of shipper shortcuts available in the picker. Include own to keep your own pickup places in a restricted list. When omitted, all available parcelshop shippers and your own pickup places are shown.
countries Array or comma-separated list of ISO 3166-1 alpha-2 country codes used to limit parcelshops and location suggestions, for example ["SK", "CZ"].
language Preferred picker UI language, location suggestion language and language of your own pickup places' texts, for example sk-SK. Regional tags fall back to the supported base UI language, for example en-US renders the UI in English.
autoZoomToUser Enables browser geolocation and automatic zoom to the customer's current position. Defaults to true in the JavaScript library.
markerIcons Map marker design. Allowed values are alt (carrier logo in the bubble, place type in the badge) and classic (place type in the bubble, carrier logo in the badge). Defaults to alt. The sidebar always shows round carrier badges.
prices Array of price rules shown next to each parcelshop in the list, the map popup and the detail panel. See the Prices section below. When omitted, no price is shown.
closeOnBackdrop Set to false to keep the picker open when the overlay backdrop is clicked.
title Iframe/dialog title.
zIndex, backdrop, padding Visual options for the full-screen dialog.
onSelect, onClose, onReady, onError Lifecycle callbacks.

When the library is loaded from https://aplikacia.neoship.sk/parcelshop-picker/v1/library.js, the default picker iframe opens https://aplikacia.neoship.sk/neoship/parcelshop-picker/ even when the script is embedded on another domain. You can override this only with url or pickerUrl in advanced integrations.

Prices

The picker does not know your shipping prices; you pass them as rules and it shows the matching one on every place. Each rule is an object with a price text and up to three optional selectors:

Field Description
price Text shown to the customer, exactly as you provide it, for example 2,90 €, 89 Kč, od 2,90 € or Zdarma. Formatting and currency are yours to decide; the picker never parses it. Rules without a price are ignored.
shipper Shipper shortcut, for example GLS, SPS, Packeta, DPD, SK_POSTA, or own for your own pickup places. Case-insensitive. Omit to match every shipper.
kind Place type: box, parcelshop or post_office (the same values as kind in the selection payload). Omit to match every type. A place whose carrier reports no type only matches rules without kind.
country ISO 3166-1 alpha-2 code of the place's country, for example SK. Case-insensitive. Omit to match every country.

When several rules match a place, the most specific one wins: shipper outranks kind, which outranks country, so shipper + kind + country beats shipper + kind, which beats shipper + country, which beats shipper alone, and a rule naming no selector is the fallback for everything. Between rules of equal specificity the first one in the array wins. A place that matches no rule shows no price.

prices: [
  { price: "3,90 €" },                                   // fallback for everything
  { kind: "box", price: "2,90 €" },                      // every locker
  { shipper: "GLS", kind: "box", price: "2,50 €" },      // GLS lockers only
  { shipper: "Packeta", country: "CZ", price: "89 Kč" }, // Packeta in Czechia
  { shipper: "SPS", price: "Zdarma" },                   // every SPS place
]

The rules are sent into the iframe with postMessage once the picker reports neoship:parcelshop-picker:ready; they must therefore be JSON-serialisable. Sending a new array replaces the previous rules, and an empty array removes all prices.

Own pickup places

Besides carrier parcelshops, the picker can offer your own pickup places, for example your store or warehouse. You manage them in Neoship under Parcelshopy → Osobný odber; nothing changes in your integration. Every picker opened with your API key shows your active places automatically, next to the carrier parcelshops:

  • They appear on the map, in search results and in the detail panel like any other place, and the carrier filter gets an extra entry for them. You set its name in Parcelshopy → Nastavenia mapy; without one it reads Osobný odber in the picker's language. The same page takes your own map pin and list icon.
  • The selection payload carries shipperId: "own", ownPlace: true and your place code as parcelshopId.
  • The type filter treats them as parcelshop, so they stay visible unless the customer picks only other types.
  • A price set on the place is shown instead of your prices rules. Places without one follow the rules like any other place; use shipper: "own" to price them separately.
  • When you restrict the carriers with availableShippers, include own to keep your places; selectedShipper: "own" opens the picker on them alone.
  • The price, opening hours and filter entry name can be translated in Neoship. The picker shows them in its language and falls back to the Slovak text when a translation is missing.
  • They are not used for the location hints the picker suggests from the customer's position.

Manual iframe integration

The JavaScript library is recommended. If you need to render the iframe manually, use the picker page directly and handle window.postMessage yourself:

<iframe
  src="https://aplikacia.neoship.sk/neoship/parcelshop-picker/?apiKey=XXXXXXXXXXXXX&selected_shipper=GLS&available_shippers=GLS,Packeta&countries=SK,CZ&language=sk-SK&marker_icons=alt"
  title="Výber parcelshopu"
  allow="geolocation"
  style="width: 100%; height: 700px; border: 0;"
></iframe>
const pickerOrigin = "https://aplikacia.neoship.sk";
const iframe = document.querySelector("iframe");

window.addEventListener("message", (event) => {
  if (event.origin !== pickerOrigin) {
    return;
  }

  const message = event.data || {};

  if (message.type === "neoship:parcelshop-picker:ready") {
    // Optional: attach your prices once the picker is up (see Prices above).
    iframe.contentWindow.postMessage(
      { type: "neoship:parcelshop-picker:prices", detail: { prices: [{ price: "2,90 €" }] } },
      pickerOrigin,
    );
  }

  if (message.type === "neoship:parcelshop-picker:selected") {
    const parcelshop = message.detail;
    // Save parcelshop.parcelshopId into your order/package parcelshop field.
  }

  if (message.type === "neoship:parcelshop-picker:close") {
    // Close your modal or hide the iframe.
  }
});

Posted messages

The iframe sends these message types to the parent window:

  • neoship:parcelshop-picker:ready - picker loaded and initialized
  • neoship:parcelshop-picker:selected - user selected a parcelshop
  • neoship:parcelshop-picker:error - picker initialization or data loading failed
  • neoship:parcelshop-picker:close - user clicked close or pressed Escape

Received messages

The iframe accepts these message types from its parent window (iframe.contentWindow.postMessage(message, pickerOrigin)):

  • neoship:parcelshop-picker:prices - detail.prices is an array of price rules as described in the Prices section above. Send it after neoship:parcelshop-picker:ready; send it again to replace the rules.
query Parameters
apiKey
string
Default: null
Example: apiKey=XXXXXXXXXXXXX

API key assigned to your Neoship account for this picker origin. Required when embedding the picker from an external origin. Default is no API key, which only allows same-origin Neoship usage.

theme
string
Default: "light"
Enum: "light" "dark"
Example: theme=light

Visual theme for the picker iframe.

selected_shipper
string or null
Default: null
Example: selected_shipper=GLS

Initially selected shipper shortcut, or own for your own pickup places. If available_shippers is not provided, this also limits the picker to this shipper.

available_shippers
Array of strings
Default: ""
Example: available_shippers=GLS,Packeta

Comma-separated list of shipper shortcuts available in the picker. Include own to keep your own pickup places. Default is empty, which means all available parcelshop shippers and your own pickup places are shown.

countries
Array of strings[ items = 2 characters ]
Default: ""
Example: countries=SK,CZ

Comma-separated list of ISO 3166-1 alpha-2 country codes used to limit parcelshops and location suggestions. Default is empty, which means no country filter.

language
string or null
Default: null
Example: language=sk-SK

Preferred picker UI language, location suggestion language and language of your own pickup places' texts. Regional tags fall back to the supported base UI language, for example en-US renders the UI in English. Defaults to the picker application language when omitted.

auto_zoom_to_user
boolean
Default: false
Example: auto_zoom_to_user=true

Enables browser geolocation and automatic zoom to the customer's current position when allowed by the browser.

marker_icons
string
Default: "alt"
Enum: "alt" "classic"
Example: marker_icons=alt

Map marker design. alt shows the carrier logo in the bubble and the place type in the badge, classic the other way round. Unknown values fall back to alt. The sidebar always shows round carrier badges.

Responses

Storing a selected parcelshop

A parcelshop delivery needs a parcelshop ID. Regardless of how the customer picks the parcelshop — the parcelshop picker, the parcelshop list / detail endpoints, or the e-shop's own pickup-point selector — the integrator must persist the parcelshop ID on the order in the exact field the Neoship connector reads. Every Neoship e-commerce connector (WooCommerce, PrestaShop, Shopify, Shoptet) loads this stored value back from the order when it later creates the shipment. Without it, the connector cannot create a parcelshop shipment correctly.

Which value to store

Store only the parcelshop ID, for example PS-BBMK0269. This is the canonical identifier Neoship resolves against its parcelshop registry. In the picker payload this is parcelshopId; in the parcelshop list/detail responses it is parcelshop_id.

Do not store the parcelshop name, street, city, ZIP or state code in this field. Those are only human-readable details for display in your checkout; the connector re-fetches the authoritative address from Neoship using the stored ID. Storing anything other than the ID (for example the parcelshop name) breaks shipment creation.

Where to store it per connector

Connector Where to put the parcelshop ID Notes
WooCommerce Order meta key _parcelshop_id Neoship plugin. Official carrier plugins are auto-detected too: GLS _gls_pickup_info (JSON id), Packeta point_id, SPS _slovakparcelservice_pp_*.
PrestaShop Order field neoship_delivery_point_id Set on the order.
Shopify Order attribute with key PickupPointId Cart/checkout attribute set by the pickup-point selector; its value is the parcelshop ID.
Shoptet Delivery branch id (branchId) of the order Shoptet's pickup-point/branch id. For DPD the id is embedded in the delivery-address company name as [[ID]].
Money S5 Not supported Money S5 orders are always created as courier deliveries; there is no parcelshop field.

Example (WooCommerce order meta):

_parcelshop_id = "PS-BBMK0269"

Example (PrestaShop order field):

neoship_delivery_point_id = "PS-BBMK0269"

Mapping to the shipment API

Whichever connector is used, the stored value is mapped to the parcelshop field of the package create request:

Stored field / meta key / attribute API field
WooCommerce _parcelshop_id parcelshop
PrestaShop neoship_delivery_point_id parcelshop
Shopify PickupPointId attribute parcelshop
Shoptet branchId parcelshop

Because the stored value flows directly into the API parcelshop field, it must always be the parcelshop ID (e.g. PS-BBMK0269) and nothing else.