Newer Version Available

This content describes an older version of this product. View Latest

Retrieve Unpackaged Source by Creating a Temporary Unmanaged Package

Don’t already have your source defined in a package.xml file? No worries. To simplify the source retrieval process, you can use the Unmanaged Package UI to define what you want to retrieve. Create an unmanaged package in your sandbox, and add your app’s source to it.
  1. Open the sandbox org that contains your metadata.
    You can use the sandbox username or an alias.
  2. Open All Setup.
  3. Open Package Manager.
  4. Create a package with the name of your application.
  5. Add the metadata source to the package.
  6. In your Salesforce DX project, create a folder for the MDAPI retrieve, for example, mdapipkg.
  7. Retrieve the metadata.
    The -s parameter indicates that you’re retrieving a single package. The package name is the name you used in step 4.
  8. Check the status of the retrieve.
  9. Unzip the zip file.
  10. (Optional) Delete the zip file.

After you retrieve your source, you can delete or refresh your sandbox or delete the package definition in the sandbox org. Now that you have the source, you don’t need the resources.

Next, convert the metadata source.