For ecommerce software (Magento, Prestashop, WooCommerce, Opencart) see the pre-made plugins.
To add an order form in your website, where customers can create shipments without logging in, you can adapt this PHP example.
To integrate shipment tracking and client registration/login in your website, use the Settings/Integrations menu, then copy and adapt the links and forms there.
Each instance of the CurierManager app may have its own base URL. The generic api url is:
For example if your software instance is http://app.curiermanager.ro/cscourier/ (but it may differ in your case) the full URL to create an expedition will be:
The API Key will be created by the courier company. The rest of the parameters are also given as GET/POST parameters (no JSON for input params).
Security note: if it is expected for a request URL to end up in a browser address bar, there is the risk of making the API key public. Please note that even using the api key in a development environment risks URLs to leak due to various browser plugins sending meta-data home. Another example is using print URLs as links, which may lead to them being printed as the page header - including the api key. Therefore, we recommend against using the api key in public GET requests. You also have the option of using the HTTP header field "api_key". Also, of course, the SSL version is always preferred.
All responses are a JSON map, with the following fields:
- status can be "done", "forbidden" or "failed"
- message is a text field that usually explains the status
- data contains the detailed response.
The API can be tested using the following address
The following fields can be added:
"type", "service_type", "retur", "retur_type", "ramburs", "ramburs_type", "insurance", "weight", "content", "comments", "cnt", "content", "customer_reference", "fragile", "width", "height", "length",
from_name, from_contact, from_str, from_nr, from_bl, from_sc, from_et, from_ap, from_interfon, from_sector, from_city, from_county, from_zipcode, from_country, from_phone,
to_name, to_contact", to_str, to_nr, to_bl, to_sc, to_et, to_ap, to_interfon, to_sector, to_city, to_county, to_country, to_zipcode, to_phone, to_extra, to_cui, to_regcom
type: envelope | package
service_type: obtain from courier company (eg: regular, express). you can also use the list_services API mentioned below, with type=main
retur: 0 | 1 - Package swap
cnt: number of packages/envelopes
retur_type: colet | document
ramburs: <CoD amount>
ramburs_type: cont | cash | instrumente_plata - CoD type, with values meaning account, cash or check.
weight: <weight in kg>
insurance: insured value
payer: who is paying the cost of transport for this shipment. Allowed values are:
- client (default value), if the payment will be made by the contracted client, usually on a monthly invoice
- sender|expeditor, if the payment is made in cash by the sender
- recipient | destinatar, if the payment is made in cash by the recipient.
from_... fields are used for the sender address, to_... fields for the recipient address
...name: name, company name if applicable
...contact: contact within company
...nr: street number
...interfon: interphone number
to_extra: any extra information regarding recipient address
use_default_from_address: if "true", it will use the default expedition address in the system instead of the fields above.
There are no mandatory fields except api_key, but you should be aware that expeditions lacking relevant information most likely can't be delivered.
Expeditions with the "cnt" set to values over 1 will be automatically converted to groups. You will receive in the response the number of the first package in the group (like "XXX"), and the rest are created as such:
1st package: XXX
2nd package: XXX/2
3rd package: XXX/3
And so on.
Any number of extra services (like “Delivery Saturday”) can be specified, each by adding a parameter like service_<service id> with the value true. For example if Delivery Saturday has the id 57, you would have: service_57=true
Do not use "1" as synonym for "true" - it is a common cause of problems.
The full list of services can be obtained through the API using the URL:
The data field contains a map with the created expedition. Expedition number is in the "no" field.
The status for the created expedition will be uncollected by default (neridicat for Romanian accounts). It can be changed from the Settings menu (Initial_api_status).
awb_event_handler is an optional parameter which can be used when creating the awb. It contains an URL towards which the system will send event call – GET requests, having the content parameter added containing a JSON map with the following fields:
Right now the system is sending events for status changes.
Events are being sent asynchronously, with a delay of max 60s.
Takes the same parameters as API_createAWB, and returns a map with fields "price" and "zone"
Returns the HTML version of the printed waybill.
If you want to save the awb in a pdf format add &pdf=true
You can change the format with the parameter format, with the legal values: a6, default. The default value is approximately a5.
Returns a text with the current expedition status.
Changes the status of the expedition. Can be used to change status from draft to uncollected, from uncollected to active. Can also be used to cancel an expedition, if the permissions to do so are granted.
Returns a JSON map consisting of:
type is optional and defaults to "picture".
If there is a document of that type, it will download it. If there are several documents of the same type it will download only the most recent one.
Extension of downloaded documents may vary - currently we have jpg and pdf in use.
Returns a json map with the fields "no", "status" and "history", where history is a list of status changes with the fields: date (unixtime), status and description.
If the parameter full is true and the api key is not a client api key (i.e. is a courier api key), it will add extra raw information from the database - both extra rows and extra fields.
Returns "ok" in case of success, or "forbidden" if the api key client does not have the permission to cancel shipments.
Returns a json list of shipments.
The from_date and to_date parameters should be dd-MM-yyyy.
Returns a json list of cities, with the fields "name" and "province" for each.
Returns a json list of invoices.
The from_date and to_date parameters should be dd-MM-yyyy.
Returns the raw list of saved addresses. If the api key is not attached to a client, it will return the saved addresses for all clients. If only_common is true, it will returned only predefined addresses that are public to all clients.
An expedition can have one of the following statuses:
Romanian companies will use Romanian language status names. These are: initial, neridicat, in_curs, livrat, returnat, anulat, exceptie.