JSON (RESTful) Operations

Provides important specifications for creating JSON (RESTful) service interface operations.

When defining a JSON (RESTful) service interface, you have the option to create a set of operations based on the group structures in the selected COBOL entry point. You are presented with a set of options via the API Resources wizard. The options that appear on this wizard are derived from the COBOL entry point specified for the service interface.

Tip: We recommend that you work through Tutorial: JSON RESTful Web Service using API Resources to become familiar with this feature.

The API Resources wizard presents one resource entry for each COBOL group item in the chosen entry point. In general, the default methods selected for each resource are a GET operation for retrieving the group item, and a PUT operation for updating the item. However, for each COBOL group item defined with a nonzero OCCURS clause (i.e., an array), two separate resource entries are presented as follows:

The default relative path provided for each COBOL resource listed on the API Resources wizard is derived from the field groupings defined in the resource, and represents the relative path portion of the request URI. See HTTP Method/Path for details.

Important: Before you click OK to create the operations, you may select any or all resources listed on the API Resources wizard, and also modify the default path and method settings for any selected resource. See To generate new API resource operations for details.

Enterprise Developer creates a new and separate operation for each selected method of each selected resource. For example, if you select both a GET and PUT method for a single selected resource, Enterprise Developer creates two operations - one for the GET method and one for the PUT method.

The resulting operations are defined as follows:

The following topics provide important details about JSON (RESTful) service interface concepts: