Hi @LeviRoberts, I am in the same boat as you with your second error.
The behaviour is described in this article here - Print maps that contain secured services
Essentially because your GIS Server has a self signed certificate (which you correctly noted is the standard practice), the print service is unable to use the Portal referrers token to access the secured services.
There are two workarounds, Short Term Tokens and Embedding credentials into a service:
Short Term Tokens:
- if your services have short term tokens enabled (which is default and recommended) then if you start your session by going directly to your web app, then you will be prompted to sign in to the web app. This will generate a token that is stored in the web map, which is then passed to the Print Service which can then successfully access your secure services. You should be able to replicate this easily - copy the URL of your web app, open an incognito/private browser window and paste your web app URL. Sign in to your portal account, and then you should be able to print any of your secured services.
This is obviously an annoying workaround.
Embedding credentials into a service:
- You can create a python script that uses the Convert Web Map To ArcGIS Project function, and embed credentials to your site into this script with the ImportCredentials function.
There are examples of how to use this in ConvertWebMapToArcGISProject example 8.
-------------------------------------------------------
This is where I am stuck, because I cannot get the script to work. We have no registered folders for our server so rely on copying the templates, but every way I try to use this function as per the example, I just get errors and fail the script.
Would love to know if anyone else has used this script and if they have the same errors, or are successful.
Now this is where