Okay, my reply is long overdue. But I have reached resolution!
I attempted to follow the documentation for the DotNet proxy on GitHub by inspecting examples and also followed the instructions here : on the "Manage Apps" section on the docs.arcgis.com site
In actuality there are three workflows that I've found. Items one and two will necessitate a proxy if you are to utilize AGOL items and wish to employ your web server's security. Item three will not require a proxy, but might require you to keep the Web Appbuilder version in sync with the Github LocalLayer Widget. I also believe that item three will not have any 1's and 0's going to agol either during client sessions.
- AGOL Web Appbuilder (download your code after configuration in AGOL). -- The example below
- Developer Edition Web Appbuilder
- Developer Edition Web Appbuilder with LocalLayer Widget : Bypassing AGOL Items
Here's the variables:
---------------------------------------------------------
1. The Proxy Config:
<?xml version="1.0" encoding="utf-8" ?>
<ProxyConfig allowedReferers="*"
mustMatch="true">
<serverUrls>
<serverUrl url="https://services.arcgisonline.com"
matchAll="true"/>
<serverUrl url="https://mysite.com"
matchAll="true"
/>
<serverUrl url="https://myorg.maps.arcgis.com/"
clientId="1111111111111111"
clientSecret="22222222222222222222222222222222"
oauth2Endpoint="https://myorg.maps.arcgis.com/sharing/oauth2/"
rateLimit="600"
rateLimitPeriod="60"
matchAll="true">
</serverUrl>
</serverUrls>
</ProxyConfig>
<!-- See https://github.com/Esri/resource-proxy for more information -->
--------------------------------------------------------------
2. The Json code to add at the end of your config.json
"httpProxy" : {
"useProxy" : true,
"url" : "https://mysite.com/DotNet/proxy.ashx",
"alwaysUseProxy" : false,
"rules" : [{
"urlPrefix" : "https://myorg.maps.arcgis.com/",
"proxyUrl" : "/DotNet/proxy.ashx"
}
]
}
-------------------------------------------------------------------------------------------------------------
3. The Requisite Configurable App Registration Information on AGOL
URL: https://mysite.com/mywebapp
API: JavaScript
App Type: browser
Purpose: Configurable
Redirect URI's: http://mysite.com, https://mysite.com