
SAP Global Track & Trace (GTT) can be used to capture, process and store tracking information about tracked business processes. A typical use case for GTT is for tracking ocean container shipments.
Postman can be used to quickly test and simulate the BN4L APIs without connecting to a backend carrier system. Best of all, it's free to use!
Below is a typical data flow. I have not shown any optional middleware.
In this blog I will show you how to connect the Carrier Tenant to a Postman Mock Server via a webhook API and how to post a tracking request.
More details on Postman mock server: https://learning.postman.com/docs/designing-and-developing-your-api/mocking-data/setting-up-mock/
PREREQUISITES
Shipper backend System is already connected to BN4L.
Shipper GTT is already connected to the Carrier Tenant (aka Data Contributor tenant).
STEP 1 - Get an API Key for the mock server
This will be used for authentication to the mock server. Note that this is an optional step because you can call the mock server with no authentication.
Step 2 – Create the Mock Server
a) In Postman click Create Mock Server (click on the Configure Workspace button if you can’t see Mock Servers):
b) Enter a new PUT request method. Give it a name that will be used to call it (e.g. "GTTTrackingRequest") and a Response text (e.g. "Tracking request successful"). Then click Next:
c) Enter a name for your mock server. Select 'make mock server private' if you want to use the API key created in Step 1a.
d) Mock server is ready!
e) Postman will automatically create a Collection that you can use to test or make changes.
STEP 2 – Configure the Carrier (Data Contributor) tenant.
a) In System Connections, select Manage Details then Communication Details. Add an HTTPS connection and assign a name and the url of the mock server from Step 1d.
b) In Authentication details add the api key from Step 1a.
c) System Connections. Create a new service using the communication and authentication just created.
Step 3 – Shipper Tenant – Partner Connections.
Add x-api-key and the api key from step 1a to the Custom Headers.
Step 4 – Test
Create a new shipment in your backend Shipper system that triggers a new tracking request idoc (or trigger a ShipmentEvent from the GTT Runtime).
In the Postman mock server logs you should see a payload and a Success message 😊
CONCLUSION
In this blog I showed how to quickly start testing tracking requests with BN4L GTT and Postman.
Next steps would be to replace the mock server with your own carrier system.
Further Details
SAP Help for GTT - https://help.sap.com/docs/business-network-global-track-and-trace
Help for carriers who want to join BN4L network:
https://help.sap.com/docs/business-network-logistics-provider
https://github.com/SAP-samples/logistics-business-network-integration
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
4 | |
2 | |
2 | |
1 | |
1 | |
1 | |
1 | |
1 |