NAV Navbar
API Version:   V1.0.10
Logo
shell ruby python javascript

Introduction

About us

Boxme Global is one-stop solution for Cross-Border E-Commerce seller, who want to become millionaire.

Boxme Indo is a member of Boxme Global provide shipping gateway for ecommerce.

API Key

How to get your API Key?

Before you started with using our REST API services, you will need to obtain your API key under your own user account.

API end point

Once you’ve registered your API it’s easy to start requesting data from Boxme Indo.

All endpoints are only accessible via https

API Supported

Products

Shipment

Location

Order

Location

CSV file

You can download it here : https://bitbucket.org/loihv/boxme-location-database

Get Area

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/courier/get_area_by_country")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request["headers"] = '{'content-type': 'application/x-www-form-urlencoded'}'
request["content-type"] = 'application/x-www-form-urlencoded'

response = http.request(request)
puts response.read_body
import requests

url = "http://seller.boxme.id/courier/get_area_by_country"

payload = ""
headers = {
    'headers': "{'content-type': 'application/x-www-form-urlencoded'}",
    'content-type': "application/x-www-form-urlencoded"
    }

response = requests.request("GET", url, data=payload, headers=headers)

print(response.text)
# With shell, you can just pass the correct header with each request
curl --request GET \
  --url http://seller.boxme.id/courier/get_area_by_country \
  --header 'content-type: application/x-www-form-urlencoded' \
  --header 'headers: {'\''content-type'\'': '\''application/x-www-form-urlencoded'\''}'
var data = null;

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "http://seller.boxme.id/courier/get_area_by_country");
xhr.setRequestHeader("headers", "{'content-type': 'application/x-www-form-urlencoded'}");
xhr.setRequestHeader("content-type", "application/x-www-form-urlencoded");

xhr.send(data);

The above command returns JSON structured like this:

{
  "_embedded": {
    "area":[
    {
      "id": 1,
      "jabotabek": 0,
      "name": "Bali"
    },
    {
      "id": 2,
      "jabotabek": 0,
      "name": "Bangka Belitung"
    },
  ]
}

HTTP Request

GET http://seller.boxme.id/courier/get_area_by_country

Query Parameters

Parameter Default Description
headers false ‘content-type’: ‘application/x-www-form-urlencoded’.

Get address by area

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/api/public/api/base/list-address?state=4")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request["headers"] = '{'content-type': 'application/x-www-form-urlencoded'}'
request["content-type"] = 'application/x-www-form-urlencoded'

response = http.request(request)
puts response.read_body
import requests

url = "http://seller.boxme.id/api/public/api/base/list-address?state=4"

payload = ""
headers = {
    'headers': "{'content-type': 'application/x-www-form-urlencoded'}",
    'content-type': "application/x-www-form-urlencoded"
    }

response = requests.request("GET", url, data=payload, headers=headers)

print(response.text)
# With shell, you can just pass the correct header with each request
curl --request GET \
  --url http://seller.boxme.id/api/public/api/base/list-address?state=4 \
  --header 'content-type: application/x-www-form-urlencoded' \
  --header 'headers: {'\''content-type'\'': '\''application/x-www-form-urlencoded'\''}'
var data = null;

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "http://seller.boxme.id/api/public/api/base/list-address?state=4");
xhr.setRequestHeader("headers", "{'content-type': 'application/x-www-form-urlencoded'}");
xhr.setRequestHeader("content-type", "application/x-www-form-urlencoded");

xhr.send(data);

The above command returns JSON structured like this:

{
  "error": false,
  "data": [
    {
      "city_id": 51,
      "city_name": "Kab. Bengkulu Selatan",
      "district_id": 730,
      "district_name": "Air Nipis",
      "full_address": "Air Nipis - Kab. Bengkulu Selatan"
    },
    {
      "city_id": 51,
      "city_name": "Kab. Bengkulu Selatan",
      "district_id": 731,
      "district_name": "Bunga Mas",
      "full_address": "Bunga Mas - Kab. Bengkulu Selatan"
    },
  ]
}

HTTP Request

GET http://seller.boxme.id/api/public/api/base/list-address?state=4

Query Parameters

Parameter Default Description
headers false ‘content-type’: ‘application/x-www-form-urlencoded’.

Get address by zipcode

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/courier/get_zipcode_by_country?zipcode=80361")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request["headers"] = '{'content-type': 'application/x-www-form-urlencoded'}'
request["content-type"] = 'application/x-www-form-urlencoded'

response = http.request(request)
puts response.read_body
import requests

url = "http://seller.boxme.id/courier/get_zipcode_by_country?zipcode=80361"

payload = ""
headers = {
    'headers': "{'content-type': 'application/x-www-form-urlencoded'}",
    'content-type': "application/x-www-form-urlencoded"
    }

response = requests.request("GET", url, data=payload, headers=headers)

print(response.text)
# With shell, you can just pass the correct header with each request
curl --request GET \
  --url http://seller.boxme.id/courier/get_zipcode_by_country?zipcode=80361 \
  --header 'content-type: application/x-www-form-urlencoded' \
  --header 'headers: {'\''content-type'\'': '\''application/x-www-form-urlencoded'\''}'
var data = null;

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "http://seller.boxme.id/courier/get_zipcode_by_country?zipcode=80361");
xhr.setRequestHeader("headers", "{'content-type': 'application/x-www-form-urlencoded'}");
xhr.setRequestHeader("content-type", "application/x-www-form-urlencoded");

xhr.send(data);

The above command returns JSON structured like this:

