Replenishments API

 In API/Developers

API REPLENISHMENT

Method: CreateReple
Creates replenishment.
HTTP: POST
https://integration.shipedge.com/API/Rest/Replenishment/CreateReple
Format: JSON

 

(*) means required data.

Paremeter

Type

Description

Key(*)VarcharFound in your ShipEdge account. Preferences > API Integration > Key (Required).
AccountID(*)IntFound in your ShipEdge account. Preferences > API Integration > AccountID (Required).
Warehouse(*)VarcharThis will be found in your ShipEdge account. Preferences > API Integration > Warehouse (Required).
ExpectedDeliveryDate(*)Date(YYYY/MM/DD)Expected date of arrival of products (Required).
PreSyncEnum (On,Off)Updated inventory in Shopping Carts before product physically arriving (Optional).
Sku(*)varcharThe SKU’s name is unique by product. The SKU must be in your Shipedge inventory (Required).
Qty(*)intQuantity of the product expected. The Qty must be greater than zero (Required).
TrackingNumvarchar(Optional)
PoNumvarchar(Optional)
SupplierNamevarcharThe name of the sender visible in the from field of the shipment’s Shipping Label or Bill of Lading (Optional).
CommentsvarcharYou can use comments to give some special instructions or reminders to the warehouse team (Optional).

(*)Required Parameters

 

Request (Example):

{  “AccountID”:”1″,
“Key”:”123456789″,
“Warehouse”:”nc2″,

“SupplierName”:”Test Name”,

“PoNum”:”123″,
“TrackingNum”:”456″,

“Comments”:”Hello”,

“ExpectedDeliveryDate”:”2014-12-10″,

“PreSync”:”On”,
“Items”:[

{“Sku”:”Sku1″,”Qty”:”1″}, {“Sku”:”Sku2″,”Qty”:”2″}, {“Sku”:”Sku3″,”Qty”:”3″}

]

}

 

Answers Successful (Example):

1. If there is any ErrorSku.

{“Status”:”Successful”,”RepleID”:”123″,””RecordsReceived”:”2″of”3″,”ErrorSku”:”Sku1″}
2. If everything was inserted.

{“Status”:”Successful”,”RepleID”:”123″,””RecordsReceived”:”3″of”3″}

Status

RepleID

RecordsReceived

ErrorSku

Successful2

Unique Replenishment ID created in Shipedge.

Amount of products inserted.

 

List of SKU’s that were not inserted to this replenishment.

 

 

Answers Error (Example):
{“Status”:”Error”,””Description”:”Invalid”PreSync”}

 

Status

Description

Error

No AccountID provided. *(Required)

No Key provided. *(Required)

No Warehouse provided. *(Required)

No ExpectedDeliveryDate provided.*(Required)

Invalid AcountID.

Invalid Key.

Invalid Warehouse.

Invalid PreSync. *(Format On,Off)

Invalid ExpectedDeliveryDate. *(Format YYYY/MM/DD)

Example: In Php.
<?php
$data = array(
“AccountID” => “1”,
“Key” => “123456789”,
“Warehouse” => “demo”,

“ExpectedDeliveryDate” => “2014-05-05”,

“SupplierName” => “TestName”,

“PoNum” => “123”,

“TrackingNum” => “456”,

“Comments” => “Hello”,

“PreSync” => “On”,

“Items” => array(

array(“Sku” => “Sku1″ ,”Qty” => “1”),

array(“Sku” => “Sku2″ ,”Qty” => “2”),

array(“Sku” => “Sku3″ ,”Qty” => “3”)

)

);

$data = json_encode($data);
$url =”https://integration.shipedge.com/API/Rest/Replenishment/CreateReple”; $curl = curl_init();
curl_setopt($curl, CURLOPT_HEADER, false);
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS, $data);
curl_setopt($curl, CURLOPT_HTTPHEADER, array(‘Content-Type: application/json’,’Content-Length: ‘ . strlen($data)));
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
$x = curl_exec($curl);

print_r($x);

?>

(*) Use the information in your account.

 

 API REPLENISHMENT

Method: UpdateReple Update replenishment.
HTTP:POST

https://integration.shipedge.com/API/Rest/Replenishment/UpdateReple

Format: JSON

Parameter

Type

Description

RepleID (*)

Int

The RepleID of the replenishment you want to update (Required).

AccountID (*)

int

Found in your ShipEdge account. Preferences>API Integration>AccountID (Required).

Warehouse (*)

varchar

This will be found in your ShipEdge account. Preferences>API Integration>Warehouse (Required).

ExpectedDeliveryDate

Date(YYYY-MM-DD)

Expected date of arrival of products (Optional).

PreSync

Enum (On,Off)

Updated inventory in ShoppingCarts before product physically arriving (Optional).

TrackingNum

varchar

(Optional)

PoNum

varchar

(Optional)

SupplierName

varchar

The name of the sender visible in the from field of the shipment’s ShippingZ Label or Bill of Lading (Optional).

Comments

varchar

You can use comments to give some special instructions or reminders to the warehouse team (Optional).

(*) Required Parameters

 

Request (Example):

