---
schema_version: "1"
id: afedef4a4bbef665c368d534a14842a7710c51db74da1f1b0c8436ef1633e0c1
title: Retrieve Child Items Using TMF620 API
collection: developer
version: current
locale: en-us
portal_url: https://docs.salesforce.com/developer/current/en-us/industries-integrations/comms/guides/TMF620/retrieve_child_items_using_TMF620_API.md
canonical_url: https://developer.salesforce.com/docs/industries/communications/guide/retrieve_child_items_using_TMF620_API.html
source_site: developer.salesforce.com
content_type: documentation
content_hash: a98e68cf8a7230b7c6e61e766b6afe65ec2ea9001c2dea2deb9df9655ae822bd
products:
  - Communications Cloud TM Forum API
  - Industries Integrations
---
# Retrieve Child Items Using TMF620 API

Create [custom metadata](https://developer.salesforce.com/docs/industries/communications/guide/tmf620_custom_metadata.md) and update the Data Mapper Transform in Salesforce for the specific resource to retrieve child items from TMF620 Product Catalog Management API resources. By default, the API returns the parent-bundled items in the response.

**note:** - With these changes, the GET and POST APIs for all TMF 620 API resources return the child items in the responses.
- To retrieve child products information, set `Specification Sub Type = Bundle` for the product specifications or offerings created through Vlocity Product Designer or Console App.

## Create custom metadata

1.  From Setup, in the Quick Find box, enter `Metadata`, and then click **Custom Metadata Types**.
2.  Click **Manage Records** associated with Vlocity Integration Setting.
3.  Click **New**.
4.  Create the TMForumDefaultAttributeCategory custom metadata with these values:
    - Label: `TMForumDefaultAttributeCategory`
    - Type of API: `TMForum`
    - API Name: `TMForumDefaultAttributeCategory`
    - Key: `AttributeCategoryName`
    - Default Value: `TMForum`
    - Vlocity Integration Setting Name: `TMForumDefaultAttributeCategory`
5.  Create the TMForumProductSpecificationUseChildForBu custom metadata for the productSpecification resource with these values:
    - Label: `TMForumProductSpecificationUseChildForBu`
    - Type of API: `TMForum`
    - API Name: `TMForumProductSpecification`
    - Key: `UseChildForBundleProduct`
    - Default Value: `true`
    - Vlocity Integration Setting Name: `TMForumProductSpecificationUseChildForBu`
6.  Create the TMForumProductOfferingUseChildForBu custom metadata for the productOffering resource with these values:
    - Label: `TMForumProductOfferingUseChildForBu`
    - Type of API: `TMForum`
    - API Name: `TMForumProductOffering`
    - Key: `UseChildForBundleProduct`
    - Default Value: `true`
    - Vlocity Integration Setting Name: `TMForumProductOfferingUseChildForBu`
7.  Create the TMForumAllFieldstoQuery custom metadata, which is required for both the productSpecification and productOffering resources, with these values:
    - Label: `TMForumAllFieldstoQuery`
    - Type of API: `TMForum`
    - API Name: `TMForum`
    - Key: `AllFieldstoQuery`
    - Default Value: `true`
    - Vlocity Integration Setting Name: `TMForumAllFieldstoQuery`

## Update Data Mapper Transform

1. Update the TMFTMForumProductSpecificationResponseTransform Data Mapper Transform for the productSpecification resource.
   1. On the OmniStudio DataRaptors tab in the OmniStudio app, access the TMFTMForumProductSpecificationResponseTransform Data Mapper Transform.
   2. Modify the mapping for the bundledProductSpecification node to use the `ChildProductId__r` field for the Name and ID properties.
      - Change the input JSON path from `productChildItems:vlocity_cmt__ParentProductId__r:Name` to `productChildItems:vlocity_cmt__ChildProductId__r:Name`.
      - Change the input JSON path from `productChildItems:vlocity_cmt__ParentProductId__r:vlocity_cmt__GlobalKey__c` to `productChildItems:vlocity_cmt__ChildProductId__r:vlocity_cmt__GlobalKey__c`.
   3. Modify the formula for `productChildItems:href` to use the `ChildProductId` field instead of the `ParentProductId` field.
      - Change the formula from `IF(productChildItems:Id != null, CONCAT(requestUrl,'productSpecification/',productChildItems:vlocity_cmt__ParentProductId__r:Id), null)` to `IF(productChildItems:Id != null, CONCAT(requestUrl,'productSpecification/',productChildItems:vlocity_cmt__ChildProductId__r:Id), null)`.
2. Update the TMFTMForumProductOfferingResult Data Mapper Transform for the productOffering resource.
   1. On the OmniStudio DataRaptors tab in the OmniStudio app, access the TMFTMForumProductOfferingResult Data Mapper Transform.
   2. Modify the mapping for the bundleProductOffering node to use the `ChildProductId__r` field for the Name and ID properties.
      - Change the input JSON path from `productChildItems:vlocity_cmt__ParentProductId__r:Name` to `productChildItems:vlocity_cmt__ChildProductId__r:Name`.
      - Change the input JSON path from `productChildItems:vlocity_cmt__ParentProductId__r:vlocity_cmt__GlobalKey__c` to `productChildItems:vlocity_cmt__ChildProductId__r:vlocity_cmt__GlobalKey__c`.
   3. Modify the formula for `productChildItems:href` to use the `ChildProductId` field instead of the `ParentProductId` field.
      - Change the formula from `IF(productChildItems:Id != null, CONCAT(requestUrl,'productOffering/',productChildItems:vlocity_cmt__ParentProductId__r:Id), null)` to `IF(productChildItems:Id != null, CONCAT(requestUrl,'productOffering/',productChildItems:vlocity_cmt__ChildProductId__r:Id), null)`.
