Update Metadata

URL:
https://<root>/<serviceName>/FeatureServer/<layerId>/metadata/update
Methods:
POST
Version Introduced:
11.2

Description

The update operation updates the metadata for a hosted feature layer or table. When done, the operation returns a status URL that can be used to occasionally poll the status of the edits being made to the metadata. The status URL will return as COMPLETED once the edits have been made.

Request parameters

ParameterDetails

metadata

An XML object containing metadata for the layer.

Syntax

Use dark colors for code blocksCopy
1
2
3
metadata=[<metadata xml:lang="en">
….
</metadata>]

Example

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
metadata=<metadata xml:lang="en">
<Esri>
<CreaDate>20200118</CreaDate>
<CreaTime>15191300</CreaTime>
<ArcGISFormat>1.0</ArcGISFormat>
<SyncOnce>TRUE</SyncOnce>
</Esri>
<dataIdInfo>
<idCitation>
<resTitle>Cities</resTitle>
</idCitation>
<idAbs/>
<idCredit/>
</dataIdInfo>
</metadata>

f

The response format. The default format is html .

Values: html | json | pjson

Example usage

The following is a sample POST request for the update operation:

Use dark colors for code blocksCopy
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
POST /webadaptor/rest/services/SanFrancisco/311_Incidents/FeatureServer/0/metadata/update HTTP/1.1
Host: machine.domain.com
Content-Type: application/x-www-form-urlencoded
Content-Length: []

metadata=<metadata xml:lang="en">
<Esri>
<CreaDate>20200118</CreaDate>
<CreaTime>15191300</CreaTime>
<ArcGISFormat>1.0</ArcGISFormat>
<SyncOnce>TRUE</SyncOnce>
</Esri>
<dataIdInfo>
<idCitation>
<resTitle>Cities</resTitle>
</idCitation>
<idAbs/>
<idCredit/>
</dataIdInfo>
</metadata>
&f=pjson

JSON Response example

Use dark colors for code blocksCopy
1
{"statusUrl": "https://machine.domain.com/webadaptor/rest/services/Hosted/example/FeatureServer/jobs/jbd9bc06f-81d7-4512-bc1c-1add7e558419"}

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.