AgileApps Support Wiki Pre Release

Difference between revisions of "REST API:field Resource"

From AgileApps Support Wiki
imported>Aeric
imported>Aeric
Line 16: Line 16:
;URI:<tt>{{platformURL}}/rest/field/{objectName}</tt>
;URI:<tt>{{platformURL}}/rest/field/{objectName}</tt>
;Response:An array of metadata structures containing definitions of all the fields in the object, as described in the [[REST API/Payload Examples]].
;Response:An array of metadata structures containing definitions of all the fields in the object, as described in the [[REST API/Payload Examples]].
See also: [http://lj.platformatyourservice.com/~platfor1/V7/javadocs/fields/ JavaDocs for fields ]


===Add a Field===
===Add a Field===

Revision as of 21:12, 23 July 2015

Manage Field metadata using the REST API.

Access Permissions

Lock-tiny.gif

Retrieve Field Metadata

Get metadata for a specific object field.

Method
GET
URI
https://{yourDomain}/networking/rest/field/{objectName}/{fieldName}
Response
Metadata structure that defines the field, as described in the REST API/Payload Examples.

Retrieve Metadata for All Fields in an Object

Retrieves an array of metadata for fields within an object

Method
GET
URI
https://{yourDomain}/networking/rest/field/{objectName}
Response
An array of metadata structures containing definitions of all the fields in the object, as described in the REST API/Payload Examples.

Add a Field

Add metadata for a new object field.

Method
POST
URI
https://{yourDomain}/networking/rest/field/{objectName}/{fieldName}
Request
As described in the REST API/Payload Examples
Response
<syntaxhighlight lang="xml" enclose="div">

<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <platform>

   <message>
       0
       <description>Success</description>
       <id>34813dcd768740ad91dc4f168023a9cc</id>  -- field ID
   </message>

</platform> </syntaxhighlight>

Update a Field Definition

Update field metadata.

Method
PUT
URI
https://{yourDomain}/networking/rest/field/{objectName}/{fieldName}
Request
As described in the REST API/Payload Examples
Response
<syntaxhighlight lang="xml" enclose="div">

<?xml version="1.0" encoding="UTF-8" standalone="yes"?> <platform>

   <message>
       0
       <description>Success</description>
   </message>

</platform> </syntaxhighlight>

Payload Examples