API reference · Orders
Send shipment information
Sends the shipping company and tracking code of an order line to the marketplace and saves them in StockMount.
https://out.stockmount.com/api/Integration/SetOrderShipmentInformation
Only does something for these store types: N11 (IntegrationId 2), T-Soft (22) and StockMount (9999). GittiGidiyor (1) code still exists but the marketplace is closed. For other marketplaces (Trendyol, Hepsiburada, etc.) the call sends nothing and returns Result false with ErrorCode 60001.
If IntegrationId is not sent, it is looked up from the store. Sending it is recommended, since you know the store's marketplace.
SendShipmentInformation must be true, otherwise 00003 / SendShipmentInformation is returned. OrderId and IntegrationOrderDetailId are looked up from OrderDetailId when missing.
ShipmentCompany is the marketplace's shipping company code: the Code value from GetIntegrationShipmentCompanies. For N11 it must be numeric. For T-Soft it is checked against the T-Soft shop's cargo list. For StockMount stores it is free text. An unknown code returns 00004 / ShipmentCompany.
If the line already has a tracking code you get 60002 / Order item shipment information already exists !; the info cannot be changed.
On success StockMount saves the shipping company (ShipmentCompany or the company name, followed by ShipmentBranch), the tracking code and the shipping date (now). These values are written to all lines of the order. The status is updated: Shipped for N11 and StockMount, 6 for T-Soft.
The fields ShipmentCompanyName, ShipmentCompanyId, ShipmentMethod, CampaignNumber, SendPhoneMessage, UserMessage and SmUser are ignored.
Request fields
| Field | Type | Description |
|---|---|---|
ApiCode
required
|
string |
API code returned by DoLogin.
|
StoreId
required
|
integer | Store ID. |
IntegrationId
|
integer |
The store's marketplace ID: N11 2, T-Soft 22, StockMount 9999. Looked up from the store when omitted.
|
OrderDetailId
required
|
integer | StockMount order line ID. |
SendShipmentInformation
required
|
boolean |
Must be true.
|
ShipmentCompany
required
|
string |
Shipping company code (GetIntegrationShipmentCompanies → Code).
|
ShipmentTrackingCode
required
|
string | Tracking code. |
ShipmentBranch
|
string | Shipping branch. Appended to the company name in StockMount. Was required for GittiGidiyor. |
OrderId
|
integer | StockMount order ID. Looked up from the line when missing. |
IntegrationOrderDetailId
|
string | Marketplace line ID (N11, T-Soft). Taken from the line when missing. |
IntegrationOrderCode
|
string | Marketplace order number. Only used for GittiGidiyor. |
Response fields (Response)
On success the Response field is empty; read the outcome from Result.
Error codes for this endpoint
| Code | When |
|---|---|
00004 |
ShipmentCompany is not a known code for this marketplace. |
10001 |
StoreId is not a store in your account (ErrorMessage: Invalid store.). |
60001 |
The store is not an N11, T-Soft or StockMount store, or the marketplace rejected the tracking details. |
60002 |
The line already has a tracking code. |
99999 |
Unexpected error (e.g. non-numeric ShipmentCompany for N11, missing IntegrationId). |
For session errors (00001, 00006) and every other code see error codes.
Related endpoints
Example request
{
"ApiCode": "API_CODE",
"StoreId": 12345,
"IntegrationId": 2,
"OrderDetailId": 9876543,
"SendShipmentInformation": true,
"ShipmentCompany": "344",
"ShipmentTrackingCode": "1234567890123"
}
curl -X POST 'https://out.stockmount.com/api/Integration/SetOrderShipmentInformation' \
-H 'Content-Type: application/json' \
-d '{
"ApiCode": "API_CODE",
"StoreId": 12345,
"IntegrationId": 2,
"OrderDetailId": 9876543,
"SendShipmentInformation": true,
"ShipmentCompany": "344",
"ShipmentTrackingCode": "1234567890123"
}'
using System.Net.Http;
using System.Text;
using var http = new HttpClient();
var json = """
{
"ApiCode": "API_CODE",
"StoreId": 12345,
"IntegrationId": 2,
"OrderDetailId": 9876543,
"SendShipmentInformation": true,
"ShipmentCompany": "344",
"ShipmentTrackingCode": "1234567890123"
}
""";
var response = await http.PostAsync(
"https://out.stockmount.com/api/Integration/SetOrderShipmentInformation",
new StringContent(json, Encoding.UTF8, "application/json"));
var result = await response.Content.ReadAsStringAsync();
// Result == false ise ErrorCode ve ErrorMessage alanlarına bakın.
Console.WriteLine(result);
<?php
$body = <<<'JSON'
{
"ApiCode": "API_CODE",
"StoreId": 12345,
"IntegrationId": 2,
"OrderDetailId": 9876543,
"SendShipmentInformation": true,
"ShipmentCompany": "344",
"ShipmentTrackingCode": "1234567890123"
}
JSON;
$ch = curl_init('https://out.stockmount.com/api/Integration/SetOrderShipmentInformation');
curl_setopt_array($ch, [
CURLOPT_POST => true,
CURLOPT_HTTPHEADER => ['Content-Type: application/json'],
CURLOPT_POSTFIELDS => $body,
CURLOPT_RETURNTRANSFER => true,
]);
$result = json_decode(curl_exec($ch), true);
curl_close($ch);
if (!$result['Result']) {
echo $result['ErrorCode'] . ' ' . $result['ErrorMessage'];
}
import requests
payload = {
"ApiCode": "API_CODE",
"StoreId": 12345,
"IntegrationId": 2,
"OrderDetailId": 9876543,
"SendShipmentInformation": True,
"ShipmentCompany": "344",
"ShipmentTrackingCode": "1234567890123"
}
response = requests.post("https://out.stockmount.com/api/Integration/SetOrderShipmentInformation", json=payload, timeout=60)
result = response.json()
if not result["Result"]:
print(result["ErrorCode"], result["ErrorMessage"])
const payload = {
"ApiCode": "API_CODE",
"StoreId": 12345,
"IntegrationId": 2,
"OrderDetailId": 9876543,
"SendShipmentInformation": true,
"ShipmentCompany": "344",
"ShipmentTrackingCode": "1234567890123"
};
const response = await fetch("https://out.stockmount.com/api/Integration/SetOrderShipmentInformation", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify(payload),
});
const result = await response.json();
if (!result.Result) {
console.error(result.ErrorCode, result.ErrorMessage);
}
Example response
{
"Result": true
}
Try it
The request goes straight from your browser to out.stockmount.com. The ApiCode is not stored by this site; it is kept only while this tab is open.
Get an ApiCode before sending requests.
This endpoint changes real data in your account.
Recent requests
Requests sent from this tab; click one to load its body again.