Custom Shapes

A shape is the structure of the data for a resource. For example, for the shipments resource, a shipment contains stops, a stop contains sShipUnits, and an sShipUnit contains lines. You can't change that structure. However, for special situations an alternative structure is available. For example, when a shipment contains stops and sShipUnits as a direct child record, and not nested under the stops. This alternative structure is a custom shape. You must specify which shape to use via the glog.fusion.cil.config.defaultShape property.

The property takes this structure:

glog.fusion.cil.config.defaultShape.<version>.<resource name>=<custom name>

For example, to make the custom shape "abcd" the default shape for the shipments resource name, set the following:

glog.fusion.cil.config.defaultShape.v2.shipments=abcd

Note:

When sending outbound JSON for any business object, the OTM uses the default shape based on the glog.fusion.cil.config.defaultShape.v2 property.
Your options for using custom shapes include:
  • To use the standard shape, make a GET call using the standard resource, without defining the property.
  • To use a custom shape, make a Get call for the standard resource with the property set for the preferred custom shape.
  • Or, to use a custom shape, make a Get call using the custom shape as the resource name.

Table - Available Custom Shapes

Resource Custom Shape Custom Shape Description Default Shape
customsDeclarations customsDeclarationWithoutTradeLicenses This shape doesn't contain any Trade Licenses information. The default shape (customsDeclarations) includes Trade Licenses information as part of the customsDeclarations resource. customsDeclarations
items itemsWithProdClassCodeGid This shape includes both the Product Classification Code and the Product Classification Code ID (ProdClassCodeGid) attributes as part of the items resource. The default shape (items) only allows the Product Classification Code and excludes the Product Classification Code ID for the items resource. items
shipments shipmentNoSSUs This shape doesn't contain sShipUnits as a direct child of the shipments root resource. sShipUnits are included as a part of shipment stop details child resource. shipments
tradeTransactions tradeTransactionsWithoutTradeLicenses This shape doesn't contain any Trade Licenses information. The default shape (tradeTransactions) includes Trade Licenses information as part of the tradeTransactions resource. tradeTransactions

The available shapes are described below.

customsDeclarations

The default shape called customsDeclarations contains the trade license information as a sub-resource within customsDeclarations/lines/licenses. TradeLicenses are available in a read-only capacity.

items

This default shape only includes the Product Classification Code as an attribute of the items resource. This structure supports the creating and updating of product classification information as part of item create and/or update.

Note:

Oracle recommends the use of the classification code over the ProdClassCodeGid. In a future release, the ProdClassCodeGid will be deprecated and removed.

shipments

shipmentNoSSUs - Enhanced Shipment Ship Unit Support

In the OTM 23 release, the default structure for shipments was redefined. The shipments resource contained shipment ship unit information in a read-only capacity. In addition, the content appeared within the shipment stop detail and in a redundant manner, that is, the same ship unit information appeared multiple times; once for the pick up stop and once for the drop off stop.

The ship unit information now appears once as an immediate child resource of the shipment and will not appear under each stop detail. This structure supports the creating and updating of shipment ship units as part of the shipment create and/or update.

This structure was implemented as the default resource structure for the shipments resource for all new customers as of the OTM 23 release. However, if you were using OTM before the OTM 23 release, you were using the original structure. To support the older functionality, your systems were set to see the original structure when the shipments resource name is used. This has been achieved by defining a custom shape call shipmentNoSSUs ,which correlates to the original structure, and staging a default shape property in the CUSTOM property set so that requests for the shipments resource uses the shipmentNoSSUs shape. Setting the property this way for you preserved backward compatibility:

glog.fusion.cil.config.defaultShape.v2.shipments=shipmentNoSSUs
To use the new shape/structure as the default, after evaluation of the new shape, remove the above property definition from the CUSTOM property set.

tradeTransactions

The default shape called tradeTransactions contains the trade license information as a sub-resource within tradeTransactions/lines/licenses. TradeLicenses are available in a read-only capacity.