{
  "_embedded": {
    "area":[
    {
      "city_id": 16,
      "city_name": "Kab. Badung",
      "district_id": 263,
      "district_name": "Kuta Utara",
      "full_address": "Kuta Utara - Kab. Badung",
      "id": 4,
      "jabotabek": 0,
      "name": "Bengkulu",
      "zipcode": "80361"
    }
  ]
}

HTTP Request

GET http://seller.boxme.id/courier/get_zipcode_by_country?zipcode=80361

Query Parameters

Parameter Default Description
headers false ‘content-type’: ‘application/x-www-form-urlencoded’.

Product

Get Lists Inventory

To authorize, use this code:

require 'uri'
require 'net/http'
url = URI("http://seller.boxme.id/bxapi/list_inventory-sdk")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request["content-type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
import http.client

conn = http.client.HTTPConnection("prod.boxme.vn")

payload = "{}"

headers = { 'content-type': "application/json" }

conn.request("GET", "/bxapi/list_inventory-sdk", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
# With shell, you can just pass the correct header with each request
curl --request GET \
  --url http://seller.boxme.id/bxapi/list_inventory-sdk \
  --header 'content-type: application/json' \
  --data '{}'
var settings = {
  "async": true,
  "crossDomain": true,
  "url": "http://seller.boxme.id/bxapi/list_inventory-sdk",
  "method": "GET",
  "headers": {
    "content-type": "application/json"
  },
  "processData": false,
  "data": "{}"
}

$.ajax(settings).done(function (response) {
  console.log(response);
});

The above command returns JSON structured like this:

{
  "inventory": [
    {
      "City": "Kota Jakarta Utara",
      "Code": null,
      "Name": "Inventory example",
      "District": "Tanjung Priok",
      "Phone": "0123456789",
      "InventoryId": "218613",
      "Type": 0,
      "AddressLine": "Bangli, Bali, In-đô-nê-xi-a"
    }
  ]
}

HTTP Request

GET http://seller.boxme.id/bxapi/list_inventory-sdk

Query Parameters

Parameter Default Description
ApiKey false Your api key of seller.

Edit Product

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/bxapi/edit-product-sdk")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\"InventoryId\":\"137123\",\"ApiKey\":\"7e4e80c6bdb03c5a2d639c4828bcf156\",\"SellerSKU\":\"KA-07\",\"Name\":\"iphone 9 \",\"Description\":\"Iphone 7s black new 100%\",\"BasePrice\":10000,\"SalePrice\":20000,\"Weight\":1223,\"Volume\":\"\",\"ProductImages\":\"\"}"

response = http.request(request)
puts response.read_body
import http.client

conn = http.client.HTTPConnection("prod.boxme.vn")

payload = "{\"InventoryId\":\"137123\",\"ApiKey\":\"7e4e80c6bdb03c5a2d639c4828bcf156\",\"SellerSKU\":\"KA-07\",\"Name\":\"iphone 9 \",\"Description\":\"Iphone 7s black new 100%\",\"BasePrice\":10000,\"SalePrice\":20000,\"Weight\":1223,\"Volume\":\"\",\"ProductImages\":\"\"}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/bxapi/edit-product-sdk", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
# With shell, you can just pass the correct header with each request
curl --request POST \
  --url http://seller.boxme.id/bxapi/edit-product-sdk \
  --header 'content-type: application/json' \
  --data '{"InventoryId":"137123","ApiKey":"7e4e80c6bdb03c5a2d639c4828bcf156","SellerSKU":"KA-07","Name":"iphone 9 ","Description":"Iphone 7s black new 100%","BasePrice":10000,"SalePrice":20000,"Weight":1223,"Volume":"","ProductImages":""}'
var data = JSON.stringify({
  "InventoryId": "137123",
  "ApiKey": "7e4e80c6bdb03c5a2d639c4828bcf156",
  "SellerSKU": "KA-07",
  "Name": "iphone 9 ",
  "Description": "Iphone 7s black new 100%",
  "BasePrice": 10000,
  "SalePrice": 20000,
  "Weight": 1223,
  "Volume": "",
  "ProductImages": ""
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/bxapi/edit-product-sdk");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{
  "Name": "iphone 9 ",
  "SalePrice": 20000,
  "BasePrice": 10000,
  "SellerId": "87695",
  "Description": "Iphone 7s black new 100%",
  "QuantityUnit": null,
  "SellerSKU": "KA-07",
  "Weight": 1223,
  "Volume": null,
  "InventoryId": "137123",
  "ProductId": "88999"
}

HTTP Request

POST http://seller.boxme.id/bxapi/edit-product-sdk

Query Parameters

Parameter Default Description
ApiKey false You Key API.
SellerSKU false Product code (sku) to edit.
Name false New product name.
InventoryId false New ID warehouse (Pickup address config).
Description false New product description .
BasePrice false New product base price .
SalePrice false New product sale price (Price to create orders) .
Weight false New product weight (weight to create orders) .
Volume false New Volume product .

Add Product

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/bxapi/product-sdk")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\"InventoryId\":\"105341\",\"ApiKey\":\"7e4e80c6bdb03c5a2d639c4828bcf156\",\"SellerSKU\":\"Test-Pro-IP7S\",\"Name\":\"IPhone 7s Black\",\"CategoryName\":\"Phone\",\"SupplierName\":\"Apple\",\"BrandName\":\"Apple\",\"Description\":\"Iphone 7s black new 100%\",\"ProductTags\":\"iphone,iphone7s,iphone7\",\"Quantity\":50,\"BasePrice\":16000000,\"SalePrice\":16500000,\"BarcodeManufacturer\":\"IP7SABC\",\"ModelName\":\"IPhone7s\",\"Weight\":200,\"Volume\":\"2x2x2\",\"ProductImages\":\"\"}"

response = http.request(request)
puts response.read_body
import http.client

conn = http.client.HTTPConnection("prod.boxme.vn")

payload = "{\"InventoryId\":\"105341\",\"ApiKey\":\"7e4e80c6bdb03c5a2d639c4828bcf156\",\"SellerSKU\":\"Test-Pro-IP7S\",\"Name\":\"IPhone 7s Black\",\"CategoryName\":\"Phone\",\"SupplierName\":\"Apple\",\"BrandName\":\"Apple\",\"Description\":\"Iphone 7s black new 100%\",\"ProductTags\":\"iphone,iphone7s,iphone7\",\"Quantity\":50,\"BasePrice\":16000000,\"SalePrice\":16500000,\"BarcodeManufacturer\":\"IP7SABC\",\"ModelName\":\"IPhone7s\",\"Weight\":200,\"Volume\":\"2x2x2\",\"ProductImages\":\"\"}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/bxapi/product-sdk", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
# With shell, you can just pass the correct header with each request
curl --request POST \
  --url http://seller.boxme.id/bxapi/product-sdk \
  --header 'content-type: application/json' \
  --data '{"InventoryId":"105341","ApiKey":"7e4e80c6bdb03c5a2d639c4828bcf156","SellerSKU":"Test-Pro-IP7S","Name":"IPhone 7s Black","CategoryName":"Phone","SupplierName":"Apple","BrandName":"Apple","Description":"Iphone 7s black new 100%","ProductTags":"iphone,iphone7s,iphone7","Quantity":50,"BasePrice":16000000,"SalePrice":16500000,"BarcodeManufacturer":"IP7SABC","ModelName":"IPhone7s","Weight":200,"Volume":"2x2x2","ProductImages":""}'
var data = JSON.stringify({
  "InventoryId": "105341",
  "ApiKey": "7e4e80c6bdb03c5a2d639c4828bcf156",
  "SellerSKU": "Test-Pro-IP7S",
  "Name": "IPhone 7s Black",
  "CategoryName": "Phone",
  "SupplierName": "Apple",
  "BrandName": "Apple",
  "Description": "Iphone 7s black new 100%",
  "ProductTags": "iphone,iphone7s,iphone7",
  "Quantity": 50,
  "BasePrice": 16000000,
  "SalePrice": 16500000,
  "BarcodeManufacturer": "IP7SABC",
  "ModelName": "IPhone7s",
  "Weight": 200,
  "Volume": "2x2x2",
  "ProductImages": ""
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/bxapi/product-sdk");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{
  "WeightUnit": 1,
  "BrandName": "brank",
  "SalePrice": 2000,
  "BasePrice": 1000,
  "SupplierName": "soupper",
  "Name": "Product Test",
  "Description": "Description testt",
  "Volume": "2x2x2",
  "ManufactureBarcode": null,
  "SellerId": "30788",
  "Quantity": 200,
  "ModelName": "moel",
  "SupplierId": null,
  "ModelId": null,
  "ExternalUrl": null,
  "CategoryId": null,
  "CategoryName": "Phone",
  "QuantityUnit": 1,
  "SellerSKU": "Biaaaa",
  "Weight": 200,
  "BrandId": "",
  "InventoryId": "36",
  "ProductTags": "tag 1 tag 2",
  "ProductId": "11584"
}

HTTP Request

POST http://seller.boxme.id/bxapi/product-sdk

Query Parameters

Parameter Default Description
ApiKey false You Key API.
SellerSKU false Product code (sku) to edit.
InventoryId false Id inventory (not boxme).
Name false Product Name.
CategoryName false Product CategoryName .
SupplierName false Product SupplierName .
BrandName false Product Brand.
Description false Product Description.
ProductTags false Product tag.
Quantity false Product quantity.
BasePrice false New product base price.
SalePrice false New product sale price (Price to create orders) .
Weight false New product weight (weight to create orders).
BarcodeManufacturer false Barcode (if exist).
ProductImages false Images (if exist) .

Get Lists Product

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/bxapi/list_product-sdk")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request["content-type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
import http.client

conn = http.client.HTTPConnection("prod.boxme.vn")

payload = "{}"

headers = { 'content-type': "application/json" }

conn.request("GET", "/bxapi/list_product-sdk", payload, headers)

res = conn.getresponse()
# With shell, you can just pass the correct header with each request
curl --request GET \
  --url http://seller.boxme.id/bxapi/list_product-sdk \
  --header 'content-type: application/json' \
  --data '{}'
var data = JSON.stringify({});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "http://seller.boxme.id/bxapi/list_product-sdk");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{
  "total_items": 26,
  "data": {
    "product": [
      {
        "Name": "iphone 9 ",
        "InventoryName": "BoxMe Id",
        "SalePrice": 200000,
        "BasePrice": 10000,
        "Description": "Iphone 7s black new 100%",
        "SellerSKU": "A-377AAEE",
        "Weight": 1223,
        "ProductImages": [],
        "InventoryId": 137123,
        "Quantity": 1,
        "ProductId": "89034",
        "ToBoxme": false
      }
    ]
  }
}

HTTP Request

GET http://seller.boxme.id/bxapi/list_product-sdk

Query Parameters

Parameter Default Description
ApiKey false You Key API.

Get List Product To Create Order

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/bxapi/get_list_products_create_order")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request["content-type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
import http.client

conn = http.client.HTTPConnection("prod.boxme.vn")

payload = "{}"

headers = { 'content-type': "application/json" }

conn.request("GET", "/bxapi/get_list_products_create_order", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
# With shell, you can just pass the correct header with each request
curl --request GET \
  --url http://seller.boxme.id/bxapi/get_list_products_create_order \
  --header 'content-type: application/json' \
  --data '{}'
var data = JSON.stringify({});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "http://seller.boxme.id/bxapi/get_list_products_create_order");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{
  "total_items": 1,
  "data": {
    "product": [
      {
        "InventoryName": "BoxMe - Id",
        "Waiting": 0,
        "InventoryLimit": 0,
        "SalePrice": "150000",
        "SellerSKU": "PO-150M4NU",
        "Weight": 200,
        "InventoryId": 133902,
        "Name": "Đồng hồ CẶP thời trang Pollock + 2 Pin dự phòng",
        "Quantity": 24,
        "ProductId": "88954"
      }
    ]
  }
}

HTTP Request

GET http://seller.boxme.id/bxapi/get_list_products_create_order

Query Parameters

Parameter Default Description
ApiKey false You Key API.
inventory_id false ID inventory(boxme) (non-mandatory).
sellerSKU false SKU (non-mandatory).

Shipment

Create Shipment

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/bxapi/shipment-sdk")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\"ApiKey\":\"7e4e80c6bdb03c5a2d639c4828bcf156\",\"ShipToAddress\":{\"InventoryId\":133455},\"ShipFromAddress\":{\"InventoryId\":105341},\"TypeTransport\":1,\"ShipmentStatus\":\"ReadyToShip\",\"Volumes\":\"10x10x10\",\"Weight\":500,\"ShippingMethod\":\"MYSELF\",\"ShipmentItems\":[{\"SKU\":\"14398602\",\"QuantityShipped\":100}]}"

response = http.request(request)
puts response.read_body
import http.client

conn = http.client.HTTPConnection("seller.boxme.id")

payload = "{\"ApiKey\":\"7e4e80c6bdb03c5a2d639c4828bcf156\",\"ShipToAddress\":{\"InventoryId\":133455},\"ShipFromAddress\":{\"InventoryId\":105341},\"TypeTransport\":1,\"ShipmentStatus\":\"ReadyToShip\",\"Volumes\":\"10x10x10\",\"Weight\":500,\"ShippingMethod\":\"MYSELF\",\"ShipmentItems\":[{\"SKU\":\"14398602\",\"QuantityShipped\":100}]}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/bxapi/shipment-sdk", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
# With shell, you can just pass the correct header with each request
curl --request POST \
  --url http://seller.boxme.id/bxapi/shipment-sdk \
  --header 'content-type: application/json' \
  --data '{"ApiKey":"7e4e80c6bdb03c5a2d639c4828bcf156","ShipToAddress":{"InventoryId":133455},"ShipFromAddress":{"InventoryId":105341},"TypeTransport":1,"ShipmentStatus":"ReadyToShip","Volumes":"10x10x10","Weight":500,"ShippingMethod":"MYSELF","ShipmentItems":[{"SKU":"14398602","QuantityShipped":100}]}'
var data = JSON.stringify({
  "ApiKey": "7e4e80c6bdb03c5a2d639c4828bcf156",
  "ShipToAddress": {
    "InventoryId": 133455
  },
  "ShipFromAddress": {
    "InventoryId": 105341
  },
  "TypeTransport": 1,
  "ShipmentStatus": "ReadyToShip",
  "Volumes": "10x10x10",
  "Weight": 500,
  "ShippingMethod": "MYSELF",
  "ShipmentItems": [
    {
      "SKU": "14398602",
      "QuantityShipped": 100
    }
  ]
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/bxapi/shipment-sdk");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{
  "inventory": [
    {
      "City": "Bangli",
      "Code": null,
      "Name": "Inventory - ... - ...",
      "District": "--",
      "Phone": "0938131593",
      "InventoryId": "92932",
      "Type": 0,
      "AddressLine": "aaa"
    }
  ]
}

HTTP Request

POST http://seller.boxme.id/bxapi/shipment-sdk

Query Parameters

Parameter Default Description
ApiKey false Your api key of seller.

Orders

List of shipping services

id name
11 Regular service

Calculate Shipping fee

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/courier/caculate_courier_order_new")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\"From\":{\"City\":446,\"Province\":6727,\"Stock\":218613},\"To\":{\"City\":30,\"Province\":501,\"Country\":101},\"Order\":{\"Amount\":10000,\"Weight\":100},\"Config\":{\"Service\":11,\"CoD\":2,\"Protected\":1,\"Checking\":2,\"Payment\":1,\"Fragile\":2},\"Domain\":\"seller.boxme.id\",\"MerchantKey\":\"e80d1bb5cde172364fdd6c338b8966ac\"}"

response = http.request(request)
puts response.read_body
import http.client

conn = http.client.HTTPConnection("seller.boxme.id")

payload = "{\"From\":{\"City\":446,\"Province\":6727,\"Stock\":218613},\"To\":{\"City\":30,\"Province\":501,\"Country\":101},\"Order\":{\"Amount\":10000,\"Weight\":100},\"Config\":{\"Service\":11,\"CoD\":2,\"Protected\":1,\"Checking\":2,\"Payment\":1,\"Fragile\":2},\"Domain\":\"seller.boxme.id\",\"MerchantKey\":\"e80d1bb5cde172364fdd6c338b8966ac\"}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/courier/caculate_courier_order_new", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
# With shell, you can just pass the correct header with each request
curl --request POST \
  --url http://seller.boxme.id/courier/caculate_courier_order_new \
  --header 'content-type: application/json' \
  --data '{"Domain":"seller.boxme.id","From":{"City":446,"Province":6727,"Stock":218613},"To":{"City":"30","Province":501,"Address":"Bangli, Bali, In-đô-nê-xi-a","Country":101},"Order":{"Weight":100,"Amount":347000,"Quantity":1,"Box":""},"Config":{"Service":11,"Protected":2,"Fragile":2,"CoD":2,"Payment":1,"PaymentCod":2,"Checking":2},"MerchantKey":"e80d1bb5cde172364fdd6c338b8966ac"}'
var data = JSON.stringify({
  "From": {
    "City": 446,
    "Province": 6727,
    "Stock": 218613
  },
  "To": {
    "City": 30,
    "Province": 501,
    "Country": 101,
    "Address": "Bangli, Bali, In-đô-nê-xi-a"
  },
  "Order": {
    "Amount": 347000,
    "Quantity": 1,
    "Weight": 100
  },
  "Config": {
    "Service": 11,
    "CoD": 2,
    "Protected": 1,
    "Checking": 2,
    "Payment": 1,
    "Fragile": 2
  },
  "Domain": "seller.boxme.id",
  "MerchantKey": "e80d1bb5cde172364fdd6c338b8966ac"
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/courier/caculate_courier_order_new");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{
    "code": "SUCCESS",
    "error_message": "success",
    "user": 0,
    "error": false,
    "message": "success",
    "data": {
        "courier": {
            "system": [
                {
                    "courier_id": 30,
                    "logo": "http://jet.co.id/images/logo-red.png",
                    "leatime_str": "2 day",
                    "fee": {
                        "collect": 0,
                        "pvc": "28000.0",
                        "total": "28000.0",
                        "discount": {
                            "pvc": 0,
                            "pcod": 0
                        },
                        "vas": {
                            "protected": 0,
                            "cod": 0
                        }
                    },
                    "leatime_delivery": 48,
                    "courier_name": "J&T",
                    "leatime_courier": 48,
                    "priority": 0,
                    "leatime_ward": 0,
                    "leatime_total": 48,
                    "money_pickup": 0
                },
                {
                    "courier_id": 27,
                    "logo": "http://firstlogistics.co.id/img/logo/logonew.png",
                    "leatime_str": "3 day",
                    "fee": {
                        "collect": 0,
                        "pvc": "40000.0",
                        "total": "40000.0",
                        "discount": {
                            "pvc": 0,
                            "pcod": 0
                        },
                        "vas": {
                            "protected": 0,
                            "cod": 0
                        }
                    },
                    "leatime_delivery": 72,
                    "courier_name": "Firstlogistics",
                    "leatime_courier": 72,
                    "priority": 0,
                    "leatime_ward": 0,
                    "leatime_total": 72,
                    "money_pickup": 0
                },
                {
                    "courier_id": 28,
                    "logo": "http://www.jne.co.id/frontend/images/material/logo.jpg",
                    "leatime_str": "6 day",
                    "fee": {
                        "collect": 0,
                        "pvc": "43000.0",
                        "total": "43000.0",
                        "discount": {
                            "pvc": 0,
                            "pcod": 0
                        },
                        "vas": {
                            "protected": 0,
                            "cod": 0
                        }
                    },
                    "leatime_delivery": 144,
                    "courier_name": "JNE",
                    "leatime_courier": 144,
                    "priority": 0,
                    "leatime_ward": 0,
                    "leatime_total": 144,
                    "money_pickup": 0
                },
                {
                    "courier_id": 14,
                    "logo": "http://cloud.shipchung.vn//uploads/images/cards/8712b0b57eec9362beb8273986dcd2ce.png",
                    "leatime_str": "7 day",
                    "fee": {
                        "collect": 0,
                        "pvc": "43000.0",
                        "total": "43000.0",
                        "discount": {
                            "pvc": 0,
                            "pcod": 0
                        },
                        "vas": {
                            "protected": 0,
                            "cod": 0
                        }
                    },
                    "leatime_delivery": 168,
                    "courier_name": "Ninjavan",
                    "leatime_courier": 168,
                    "priority": 0,
                    "leatime_ward": 0,
                    "leatime_total": 168,
                    "money_pickup": 0
                }
            ]
        },
        "discount": {
            "pvc": 0,
            "pcod": 0
        },
        "seller": {
            "discount": 0,
            "pvc": 0,
            "pcod": 0
        },
        "collect": 0,
        "pvc": 0,
        "vas": {
            "protected": 0,
            "cod": 0
        }
    },
    "stock": 218613
}

HTTP Request

POST http://prod.boxme.vn/api/public/api/rest/courier/calculate

Query Parameters

Parameter Default Description
ApiKey (MerchantKey) false Your api key of seller.
From.City false From city send order.
From.Province false From province send order.
To.City false To city receive order.
To.Province false To province receive order.
Order.Amount false Order amount.
Order.Weight false Order weight.
Config.Service false Shipping method:1. Economy delivery service,2. Express delivery service.
Config.CoD false Cash On Delivery (COD) 1: Use; 2: Don’t use.
Config.Protected false Insurance.
Config.Checking false Accept receiver view item in order before confirm received or not.
Config.Payment false Payment.
Config.Fragile false Fragile.

Create Order Fulfillment (Boxme)

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/courier/add_order_courier")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\"Domain\":\"seller.boxme.id\",\"MerchantKey\":\"e80d1bb5cde172364fdd6c338b89661ac\",\"From\":{\"City\":446,\"Province\":6727,\"Stock\":218613,\"Address\":\"Bangli, Bali, In-đô-nê-xi-a,\"Name\":\"loa\"},\"Courier\":30,\"To\":{\"City\":30,\"Province\":502,\"Address\":\"Bangli, Bali, In-đô-nê-xi-a\",\"Country\":101,\"Phone\":\"0914392331\",\"PhoneCode\":\"62\",\"Name\":\"Nguyễn Thị Sen\"},\"Order\":{\"Weight\":100,\"Amount\":1000,\"Quantity\":1,\"ProductName\":\"Cám Gạo Tinh Nghệ Mật Ong Nguyên Chất\"},\"Config\":{\"Service\":11,\"Protected\":2,\"Checking\":2,\"Fragile\":2,\"CoD\":2,\"Payment\":1,\"AutoAccept\":1}}"

response = http.request(request)
puts response.read_body
import http.client

conn = http.client.HTTPConnection("prod.boxme.vn")

payload = "{\"Domain\":\"seller.boxme.id\",\"MerchantKey\":\"e80d1bb5cde172364fdd6c338b89661ac\",\"From\":{\"City\":446,\"Province\":6727,\"Stock\":218613,\"Address\":\"Bangli, Bali, In-đô-nê-xi-a,\"Name\":\"loa\"},\"Courier\":30,\"To\":{\"City\":30,\"Province\":502,\"Address\":\"Bangli, Bali, In-đô-nê-xi-a\",\"Country\":101,\"Phone\":\"0914392331\",\"PhoneCode\":\"62\",\"Name\":\"Nguyễn Thị Sen\"},\"Order\":{\"Weight\":100,\"Amount\":1000,\"Quantity\":1,\"ProductName\":\"Cám Gạo Tinh Nghệ Mật Ong Nguyên Chất\"},\"Config\":{\"Service\":11,\"Protected\":2,\"Checking\":2,\"Fragile\":2,\"CoD\":2,\"Payment\":1,\"AutoAccept\":1}}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/courier/add_order_courier", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
# With shell, you can just pass the correct header with each request
curl --request POST \
  --url http://seller.boxme.id/courier/add_order_courier \
  --header 'content-type: application/json' \
  --data '{"Domain":"seller.boxme.id","From":{"City":446,"Province":6727,"Stock":218613,"Address":"Bangli, Bali, In-đô-nê-xi-a","Phone":"0123456789","Name":"loa"},"To":{"City":"30","Province":502,"Address":"Bangli, Bali, In-đô-nê-xi-a","Country":101,"Phone":"0629689652","PhoneCode":"62","Name":"Trần Khánh"},"Order":{"Weight":100,"Amount":1000,"Quantity":1,"Box":"","ProductName":"bánh"},"Config":{"Service":11,"Protected":2,"Fragile":2,"CoD":2,"Payment":1,"PaymentCod":2,"Checking":2,"AutoAccept":0,"exchangeRate":347},"Courier":30}'
var data = JSON.stringify({
  "Domain": "seller.boxme.id",
  "MerchantKey": "e80d1bb5cde172364fdd6c338b89661ac",
  "From": {
    "Address":"Bangli, Bali, In-đô-nê-xi-a",
    "City":446,
    "Name":"loa",
    "Phone":"0123456789",
    "Province":6727,
    "Stock":218613
  },
  "Courier": 1,
  "To": {
    "Address":"Bangli, Bali, In-đô-nê-xi-a"
    "City":30,
    "Country":101,
    "Name":"Trần Khánh",
    "Phone":"0629689652",
    "PhoneCode":"62",
    "Province":502
  },
  "Order": {
    "Weight": 100,
    "Amount": 1000,
    "Quantity": 1,
    "ProductName": "Cám Gạo Tinh Nghệ Mật Ong Nguyên Chất"
  },
  "Config": {
    "Service": 11,
    "Protected": 2,
    "Checking": 1,
    "Fragile": 2,
    "CoD": 2,
    "Payment": 1,
    "AutoAccept": 0
  }
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/courier/add_order_courier");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{  
   "message":"Thành Công",
   "code":"SUCCESS",
   "data":{  
      "Discount":0,
      "ShowFee":{  
         "pvc":28000,
         "cod":0,
         "pbh":0
      },
      "CourierId":30,
      "TrackingCode":"BMIN185464513",
      "MoneyCollect":0
   },
   "error_message":"Thành Công",
   "error":false
}

HTTP Request

POST http://seller.boxme.id/courier/add_order_courier

Query Parameters

Parameter Default Description
ApiKey (MerchantKey) false Your api key of seller.
Courier false Courier.
From.City false City inventory.
From.Province false Province inventoryr.
From.Stock false Id inventory.
From.Ward false Ward inventory.
From.Address false Address inventory.
From.Phone false Phone seller.
From.Name false Name seller.
To.City false City receive order.
To.Province false Province receive order.
To.Country false Country receive order.
To.Ward false Ward receive order.
To.Address false Address receive order.
To.Phone false Phone buyer.
To.Name false Name buyer.
To.PhoneCode false Name seller.
Items.Name false Name product.
Items.Price false Price product.
Items.Quantity false Quantity product.
Items.Weight false Weight product.
Items.BSIN false BSIN product.
Order.Weight false Total weight of item in order.
Order.Amount false Total product value.
Order.Quantity false Total quantity of item in order.
Order.Collect false Total money collect from buyer( when you use CoD). Currency: VND.
Order.ProductName false Info orders.
Config.Service false Shipping method:1. Economy delivery service,2. Express delivery service.
Config.CoD false Cash On Delivery (COD) 1: Use; 2: Don’t use.
Config.Protected false Insurance.
Config.Checking false Accept receiver view item in order before confirm received or not.
Config.Payment false Payment.
Config.Fragile false Fragile.
Config.AutoAccept false 1.Auto accept 0. No accept (default).

Create Shipping Order (Only Ship)

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/courier/add_order_courier")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\"Domain\":\"seller.boxme.id\",\"MerchantKey\":\"e80d1bb5cde172364fdd6c338b89661ac\",\"From\":{\"City\":446,\"Province\":6727,\"Stock\":218613,\"Address\":\"Bangli, Bali, In-đô-nê-xi-a,\"Name\":\"loa\"},\"Courier\":30,\"To\":{\"City\":30,\"Province\":502,\"Address\":\"Bangli, Bali, In-đô-nê-xi-a\",\"Country\":101,\"Phone\":\"0914392331\",\"PhoneCode\":\"62\",\"Name\":\"Nguyễn Thị Sen\"},\"Order\":{\"Weight\":100,\"Amount\":1000,\"Quantity\":1,\"ProductName\":\"Cám Gạo Tinh Nghệ Mật Ong Nguyên Chất\"},\"Config\":{\"Service\":11,\"Protected\":2,\"Checking\":2,\"Fragile\":2,\"CoD\":2,\"Payment\":1,\"AutoAccept\":0}}"

response = http.request(request)
import http.client

conn = http.client.HTTPConnection("seller.boxme.id")

payload = "{\"Domain\":\"seller.boxme.id\",\"MerchantKey\":\"e80d1bb5cde172364fdd6c338b89661ac\",\"From\":{\"City\":446,\"Province\":6727,\"Stock\":218613,\"Address\":\"Bangli, Bali, In-đô-nê-xi-a,\"Name\":\"loa\"},\"Courier\":30,\"To\":{\"City\":30,\"Province\":502,\"Address\":\"Bangli, Bali, In-đô-nê-xi-a\",\"Country\":101,\"Phone\":\"0914392331\",\"PhoneCode\":\"62\",\"Name\":\"Nguyễn Thị Sen\"},\"Order\":{\"Weight\":100,\"Amount\":1000,\"Quantity\":1,\"ProductName\":\"Cám Gạo Tinh Nghệ Mật Ong Nguyên Chất\"},\"Config\":{\"Service\":11,\"Protected\":2,\"Checking\":2,\"Fragile\":2,\"CoD\":2,\"Payment\":1,\"AutoAccept\":0}}"

headers = { 'content-type': "application/json" }

conn.request("POST", "/courier/add_order_courier", payload, headers)

res = conn.getresponse()
data = res.read()

print(data.decode("utf-8"))
# With shell, you can just pass the correct header with each request
curl --request POST \
  --url http://seller.boxme.id/courier/add_order_courier \
  --header 'content-type: application/json' \
  --data '{"Domain":"seller.boxme.id","From":{"City":446,"Province":6727,"Stock":218613,"Address":"Bangli, Bali, In-đô-nê-xi-a","Phone":"0123456789","Name":"loa"},"To":{"City":"30","Province":502,"Address":"Bangli, Bali, In-đô-nê-xi-a","Country":101,"Phone":"0629689652","PhoneCode":"62","Name":"Trần Khánh"},"Order":{"Weight":100,"Amount":1000,"Quantity":1,"Box":"","ProductName":"bánh"},"Config":{"Service":11,"Protected":2,"Fragile":2,"CoD":2,"Payment":1,"PaymentCod":2,"Checking":2,"AutoAccept":0,"exchangeRate":347},"Courier":30}'
var data = JSON.stringify({
  "Domain": "seller.boxme.id",
  "MerchantKey": "e80d1bb5cde172364fdd6c338b89661ac",
  "From": {
    "Address":"Bangli, Bali, In-đô-nê-xi-a",
    "City":446,
    "Name":"loa",
    "Phone":"0123456789",
    "Province":6727,
    "Stock":218613
  },
  "Courier": 1,
  "To": {
    "Address":"Bangli, Bali, In-đô-nê-xi-a"
    "City":30,
    "Country":101,
    "Name":"Trần Khánh",
    "Phone":"0629689652",
    "PhoneCode":"62",
    "Province":502
  },
  "Order": {
    "Weight": 100,
    "Amount": 1000,
    "Quantity": 1,
    "ProductName": "Cám Gạo Tinh Nghệ Mật Ong Nguyên Chất"
  },
  "Config": {
    "Service": 11,
    "Protected": 2,
    "Checking": 1,
    "Fragile": 2,
    "CoD": 2,
    "Payment": 1,
    "AutoAccept": 0
  }
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/courier/add_order_courier");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{  
   "message":"Thành Công",
   "code":"SUCCESS",
   "data":{  
      "Discount":0,
      "ShowFee":{  
         "pvc":28000,
         "cod":0,
         "pbh":0
      },
      "CourierId":30,
      "TrackingCode":"BMIN185464513",
      "MoneyCollect":0
   },
   "error_message":"Thành Công",
   "error":false
}

HTTP Request

POST http://prod.boxme.vn/api/public/api/rest/courier/create

Query Parameters

Parameter Default Description
ApiKey (MerchantKey) false Your api key of seller.
Courier false Courier.
From.City false City inventory.
From.Province false Province inventoryr.
From.Stock false Id inventory.
From.Ward false Ward inventory.
From.Address false Address inventory.
From.Phone false Phone seller.
From.Name false Name seller.
To.City false City receive order.
To.Province false Province receive order.
To.Country false Country receive order.
To.Ward false Ward receive order.
To.Address false Address receive order.
To.Phone false Phone buyer.
To.Name false Name buyer.
To.PhoneCode false Name seller.
Order.Weight false Total weight of item in order.
Order.Amount false Total product value.
Order.Quantity false Total quantity of item in order.
Order.Collect false Total money collect from buyer( when you use CoD). Currency: VND.
Order.ProductName false Info orders.
Config.Service false Shipping method:1. Economy delivery service,2. Express delivery service.
Config.CoD false Cash On Delivery (COD) 1: Use; 2: Don’t use.
Config.Protected false Insurance.
Config.Checking false Accept receiver view item in order before confirm received or not.
Config.Payment false Payment.
Config.Fragile false Fragile.
Config.AutoAccept false 1.Auto accept 0. No accept (default).
Type false “Type”: “excel” : We auto select best courier. You don’t define params Courier.

Cancel Order

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/api/public/api/rest/lading/cancel")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\"TrackingCode\":\"SC52078917691\",\"ApiKey\":\"string (required)\"}"

response = http.request(request)
puts response.read_body
import requests

url = "http://seller.boxme.id/api/public/api/rest/lading/cancel"

payload = "{\"TrackingCode\":\"SC52078917691\",\"ApiKey\":\"string (required)\"}"
headers = {'content-type': 'application/json'}

response = requests.request("POST", url, data=payload, headers=headers)

print(response.text)
# With shell, you can just pass the correct header with each request
curl --request POST \
  --url http://seller.boxme.id/api/public/api/rest/lading/cancel \
  --header 'content-type: application/json' \
  --data '{"TrackingCode":"SC52078917691","ApiKey":"string (required)"}'
var data = JSON.stringify({
  "TrackingCode": "SC52078917691",
  "ApiKey": "string (required)"
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/api/public/api/rest/lading/cancel");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

HTTP Request

POST http://seller.boxme.id/api/public/api/rest/lading/cancel

Query Parameters

Parameter Default Description
ApiKey (MerchantKey) false Your api key of seller.
TrackingCode false BOXMEID Tracking Code.

Accept Order

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/courier/order_change_edit")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request.body = "{\"TrackingCode\":\"string (optional)\",\"ApiKey\":\"string (optional)\",\"status\":21}"

response = http.request(request)
puts response.read_body
import requests

url = "http://seller.boxme.id/courier/order_change_edit"

payload = "{\"TrackingCode\":\"string (optional)\",\"ApiKey\":\"string (optional)\",\"status\":21}"
headers = {'content-type': 'application/json'}

response = requests.request("POST", url, data=payload, headers=headers)

print(response.text)
# With shell, you can just pass the correct header with each request
curl --request POST \
  --url http://seller.boxme.id/courier/order_change_edit \
  --header 'content-type: application/json' \
  --data '{"TrackingCode":"string (optional)","ApiKey":"string (optional)", "status": 21}'
var data = JSON.stringify({
  "TrackingCode": "string (optional)",
  "ApiKey": "string (optional)",
  "status" : 21
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/courier/order_change_edit");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{
  "error": true,
  "error_message": {
    "TrackingCode": [
      "The tracking code format is invalid."
    ]
  }
}

HTTP Request

POST http://seller.boxme.id/courier/order_change_edit

Query Parameters

Parameter Default Description
ApiKey (MerchantKey) false Your api key of seller.
TrackingCode false BOXMEID Tracking Code.
status false Status 21 accept.

Merchant receive order status

This is webhook api. We will push order status and journey of order to your system via RestApi. Config at:

http://seller.boxme.id/#/app/config/key

http://seller.boxme.id/#/app/config/key

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/api/public/your-webhook-api")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["http_x_shipchung_refesh_token"] = 'your key'
request["content-type"] = 'application/json'
request.body = "{\"TrackingCode\":\"SC5238848343\",\"StatusId\":\"string (required)\",\"StatusName\":\"string (required)\",\"TimeStamp\":\"integer (required)\"}"
import requests

url = "http://seller.boxme.id/api/public/your-webhook-api"

payload = "{\"TrackingCode\":\"SC5238848343\",\"StatusId\":\"string (required)\",\"StatusName\":\"string (required)\",\"TimeStamp\":\"integer (required)\"}"
headers = {
    'http_x_shipchung_refesh_token': "your key",
    'content-type': "application/json"
    }

response = requests.request("POST", url, data=payload, headers=headers)
# With shell, you can just pass the correct header with each request
curl --request POST \
  --url http://seller.boxme.id/api/public/your-webhook-api \
  --header 'content-type: application/json' \
  --header 'http_x_shipchung_refesh_token: your key' \
  --data '{"TrackingCode":"SC5238848343","StatusId":"string (required)","StatusName":"string (required)","TimeStamp":"integer (required)"}'
var data = JSON.stringify({
  "TrackingCode": "SC5238848343",
  "StatusId": "string (required)",
  "StatusName": "string (required)",
  "TimeStamp": "integer (required)"
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/api/public/your-webhook-api");
xhr.setRequestHeader("http_x_shipchung_refesh_token", "your key");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{
  "error": true,
  "error_message": {
    "TrackingCode": [
      "The tracking code format is invalid."
    ]
  }
}

HTTP Request

POST http://seller.boxme.id/api/public/your-webhook-api

Query Parameters

Parameter Default Description
ApiKey (MerchantKey) false Your api key of seller.
TrackingCode false BOXMEID Tracking Code.
StatusId false Status Code defined status api.
StatusName false Status name.
TimeStamp false Time update this status.

List Status Order

This is webhook api. We will push order status and journey of order to your system via RestApi. Config at:

http://seller.boxme.id/#/app/config/key

http://seller.boxme.id/#/app/config/key

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/api/public/api/merchant/rest/lading/status")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request.body = "{}"

response = http.request(request)
puts response.read_body
import requests

url = "http://seller.boxme.id/api/public/api/merchant/rest/lading/status"

payload = "{}"
response = requests.request("GET", url, data=payload)

print(response.text)
# With shell, you can just pass the correct header with each request
curl --request GET \
  --url http://seller.boxme.id/api/public/api/merchant/rest/lading/status \
  --data '{}'
var data = "{}";

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "http://seller.boxme.id/api/public/api/merchant/rest/lading/status");

xhr.send(data);

The above command returns JSON structured like this:

{
  "error": false,
  "message": "Thành công",
  "data": [
    {
      "StatusId": 12,
      "StatusName": "Chờ duyệt",
      "StatusName_EN": "Waiting approve"
    },
    {
      "StatusId": 13,
      "StatusName": "Đã duyệt",
      "StatusName_EN": "Approved"
    },
    {
      "StatusId": 14,
      "StatusName": "Đang lấy hàng",
      "StatusName_EN": "Picking"
    },
    {
      "StatusId": 15,
      "StatusName": "Lấy không thành công",
      "StatusName_EN": "Pickup failed"
    },
    {
      "StatusId": 16,
      "StatusName": "Đã lấy hàng",
      "StatusName_EN": "Picked"
    },
    {
      "StatusId": 17,
      "StatusName": "Đang phát hàng",
      "StatusName_EN": "Delivering"
    },
    {
      "StatusId": 18,
      "StatusName": "Phát không thành công",
      "StatusName_EN": "Delivery failed"
    },
    {
      "StatusId": 19,
      "StatusName": "Đã phát thành công",
      "StatusName_EN": "Delivered"
    },
    {
      "StatusId": 20,
      "StatusName": "Chờ XN chuyển hoàn",
      "StatusName_EN": "Waiting return"
    },
    {
      "StatusId": 21,
      "StatusName": "Chuyển hoàn",
      "StatusName_EN": "Returning"
    },
    {
      "StatusId": 22,
      "StatusName": "Hủy đơn hàng",
      "StatusName_EN": "Cancelled"
    }
  ]
}

Get Status List Order

This is webhook api. We will push order status and journey of order to your system via RestApi. Config at:

http://seller.boxme.id/#/app/config/key

http://seller.boxme.id/#/app/config/key

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/api/public/api/merchant/rest/lading/statusmultil/{listorder}?MerchantKey={MerchantKey}")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request.body = "{}"

response = http.request(request)
puts response.read_body
import requests

url = "http://seller.boxme.id/api/public/api/merchant/rest/lading/statusmultil/[listorder]?MerchantKey=[MerchantKey]"

payload = "{}"
response = requests.request("GET", url, data=payload)

print(response.text)
# With shell, you can just pass the correct header with each request
curl --request GET \
  --url http://seller.boxme.id/api/public/api/merchant/rest/lading/statusmultil/[listorder] \
  --data '{MerchantKey=[MerchantKey]}'
var data = "{}";

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "http://seller.boxme.id/api/public/api/merchant/rest/lading/statusmultil/[listorder]?MerchantKey=[MerchantKey]");

xhr.send(data);

The above command returns JSON structured like this:

{
  "error": false,
  "message": "Thành công",
  "data": [
    {
      "tracking_code": "SC51786275290",
      "status": 20,
      "status_name": "Chờ duyệt",
      "status_name_en": "Awaiting approve",
      "status_group_name": "Chờ duyệt",
      "status_group_name_en": "Waiting approve"
    }
  ]
}

HTTP Request

GET http://seller.boxme.id/api/public/api/merchant/rest/lading/statusmultil/[listorder]?MerchantKey=[MerchantKey]

International Shipping

Steps to create an international order:

Get country

The above command returns JSON structured like this:

    {
    "error": false,
    "data": [{
              "id": 1,
              "country_code": "AF",
              "country_name": "Afghanistan",
              "active": 1,
              "required_zipcode": 0,
              "phone_code": 93
            },{
              "id": 2,
              "country_code": "AL",
              "country_name": "Albania",
              "active": 1,
              "required_zipcode": 0,
              "phone_code": 355
        }]
 }      

HTTP Request

GET http://seller.boxme.id/api/public/api/base/country

Get city from country

The above command returns JSON structured like this:

{
    "error": false,
    "data": [{
            "id": 742492,
            "_id": 742492,
            "country_id": 230,
            "country_code": "US",
            "country_name": "UNITED STATES OF AMERICA",
            "state_code": "MN",
            "state_name": "MINNESOTA",
            "city_name": "NEW YORK MILLS",
            "city_name_local": null,
            "airport": "STP",
            "zipcode": "56567",
            "to_zipcode": "\u000056567",
            "col9": "STP",
            "col10": "",
            "region": null,
            "priority": null,
            "code": null
        }]
 }        

Query Parameters

Parameter Default Description
id_country false ID country get from “api get country”.
keyword false Name city in country.

HTTP Request

GET http://seller.boxme.id/api/public/api/v1/mobile/city-global/{id_country}?q={keyword}

Calculate Fee

HTTP Request

POST http://seller.boxme.id/api/rest/global/calculate

Query Parameters

Parameter Default Description
ApiKey (MerchantKey) Required Your api key of seller.
From.City Required From city send order.
From.Province Required From province send order.
From.Stock Required ID inventory
To.Country Required Id country
To.City Required Id city
Order.Weight Required Order weight.
Order.Amount Required Total product value
Order.Quantity Required Quantity.
Order.ProductName Required Name product
Config.Service Required Shipping method:9. Economy delivery service,8. Express delivery
Type Required “Type”: “excel” : We auto select best courier. You don’t define params Courier.
——— ——- ———–

The body request JSON structured like this:

{"Domain": "seller.shipchung.vn",
  "From": {
    "City": 52,
    "Province": 551,
    "Stock": 206963,
    "Address": "18h cong hoa",
    "Phone": "0123456789",
    "Name": "Dev"
  },
  "To": {
   "Country": 230,
    "City": 750012,
    "Address": "a",
    "Zipcode": "11444"
  },
  "Order": {
    "Weight": 100,
    "Amount": 200000,
    "Quantity": 1,
    "ProductName": "Book"
  },
  "Config": {
    "Service": 8,
    "Checking": 1,
    "Fragile": 2,
    "AutoAccept": 0
  },
  "MerchantKey": ""
}

The above command returns JSON structured like this:

{
    "error": false,
    "code": "SUCCESS",
    "message": "success",
    "error_message": "success",
    "data": {
        "courier": {
            "system": [
                {
                    "courier_id": 17,
                    "courier_name": "DHL",
                    "courier_description": "",
                    "courier_logo": "https://seller.shipchung.vn/img/logo-hvc/17.png",
                    "money_pickup": 0,
                    "leatime_delivery": 120,
                    "leatime_courier": 1,
                    "leatime_total": 120,
                    "leatime_ward": 0,
                    "leatime_str": "5 ngày",
                    "priority": 9,
                    "fee": {
                        "fee_id": 1364,
                        "detail_id": 59647,
                        "pvc": 856548,
                        "collect": 0,
                        "vas": {
                            "cod": 0,
                            "protected": 0
                        },
                        "discount": {
                            "pvc": 0,
                            "pcod": 0
                        }
                    }
                },
                {
                    "courier_id": 15,
                    "courier_name": "UPS",
                    "courier_description": "",
                    "courier_logo": "https://seller.shipchung.vn/img/logo-hvc/15.png",
                    "money_pickup": 0,
                    "leatime_delivery": 72,
                    "leatime_courier": 1,
                    "leatime_total": 72,
                    "leatime_ward": 0,
                    "leatime_str": "3 ngày",
                    "priority": 9,
                    "fee": {
                        "fee_id": 2109,
                        "detail_id": 61480,
                        "pvc": 720196,
                        "collect": 0,
                        "vas": {
                            "cod": 0,
                            "protected": 0
                        },
                        "discount": {
                            "pvc": 0,
                            "pcod": 0
                        }
                    }
                }
            ]
        }
    },
    "stock": 206963
}     

Create Order

HTTP Request

POST http://seller.boxme.id/api/rest/global/calculate

Query Parameters

Parameter Default Description
ApiKey (MerchantKey) Required Your api key of seller.
From.City Required From city send order.
From.Province Required From province send order.
From.Stock Required ID inventory
To.Country Required Id country
To.City Required Id city
To.Zipcode Required Zipcode to city
To.Address Required addresss
To.Name Required Name buyer
To.Phone Required Phone number
To.PhoneCode Required Phone number
Order.Weight Required Order weight.
Order.Amount Required Total product value
Order.Quantity Required Quantity.
Order.ProductName Required Name product
Config.Service Required Shipping method:9. Economy delivery service,8. Express delivery
Config.Checking Required Accept receiver view item in order before confirm received or not.
Config.AutoAccept Required 1.Auto accept 0. No accept (default).
Config.Fragile Required Fragile.
Type Required “Type”: “excel” : We auto select best courier. You don’t define params Courier.

The body request JSON structured like this:

{
  "Domain": "seller.boxme.id",
  "From": {
    "City": 52,
    "Province": 551,
    "Stock": 206963,
    "Ward": 4394,
    "Address": "18h cong hoa",
    "Phone": "0123456789",
    "Name": "dev"
  },
  "To": {
   "Country": 230,
    "City": 750012,
    "Address": "a",
    "Zipcode": "11444",
    "Phone": "123456789",
    "PhoneCode": 1,
    "Name": "Jack"
  },
  "Order": {
    "Weight": 100,
    "Amount": 200000,
    "Quantity": 1,
    "ProductName": "Book"
  },
  "Config": {
    "Service": 8,
    "Checking": 1,
    "Fragile": 2,
    "AutoAccept": 0
  },
  "Type":"excel",
  "MerchantKey": ""
}

The above command returns JSON structured like this:

{
    "error": false,
    "code": "SUCCESS",
    "message": "success",
    "data": {
        "TrackingCode": "SC51851803887",
        "CourierId": 17,
        "ShowFee": {
            "pvc": 856548
        }
    }
}  

Manifest

Create manifest

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/api/public/api/manifests")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/json'
request["cache-control"] = 'no-cache'
request["postman-token"] = 'efeb234f-600b-e7ce-ea49-ab8b6ac3a57c'
request.body = "{ \"token\":\"29cf9d7c9c6d1ecef3812034c75f34ec\",  \"reference_code\":\"MF-TEST\",    \"inventory_id\":186019,\"entry_point\":\"VTPHN01\", \"overpacks\":[ {\"description\" : \"Test manifes boxme\",\"volume\" : \"10x10x10\",\"weight\" : 1100,\"color\" : \"red\",\"total\" : 100,\"overpack_partner_code\" : \"MFXXXXXX\",\"manifest_orders\":[ {\"tracking_code\" : \"SC5388176946\",\"quantity_tracking\" : 50,\"volume_tracking\" : \"10x10x10\",\"color_tracking\" : \"Red\",\"material_tracking\" : \"Plastic\",\"qc_tracking\" : \"Test\",\"tag_warehouse_code\" : \"MFXXXXXX\",\"partner_code\" : \"MFXXXXXX\",\"weight_tracking\" : 100,\"images\":[{\"tracking_code\" : \"SC5388176946\",\"url\" : \"http://placehold.it/170x100&text=one\"},{\"tracking_code\" : \"SC5388176946\",\"url\" : \"http://placehold.it/170x100&text=one\"}]} ]} ]}"

response = http.request(request)
puts response.read_body

import requests

url = "http://seller.boxme.id/api/public/api/manifests"

payload = "{    \"token\":\"29cf9d7c9c6d1ecef3812034c75f34ec\", \"reference_code\":\"MF-TEST\",  \"inventory_id\":186019, \"entry_point\":\"VTPHN01\",\"overpacks\":[  { \"description\" : \"Test manifes boxme\",\"volume\" : \"10x10x10\",  \"weight\" : 1100, \"color\" : \"red\", \"total\" : 100,\"overpack_partner_code\" : \"MFXXXXXX\",\"manifest_orders\":[ {  \"tracking_code\" : \"SC5388176946\",\"quantity_tracking\" : 50,\"volume_tracking\" : \"10x10x10\",\"color_tracking\" : \"Red\",\"material_tracking\" : \"Plastic\",\"qc_tracking\" : \"Test\",\"tag_warehouse_code\" : \"MFXXXXXX\",\"partner_code\" : \"MFXXXXXX\",\"weight_tracking\" : 100,\"images\":[{\"tracking_code\" : \"SC5388176946\",\"url\" : \"http://placehold.it/170x100&text=one\"},{\"tracking_code\" : \"SC5388176946\",\"url\" : \"http://placehold.it/170x100&text=one\"}] }]}]}"
headers = {
    'content-type': "application/json",
    'cache-control': "no-cache",
    'postman-token': "2c7edb7b-ecfa-1824-5722-1752155bfdf1"
    }

response = requests.request("POST", url, data=payload, headers=headers)

print(response.text)
curl --request POST \
  --url http://seller.boxme.id/api/public/api/manifests \
  --header 'cache-control: no-cache' \
  --header 'content-type: application/json' \
  --header 'postman-token: f6f86e0a-d1d2-ce55-db9d-ca5c77bf65c1' \
  --data '{"token":"29cf9d7c9c6d1ecef3812034c75f34ec",  "reference_code":"MF-TEST","inventory_id":186019, "entry_point":"VTPHN01",    "overpacks":[{"description" : "Test manifes boxme","volume" : "10x10x10",       "weight" : 1100, "color" : "red","total" : 100, "overpack_partner_code" : "MFXXXXXX","manifest_orders":[ {"tracking_code" : "SC5388176946","quantity_tracking" : 50,  "volume_tracking" : "10x10x10",         "color_tracking": "Red","material_tracking" : "Plastic",                    "qc_tracking" : "Test", "tag_warehouse_code" : "MFXXXXXX",                  "partner_code" : "MFXXXXXX","weight_tracking" : 100,    "images":[{"tracking_code" : "SC5388176946","url" :"http://placehold.it/170x100&text=one"   },{"tracking_code" : "SC5388176946","url" :"http://placehold.it/170x100&text=one"}]}]} ]}'
var data = JSON.stringify({
  "token": "xxxxxxxxx",
  "reference_code": "MF-TEST",
  "inventory_id": 186019,
  "entry_point": "VTPHN01",
  "overpacks": [
    {
      "description": "Test manifes boxme",
      "volume": "10x10x10",
      "weight": 1100,
      "color": "red",
      "total": 100,
      "overpack_partner_code": "MFXXXXXX",
      "manifest_orders": [
        {
          "tracking_code": "SC5388176946",
          "quantity_tracking": 50,
          "volume_tracking": "10x10x10",
          "color_tracking": "Red",
          "material_tracking": "Plastic",
          "qc_tracking": "Test",
          "tag_warehouse_code": "MFXXXXXX",
          "partner_code": "MFXXXXXX",
          "weight_tracking": 100,
          "images": [
            {
              "tracking_code": "SC5388176946",
              "url": "http://placehold.it/170x100&text=one"
            },
            {
              "tracking_code": "SC5388176946",
              "url": "http://placehold.it/170x100&text=one"
            }
          ]
        }
      ]
    }
  ]
});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === 4) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/api/public/api/manifests");
xhr.setRequestHeader("content-type", "application/json");
xhr.setRequestHeader("cache-control", "no-cache");
xhr.setRequestHeader("postman-token", "d23635ff-98ac-0288-f985-ba65bc13fa35");

xhr.send(data);

The above command returns JSON structured like this:

{
    "manifest": {
        "overpacks": [
            {
                "overpack_reference_code": null,
                "overpack_weight": 1100,
                "_embedded": {
                    "data": [
                        {
                            "tracking_code": "SC5388176946",
                            "volume": "10x10x10",
                            "qc": "Test",
                            "weight": 100,
                            "overpack_code": "OPae0613",
                            "warehouse": "VTPHN01",
                            "images": [
                                {
                                    "tracking_code": "SC5388176946",
                                    "urls": "http://placehold.it/170x100&text=one"
                                },
                                {
                                    "tracking_code": "SC5388176946",
                                    "urls": "http://placehold.it/170x100&text=one"
                                }
                            ],
                            "material": "Plastic",
                            "color": "Red",
                            "quantity": 50
                        }
                    ]
                },
                "overpack_code": "OPae0613",
                "overpack_id": 244,
                "time_create": "2017-07-23 11:13:12.130950",
                "overpack_partner_code": "MFXXXXXX",
                "overpack_total": 100,
                "overpack_volume": "10x10x10"
            }
        ],
        "entry_point": "VTPHN01",
        "id": 147,
        "created": "2017-07-23 11:13:12.122047"
    },
    "error": "false"
}

HTTP Request

POST http://seller.boxme.id/api/public/api/manifests

Query Parameters

Parameter Default Description
token false You Key API.
reference_code false Partner reference code.
inventory_id false Id inventory of Boxme/Indo.
entry_point false Warehouse of Boxme.
overpacks.description false Description of Overpacks .
overpacks.volume false Volume of Overpacks .
overpacks.weight false Weight of Overpacks .
overpacks.color false Color of Overpacks .
overpacks.overpack_partner_code false Reference code of Overpacks .
overpacks.manifest_orders.tracking_code false Tracking code of Boxme/Indo.
overpacks.manifest_orders.quantity_tracking false Quantity of tracking code.
overpacks.manifest_orders.volume_tracking false Volume of tracking code.
overpacks.manifest_orders.color_tracking false Color of tracking code.
overpacks.manifest_orders.material_tracking false Material of tracking code.
overpacks.manifest_orders.qc_tracking false Quality control.
overpacks.manifest_orders.tag_warehouse_code false Warehouse partner reference code.
overpacks.manifest_orders.partner_code false Partner code.
overpacks.manifest_orders.weight_tracking false Weight of tracking code.
overpacks.manifest_orders.images.url false Partner reference code.

The above command body JSON structured like this:

{
    "token":"xxxxxxxxxxx",
    "reference_code":"MF-TEST",
    "inventory_id":144469,
    "entry_point":"VTPHN01",
    "overpacks":[
        {
            "description" : "Test manifes boxme",
            "volume" : "10x10x10",
            "weight" : 1100,
            "color" : "red",
            "total" : 100,
            "overpack_partner_code" : "MFXXXXXX",
            "manifest_orders":[
                {
                    "tracking_code"         : "SC123456789",
                    "quantity_tracking"     : 50,
                    "volume_tracking"       : "10x10x10",
                    "color_tracking"        : "Red",
                    "material_tracking"     : "Plastic",
                    "qc_tracking"           : "Test",
                    "tag_warehouse_code" : "MFXXXXXX",
                    "partner_code" : "MFXXXXXX",
                    "weight_tracking"       : 100,
                    "images":[
                        {
                            "url" : "http://placehold.it/170x100&text=one"
                        },
                        {
                            "url" : "http://placehold.it/170x100&text=one"
                        }
                    ]
                }
            ]
        }
    ]
}

Get list manifest

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/api/list_manifests")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request["content-type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body

import http.client

conn = http.client.HTTPConnection("seller.boxme.id")

payload = "{}"

headers = { 'content-type': "application/json" }

conn.request("GET", "/api/list_manifests", payload, headers)

res = conn.getresponse()
# With shell, you can just pass the correct header with each request
curl --request GET \
  --url http://seller.boxme.id/api/public/api/list_manifests \
  --header 'content-type: application/json' \
  --data '{}'
var data = JSON.stringify({});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "http://seller.boxme.id/api/public/api/list_manifests");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{
  total_items: 7,
  _embedded: {
    data: [
      {
        status: 1,
        created: "2017-07-13 16:59:07",
        manifest_code: "MF3daa18",
        inventory_id: 166911,
        entry_point: "VTPHCM01",
        reference_code: "WV-TEST"
      },
      {
        status: 1,
        created: "2017-07-13 17:03:32",
        manifest_code: "MF12a5d1",
        inventory_id: 166911,
        entry_point: "VTPHCM01",
        reference_code: "WV-TEST"
      },
      {
        status: 6,
        created: "2017-07-15 13:43:35",
        manifest_code: "MF761659",
        inventory_id: 183333,
        entry_point: "VTPHCM01",
        reference_code: "WV-218B"
      },
      {
        status: 3,
        created: "2017-07-18 11:53:07",
        manifest_code: "MF6a139a",
        inventory_id: 183333,
        entry_point: "VTPHCM01",
        reference_code: "WV-220"
      },
      {
        status: 3,
        created: "2017-07-18 16:02:14",
        manifest_code: "MF8e344d",
        inventory_id: 183333,
        entry_point: "VTPHCM01",
        reference_code: "WV-221"
      },
      {
        status: 3,
        created: "2017-07-20 15:21:26",
        manifest_code: "MFa297a4",
        inventory_id: 186019,
        entry_point: "VTPHCM01",
        reference_code: "WV-222"
      },
      {
        status: 2,
        created: "2017-07-21 16:02:00",
        manifest_code: "MF51df58",
        inventory_id: 186019,
        entry_point: "VTPHCM01",
        reference_code: "WV-223"
      }
    ]
  },
  page_count: 1,
  page_size: 25,
  _links: {
    next: {
      href: "/list_manifests?page=1"
    },
    self: {
      href: "/list_manifests"
    },
    prev: {
      href: "/list_manifests?page=1"
    },
    last: {
      href: "/list_manifests?page=1"
    },
    first: {
      href: "/list_manifests?page=1"
    }
  },
  error: "false"
}

HTTP Request

GET http://seller.boxme.id/api/public/api/list_manifests

Query Parameters

Parameter Default Description
token false You Key API.

Get detail manifest

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/api/public/api/manifests/manifest_code")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Get.new(url)
request["content-type"] = 'application/json'
request.body = "{}"

response = http.request(request)
puts response.read_body
import http.client

conn = http.client.HTTPConnection("http://seller.boxme.id")

payload = "{}"

headers = { 'content-type': "application/json" }

conn.request("GET", "/api/public/api/manifests/manifest_code", payload, headers)

res = conn.getresponse()
# With shell, you can just pass the correct header with each request
curl --request GET \
  --url http://seller.boxme.id/api/public/api/manifests/manifest_code \
  --header 'content-type: application/json' \
  --data '{}'
var data = JSON.stringify({});

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === this.DONE) {
    console.log(this.responseText);
  }
});

xhr.open("GET", "http://seller.boxme.id/api/public/api/manifests/manifest_code");
xhr.setRequestHeader("content-type", "application/json");

xhr.send(data);

The above command returns JSON structured like this:

{
  manifest: {
    status: 6,
    user_phone: "0902165440",
    manifest_code: "MF761659",
    inventory_id: 183333,
    total_ovepacked: 2,
    overpacks: [
      {
        total_order: 2,
        status: 2,
        weight: 2200,
        volume: "",
        total: 22,
        total_receive: 22,
        overpack_code: "OP248798",
        status_name: "Packed",
        overpack_partner_code: "WV-218B-BOX-4",
        created: "2017-07-15 13:43:36",
        overpack_id: "189"
      },
      {
        total_order: 1,
        status: 2,
        weight: 1500,
        volume: "",
        total: 9,
        total_receive: 9,
        overpack_code: "OPf747ab",
        status_name: "Packed",
        overpack_partner_code: "WV-218B-BOX-1",
        created: "2017-07-15 13:43:36",
        overpack_id: "190"
      }
    ],
    total: 31,
    status_name: "Closed",
    created: "2017-07-15 13:43:35",
    order_mf: [
      {
        status: 11,
        weight: 1900,
        tracking_code: "SC5836474452",
        overpack_id: 189,
        images: [
          {
            url: "http://admin.weshop.asia/uploads/warehouse_proxy/stock_in/2017/06/30/3691086/rdfus6ozxz6wu08.png"
          },
          {
            url: "http://admin.weshop.asia/uploads/warehouse_proxy/stock_in/2017/06/30/3691086/6klujinrzbap7ot.png"
          },
          {
            url: "http://admin.weshop.asia/uploads/warehouse_proxy/stock_in/2017/06/30/3691086/sqn6kl1bfpae1lb.png"
          }
        ],
        courier_id: 1,
        total: 12,
        check: "[7, 7]",
        volume: "NonexNonexNone",
        overpack_code: "OP248798",
        status_name: "Sẵn sàng giao hàng",
        created: "2017-07-15 13:43:36",
        warehouse: "VTPHCM01"
      },
      {
        status: 11,
        weight: 1700,
        tracking_code: "SC51537766825",
        overpack_id: 189,
        images: [
          {
            url: "http://admin.weshop.asia/uploads/warehouse_proxy/stock_in/2017/06/30/NT_1498776131016/dr1hmk58h1g8da7.png"
          },
          {
            url: "http://admin.weshop.asia/uploads/warehouse_proxy/stock_in/2017/06/30/NT_1498776131016/tmpfx0j7hmta1fd.png"
          }
        ],
        courier_id: 1,
        total: 10,
        check: "[7]",
        volume: "NonexNonexNone",
        overpack_code: "OP248798",
        status_name: "Sẵn sàng giao hàng",
        created: "2017-07-15 13:43:36",
        warehouse: "VTPHCM01"
      },
      {
        status: 11,
        weight: 1500,
        tracking_code: "SC51755077834",
        overpack_id: 190,
        images: [
          {
            url: "http://admin.weshop.asia/uploads/warehouse_proxy/stock_in/2017/06/30/NT_1498776877622/8z3yex5zha6qmtj.png"
          },
          {
            url: "http://admin.weshop.asia/uploads/warehouse_proxy/stock_in/2017/06/30/NT_1498776877622/58uycertaq28lbs.png"
          }
        ],
        courier_id: 1,
        total: 9,
        check: "[7, 7]",
        volume: "NonexNonexNone",
        overpack_code: "OPf747ab",
        status_name: "Sẵn sàng giao hàng",
        created: "2017-07-15 13:43:36",
        warehouse: "VTPHCM01"
      }
    ],
    entry_point: "VTPHCM01",
    user_name: "Weshop Vietnam"
  },
  error: "false"
}

HTTP Request

GET http://seller.boxme.id/api/public/api/manifests/manifest_code

Query Parameters

Parameter Default Description
token false You Key API.

Update orders hold

To authorize, use this code:

require 'uri'
require 'net/http'

url = URI("http://seller.boxme.id/api/public/api/update_orders_hold")

http = Net::HTTP.new(url.host, url.port)

request = Net::HTTP::Post.new(url)
request["content-type"] = 'application/x-www-form-urlencoded'
request["cache-control"] = 'no-cache'
request["postman-token"] = '2d8c1289-cc95-e4ae-acb8-358dd0b9ff2a'

response = http.request(request)
puts response.read_body
import requests

url = "http://seller.boxme.id/api/public/api/update_orders_hold"

payload = ""
headers = {
    'content-type': "application/x-www-form-urlencoded",
    'cache-control': "no-cache",
    'postman-token': "5ecb3c24-4ffc-dfdb-b703-f083adf144fe"
    }

response = requests.request("POST", url, data=payload, headers=headers)

print(response.text)
curl --request POST \
  --url http://seller.boxme.id/api/public/api/update_orders_hold \
  --header 'cache-control: no-cache' \
  --header 'content-type: application/x-www-form-urlencoded' \
  --header 'postman-token: 49305424-7f22-727a-2fd0-2a0dc5d31680'
var data = null;

var xhr = new XMLHttpRequest();
xhr.withCredentials = true;

xhr.addEventListener("readystatechange", function () {
  if (this.readyState === 4) {
    console.log(this.responseText);
  }
});

xhr.open("POST", "http://seller.boxme.id/api/public/api/update_orders_hold");
xhr.setRequestHeader("content-type", "application/x-www-form-urlencoded");
xhr.setRequestHeader("cache-control", "no-cache");
xhr.setRequestHeader("postman-token", "2ad0febf-f0e7-7475-49e9-7c5c0b956388");

xhr.send(data);

The above command returns JSON structured like this:

{
    'error'     : 'false',
    '_embedded' : {
        'created'   : '2017-07-10 14:14:14',
        'data'  : [
            {
                'tracking_code' : 'SC5145506872',
                'note'  : 'Cập nhật trạng thái đơn thành công.'  
        }
        ]
}

HTTP Request

POST http://seller.boxme.id/api/public/api/update_orders_hold

Query Parameters

Parameter Default Description
token false You Key API.
order_list.tracking_code false Tracking code of seller BOXMEID.
order_list.note false Note.

The above command body JSON structured like this:

{
  "token": "xxxxxxxxxxxxxxxxxxxxxxxxxxxx",
  "order_list": [
        {
            "tracking_code" : "BMIN51627745352",
            "note" : "Boxme test"
        },
        {
            "tracking_code" : "BMIN5145506872",
            "note" : "Boxme test"
        }
    ]
}

Errors

Error Code Meaning
400 Bad Request – Your request sucks
401 Unauthorized – Your API key is wrong
403 Forbidden – The kitten requested is hidden for administrators only
404 Not Found – The specified kitten could not be found
405 Method Not Allowed – You tried to access a kitten with an invalid method
406 Not Acceptable – You requested a format that isn’t json
410 Gone – The kitten requested has been removed from our servers
418 I’m a teapot
429 Too Many Requests – You’re requesting too many kittens! Slow down!
500 Internal Server Error – We had a problem with our server. Try again later.
503 Service Unavailable – We’re temporarily offline for maintenance. Please try again later.