- Authentication
- Rates
- Shipments
- Tracking
- Batches
- Classifications
- Customer
- Landed Cost
- Manifest
- Webhooks
- Invoices
Create Batch
POST
/Batches
ShipmentBatchesController
Request
Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.Example:
Authorization: Bearer ********************
Body Params application/json
CustomerKey
string
optional
HashKey
string
optional
DutyHashKey
string
optional
PickUpDate
string
optional
Async
boolean
optional
Default:
false
Reference
string
required
BatchID
string
required
LabelFormat
enum<string>
optional
Allowed values:
PDFZPL
Default:
PDF
WeightUnit
enum<string>
optional
Allowed values:
KGLB
Default:
KG
Currency
string
optional
Default:
USD
DimensionUnit
enum<string>
optional
Allowed values:
INCM
Default:
IN
Insurance
enum<string>
optional
Allowed values:
YN
Default:
N
ServiceCode
enum<string>
required
Allowed values:
STANDARDEXPRESSSTANDARD-ECONOMYEXPRESS-ECONOMY
TermsOfTrade
enum<string>
optional
Allowed values:
DDPDDU
Default:
DDP
IsReturn
enum<string>
optional
Allowed values:
YN
Default:
N
ShipmentKey
string
optional
ShipFromAddress
object (ShipFromAddress)
required
Name
string
optional
Default:
Test Shipper
AttentionName
string
optional
Default:
Test Shipper
LocationName
string
optional
Default:
AddressLine1
string
required
AddressLine2
string
optional
AddressLine3
string
optional
City
string
required
State
string
optional
Country
string
required
Zip
string
optional
Phone
string
required
Email
string
required
ShipToAddress
object (ShipToAddress)
required
Name
string
required
Default:
Test consignee
AttentionName
string
optional
Default:
Test consignee
AddressLine1
string
required
AddressLine2
string
optional
AddressLine3
string
optional
City
string
required
State
string
optional
Country
string
required
Zip
string
optional
Phone
string
required
Email
string
required
FederalTaxId
string
optional
StateTaxId
string
optional
ReasonForExport
string
optional
Default:
merchandise
Metadata
object (Metadata)
optional
IndiaExportInfo
object (IndiaExportInfo)
optional
B2b
boolean
optional
Default:
false
IsNewShipment
boolean
optional
Default:
false
Example
{
"AppID": "{{app_id}}",
"RestApiKey": "{{rest_api_key}}",
"Async": false,
"Reference": "{{batch_id}}",
"BatchID": "{{batch_id}}",
"LabelFormat": "PDF",
"WeightUnit": "LB",
"Currency": "USD",
"DimensionUnit": "IN",
"Insurance": "N",
"ServiceCode": "EXPRESS",
"TermsOfTrade": "DDP",
"IsReturn": "N",
"ShipmentKey": "",
"ShipFromAddress": {
"Name": "FC Rates",
"AttentionName": "",
"AddressLine1": "1562 Washington St",
"AddressLine2": "",
"AddressLine3": "",
"City": "San Francisco",
"State": "CA",
"Country": "US",
"Zip": "94109",
"Phone": "1111111111",
"Email": "test@test.com"
},
"ShipToAddress": {
"Name": "FC Rates",
"AttentionName": "FC Rates",
"AddressLine1": "49 Montcalm Ave",
"AddressLine2": "",
"AddressLine3": "",
"City": "York",
"State": "ON",
"Country": "CA",
"Zip": "M6E 4N8",
"Phone": "1111111111",
"Email": "test@test.com"
},
"ReasonForExport": "merchandise"
}
Request samples
Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://partnerapi.flavorcloud.com/Batches' \
--header 'Content-Type: application/json' \
--data-raw '{
"AppID": "{{app_id}}",
"RestApiKey": "{{rest_api_key}}",
"Async": false,
"Reference": "{{batch_id}}",
"BatchID": "{{batch_id}}",
"LabelFormat": "PDF",
"WeightUnit": "LB",
"Currency": "USD",
"DimensionUnit": "IN",
"Insurance": "N",
"ServiceCode": "EXPRESS",
"TermsOfTrade": "DDP",
"IsReturn": "N",
"ShipmentKey": "",
"ShipFromAddress": {
"Name": "FC Rates",
"AttentionName": "",
"AddressLine1": "1562 Washington St",
"AddressLine2": "",
"AddressLine3": "",
"City": "San Francisco",
"State": "CA",
"Country": "US",
"Zip": "94109",
"Phone": "1111111111",
"Email": "test@test.com"
},
"ShipToAddress": {
"Name": "FC Rates",
"AttentionName": "FC Rates",
"AddressLine1": "49 Montcalm Ave",
"AddressLine2": "",
"AddressLine3": "",
"City": "York",
"State": "ON",
"Country": "CA",
"Zip": "M6E 4N8",
"Phone": "1111111111",
"Email": "test@test.com"
},
"ReasonForExport": "merchandise"
}'
Responses
🟢200Create Batch
application/json
Body
id
number
optional
customerId
number
optional
shipmentId
number
optional
packageJSON
string
optional
baseRequestJSON
string
optional
responseJSON
string
optional
batchId
string
optional
status
enum<string>
optional
Allowed values:
OpenFC-ClosedCompleted
createdDate
string <date-time>
optional
modifiedDate
string <date-time>
optional
completedDate
string <date-time>
optional
createdBy
number
optional
modifiedBy
number
optional
Example
{
"id": 0,
"customerId": 0,
"shipmentId": 0,
"packageJSON": "string",
"baseRequestJSON": "string",
"responseJSON": "string",
"batchId": "string",
"status": "Open",
"createdDate": "2019-08-24T14:15:22Z",
"modifiedDate": "2019-08-24T14:15:22Z",
"completedDate": "2019-08-24T14:15:22Z",
"createdBy": 0,
"modifiedBy": 0
}
Modified at 2025-04-28 20:49:46