Not seeing anything related to these in the Metadata types documenation.

Can anyone give me an example of how these can be referenced?


They are in the objects metadata with the webLinks tag.

Sure in my Account metadata I have the following link:

  • could you be a bit more specific? maybe show a quick xml example – NSjonas Aug 15 '14 at 21:51
  • Oh I see, they can't be retrieved and deployed independently of custom objects (like you can do with custom fields). Basically its all or nothing when migrating custom objects – NSjonas Aug 15 '14 at 23:45
  • No, you can specify the Weblink metadata type separately. It will appear in the objects directory under the appropriate object, but that object's XML won't include other properties, like fields or related lists, unless explicitly retrieved. There's a typo in the documentation. Docs say it's WebLink, but it's actually Weblink. – sfdcfox Aug 15 '14 at 23:58

The correct way to reference these in the Ant Migration tool is to create a WebLink metadata type in your package.xml file. The actual detail of the button/link will be stored within the custom object xml file. For example:

<?xml version="1.0" encoding="UTF-8"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">

Will result with the metadata of the Send_SMS button inside of the Contact metadata file in the objects folder:


The button can then be retrieved and deployed as desired.

<?xml version="1.0" encoding="UTF-8"?>
<CustomObject xmlns="http://soap.sforce.com/2006/04/metadata">
        <masterLabel>Send SMS</masterLabel>
        <url>code omitted for brevity</url>

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.