Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

To collect the list of dispatch points for a particular organization the user needs to be a member thereof.

The dispatch point is defined by the physical address where the shipment collection can be made from by the courier, which have been specified under the collection order.

PanelbgColor#f0f0f0titleBGColor#f0f0f0title

Dispatch points define addresses from which shipments can be picked up by the courier. Which have been specified in the dispatch order.


On this page

Table of Contents
minLevel2
 
Authentication

Access to the resource requires provision of the correct and valid access token.

Structure

The DispatchPoint

Dispatch points resource has the following attributes:

Attribute

Type

Description

Correct

Valid values

hrefstring

URI address to the resource

id

integer

Integer

Dispatch point

ID

identifier


name

string

String

Dispatch point name


office_hours

stringPoint working Point's

String

Dispatch point operating hours


phone

string

String

Dispatch point phone number


email

stringPoint's e-mail

String

Dispatch point email address


comments

string

String

Additional

information

informations


address

Object

Address

Dispatch point address


status

String

Status

Dispatch point status

created, activated, suspended

Sample DispatchPoint resource in the JSON format

Dispatch Point example in JSON:

Code Block
languagejson
{
  "href": "https://api-shipx-pl.easypack24.net/v1/dispatch_points/1",
  "id": 1,
  "name": "My dispatch point",
  "office_hours": "8-16",
  "phone": "777888999",
  "email": null,
  "comments": null,
  "status": "created",
  "address": {
    "id": 230,
    "street": "
Długa
Long",
    "building_number": "24",
    "city": "
Krakow
Cracow",
    "post_code": "30-624",
    "country_code": "PL"
  }
}

Collecting information about the point

Code Block

Authentication

Access to the resource requires a valid access token.


List of dispatch points

List of dispatch points within a specific organization.

Info

To get a dispatch point list for a specific organization, the user must be a member of it.

Code Block
languagejson
GET /v1/organizations/:organization_id/dispatch_points
/:idSample request

Request example

Code Block
languagejson
curl -X GET https:/
v1
/
dispatch_points/1 HTTP/1.1 Host:
api-shipx-pl.easypack24.net
Content-Type: application/json
/v1/organizations/1/dispatch_points -H 'Authorization: Bearer
lkfjasd9f70y43ohriw...[ommited for brevity]...
 token' -H 'Content-Type: application/json'

Response

Code Block
languagejson
HTTP/1.1 200 OK
Content-Type: application/json
{
   
{ "
 "href": "https://api-shipx-pl.easypack24.net/v1/organizations/1/dispatch_points",
    "count": 15,
    "per_page": 30,
    "page": 1,
    "items": [
        {
			"href": "https://test.api.shipx.pl.easypack24.net/v1/dispatch_points/1",
			"id": 1,
			"name": "My dispatch point",
			"office_hours": "8-16",
			"phone": "777888999",
			"email": null,
			"comments": null,
			"status": "created",
			"address": {
				"id": 230,
				"street": "Długa",
				"building_number": "24",
				"city": "Krakow",
				"post_code": "30-624",
				"country_code": "PL"
			}
		}
    
}
]
}

Warning

Errors

Errors that may occur while getting the list of dispatch points:

  • resource_not_found - the organization for which the user wants to get the dispatch point

with the stated ID

  • list does not exist

,

List of dispatch points

The list of dispatch points within the given organization can be collected at:

Code Block

  • .

  • forbidden - the specific access token does not entitle you to get the dispatch point list for the selected organization.


Dispatch point details

Code Block
languagejson
GET /v1/
organizations
dispatch_points/:
organization_
id
/dispatch_points

Rights

Aby pobrać listę punktów odbioru dla określonej organizacji użytkownik musi być jej członkiem.

Sample request

Code BlockGET /v1/organizations/12345

Request example

Code Block
languagejson
curl -X GET https://api-shipx-pl.easypack24.net/v1/dispatch_points
HTTP
/1
.1 Host: api-shipx-pl.easypack24.net
 -H 'Authorization: Bearer token' -H 'Content-Type: application/json
Authorization: Bearer lkfjasd9f70y43ohriw...[ommited for brevity]...

 In reply to a correctly sent request, the server will return a response with HTTP 200 OK code:

code
'

Response

Code Block
languagejson
HTTP/1.1 200 OK
Content-Type: application/json
 {
 
{
 
"href": "https://test.api
-
.shipx
-
.pl.easypack24.net/v1/
organizations/1/dispatch_points", "count": 15, "per_page": 30, "page": 1, "items": [ { "href": "https://api-shipx-pl.easypack24.net/v1/dispatch_points/3", "id": 123, ... other attribute omitted for brevity .... } ... other items omitted for brevity ... ] }

Errors that may occur when collecting the collection orders list:

• resource_not_found - the organization which the user wants to collect the collection orders list for does not exist,
• forbidden - the token does not authorize to collect the collection orders list for the selected organization
dispatch_points/1",
  "id": 1,
  "name": "My dispatch point",
  "office_hours": "8-16",
  "phone": "777888999",
  "email": null,
  "comments": null,
  "status": "created",
  "address": {
    "id": 230,
    "street": "Długa",
    "building_number": "24",
    "city": "Krakow",
    "post_code": "30-624",
    "country_code": "PL"
  }
}

Warning

Errors

  • resource_not_found - dispatch point with given ID does not exist.