Skip to main content
I’m trying to figure out how to retrieve Field Audit Trail metadata using the WorkBench, and I’m stumped. I used the WorkBench to deploy a zip file named package-Dev.zip, which contained the following files:

1) A file named Account.object: 

<?xml version="1.0" encoding="UTF-8"?>

<CustomObject xmlns="http://soap.sforce.com/2006/04/metadata">

   <historyRetentionPolicy>

       <archiveAfterMonths>14</archiveAfterMonths>

       <archiveRetentionYears>10</archiveRetentionYears>

       <description>Account object field history retention policy -- Dev</description>

       <gracePeriodDays>0</gracePeriodDays>

   </historyRetentionPolicy>

   <fields>

       <fullName>BillingAddress</fullName>

       <fullName>City_Mailing_Address_Group__c</fullName>

   </fields>

</CustomObject>

 

2) A file named package.xml: 

<?xml version="1.0" encoding="UTF-8"?>

<Package xmlns="http://soap.sforce.com/2006/04/metadata">

    <types>

        <members>Account</members>

    </types>

    <version>32.0</version>

</Package>

 

Now I want to use the WorkBench to retrieve the metadata (history retention policy and fields) that I deployed for the account object via package-Dev.zip. What ‘s the XML code that I need to use to retrieve that metadata? I'm not an XML or API programmer, and all of the examples I've found seem to assume that I know more than I do, so I'm lost.

 

Thanks for your help!

 
10 answers
  1. Jan 28, 2016, 8:31 PM
    Yes, I used that guide to figure out how to set the retention policy, and I used the Deploy feature of the Workbench to set it. I feel kinda blind not being able to retrieve the retention policy so I can verify that I set it correctly, but I guess I can't do that via the Workbench. :(

    Anyway, thanks so much, Swayam, I greatly apprecaite all of your help.
0/9000