### Get Order API Request Example Source: https://api.qapla.dev/v2/1 This is an example of a GET request to the getOrder API endpoint. It requires an API key and an order reference for retrieving specific order details. ```http GET https://api.qapla.it/1.3/getOrder/?apiKey=[API_KEY]&reference=[ORDER_REFERENCE] ``` -------------------------------- ### Example Country Parameter Usage Source: https://api.qapla.dev/v2/1 Demonstrates how to use the optional 'country' parameter to filter results by specific nations. Multiple countries can be specified, separated by commas. ```text country=it,fr,global ``` -------------------------------- ### Example Carrier Code Parameter Usage Source: https://api.qapla.dev/v2/1 Illustrates the use of the optional 'code' parameter to specify a Qapla carrier code for filtering. ```text code=BRT ``` -------------------------------- ### Confirm Label Request Body Example Source: https://api.qapla.dev/v2/1 Example JSON request body for the confirmLabel API call. It includes the API key and confirmation details such as courier, label creation date or label ID, and pickup date/time. ```JSON { "apiKey": "[API_KEY]", "confirmLabel": { "courier": "DHL", "labelCreationDate": "2020-08-10", "pickupDate": "2020-08-12", "labelID": [ 100, 101, 102, 103 ] } } ``` -------------------------------- ### Confirm Label Response Body Example Source: https://api.qapla.dev/v2/1 Example JSON response for the confirmLabel API call when successful. It includes version, result, errors, courier, confirmation number, date, number of shipments, and a Base64 encoded PDF manifest. ```JSON { "confirmLabel": { "version": "1.3.1", "result": "OK", "error": [ { "100": "error message" } ], "courier": "GLS-ITA", "number": "00003-2024", "date": "02-02-2024 12:58:00", "shipments": 3, "manifest": "[base64PDF]" } } ``` -------------------------------- ### Get Qapla Status Request URL Parameters Source: https://api.qapla.dev/v2/1 This example demonstrates how to construct a URL to retrieve Qapla shipment statuses. It includes mandatory 'apiKey' and optional 'lang' and 'id' parameters for filtering. ```url https://api.qapla.it/1.2/getQaplaStatus/?apiKey=[API_KEY]&lang=[LANG]&id=[ID] ``` -------------------------------- ### Check Label Response Body Example Source: https://api.qapla.dev/v2/1 Example JSON response for the checkLabel API call when successful. It includes version, result, error, date, ID, reference, tracking number, format, courier information, and printing/confirmation status. ```JSON { "checkLabel": { "version": "1.2.2", "result": "OK", "error": null, "date": "2023-03-07 17:33:12", "id": 999, "reference": "77354", "trackingNumber": "QQ42687937", "format": "PDF", "courier": { "code": "TNT-ITA", "name": "TNT Italia" }, "isPrinted": 1, "isPrintedDate": "2023-04-11 11:45:24", "isConfirmed": 0, "isConfirmedDate": null } } ``` -------------------------------- ### Create Channel API Request Example Source: https://api.qapla.dev/v2/1 This JSON snippet demonstrates a successful API request to create a new channel. It includes parameters for channel creation settings such as name, URL, and platform-specific configurations like Ecwid's store ID and access token. ```json { "createChannel": { "settings": { "name": "My channel name", "url": "https://www.example.it", "orderSettings": { "import": "auto" }, "platform": { "ecwid": { "storeID": "12345", "accessToken": "your_access_token" } } } } } ``` -------------------------------- ### Create Channel API Response Example (Success) Source: https://api.qapla.dev/v2/1 This JSON snippet represents a successful response from the 'createChannel' API endpoint. It returns the newly created channel's code, name, URL, and both private and public API keys. ```json { "createChannel": { "result": { "code": "MYC1", "name": "My channel name", "url": "https://www.example.it", "privateApiKey": "1q2w3e4r5t6y7u8i9o0pazsxdc", "publicApiKey": "1q2w3e4r" } } } ``` -------------------------------- ### Get Tracking by Timeframe (GET) Source: https://api.qapla.dev/v2/1 Retrieves a list of shipments that have had their tracking status updated within a specified time frame. Requires an API key and optional date parameters (dateFrom, dateTo) and language. ```url GET https://api.qapla.it/1.2/trackingByTimeFrame/ Parameters: apiKey*(string): The API key for the channel. dateFrom(timestamp): Optional, defaults to one hour ago. ISO 8601 format "yyyy-mm-dd hh:mm:ss". dateTo(timestamp): Optional. ISO 8601 format "yyyy-mm-dd hh:mm:ss". lang: Optional, language for Qapla status names (it, en, es), default: it. Example: &lang=en ``` -------------------------------- ### Get Order API Source: https://api.qapla.dev/v2/1 Retrieves the details of a specific order using its reference. ```APIDOC ## GET /getOrder ### Description This endpoint allows you to retrieve a specific order using its reference. ### Method GET ### Endpoint https://api.qapla.it/1.3/getOrder/ ### Parameters #### Query Parameters - **apiKey** (string) - Required - Your API key. - **reference** (string) - Required - The reference of the order to retrieve. ### Response #### Success Response (200) (Response structure for a successful order retrieval is not detailed in the provided text but would typically include order details.) #### Response Example (Example response not provided in the source text.) ``` -------------------------------- ### Create Channel API Response Example (Error) Source: https://api.qapla.dev/v2/1 This JSON snippet illustrates an error response from the 'createChannel' API endpoint. In case of an error, the 'result' field will contain 'KO' and the 'error' field will provide a description of the encountered issue. ```json { "createChannel": { "result": "KO", "error": "Specific error description here" } } ``` -------------------------------- ### Get Credits API Source: https://api.qapla.dev/v2/1 Retrieve the remaining credits on your premium Qapla account. This endpoint requires your API key. ```APIDOC ## GET /1.2/getCredits/ ### Description Retrieves the remaining credits on your premium Qapla account. ### Method GET ### Endpoint https://api.qapla.it/1.2/getCredits/ ### Parameters #### Query Parameters - **apiKey** (string) - Required - The API Key assigned to the channel you want to query. ### Response #### Success Response (200) - **getCredits** (object) - Contains the credit information. - **result** (string) - The result of the operation: OK or KO in case of error. - **error** (string) - The error message if result is KO, otherwise null. - **credits** (int) - The remaining credits. - **date** (string) - The date and time the credit count was updated. #### Response Example ```json { "getCredits": { "result": "OK", "error": null, "credits": 9916, "date": "2019-06-20 12:33:02" } } ``` ``` -------------------------------- ### GET /1.2/getOrders/ Source: https://api.qapla.dev/v2/1 Retrieves a list of orders imported from Qapla'. Supports filtering by date parameters. ```APIDOC ## GET /1.2/getOrders/ ### Description Retrieves a list of orders imported from Qapla'. Supports filtering by date parameters. ### Method GET ### Endpoint https://api.qapla.it/1.2/getOrders/ ### Parameters #### Query Parameters - **apiKey** (string) - Required - The API key assigned to the channel. - **updatedAt** (string) - Optional - Order update date in ISO 8601 format "YYYY-MM-DD". - **createdAt** (string) - Optional - Order creation date in ISO 8601 format "YYYY-MM-DD". - **dateIns** (string) - Optional - Order insertion date in ISO 8601 format "YYYY-MM-DD". - **dateFrom** (string) - Optional - Start date for filtering by "_updatedAt_" in ISO 8601 format "yyyy-mm-dd hh:mm:ss". - **dateTo** (string) - Optional - End date for filtering by "_updatedAt_" in ISO 8601 format "yyyy-mm-dd hh:mm:ss". *If no [DATE] parameter is passed, the default is dateFrom = 1 hour ago at 00:00:00.* ### Response #### Success Response (200) - **getOrders** (object) - Contains the result of the operation. - **result** (string) - "OK" if the operation was successful. - **error** (string) - Null if no error occurred. - **version** (string) - API version. - **count** (integer) - Number of orders returned. - **orders** (array) - List of orders. - **reference** (string) - Order reference. - **orderID** (string) - Order ID (can be null). - **status** (string) - Order status. - **dateIns** (string) - Order insertion date. - **createdAt** (string) - Order creation date. - **updatedAt** (string) - Order update date. - **isActive** (boolean) - Indicates if the order is active. - **isDeleted** (boolean) - Indicates if the order is deleted. - **isShipped** (boolean) - Indicates if the order is shipped. - **courier** (string) - Courier name. - **origin** (string) - Order origin. - **getOrder** (string) - URL to get specific order details. #### Response Example ```json { "getOrders": { "result": "OK", "error": null, "version": "1.2.9", "count": 1, "orders": [ { "reference": "154-D1", "orderID": null, "status": "Completed", "dateIns": "2019-06-20 10:00:22", "createdAt": "2019-06-20 09:50:06", "updatedAt": "2019-06-20 09:52:57", "isActive": false, "isDeleted": false, "isShipped": true, "courier": "BRT", "origin": "ebay", "getOrder": "https://api.qapla.it/1.2/getOrder/?apiKey=[API_KEY]&reference=154-D1" } ] } } ``` ``` -------------------------------- ### Get PUDO API Source: https://api.qapla.dev/v2/1 This endpoint allows requesting a list of Pick Up Drop Off (PUDO) points for multiple couriers simultaneously. Activation is required. ```APIDOC ## POST /1.2/getPudos/ ### Description `getPudos` allows requesting the list of PUDO (Pick Up Drop Off points) for multiple couriers at the same time. **Attention** * * * Request activation from Customer Care. ### Method POST ### Endpoint `https://api.qapla.it/1.2/getPudos/` ### Parameters #### Query Parameters (Optional, can be provided in the URL) - **apiKey** (string) - The API Key of the channel. Can alternatively be provided as a query parameter in the request URL. Example: `POST https://api.qapla.it/1.2/getPudos/?apiKey=[API_KEY]` #### Request Body - **apiKey** (string) - Required - The API Key of the channel. - **postCode** (string) - Required - Postal code of the location for which to search for PUDOs. - **country** (string) - Required - ISO 3166-2 code of the nation where the postCode is located. Quality of the code is not checked. - **couriers** (array) - Optional - List of Qapla' "Courier Codes" for which to retrieve PUDOs. Valid courier codes include UPS, BRT, GLS, GLS-ITA, GLS-SPAIN, GLS-AT, DHL, PTI, INPOST, INPOST_PL, FEDEX, DHLPARCEL-ES, CORREOS, SEUR, TIPSA, MRW-ES, NACEX-ES, CORREOS-EXPRESS, SENDING, DHL-PAKET, SPRING-GDS, and TNT-ITA. If this parameter is not specified or left empty, PUDOs for all valid and Qapla' configured couriers will be retrieved. - **province** (string) - Optional - Province of the location being searched. - **city** (string) - Optional - City/municipality of the location (required for TIPSA). - **street** (string) - Optional - Address, including street number if applicable. - **radius** (number) - Optional - Radius, in KM, within which to limit the PUDO search. Specifying a value <= 0 means no radius is applied. - **limit** (number) - Optional - Number of PUDOs to return per courier. Specifying a value <= 0 means no limit is applied, and the courier will return its default. ### Request Example ```json { "apiKey": "[API_KEY]", "postCode": "08960", "country": "ES", "limit": 10, "radius": 20, "couriers": [ "DHLPARCEL-ES", "UPS" ] } ``` ### Response #### Success Response (200) (The response structure for PUDOs is complex and depends on the specific couriers requested. It typically includes details for each PUDO found, such as address, operating hours, and contact information. The exact format will be provided upon successful retrieval.) #### Response Example (Example structure - actual response will contain PUDO details) ```json { "getPudos": { "result": "OK", "error": null, "version": "1.2.11", "count": 1, "pudos": [ { "courierCode": "DHLPARCEL-ES", "points": [ { "id": "PUDO123", "name": "Local Store", "address": "123 Main St, Barcelona, 08960, ES", "latitude": 41.3851, "longitude": 2.1734, "openingHours": "Mon-Fri 9am-6pm, Sat 9am-1pm", "phone": "+34 123 456 789" } ] } ] } } ``` ``` -------------------------------- ### Get Shipment with Optional Parameters Source: https://api.qapla.dev/v2/1 Demonstrates how to use optional parameters like language and data for the getShipment endpoint. The 'data' parameter allows specifying the level of detail in the response, such as consignee information or tracking history. ```HTTP _GET_https://api.qapla.it/1.3/getShipment/?apiKey=[API_KEY]&trackingNumber=[TRACKING_NUMBER]&lang=en&data=consignee,history ``` -------------------------------- ### Get Couriers API Source: https://api.qapla.dev/v2/1 Retrieves a list of available couriers, either total or filtered by country or code. ```APIDOC ## GET /1.2/getCouriers/ ### Description Requests the list of available couriers, either total or for a specific country or code. ### Method GET ### Endpoint `/1.2/getCouriers/` ### Parameters #### Query Parameters - **apiKey** (string) - Required - The API Key of the channel. - **country** (string) - Optional - A comma-separated list of country codes to filter couriers by. - **code** (string) - Optional - A comma-separated list of courier codes to filter by. ### Request Example ```json GET https://api.qapla.it/1.2/getCouriers/?apiKey=[API_KEY]&country=[COUNTRY_LIST]&code=[COURIER_CODE] ``` ### Response (Response structure not provided in the input text, typically would include a list of courier objects with their codes, names, and supported countries.) ### Error Handling (Error handling details not provided in the input text.) ``` -------------------------------- ### Get Credits Response JSON Source: https://api.qapla.dev/v2/1 This JSON object shows the response from the getCredits endpoint, providing the operation result, remaining credits, and the timestamp of the last update. ```json { "getCredits": { "result": "OK", "error": null, "credits": 9916, "date": "2019-06-20 12:33:02" } } ``` -------------------------------- ### Get Shipment by Order Reference Source: https://api.qapla.dev/v2/1 Retrieves the status of a shipment using its order reference. Requires an API key. Other parameters like tracking number or shipment ID can be used as alternatives. ```HTTP _GET_https://api.qapla.it/1.3/getShipment/?apiKey=[API_KEY]&reference=[ORDER_REFERENCE] ``` -------------------------------- ### Create Channel API Source: https://api.qapla.dev/v2/1 This endpoint allows you to create a new sales channel with various configuration options, including platform and marketplace settings. ```APIDOC ## POST /websites/api_qapla_dev_v2/createChannel ### Description Allows the creation of a new sales channel with specified settings. ### Method POST ### Endpoint /websites/api_qapla_dev_v2/createChannel ### Parameters #### Request Body - **apiKey** (string) - Required - The API Key of the channel. - **createChannel** (object) - Required - **code** (string) - Required - The channel code (e.g., "MOC", "MYCH"). - **name** (string) - Required - The channel name (e.g., "This is my channel"). - **url** (string) - Optional - Absolute URL of your website/ecommerce (e.g., https://www.example.org). - **orderSettings** (object) - Optional - **import** (string) - Optional - Defines the import type ('none', 'auto', 'manual'). - **platform** (object) - Optional - Platform specific settings. - **ecwid** (object) - Optional - **storeID** (string) - Required. - **accessToken** (string) - Required. - **magento** (object) - Optional - **username** (string) - Required. - **storeID** (string) - Required. - **magento2** (object) - Optional - **username** (string) - Required. - **password** (string) - Required. - **storeID** (string) - Required. - **prestashop** (object) - Optional - **accessToken** (string) - Required. - **shopify** (object) - Optional - **shopName** (string) - Required. - **apiKey** (string) - Required. - **password** (string) - Required. - **storeden** (object) - Optional - **accessKey** (string) - Required. - **accessToken** (string) - Required. - **vtex** (object) - Optional - **domain** (string) - Required. - **appToken** (string) - Required. - **appKey** (string) - Required. - **woocommerce** (object) - Optional - **consumerKey** (string) - Required. - **secretKey** (string) - Required. - **updateSettings** (object) - Optional - **updateWhenShipped** (bool) - Optional - Update order to "shipped" when shipment is created. - **updateWhenShippedLocationID** (string) - Optional - Location ID from your Shopify account. - **updateWithShipmentStatus** (bool) - Optional - Update with shipment statuses. - **marketplaces** (object) - Optional - Marketplace specific settings. - **amazon** (object) - Optional - **active** (bool) - Optional - Enable/disable marketplace. - **update** (bool) - Optional - Update order. - **amazonSellerID** (string) - Required. - **amazonMWSAuthorisationToken** (string) - Required. - **amazonMarketplacesID** (array object) - Required - **country** (string) - Required - Allowed values: IT, GB, ES, FR, DE. - **marketplaceID** (string) - Required. - **carrefour** (object) - Optional - **active** (bool) - Optional - Enable/disable marketplace. - **update** (bool) - Optional - Update order. - **settings** (array object) - Required - **country** (string) - Required - Allowed value: ES. - **apiKey** (string) - Required. - **cdiscount** (object) - Optional - **active** (bool) - Optional - Enable/disable marketplace. - **username** (string) - Required. - **password** (string) - Required. - **ebay** (object) - Optional - **eprice** (object) - Optional - **active** (bool) - Optional - Enable/disable marketplace. - **update** (bool) - Optional - Update order. - **apiKey** (string) - Required. - **ibs** (object) - Optional - **active** (bool) - Optional - Enable/disable marketplace. - **update** (bool) - Optional - Update order. - **apiKey** (string) - Required. - **manomano** (object) - Optional - **apiKey** (string) - Required. - **settings** (array object) - Required - **active** (bool) - Optional - Enable/disable marketplace. - **country** (string) - Required - Allowed values: IT, GB, ES, FR, DE. - **login** (string) - Required. - **password** (string) - Required. - **apiKey** (string) - Required - Required for REST API. - **sellerContractId** (string) - Required - Required for REST API. - **privalia** (object) - Optional - **active** (bool) - Optional - Enable/disable marketplace. - **update** (bool) - Optional - Update order. - **settings** (array object) - Required - **apiKey** (bool) - Required. - **country** (string) - Required - Allowed values: IT, ES. - **spartoo** (object) - Optional - **active** (bool) - Optional - Enable/disable marketplace. - **update** (bool) - Optional - Update order. - **apiKey** (string) - Required. - **domainsCountry** (array) - Required - Allowed values: "it","es","fr","de","gb","pt","nl","be","pl","cn". - **worten** (object) - Optional - **active** (bool) - Optional - Enable/disable marketplace. - **update** (bool) - Optional - Update order. - **settings** (array object) - Required - **apiKey** (bool) - Required. - **country** (string) - Required - Allowed value: PT. ### Request Example ```json { "apiKey": "YOUR_API_KEY", "createChannel": { "code": "MYCH", "name": "My New Channel", "url": "https://www.example.com", "orderSettings": { "import": "auto" }, "platform": { "shopify": { "shopName": "my-shop.myshopify.com", "apiKey": "SHOPIFY_API_KEY", "password": "SHOPIFY_PASSWORD" } }, "marketplaces": { "amazon": { "active": true, "update": true, "amazonSellerID": "AMAZON_SELLER_ID", "amazonMWSAuthorisationToken": "MWS_AUTH_TOKEN", "amazonMarketplacesID": [ { "country": "IT", "marketplaceID": "AMAZON_IT_MARKETPLACE_ID" } ] } } } } ``` ### Response #### Success Response (200) - **createChannel** (object) - Contains the result of the channel creation. - **result** (object) - The outcome of the operation. - **code** (string) - The unique code of the created channel. - **name** (string) - The name of the created channel. - **url** (string) - The URL of the created channel. - **privateApiKey** (string) - The private API key for the channel. - **publicApiKey** (string) - The public API key for the channel. #### Response Example ```json { "createChannel": { "result": { "code": "MYC1", "name": "My channel name", "url": "https://www.example.it", "privateApiKey": "1q2w3e4r5t6y7u8i9o0pazsxdc", "publicApiKey": "1q2w3e4r" } } } ``` #### Error Response - **result** (string) - "KO" if an error occurred. - **error** (string) - Description of the error. ``` -------------------------------- ### Get Couriers API Endpoint Source: https://api.qapla.dev/v2/1 Retrieves a list of available couriers, either total or filtered by country or courier code. This GET request requires an API key and optional country and courier code parameters. ```HTTP _GET_https://api.qapla.it/1.2/getCouriers/?apiKey=[API_KEY]&country=[COUNTRY_LIST]&code=[COURIER_CODE] ``` -------------------------------- ### Website Tracking API Source: https://api.qapla.dev/v2/1 Retrieve tracking information for website orders using your API key and order references. You can specify the level of detail for the returned data. ```APIDOC ## GET /websites/api_qapla_dev_v2 ### Description Retrieve tracking information for website orders. This endpoint requires an API key and at least one order reference. The `data` parameter allows you to control the verbosity of the returned information. ### Method GET ### Endpoint /websites/api_qapla_dev_v2 ### Parameters #### Query Parameters - **apiKey** (string) - Required - The API Key assigned to the channel you want to query. - **reference** (string) - Optional - The order reference. At least one of 'reference' or 'orderID' is required. - **orderID** (string) - Optional - An alternative order reference. At least one of 'reference' or 'orderID' is required. - **data** (string) - Optional - Specifies which and how much data to return. Defaults to minimal shipping status data. Possible values: `all` (minimal data + all subsequent data), `deliveryInfo` (minimal data + shipping mode information like 'ship by', 'deliver by', 'insurance'). If not specified, minimal data is returned. ### Request Example ``` GET /websites/api_qapla_dev_v2?apiKey=YOUR_API_KEY&reference=ORDER123&data=deliveryInfo ``` ### Response #### Success Response (200) - **status** (string) - The current status of the shipment. - **tracking_details** (object) - Detailed tracking information (structure varies based on the `data` parameter). #### Response Example ```json { "status": "in_transit", "tracking_details": { "ship_by": "2023-10-27", "deliver_by": "2023-10-30", "insurance": true } } ``` ``` -------------------------------- ### POST /1.3/pushOrder/ Source: https://api.qapla.dev/v2/1 The pushOrder endpoint allows you to upload one or more orders by sending JSON data via a POST request. ```APIDOC ## POST /1.3/pushOrder/ ### Description Allows uploading one or more orders via a POST request with JSON data. ### Method POST ### Endpoint https://api.qapla.it/1.3/pushOrder/ ### Parameters #### Request Body - **apiKey** (string) - Required - Your API key for authentication. - **origin** (string) - Required - The origin system (e.g., "magento2"). - **pushOrder** (array) - Required - An array of order objects to be pushed. - **reference** (string) - Required - Unique reference for the order. - **orderID** (integer) - Required - The order ID from the origin system. - **courier** (string) - Required - The courier code (e.g., "GENERIC"). - **courierService** (string) - Required - The specific service code for the courier (e.g., "P46"). - **status** (string) - Required - The current status of the order (e.g., "Processato"). - **createdAt** (string) - Required - The date and time the order was created (YYYY-MM-DD HH:MM:SS). - **updatedAt** (string) - Required - The date and time the order was last updated (YYYY-MM-DD HH:MM:SS). - **name** (string) - Required - The recipient's full name. - **street** (string) - Required - The recipient's street address. - **city** (string) - Required - The recipient's city. - **state** (string) - Required - The recipient's state or province. - **postCode** (string) - Required - The recipient's postal code. - **country** (string) - Required - The recipient's country code (ISO 3166-1 alpha-2). - **email** (string) - Optional - The recipient's email address. - **telephone** (string) - Optional - The recipient's phone number. - **amount** (number) - Required - The total amount of the order. - **shippingCost** (number) - Required - The cost of shipping. - **currencyCode** (string) - Required - The currency code for the order (e.g., "EUR"). - **payment** (string) - Required - The payment method used (e.g., "pp_hosted"). - **isCOD** (boolean) - Required - Indicates if the order is Cash On Delivery. - **notes** (string) - Optional - Any special notes for the order. - **parcels** (array) - Optional - An array of parcel details. - **width** (number) - Required - Parcel width. - **height** (number) - Required - Parcel height. - **weight** (number) - Required - Parcel weight. - **length** (number) - Required - Parcel length. - **boxCode** (string) - Optional - Code for the box used. - **content** (string) - Optional - Description of the parcel content. - **originCountry** (string) - Optional - Origin country of the parcel. - **isReturnable** (boolean) - Required - Indicates if the order is returnable. - **shippingCODPaymentOption** (string) - Optional - COD payment option for shipping. - **shippingInsurance** (string) - Optional - Insurance value for shipping. - **shippingDeliveryOptions** (string) - Optional - Delivery options for shipping (e.g., "A,P"). - **shippingRequiredDeliveryDate** (string) - Optional - Required delivery date (YYYY-MM-DD). - **latestShipDate** (string) - Optional - Latest possible ship date (YYYY-MM-DD). - **latestDeliveryDate** (string) - Optional - Latest possible delivery date (YYYY-MM-DD). - **tag** (string) - Optional - A tag for the order. - **pickUpDate** (string) - Optional - The pickup date (YYYY-MM-DD). - **custom1** (string) - Optional - Custom field 1. - **custom2** (string) - Optional - Custom field 2. - **custom3** (string) - Optional - Custom field 3. - **pickupPoint** (string) - Optional - Pickup point identifier. - **content** (string) - Optional - General content description for the order. - **rows** (array) - Required - An array of order items. - **sku** (string) - Required - Stock Keeping Unit for the item. - **name** (string) - Required - Name of the item. - **qty** (integer) - Required - Quantity of the item. - **weight** (number) - Optional - Weight of the item. - **url** (string) - Optional - URL of the product. - **imageUrl** (string) - Optional - URL of the product image. - **price** (number) - Required - Price of a single item unit. - **total** (number) - Required - Total price for the item quantity. - **isReturnable** (boolean) - Optional - Indicates if the item is returnable. - **notes** (string) - Optional - Notes specific to this item. - **customsCode** (string) - Optional - Customs code for the item. - **originCountry** (string) - Optional - Origin country of the item. - **netWeight** (number) - Optional - Net weight of the item. - **unitOfMeasurement** (string) - Optional - Unit of measurement for the item. - **parcelID** (integer) - Optional - ID of the parcel this item belongs to. - **transparencyCodes** (array) - Optional - Array of transparency codes for the item. - **sender** (object) - Optional - Sender details. - **code** (string) - Required - Sender code. - **businessName** (string) - Required - Sender's business name. - **street** (string) - Required - Sender's street address. - **city** (string) - Required - Sender's city. - **state** (string) - Required - Sender's state or province. - **postCode** (string) - Required - Sender's postal code. - **country** (string) - Required - Sender's country code. - **email** (string) - Optional - Sender's email address. - **telephone** (string) - Optional - Sender's phone number. - **referent** (string) - Optional - Sender's contact person. - **isDefault** (boolean) - Optional - Indicates if this is the default sender. - **PUDO** (object) - Optional - Pickup/Delivery Point details. - **id** (string) - Required - ID of the pickup/delivery point. - **type** (string) - Required - Type of the point (e.g., "LOCKER"). - **name** (string) - Required - Name of the pickup/delivery point. - **address** (string) - Required - Address of the pickup/delivery point. - **city** (string) - Required - City of the pickup/delivery point. - **state** (string) - Required - State/Province of the pickup/delivery point. - **country** (string) - Required - Country code of the pickup/delivery point. - **postalCode** (string) - Required - Postal code of the pickup/delivery point. - **description** (string) - Optional - Description of the pickup/delivery point. - **invoice** (object) - Optional - Invoice details. - **number** (string) - Required - Invoice number. - **date** (string) - Required - Invoice date (YYYY-MM-DD). - **goodsCode** (string) - Optional - Code for the goods being shipped. ### Request Example ```json { "apiKey": "[API_KEY]", "origin": "magento2", "pushOrder": [ { "reference": "BAT-234241299", "orderID": 234241222, "courier": "GENERIC", "courierService": "P46", "status": "Processato", "createdAt": "2018-04-01 22:38:18", "updatedAt": "2018-04-01 22:40:41", "name": "Barbara Gordon", "street": "Via manin, 8", "city": "Vigonza", "state": "Padova", "postCode": "35010", "country": "IT", "email": "batgirl@qapla.it", "telephone": "3473425220", "amount": 109.25, "shippingCost": 9.35, "currencyCode": "EUR", "payment": "pp_hosted", "isCOD": false, "notes": "Consegnare solo se in costume", "parcels": [ { "width": 20, "height": 7, "weight": 1.5, "length": 12, "boxCode": null, "content": null, "originCountry": null }, { "width": 22, "height": 10, "weight": 1.1, "length": 35, "boxCode": null, "content": null, "originCountry": null } ], "isReturnable": true, "shippingCODPaymentOption": "", "shippingInsurance": "300.99", "shippingDeliveryOptions": "A,P", "shippingRequiredDeliveryDate": "2020-09-01", "latestShipDate": "2018-04-03", "latestDeliveryDate": "2018-04-05", "tag": "blue", "pickUpDate": "2020-08-30", "custom1": "custom value 1", "custom2": "custom value 2", "custom3": "custom value 3", "pickupPoint": "0201", "content": "The goods", "rows": [ { "sku": "BAR-301", "name": "Barrette di Crusca d'Avena con Cioccolato (4 pezzi) 120g", "qty": 1, "weight": 1.5, "url": "https://www.iltuosito.it/alimenti/barretta-al-cocco", "imageUrl": "https://www.iltuosito.it/img/alimenti/barretta-al-cocco.jpg", "price": 6.35, "total": 6.35, "isReturnable": true, "notes": "this is a product note", "customsCode": null, "originCountry": null, "netWeight": null, "unitOfMeasurement": null, "parcelID": null, "transparencyCodes": [ "ABC123", "DEF456" ] }, { "sku": "BEV-001", "name": "Bevanda al mango in polvere 9g", "qty": 5, "weight": 1, "url": "https://www.iltuosito.it/alimenti/barretta-al-cocco", "imageUrl": "https://www.iltuosito.it/img/alimenti/barretta-al-cocco.jpg", "price": 0.38, "total": 1.9, "isReturnable": true, "customsCode": null, "originCountry": null, "netWeight": null, "unitOfMeasurement": null, "parcelID": null } ], "sender": { "code": "FEDO", "businessName": "fedò snc", "street": "Via I Maggio, 11", "city": "Vedano Olona", "state": "VA", "postCode": "21040", "country": "IT", "email": "evelina@fedo.it", "telephone": "0332261261", "referent": "Evelina", "isDefault": false }, "PUDO": { "id": "1234", "type": "LOCKER", "name": "Bar Mario snc", "address": "Via mario rossi", "city": "Varese", "state": "VA", "country": "IT", "postalCode": "21100", "description": "Note" }, "invoice": { "number": "A00012345/2022", "date": "2022-11-01" }, "goodsCode": "CODE123" } ] } ``` ### Response #### Success Response (200) - **status** (string) - Indicates the success of the operation. - **message** (string) - A message describing the result. - **errors** (array) - An array of errors encountered during the push, if any. #### Response Example ```json { "status": "success", "message": "Orders pushed successfully.", "errors": [] } ``` ``` -------------------------------- ### Create Label API Source: https://api.qapla.dev/v2/1 Endpoint for creating shipping labels in PDF or ZPL format. Activation is required, and test labels can be generated using the GENERIC carrier code. ```APIDOC ## Create Label ### Description Allows the creation of shipping labels in PDF or ZPL format. The format is configurable via the Control Panel. Activation is required and must be requested from Customer Care. ### Method POST ### Endpoint `https://api.qapla.it/1.3/createLabel/` ### Parameters #### Path Parameters None. #### Query Parameters None. #### Request Body * **carrierCode** (string) - Required - The code of the carrier for which to create the label. Use 'GENERIC' for test labels. * **labelFormat** (string) - Optional - The desired format for the label (e.g., 'PDF', 'ZPL'). Defaults to Control Panel setting. ### Request Example ```json { "carrierCode": "GENERIC", "labelFormat": "PDF" } ``` ### Response #### Success Response (200) * **labelData** (string) - The generated label data (e.g., base64 encoded PDF or ZPL string). * **format** (string) - The format of the returned label data. #### Response Example ```json { "labelData": "JVBERi0xLjQKJcO...", "format": "PDF" } ``` ### Note * To generate a "dummy label" for testing, use the carrier code `GENERIC`. ```