Include control parameters with HTTP requests to alter the way that the REST Web Services handle them. For example, if you would like the server to include an identifying string in the response, you can use the atg-rest-user-input control parameter to specify that identifying string.

You can include control parameters either in the URL for the REST Web Service or in the message body of a POST or PUT request.

Note: Several control parameters have equivalent configuration properties. Set these configuration properties to control the way that REST MVC Web Services are processed by default. See The REST MVC Definition Framework.

The following table explains the control parameters recognized by the REST Web Services server.

Parameter

Explanation

atg-rest-class-descriptor

Use this parameter to specify the container and element Java classes for nested object property values.

atg-rest-class-type

Use this parameter to specify a Java class when you are setting an object property value.

atg-rest-index

Use this parameter to specify the entry in an array or ordered list that will be the starting point when that array or ordered list is returned by the server. Set the value of the parameter to the integer value of the starting position.

Use this parameter with atg-rest-count.

atg-rest-input

Use this parameter to override the default input format configured for the server.

Set the value of this parameter to json or xml.

atg-rest-json-input

Use this parameter to control whether the REST Web Services server will accept standard JSON markup for setting collection or map values on repository item properties.

atg-rest-method

Use this parameter to specify the Java method signature when calling an overloaded method.

This parameter is only needed if two or more instances of the overloaded method have the same number of arguments.

atg-rest-null

Use this parameter to set the value of a component or repository item property to null. Set the property and include this parameter as the new value.

atg-rest-output

Use this parameter to override the default output format configured for the server. Set the value of this parameter to json or xml.

atg-rest-param-class-types

Use this parameter to specify the Java classes for multiple values in JSON functional parameters. The atg-rest-param-class-types parameter includes three components, container-class, element-class, and key-class.

For example, if a functional parameter is a java.util.ArrayList<String>, set the atg-rest-param-class-types as shown below.

{'container-class':
'java.util.ArrayList',
'element-class':'java.lang.String'}

Use the key-class attribute when the container-class implements java.util.Map. For example:

{'container-class':'java.util.HashMap',
'key-class':'java.lang.String',
'element-class':'java.lang.String'}

atg-rest-simple-response-codes

Include this parameter to cause the server to return OK (200) for success rather than CREATED (201) or GONE (410).

atg-rest-transient

Use this parameter to create transient repository items.

atg-rest-user-input

Use this parameter to specify an identifying string that the REST Web Services server will include in the HTTP response.


Copyright © 1997, 2017 Oracle and/or its affiliates. All rights reserved. Legal Notices