Lấy danh sách ca lấy

API Lấy danh sách ca lấy

 

Sử dụng API này để lấy danh sách các ca lấy.

Lưu ý : API này cần truyền token ở header.

post/get
https://online-gateway.ghn.vn/shiip/public-api/v2/shift/date
https://dev-online-gateway.ghn.vn/shiip/public-api/v2/shift/date
curl --location --request GET 'https://dev-online-gateway.ghn.vn/shiip/public-api/v2/shift/date' \
--header 'token: f4928-9fcb-11ea-b3e1-b2e69541627f'

Cấu trúc Request

Trường dữ liệu Kiểu dữ liệu Mô tả
token String

Dùng để xác định định danh của tài khoản và dùng cho các trường hợp gọi tới các API.

{
    "code": 200,
    "message": "Success",
    "data":[  
    {
    "id":2 
    "title":"Ca lấy 12-03-2021 (12h00 - 18h00)",
    "from_time":43200,
    "to_time":64800
    }, 
    {
    "id":3 
    "title":"Ca lấy 13-03-2021 (7h00 - 12h00)",
    "from_time":111600,
    "to_time":129600
    }, 
    {
    "id":4 
    "title":"Ca lấy 13-03-2021 (12h00 - 18h00)",
    "from_time":129600,
    "to_time":151200
    }
]
}

Cấu trúc Response

Trường dữ liệu Mô tả
id

Mã ca lấy.

title

Thông tin ca lấy.

from_time

Từ giờ.

to_time

Đến giờ.

{
    "code": 400,
    "message": "Token is required!",
    "data": null
    "code_message":"USER_ERR_COMMON"
}