Access Metadata

You can use the GET method to retrieve metadata about REST resources from their /describe endpoints. Each resource's metadata contains a comprehensive description, including the object resource URIs, attributes, supported actions, child resources, and list-of-value (LOV) resources.

Retrieving Metadata for a Specific Resource

Perform the GET operation on the resource using the following request URL syntax:

https://servername.fa.us2.oraclecloud.com/fscmRestApi/resources/<version>/<resource>/describe

Let's say you want to get the metadata for the announcements resource. Perform the GET operation using the following request URL:

https://servername.fa.us2.oraclecloud.com/fscmRestApi/resources/11.13.18.05/announcements/describe

You can use this cURL command to complete the operation:

curl -X GET -u <username:password> https://servername.fa.us2.oraclecloud.com/fscmRestApi/resources/11.13.18.05/announcements/describe HTTP/1.1 -H 'Content-Type: application/vnd.oracle.adf.resourceitem+json'  | json_pp

Retrieving Metadata for All Resources in an Application

To access the metadata for all resources hosted in an application, perform the GET operation using the following request URL:

https://servername.fa.us2.oraclecloud.com/fscmRestApi/resources/<version>/describe

You can use this cURL command to complete the operation:

curl -X GET -u <username:password> https://servername.fa.us2.oraclecloud.com/fscmRestApi/resources/11.13.18.05/describe HTTP/1.1 -H 'Content-Type: application/vnd.oracle.adf.resourceitem+json'  | json_pp

Such a request might return a very large result, but there might be times when you need to inventory all available resources.

Retrieving Minimal Metadata for All Resources in an Application

To limit the amount of metadata retrieved for an application, use the metadataMode parameter. Perform the GET operation using the following request URL:

https://servername.fa.us2.oraclecloud.com/fscmRestApi/resources/<version>/describe?metadataMode=minimal

You can use this cURL command to return only the resources:

curl -X GET -u <username:password> https://servername.fa.us2.oraclecloud.com/fscmRestApi/resources/<version>/describe?metadataMode=minimal HTTP/1.1 -H 'Content-Type: application/vnd.oracle.adf.resourceitem+json'  | json_pp

Note:

You cannot use the metadataMode parameter to access the metadata for a specific resource.

If your application has a large number of custom objects, you can use the metadataMode parameter to retrieve a smaller response much faster.

Retrieving Metadata in Your Preferred Language

If you want to retrieve the metadata in your preferred language, you can use the Accept-Language header in the GET request. Include the Accept-Language header in the cURL command and provide the language short code as its value. For example, to retrieve the metadata in Turkish, use tr as the Accept-Language header value.

Run the cURL command as shown here:

curl -X GET -u <username:password> https://servername.fa.us2.oraclecloud.com/fscmRestApi/resources/11.13.18.05/partnerTypesLOV/describe \  
  -H 'Accept-Language: tr' \
  -H 'Content-Type: application/vnd.oracle.adf.resourceitem+json'

The response contains the translated metadata.

Response displaying the translated labels

You can see that the values for title and titlePlural appear translated in Turkish. In English, these would appear as Partner Type and Partner Types.

Note:

The translation applies only to the customer-facing labels and depends on the internationalization settings defined in the application implementation.