Follow

Generating GS1 QR Codes with GTIN and CPV Attributes Using APIs

Scantrust is designed to handle large volumes of codes efficiently. To accommodate this, new codes are generated asynchronously in the background using a work order system, ensuring scalability. Once created, the codes can be downloaded in a zip archive in Scantrust's Compact-12 format.

The Code Upload API enables brand owners to upload files containing their unique identifiers in any format, provided they meet the system’s length and character requirements (outlined below). GS1 identifiers are also supported. Using this API, users can assign different products to each code and select the relevant SCM fields.

The Code Upload API can generate two types of codes:

  • Serialized Identifiers (SID): These are Scantrust QR codes without the secure graphic. Brand owners can self-generate and download these codes without needing a printing partner.
  • Secure Codes (SSC): These include a copy-protection secure graphic and require a printing partner with calibrated equipment and specific substrates. These codes are linked to an existing work order (or uploaded via a template) with the secure graphic, which is then printed by the partner.

Scantrust supports 3 methods for uploading codes, in this article will focus on the first one:  Upload using an Ingestion Template (recommended). Following you'll find the steps to achieve this upload: 

 

Important, be sure to have this checklist, before setting the API call: 

  • Have the UAT tokens for the user who is going to set the API request, for further details, please check this article: Creating a User Authorization Token.  Here are the permissions required: 
    • workorder_view
    • workorder_download
    • workorder_sid_download
    • ingestion_view
    • ingestion_cancel
    • ingestion_code_create
    • product_view
  • If you are using Postman, please follow the recommendations we mention in this article: How to use Postman - Beginners Instructions

 

1. Please open Postman, in the home page you should be able to see the following:

Picture1.png

 

2. Then, please on the tap labeled: “Workspaces”, in the upper left corner: 

Picture2.png

 

3. Then, please click on the option labeled: “My workspace”: 

Picture3.png

 

4. Once you are in your workspace, please click on the “+” sign as follows: 

Picture4.png

 

5. After that, a new tab will appear with a preconfigured API request: GET:

Picture5.png 

 

6. Now, it is important to set up the API Authorization, to do that, please click on the tab labeled as:               “Authorization”: 

Picture6.png

 

7. Then, click on the "Type" section and select: the "API Key" option, as follows: 

Picture7.png

 

8. Now, type the word: "Authorization" on the key field, then copy your UAT token from the ST portal            and paste it into the field labeled as: “Value”, including the characters UAT: UAT [your token],                    leaving a spacebar between the UAT string and the token: 

Picture8.png

 

9. Then, go to the “Body” tab, select “raw” and select “JSON”:

Picture9.png

Steps to Upload Codes:

10. Set a POST request with this URL:

https://api.staging.scantrust.io/api/v2/ingestion/codes/create-from-template/

 

11. Then, set the body by following exactly this syntax: 

 

12. Click on: SEND, you should get a 200 OK response, with this result: 

13 Finally, if the process is successful, you will get an automatic email that confirms the ingestion. 

Was this article helpful?
0 out of 0 found this helpful
Have more questions? Submit a request

Comments