How to Access secured Geocortex REST API pages that require sign in via scripting (Python)
I have a bunch of python script to generate reports on our Geocortex sites that pull the information from the REST interface. I’d like the scripts to be able to also access pages/sites that require the user to login. I can’t figure out how to script a request to get the script access to these pages.
In ArcGIS Server REST API you can send a request to the server to get a token, supplying your username/password credentials and then using that token, you can access secured pages. There are python sample code snippets to show this process on their help pages.
With Geocortex from what it looks like, accessing the sign in page, the server generates a token for you, which you resubmit as a parameter in a POST with your username and password as “name”, “secret” value pairs in the body.
This generates a cookie which when the REST api discovers it, will validate you as logged in. All this is a bit more complex and I’m not sure if I’ve got it right.
Any advice on the specific process and/or python ways to automated would be welcomed.
Details:
We’re using windows authentication.
Sign In page usually looks like this:
[your domain]/Geocortex/Essentials/DefaultCOSA/REST/security/callback/windows/form/[some random string?]?token=[your token]
0
-
I have the same question. and when I click on the API help buton http://docs.geocortex.com/essentials/apis/rest/ it returns 404 error. Could Latitude please fix the API doc page? thank you. 0 -
Looking to do the same, has anyone figured out how or can point to any documentation? 0
Bitte melden Sie sich an, um einen Kommentar zu hinterlassen.
Kommentare
2 Kommentare