1301 - Attach a file to the existing PN

Step 1: Obtain a security token


 

Open [Postman] (https://www.postman.com) and create a new request. 

Set the request type to POST (in the drop-down menu to the left of the URL). 

  1. Enter URL: https://prod2022.plugnotes.com/Apis/External/GetToken.php
  2. In the header section, add a key: X-API-KEY
  3. For the value, enter the unique key given by Plugnotes  

Press “Send” to obtain: 
-token  
-uh 

Result From Step 1: 

Once the request has been sent, you should see this just below the parameters you filled in: 

 

Step 2: Using the API

Using the security token, create a new POST request. 

  1. Set the URL to: https://prod2022.plugnotes.com/Apis/External/1301_attach_file_to_existing_pn.php
  2. In the header section, add a key: X-AUTH-TOKEN
  3. For the value, it's the token from the previous request in “Result from Step 1”.


1. You then need to go to the Body section and select “raw”.

2. Once you have done that, you need to fill in the “uh”, “num_pf” (or “pn_hash”), “annex” and “filename”:

 “uh”: From the previous request.

“num_pf”: the number of the Plugnote. Mandatory if you do not provide the pn_hash

“pn_hash”:  the hash of the Plugnote. Mandatory if you do not provide the num_pn

Note: The Plugnote you are trying to update has to be in the right Pf_key (Pf_key stipulated when building your web service)!

“annex”: the file you want to put (in base 64)

“filename”: Name it like you want it to show

Result From Step 2

After filling everything you can send the request and it should look like this:

Result: 

  • If successful, you'll receive confirmation;
  • In the event of a problem, an error message will be provided. 

Note: Be sure to complete each step before proceeding to the next. In the event of a problem, consult the error message for assistance. 


--
Customer Success
If you have any questions, please contact our Customer Success Team