{ “RepleID”:”123″,
“AccountID”:”1″,
“Key”:”123456789″,

“Warehouse”:”nc2″,

“SupplierName”:”Test Name”,

“PoNum”:”123″,
“TrackingNum”:”456″,

“Comments”:”Hello”,

“ExpectedDeliveryDate”:”2014-12-10″,

“PreSync”:”On” }

 

Answers Successful (Example):
{ “Status”:”Successful update” , “RepleID”:”123″ }

Answers Error (Example):
{ “Status”:”Error”, “Description”:” No RepleID provided ” }

 

Status

Description

Error

No RepleID provided. *(Required)

No AccountID provided. *(Required)

No Key provided. *(Required)

No Warehouse provided. *(Required)

No ExpectedDeliveryDate provided. *(Required)

Invalid AcountID.

Invalid Key.

Invalid Warehouse.

Invalid PreSync. *(Format On,Off)

Invalid ExpectedDeliveryDate. *(Format YYYY-MM-DD)

Example: In Php.

1.

<?php
$data = array(

“RepleID” => “1”,

“AccountID” => “2”,

“Key” => “123”,

“Warehouse” => “demo”,

 

“ExpectedDeliveryDate” => “2015-01-27”,

“SupplierName” => “Supplier Name”,

“PoNum” => “1234”,
“TrackingNum” => “4564”,

“Comments” => “Hello”, “PreSync” => “On”,

);
$data = json_encode($data);
$url =”https://integration.shipedge.com/API/Rest/Replenishment/UpdateReple”; $curl = curl_init();
curl_setopt($curl, CURLOPT_HEADER, false);
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS,
curl_setopt($curl, CURLOPT_HTTPHEADER,
application/json’,’Content-Length: ‘ .
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
$x = curl_exec($curl);
print_r($x);
?>

2.

<?php
$data = array(

“RepleID” => “1”,

“AccountID” => “2”,

“Key” => “123”,

“Warehouse” => “demo”,

“ExpectedDeliveryDate” => “2015-01-27″,

);
$data = json_encode($data);
$url =”https://integration.shipedge.com/API/Rest/Replenishment/UpdateReple”; $curl = curl_init();
curl_setopt($curl, CURLOPT_HEADER, false);
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS,
curl_setopt($curl, CURLOPT_HTTPHEADER,
application/json’,’Content-Length: ‘ .
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
$x = curl_exec($curl);
print_r($x);
?>

(*) Use the information in your account.

 

 

API REPLENISHMENT 

Method: GetRepleIDs.
HTTP: POST

https://integration.shipedge.com/API/Rest/Replenishment/GetRepleIDs

Format: JSON

Parameter

Type

Description

AccountID (*)

int

Found in your ShipEdge account. Preferences>API Integration>AccountID. (Required)

Warehouse (*)

varchar

This will be found in your ShipEdge account. Preferences>API Integration> Warehouse. (Required)

PoNum (*)

varchar

PO# only for status InZtransit and Arrived. (Required)

Key (*)

varchar

Found in your ShipEdge account. Preferences>API Integration> Key. (Required)

(*) Required Parameters

 

Request (Example):

{
“AccountID”:”1″,

“Key”:”123456789″,

“Warehouse”:”demo”,

“PoNum”:”123″
}

 

Answers Successful (Example):

{“Status”:”Successful”, “PoNum”:”78″, “RepleIDs”:[“1”]}”
or

{“Status”:”Successful”, “PoNum”:””, “RepleIDs”:[“1″,”2”,”3”]}”

 

Answers Error (Example):

{ “Status”:”Error”, “Description”:” No PoNum provided ” }

Status

Description

Error

No PoNum provided. *(Required)

No AccountID provided. *(Required)

No Key provided. *(Required)

No Warehouse provided. *(Required)

Invalid AcountID.

Invalid Key.

Invalid Warehouse.

Example: In Php.

1.

<?php
$data = array(
“AccountID” => “2”,
“Key” => “123”,
“Warehouse” => “demo”,
“PoNum” => “1234”
);
$data = json_encode($data);
$url =”https://integration.shipedge.com/API/Rest/Replenishment/GetRepleIDs”; $curl = curl_init();
curl_setopt($curl, CURLOPT_HEADER, false);
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS,
curl_setopt($curl, CURLOPT_HTTPHEADER,
application/json’,’Content-Length: ‘ .
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
$x = curl_exec($curl);
print_r($x);
?>

2. All RepleIds

<?php
$data = array(
“AccountID” => “2”,
“Key” => “123”,
“Warehouse” => “demo”,
“PoNum” => “”
);
$data = json_encode($data);
$url =”https://integration.shipedge.com/API/Rest/Replenishment/GetRepleIDs”; $curl = curl_init();
curl_setopt($curl, CURLOPT_HEADER, false);
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_POSTFIELDS,
curl_setopt($curl, CURLOPT_HTTPHEADER,
application/json’,’Content-Length: ‘ .
curl_setopt($curl, CURLOPT_URL, $url);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);
$x = curl_exec($curl);
print_r($x);
?>

(*) Use the information in your account. 

 Note: Leaving PO# blank will return repleIDs for all replenishments in status: InTransit and Arrived.

Contact Us

Send us an email and we'll get back to you, ASAP.