- URL:https://[root]/content/users/[userName]/items/[itemID]/createProxies(POST only)
Example Usage
URL for Create Proxies
https://www.arcgis.com/sharing/rest/content/users/jsmith/items/266800bbb6814b13be966c1c88a59c4c/createProxies
Description
The create proxies operation (POST only) creates proxy services that will store and manage credentials and provide authentication. The operation also allows to control over rate limits and allowed referrers to prevent runaway usage but enable publically accessible version of premium ArcGIS Online services.
The operation is only available on registered apps that have Registered App type keyword with the item. Upon successful completion of the operation, an App Proxy type keyword gets appended to the app item.
The operation is only available to the item owner and the organization administrator.
Request Parameters
Parameter | Details |
---|---|
[Common Parameters] | For a complete listing, see Common parameters. |
proxies | A JSON array representing the hosted service URLs to proxy. Set the hitsPerInterval and intervalSeconds on each service for different rate limits. A single array JSON can be passed if only setting one service. Example:
|
serviceProxyParams | A JSON object that provides referrer checks when accessing the premium content and optionally rate limiting if it is not set for each service in proxies. Example:
|
Response Properties
Property | Details |
---|---|
item | See Item for response properties. |
appProxies | A JSON array consisting of the hosted service URLs to proxy, proxy URLs, proxy IDs and optionally rate limiting for each service. Example:
|
serviceProxyParams | A JSON object representing allowed referrers and optionally rate limiting if it is not set for each service. Example:
|
JSON Response Syntax
{
"id": "<item id>",
"owner": "<owner username>",
"created": date created shown in UNIX time,
"modified": date modified shown in UNIX time,
"guid": <unique id>,
"name": "<item name>",
"title": "<item title>",
"type": "<type>",
"typeKeywords": [
"<keyword1>",
"<keyword2>",
"<keyword3>",
"<keyword4>"
],
"description": "<description>",
"tags": [
"<tag1>",
"<tag2>"
],
"snippet": "<summary>",
"thumbnail": <file name>,
"documentation": null,
"extent": [
[
minX,
minY
],
[
maxX,
maxY
]
],
"spatialReference": <coordinate system>,
"accessInformation": "<credits>",
"licenseInfo": "<access and use constraints>",
"culture": "<culture code>",
"url": "<url>",
"appProxies": [
{
"sourceUrl": "<hosted service URL to proxy1>",
"proxyUrl": "<proxy URL1>",
"proxyId": "proxy ID1"
},
{
"sourceUrl": "<hosted service URL to proxy2>",
"proxyUrl": "<proxy URL2>",
"hitsPerInterval": number of requests allowed per time interval,
"intervalSeconds": time interval in seconds,
"proxyId": "proxy ID2"
}
],
"access": "private | public | org | shared",
"size": <size>,
"serviceProxyParams": {
"hitsPerInterval": number of requests allowed per time interval,
"intervalSeconds": time interval in seconds,
"referrers": [
"<allowed referrer1>",
"<allowed referrer2>"
]
},
"numComments": <number of comments>,
"numRatings": <number of ratings>,
"avgRating": <average rating>,
"numViews": <number of views>
}
JSON Response Example
{
"id": "266800bbb6814b13be966c1c88a59c4c",
"owner": "jsmith33",
"created": 1455042490000,
"modified": 1455668874682,
"guid": null,
"name": null,
"title": "direction",
"type": "Web Mapping Application",
"typeKeywords": [
"JavaScript",
"Map",
"Mapping Site",
"Online Map",
"Web Map",
"Registered App",
"App Proxy"
],
"description": "This is a description.",
"tags": ["test"],
"snippet": null,
"thumbnail": null,
"documentation": null,
"extent": [],
"spatialReference": null,
"accessInformation": null,
"licenseInfo": null,
"culture": "en-us",
"url": "https://orgname.maps.arcgis.com/apps/Directions/index.html?appid=266800bbb6814b13be966c1c88a59c4c",
"appProxies": [
{
"sourceUrl": "https://route.arcgis.com/arcgis/rest/services/World/Route/NAServer/Route_World",
"proxyUrl": "https://utility.arcgis.com/sharing/appservices/23NxxdEqioSHtmDl/rest/services/World/Route/NAServer/Route_World",
"proxyId": "23NxxdEqioSHtmDl"
},
{
"sourceUrl": "https://hydro.arcgis.com/arcgis/rest/services/Tools/Hydrology/GPServer",
"proxyUrl": "https://utility.arcgis.com/sharing/appservices/j0e7E3hSGw1wQPWi/rest/services/Tools/Hydrology/GPServer",
"hitsPerInterval": 100,
"intervalSeconds": 60,
"proxyId": "j0e7E3hSGw1wQPWi"
}
],
"access": "org",
"size": 95,
"serviceProxyParams": {
"hitsPerInterval": 1000,
"intervalSeconds": 60,
"referrers": [
"https://foo.com",
"https://bar.com"
]
},
"numComments": 0,
"numRatings": 0,
"avgRating": 0,
"numViews": 13
}