New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@salesforce/source-deploy-retrieve

Package Overview
Dependencies
Maintainers
0
Versions
492
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@salesforce/source-deploy-retrieve

JavaScript library to run Salesforce metadata deploys and retrieves

12.7.0
Source
npm
Version published
Weekly downloads
231K
-1.94%
Maintainers
0
Weekly downloads
 
Created

What is @salesforce/source-deploy-retrieve?

@salesforce/source-deploy-retrieve is an npm package that provides tools for interacting with Salesforce metadata. It allows users to retrieve, deploy, and manage Salesforce source code and metadata from a Salesforce org. This package is particularly useful for developers and administrators who need to automate and streamline their Salesforce development and deployment processes.

What are @salesforce/source-deploy-retrieve's main functionalities?

Retrieve Metadata

This feature allows you to retrieve metadata from a Salesforce org. The code sample demonstrates how to use the SourceClient to retrieve metadata for a specific package and save it to an output directory.

const { SourceClient } = require('@salesforce/source-deploy-retrieve');
const client = new SourceClient();
client.retrieve({
  packageNames: ['MyPackage'],
  output: './outputDir'
}).then(result => {
  console.log('Retrieve Result:', result);
}).catch(error => {
  console.error('Error:', error);
});

Deploy Metadata

This feature allows you to deploy metadata to a Salesforce org. The code sample demonstrates how to use the SourceClient to deploy metadata from a specified source directory.

const { SourceClient } = require('@salesforce/source-deploy-retrieve');
const client = new SourceClient();
client.deploy({
  sourcePath: './sourceDir'
}).then(result => {
  console.log('Deploy Result:', result);
}).catch(error => {
  console.error('Error:', error);
});

Convert Metadata

This feature allows you to convert metadata between different formats. The code sample demonstrates how to use the SourceClient to convert metadata from a source directory to an output directory.

const { SourceClient } = require('@salesforce/source-deploy-retrieve');
const client = new SourceClient();
client.convert({
  sourcePath: './sourceDir',
  outputDir: './outputDir'
}).then(result => {
  console.log('Convert Result:', result);
}).catch(error => {
  console.error('Error:', error);
});

Other packages similar to @salesforce/source-deploy-retrieve

Keywords

Salesforce

FAQs

Package last updated on 15 Sep 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts