Javascript API Proxy setup with Portal Federated Server

2636
1
Jump to solution
10-19-2015 12:54 PM
DaveHighness
Occasional Contributor II

Hi, I'm trying to figure out how to setup my Javascript API proxy.config "serverUrl" so it works with secured services on our Portal federated ArcGIS Server. I have not found any documentation that seems useful in this regard.

Our Portal is using default portal authentication and the ArcGIS Server is federated with the portal.

Do I use the ArcGIS Online style entry with clientId and clientSecret or do I use the ArcGIS Server token based pattern; username and password with tokenServiceUri? Or something else? Where does the token come from? Portal or Server?

If anyone could give me some examples, I would appreciate it.

Thanks, Dave

0 Kudos
1 Solution

Accepted Solutions
DaveHighness
Occasional Contributor II

I figured it out. Point the proxy to the Portal token page and give it the user and password with permission to use the service.

<?xml version="1.0" encoding="utf-8" ?>

<ProxyConfig allowedReferers="*" mustMatch="false">

<serverUrls>

<serverUrl

url="https://yourdomain.com/arcgis/"

username="youruser"

password="yourpass"

tokenServiceUri="https://yourdomain.com/portal/sharing/generateToken"

matchAll="true">

</serverUrl>

</serverUrls>

</ProxyConfig>

View solution in original post

0 Kudos
1 Reply
DaveHighness
Occasional Contributor II

I figured it out. Point the proxy to the Portal token page and give it the user and password with permission to use the service.

<?xml version="1.0" encoding="utf-8" ?>

<ProxyConfig allowedReferers="*" mustMatch="false">

<serverUrls>

<serverUrl

url="https://yourdomain.com/arcgis/"

username="youruser"

password="yourpass"

tokenServiceUri="https://yourdomain.com/portal/sharing/generateToken"

matchAll="true">

</serverUrl>

</serverUrls>

</ProxyConfig>

0 Kudos