Welcome to the JTL-WAWI technical API documentation. This guide is here to help developers understand how our REST API works and how it can be integrated into your existing systems. We'll delve into the details of authentication and data manipulation processes, providing clear examples along the way. Whether you're a developer or an IT professional, this documentation aims to give you a practical understanding, laying the groundwork for effectively using the JTL-WAWI API to enhance your processes.
You register your application with the API by sending a POST request with the required information and corresponding keys. You can find the exact request details at https://developer.jtl-software.com/products/erp/swagger/appregistration. This information has to include the following:
This data is crucial for identifying and registering your application with the API. The API uses it to generate a temporary authentication ID that allows your application to access the necessary resources. After successful validation of this information, you will receive the API key required for future authentication and API requests.
Before you can begin the registration process, you must open JTL-Wawi (new interface) and start the registration process under 'Admin->App registration'. Only at this point are you authorised to send the first API call. This step in JTL-Wawi ensures that your application is properly registered and has permission to use the API.
The API will send you an authentication ID in the form of a token. Once you have received this token and successfully completed the registration in JTL-Wawi, you will send another request to the API by including this authentication ID in the URL path.
After successful validation of this second request by the API and confirmation of the correct information, you will be provided with the actual API key. It is important to note that this API key will not be displayed again!
This API key will be used in the future to authenticate requests to the API. It is of utmost importance that you securely store the API key upon receipt, as it cannot be retrieved from any other location in the system.
This is the name of your application, in this case "MyApp/1.0.0". It is used to identify your application.
This is where the version number of your application is entered, in this case "1.0.0".
The User-Id as int or uuid to run the Request, a JTL-Wawi user can be specified to perform an API call on their behalf (more details in the documentation, Optional). To use the Header, you must have the needed Scope 'Application.RunAs'
curl -i -X GET \
'https://developer.jtl-software.com/_mock/products/erpapi/1.0-cloud/openapi/invoices?customerId=0&externalOrderNumber=string&invoiceNumber=string&isExternalInvoice=true&itemId=0&pageNumber=0&pageSize=0&paymentStatus=0&salesOrderNumber=string' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'api-version: string' \
-H 'tenant-id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-H 'x-appid: string' \
-H 'x-appversion: string' \
-H 'x-runas: string'
Returns all non-pending sales orders.
Gets or sets the total number of items available in the data source.
Gets or sets the collection of items contained in the paged list.
The external number of the sales order.
Name of the state in the departure country.
ISO code of the currency of the departure country.
Description of the Company.
Additional company information
Street name in the customer's address
Additional address information
Postal code of the customer's address
Name of city in the customer's address
Name of state in the customer's address
Landline phone number
Mobile phone number
Description of the Company.
Additional company information
Street name in the customer's address
Additional address information
Postal code of the customer's address
Name of city in the customer's address
Name of state in the customer's address
Landline phone number
Mobile phone number
The date when the invoice was created.
The payment method whith which the invoice was paid.
The payment status of the invoice.0=UnPayed | 1=PartialPayed | 2=Payed
The total gross amount of the invoice.
ISO code of the currency of the invoice.
The currency factor for the sales order at the time the sales order has been created.
The amount that is left to pay for this invoice.
The due date for payment of the sales order in days.
The cash discount of the sales order.
The days that the cash discount is valid.
The creation of dunning letters is blocked.
The stage at which dunning currently is
Indicates if the invoice of the sales order was created in an external system like Amazon VCS.
A customer comment on the sales order.
The ID of the reason for cancelling the invoice.
A comment that adds further information to the cancellation.
Gets the total number of pages based on the total number of items and the page size.
Gets a value indicating whether there is a previous page available in the paginated list.
Gets the number of the next page if there is one; otherwise, returns the total number of pages.
{ "TotalItems": 0, "PageNumber": 0, "PageSize": 0, "Items": [ { … } ], "TotalPages": 0, "HasPreviousPage": true, "HasNextPage": true, "NextPageNumber": 0, "PreviousPageNumber": 0 }
This is the name of your application, in this case "MyApp/1.0.0". It is used to identify your application.
This is where the version number of your application is entered, in this case "1.0.0".
The User-Id as int or uuid to run the Request, a JTL-Wawi user can be specified to perform an API call on their behalf (more details in the documentation, Optional). To use the Header, you must have the needed Scope 'Application.RunAs'
curl -i -X GET \
'https://developer.jtl-software.com/_mock/products/erpapi/1.0-cloud/openapi/invoices/{invoiceId}' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'api-version: string' \
-H 'tenant-id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-H 'x-appid: string' \
-H 'x-appversion: string' \
-H 'x-runas: string'
Returns the invoice for the given ID.
ISO code of the currency of the departure country.
Additional company information
Name of state in the customer's address
The date when the invoice was created.
The payment method whith which the invoice was paid.
The payment status of the invoice.0=UnPayed | 1=PartialPayed | 2=Payed
The total gross amount of the invoice.
ISO code of the currency of the invoice.
The currency factor for the sales order at the time the sales order has been created.
The amount that is left to pay for this invoice.
The due date for payment of the sales order in days.
The cash discount of the sales order.
The days that the cash discount is valid.
The creation of dunning letters is blocked.
The stage at which dunning currently is
Indicates if the invoice of the sales order was created in an external system like Amazon VCS.
A customer comment on the sales order.
The ID of the reason for cancelling the invoice.
A comment that adds further information to the cancellation.
{ "Id": 123, "Number": "A1004465", "ExternalNumber": "D456-64894-132", "CompanyId": 1, "DepartureCountry": { "CountryISO": "DE", "State": "Berlin", "CurrencyIso": "TODO", "CurrencyFactor": 1.37 }, "CustomerId": 1005, "BillingAddress": { "Id": 100, "Company": "Sportbedarf Sommer", "Company2": "Innovation Division", "FormOfAddress": "Mr.", "Title": "Dr.", "FirstName": "John", "LastName": "Doe", "Street": "Main St. 123", "Address2": "Floor 5, Apt 302", "PostalCode": "12345", "City": "Example City", "State": "Example State", "CountryIso": "DE", "VatID": "DE123456789", "PhoneNumber": "+49 1234 445556661", "MobilePhoneNumber": "+49 160 123 4567", "EmailAddress": "example@email.com", "Fax": "+49 1234 4455566615" }, "ShipmentAddress": { "Id": 100, "Company": "Sportbedarf Sommer", "Company2": "Innovation Division", "FormOfAddress": "Mr.", "Title": "Dr.", "FirstName": "John", "LastName": "Doe", "Street": "Main St. 123", "Address2": "Floor 5, Apt 302", "PostalCode": "12345", "City": "Example City", "State": "Example State", "CountryIso": "DE", "VatID": "DE123456789", "PhoneNumber": "+49 1234 445556661", "MobilePhoneNumber": "+49 160 123 4567", "EmailAddress": "example@email.com", "Fax": "+49 1234 4455566615" }, "InvoiceDate": "2023-02-01T12:45:00.0000000+00:00", "InvoicePaymentDetails": { "PaymentMethodId": 12, "PaymentStatus": "TODO", "TotalGrossAmount": 19.99, "CurrencyIso": "TODO", "CurrencyFactor": 1.37, "StillToPay": 0, "PaymentTarget": 0, "CashDiscount": 5, "CashDiscountDays": 2, "StopPaymentRequest": false, "DunningLevel": 0, "NextDueDate": "2023-02-01T12:45:00.0000000+00:00" }, "ColorcodeId": 2, "DunningBlock": false, "IsExternalInvoice": false, "Comment": "an additional order comment", "CustomerComment": "an additional customer comment", "IsCancelled": false, "LanguageIso": "DE", "CancellationDetails": { "CancellationReasonId": -4, "CancellationComment": "Change of mind (once again); we should consider terminating the customer relationship", "Date": "2023-02-01T12:45:00.0000000+00:00" } }
This is the name of your application, in this case "MyApp/1.0.0". It is used to identify your application.
This is where the version number of your application is entered, in this case "1.0.0".
The User-Id as int or uuid to run the Request, a JTL-Wawi user can be specified to perform an API call on their behalf (more details in the documentation, Optional). To use the Header, you must have the needed Scope 'Application.RunAs'
curl -i -X GET \
'https://developer.jtl-software.com/_mock/products/erpapi/1.0-cloud/openapi/invoices/{invoiceId}/lineitems' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'api-version: string' \
-H 'tenant-id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-H 'x-appid: string' \
-H 'x-appversion: string' \
-H 'x-runas: string'
The requested line items.
Unique ID to identify a sales order line item.
Type of the sales invoice item.0=CustomLineItem | 1=Item | 2=Shipping | 3=Coupon | 4=Voucher | 5=Payment | 6=ShippingSurcharge | 7=NewCustomerCoupon | 8=CashOnDelivery | 9=ShippingSurchargeItem | 10=GiftWrapping | 11=GiftForFree | 12=TrustedShops | 13=InterestPremium | 14=ProcessingFee | 15=Carton | 16=ReturnDelivery | 17=MultiPurposeVoucher | 18=MultiPurposeVoucherDigital | 19=SinglePurposeVoucher | 20=SinglePurposeVoucherDigital | 21=SinglePurposeVoucherRedemption
The price for which the merchant has bought the item.
[ { "Id": 1123, "InvoiceId": 12, "SalesOrderId": 12, "SalesOrderLineItemId": 12, "ItemId": 1000, "Name": "Awesome Binoculars", "SKU": "ART2394871", "Type": "TODO", "Quantity": 2, "SalesUnit": "stk", "SalesPriceNet": 16.8, "SalesPriceGross": 19.99, "Discount": 5, "PurchasePriceNet": 13.46, "TaxRate": 19 } ]
This is the name of your application, in this case "MyApp/1.0.0". It is used to identify your application.
This is where the version number of your application is entered, in this case "1.0.0".
The User-Id as int or uuid to run the Request, a JTL-Wawi user can be specified to perform an API call on their behalf (more details in the documentation, Optional). To use the Header, you must have the needed Scope 'Application.RunAs'
curl -i -X POST \
'https://developer.jtl-software.com/_mock/products/erpapi/1.0-cloud/openapi/invoices/{invoiceId}/output/mail?formId=0' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'api-version: string' \
-H 'tenant-id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-H 'x-appid: string' \
-H 'x-appversion: string' \
-H 'x-runas: string'
This is the name of your application, in this case "MyApp/1.0.0". It is used to identify your application.
This is where the version number of your application is entered, in this case "1.0.0".
The User-Id as int or uuid to run the Request, a JTL-Wawi user can be specified to perform an API call on their behalf (more details in the documentation, Optional). To use the Header, you must have the needed Scope 'Application.RunAs'
curl -i -X POST \
'https://developer.jtl-software.com/_mock/products/erpapi/1.0-cloud/openapi/invoices/{invoiceId}/output/pdf?formId=0' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'api-version: string' \
-H 'tenant-id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-H 'x-appid: string' \
-H 'x-appversion: string' \
-H 'x-runas: string'
"string"
This is the name of your application, in this case "MyApp/1.0.0". It is used to identify your application.
This is where the version number of your application is entered, in this case "1.0.0".
The User-Id as int or uuid to run the Request, a JTL-Wawi user can be specified to perform an API call on their behalf (more details in the documentation, Optional). To use the Header, you must have the needed Scope 'Application.RunAs'
curl -i -X POST \
'https://developer.jtl-software.com/_mock/products/erpapi/1.0-cloud/openapi/invoices/{invoiceId}/output/print?formId=0&printer=string' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'api-version: string' \
-H 'tenant-id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-H 'x-appid: string' \
-H 'x-appversion: string' \
-H 'x-runas: string'
This is the name of your application, in this case "MyApp/1.0.0". It is used to identify your application.
This is where the version number of your application is entered, in this case "1.0.0".
The User-Id as int or uuid to run the Request, a JTL-Wawi user can be specified to perform an API call on their behalf (more details in the documentation, Optional). To use the Header, you must have the needed Scope 'Application.RunAs'
curl -i -X POST \
'https://developer.jtl-software.com/_mock/products/erpapi/1.0-cloud/openapi/invoices/{invoiceId}/workflow/{workflowEventId}' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'api-version: string' \
-H 'tenant-id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-H 'x-appid: string' \
-H 'x-appversion: string' \
-H 'x-runas: string'
This is the name of your application, in this case "MyApp/1.0.0". It is used to identify your application.
This is where the version number of your application is entered, in this case "1.0.0".
The User-Id as int or uuid to run the Request, a JTL-Wawi user can be specified to perform an API call on their behalf (more details in the documentation, Optional). To use the Header, you must have the needed Scope 'Application.RunAs'
The workflow event.
curl -i -X POST \
'https://developer.jtl-software.com/_mock/products/erpapi/1.0-cloud/openapi/invoices/{invoiceId}/workflowEvents' \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'Content-Type: application/json' \
-H 'api-version: string' \
-H 'tenant-id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-H 'x-appid: string' \
-H 'x-appversion: string' \
-H 'x-runas: string' \
-d '{
"Id": 1
}'
This is the name of your application, in this case "MyApp/1.0.0". It is used to identify your application.
This is where the version number of your application is entered, in this case "1.0.0".
The User-Id as int or uuid to run the Request, a JTL-Wawi user can be specified to perform an API call on their behalf (more details in the documentation, Optional). To use the Header, you must have the needed Scope 'Application.RunAs'
curl -i -X GET \
https://developer.jtl-software.com/_mock/products/erpapi/1.0-cloud/openapi/invoices/workflowEvents \
-H 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
-H 'api-version: string' \
-H 'tenant-id: 497f6eca-6276-4993-bfeb-53cbbbba6f08' \
-H 'x-api-key: YOUR_API_KEY_HERE' \
-H 'x-appid: string' \
-H 'x-appversion: string' \
-H 'x-runas: string'
[ { "Id": 1, "Name": "Wawi workflow name" } ]