POST
|
I have a web map that I wish to share with a group in ArcGIS Enterprise. Using the Portal, I can share the map with the group: However, if I try to share the same map with the same group using the Python API, the map cannot be shared with the group: cbmt.share(org=True, groups=basemaps_group.title)
{'notSharedWith': ['Basemaps / Cartes de base'],
'itemId': '21e8f2ab90904f4ba38e44386f03851c'}
Note that I am able to successfully share other maps (e.g., Esri basemaps) with this group within the same script. Why can't I share the map with the group using the Python API?
... View more
02-05-2019
05:28 AM
|
1
|
9
|
5892
|
POST
|
Hi Shana! It turns out that there's an "undocumented" "feature" at work here with the REST API. In addition to the documented parameters, there's a `callback` parameter; if the client provides a value for this (which Portal for ArcGIS does), then the service needs to wrap the response in the provided callback. Once I did this, then it worked correctly. Thanks, Jon.
... View more
01-30-2019
08:09 AM
|
0
|
0
|
528
|
POST
|
I've created a custom GeocodeServer according to the ArcGIS Rest API specification. To this point, I've implemented the root (GeocodeServer), findAddressCandidates, and suggest, and referenced the custom GeocodeServer as a utility service in Portal for ArcGIS. In the Portal map viewer, I've selected the custom GeocodeServer from the Find dropdown list, and enter some text. No suggestions are shown, and, when I press Enter, no candidates are found. Looking at the console reveals a SyntaxError for both the suggest and findAddressCandidates requests: Looking at the response from the custom GeocodeServer for a call to suggest: it appears to have the same syntax as the response from the ArcGIS World Geocoding Service: The same is true for calls to the findAddressCandidates method. For the custom GeocodeServer: and for the ArcGIS World Geocoding Service: I do note, however, that the response headers are somewhat different. For the custom GeocodeServer, a response from suggest has the following response headers: HTTP/1.1 200 OK
Cache-Control: no-cache
Pragma: no-cache
Transfer-Encoding: chunked
Content-Type: application/json; charset=utf-8
Content-Encoding: gzip
Expires: -1
Vary: Accept-Encoding
Server: Microsoft-IIS/10.0
X-AspNet-Version: 4.0.30319
X-Powered-By: ASP.NET
Date: Thu, 03 Jan 2019 14:57:10 GMT whereas from the ArcGIS World Geocoding Service, the response headers are: HTTP/2.0 200 OK
date: Thu, 03 Jan 2019 14:58:47 GMT
content-type: application/json;charset=UTF-8
content-length: 331
vary: Origin
access-control-allow-origin: https://devweb.tcgis.ca
access-control-allow-credentials: true
cache-control: max-age=0,must-revalidate
server:
set-cookie: AGS_ROLES="419jqfa+uOZgYod4xPOQ8Q=="; Version=1; Max-Age=60; Expires=Thu, 03-Jan-2019 14:59:47 GMT; Path=/arcgis/rest; HttpOnly
etag: 73d496d8
content-encoding: gzip
X-Firefox-Spdy: h2 But, I'm not exactly sure which, if any of these, would cause the SyntaxError. Any ideas appreciated.
... View more
01-03-2019
07:00 AM
|
0
|
2
|
675
|
IDEA
|
In ArcGIS Enterprise, the administrator chooses the default basemap for an organization. However, not all users within an organization will want to use the same basemap. Please allow users to choose their own preferred basemap.
... View more
12-17-2018
09:31 AM
|
5
|
0
|
181
|
IDEA
|
While a workable technical solution, this may not be possible for policy / privacy reasons. In some cases, the organization may have reason to prevent users from making items public. In other cases, privacy or security concerns may prohibit a map (and its layers!) from being made public ... but it's still valid to share within an organization or group and to embed the map into a web site that's available within the organization or group.
... View more
12-10-2018
10:25 AM
|
0
|
0
|
1522
|
POST
|
Hi Dan, Sort of. NAP is close to what I need, but HNAP is a modification of NAP. Jon.
... View more
11-22-2018
06:47 AM
|
0
|
1
|
1097
|
POST
|
The Government of Canada has developed the Harmonized North American Profile (HNAP) of ISO 19115:2003. It extends ISO 19115:2003 (NAP), mainly to include bilingual data elements, but also specific codelists, keywords, organization names, and other business rules. Specifically to bilingual data elements, HNAP specifies that, for example, the title must be represented in both English and in French. It does so by modifying the representation in ISO 19115:2003 (NAP): <identificationInfo> <MD_DataIdentification> <citation> <CI_Citation> <title> <gco:CharacterString>English Title</gco:CharacterString> </title> </CI_Citation> </citation> </MD_DataIdentification> </identificationInfo> as follows: <identificationInfo> <MD_DataIdentification> <citation> <CI_Citation> <title> <gco:CharacterString>English Title</gco:CharacterString> <PT_FreeText> <textGroup> <LocalisedCharacterString local="#fra">Titre français</LocalisedCharacterString> <textGroup> </PT_FreeText> </title> </CI_Citation> </citation> </MD_DataIdentification> </identificationInfo> However, when the latter is imported into ArcGIS, then exported back to XML, these extra tags have been stripped from the metadata record. So, my question is, can ArcGIS Pro be extended to support extensions to the supported metadata standards and styles?
... View more
11-21-2018
05:18 AM
|
2
|
4
|
1376
|
POST
|
I'm trying to set the AGOL utility services used by a Portal using the Python API. After setting them up through the Portal UI, I can see that the URL to the AGO World Closest Facility service, for example, is: https://<domain>/portal/sharing/servers/7f5b6ab8ac444bf685520f0e642079c8/rest/services/World/ClosestFacility/NAServer/ClosestFacility_World but I also know that my login credentials are used to access the AGOL services, and I'm assuming that they're encrypted in the ID portion of the URL (the portion between /servers/ and /rest/). So, if this is the case, can I assume that this URL can be used to access the utility services, provided that the login credentials remain invalid? In that case, I can use the GIS.update_properties() method to pass in a dictionary representing the utility services. Or, is there another place in the API that I can set the AGOL utility services by passing in the login credentials?
... View more
11-06-2018
11:22 AM
|
0
|
0
|
276
|
POST
|
I want to create a new Web Map item using the Python API. I manually created a Web Map with the correct configuration, and then used Item.get_data() to get a JSON representation of the Web Map, which is as follows: {
"operationalLayers": [],
"baseMap": {
"baseMapLayers": [{
"id": "CBMT_CBCT_GEOM_3857_8319",
"layerType": "ArcGISTiledMapServiceLayer",
"url": "http://geoappext.nrcan.gc.ca/arcgis/rest/services/BaseMaps/CBMT_CBCT_GEOM_3857/MapServer",
"visibility": true,
"opacity": 1,
"title": "CBMT_CBCT_GEOM_3857"
}, {
"id": "CBMT_TXT_3857_1321",
"layerType": "ArcGISTiledMapServiceLayer",
"url": "http://geoappext.nrcan.gc.ca/arcgis/rest/services/BaseMaps/CBMT_TXT_3857/MapServer",
"visibility": true,
"opacity": 1,
"title": "CBMT_TXT_3857",
"showLegend": true
}],
"title": "The Canada Base Map - Transportation (CBMT)"
},
"spatialReference": {
"wkid": 102100,
"latestWkid": 3857
},
"authoringApp": "WebMapViewer",
"authoringAppVersion": "10.6.1",
"version": "2.11"
} I then saved this to a JSON file, CBMT.json. Next, I tried to create a new Web Map using this JSON as a template: item_properties = {
"type": "Web Map",
"tags": "basemap",
"access": "org"
}
cbmt = tc_gis.content.add(item_properties, "CBMT.json", folder = "Basemaps") The portal item is created, however, the web map appears to not be valid. In Portal, clicking on the Settings tab on the Portal item hangs, as does trying to open the web map in the map viewer.
... View more
11-06-2018
10:45 AM
|
0
|
3
|
989
|
IDEA
|
Currently, there's no way to change the basemap of a WebMap using the Python API. The basemap property is read-only, and there doesn't appear to be a way to set it.
... View more
11-05-2018
05:15 AM
|
3
|
0
|
544
|
POST
|
Using the ArcGIS Python API, I've create a WebMap and two Layers (one containing features, the other containing labels): cbmt = WebMap()
cbmt_geometry_layer = Layer(url = <url of geometry layer>)
cbmt_text_layer = Layer(url = <url of text layer>) I'd like to add both of these layers to the map as basemap layers, like you can in ArcGIS Online or Portal when adding layers to a web map. The WebMap.basemap property is read-only. Is there a property on the WebMap.add_layer() method that specifies to add layers as basemap layers? xref: How to set the basemap layers of a WebMap using the ArcGIS Python API? - Geographic Information Systems Stack Exchange
... View more
11-02-2018
08:11 AM
|
1
|
0
|
1211
|
POST
|
For sandboxing purposes, I'd like to be able to test something on a clean instance of Portal, without taking down the portal instance that my team members are using. Is it possible to create another instance of Portal on the same machine, or am I going to have to spin up a new machine?
... View more
10-31-2018
06:17 AM
|
0
|
2
|
526
|
Title | Kudos | Posted |
---|---|---|
1 | 02-19-2013 08:18 AM | |
1 | 08-13-2015 06:54 AM | |
2 | 01-17-2017 09:02 AM | |
1 | 03-25-2019 09:53 AM | |
1 | 03-26-2019 04:52 AM |
Online Status |
Offline
|
Date Last Visited |
12-10-2020
03:10 PM
|