Podcast #128: We chat with Kent C Dodds about why he loves React and discuss what life was like in the dark days before Git. Listen now.

Questions tagged [salesforcedx-cli]

Questions relating to the `sfdx` binary that is supplied as part of the tools suite for Salesforce DX.

Filter by
Sorted by
Tagged with
0
votes
1answer
17 views

Retrieving Case Object using Visual Studio Code and Salesforce CLI

Using Visual Studio Code and Salesforce CLI I am trying to retrieve "Case Object" details. But I was not able to fetch it. But the Account object is retrieved. Any particular reason? Did anyone face ...
1
vote
0answers
24 views

ERROR While running sfdx force:source:deploy command

I am getting an error while running: sfdx force:source:deploy -u Sandbox -x pathToPackage.xml My deployments were just fine but after I did a sfdx force retrieve from a sandbox then I started to get ...
0
votes
1answer
27 views

Get dynamic file name in CLI dataloader (import)

How to get dynamic file name with name example "NameFileFormatYYYYMMDD.csv"? My code looks like this <bean id="accountInsert" class="com.salesforce.dataloader.process.ProcessRunner" ...
0
votes
0answers
15 views

Quick Start: Salesforce DX trailhead error when running push command

I am trying to go through the trailhead for salesforce dx. https://trailhead.salesforce.com/content/learn/projects/quick-start-salesforce-dx/create-and-test-our-scratch-org Everything works ...
1
vote
2answers
48 views

List of valid keys for sfdx-config.json?

This article (Select the Salesforce Release for a Scratch Org) describes the ability to globally configure the default api version for created scratch orgs via the force:config:set command: sfdx ...
1
vote
0answers
35 views

Error invalid_grant - expired authorization code while running sfdx force:auth:jwt:grant

I run the command from my build job within Teamcity CI: sfdx force:auth:jwt:grant --clientid '%SFDX_HUB_CONSUMER_KEY%' --jwtkeyfile config/server.key --username %SFDX_HUB_USERNAME% --setalias hub1 --...
6
votes
2answers
378 views

ERROR running force:source:pull: Entity of type 'Workflow' named 'Workflow' cannot be found

I am having issues when pulling Workflows using SFDX with VS Code. The error that I get when pulling in the Workflow (sfdx force:source:pull) is: ERROR running force:source:pull: Entity of type '...
0
votes
1answer
179 views

Project Creation While via VS code in Lightning Web Component

I am trying to create the Project from my terminal windows in VS code from running the command as below: sfdx force:project:create -n "LWC Session" Getting error as below : {WARNING: apiVersion ...
1
vote
1answer
100 views

auth login instanceurl with parameter

When I directly go to the url https://test.salesforce.com/?un=test%40example.com.sbname (using @ instead of %40 works as well) from a browser, sandbox login page opens up with prefilled username value ...
4
votes
2answers
112 views

Activate Communities Settings: “Allow using standard external profiles for self-registration and user creation.” in a scratch org config file

Since Winter20, we have some test classes failing because of new Community Setting Allow using standard external profiles for self-registration and user creation. The problem is that we have ...
2
votes
1answer
30 views

How to launch node debugging session when developing custom sfdx plugin

Working with a friend on some pretty cool sfdx plugins. Challenge seems to be if something goes wrong I get a pretty generic error, no stack trace, and it's a real challenging tracing things back to ...
0
votes
2answers
43 views

Convert And deploy an Existing App challenge

I am stuck in completing this last part of Salesforce DX challenge. I have 2 issues. The first one i did not realise when that happened but its there. Its in the image below with JSON. file. I dont ...
3
votes
0answers
33 views

Character encoding difference between source:retrieve vs mdapi:retrieve?

Here is the screenshot of a simple validation rule in Salesforce: and I am now going to retrieve this validation rule using three different options and notice how the ' (apostrophe) is escaped(or ...
2
votes
1answer
21 views

SFDX CLI export more than 10k records

I'm trying to export records from an object that holds 20k records, and I'm using the sfdx force:data:tree:export command but it returns a max of 10k records. How do I export the remaining records, ...
1
vote
0answers
18 views

SFDX: Get Apex Debug Logs for Site Guest User in VS Code

How do I get Debug Logs for Site Guest User in VS Code? I ran SFDX: Get Apex Debug Logs and I can see debug logs for my user. But what I want is debug logs for Site Guest User which I don't see in the ...
1
vote
0answers
20 views

Testing custom salesforce plugin

I am currently trying to test a custom salesforce plugin which deploys a payload to a specific org. The plugin itself is coded in typescript and the unit tests are using mocha/chai. I am running ...
0
votes
1answer
67 views

Cannot connect to Salesforce Org from VS Code/Salesforce CLI: Must pass a username and/or OAuth options when creating an AuthInfo instance

I'm trying to connect to my Trailhead playground org with the Salesforce CLI on VS Code. Here's what I've done: I created the project then clicked on Authorizing a dev hub. I was prompted for a login ...
0
votes
1answer
52 views

Trailhead “Convert Lightning Web Components Open Source to Salesforce” stuck in “Convert Components for the Salesforce Platform” step

I'm stuck in the Trailhead "Convert Lightning Web Components Open Source to Salesforce", at the "Convert Components for the Salesforce Platform" step. When I right-click the force-app folder and ...
2
votes
0answers
28 views

Creating data with DX/CLI referencing existing records

When setting up a scratch org for CI/QA or development purposes certain "records" like the standard profiles and some other record like Accounts & Contacts ("hasSampleData": "true") are created ...
0
votes
1answer
29 views

Error when Authenticate Orgs

I'm having a very frustrated problem where Visual Studio Code show error everytime I want to authenticate an org. I use CMD and it working fine but when I try to work on Visual Studio Code it show the ...
1
vote
1answer
89 views

How to create a scratch org with communities enabled?

Given the project-scratch-def.json: { "orgName": "My Org", "edition": "Developer", "features": [ "LiveAgent", "AuthorApex", "TerritoryManagement", "ServiceCloud", "Knowledge"...
0
votes
0answers
19 views

Session expired or invalid in salesforce scim implementation

Invoking the URL GET https://salesforce_org_url/services/scim/v2/Users Header Authorization:Bearer xxxxxxxxxxxxxxxxxxxxxxxxxxxxx Expected Response Salesforce user details Actual Response Could not ...
0
votes
1answer
53 views

Download all Apex classes

I would like to set up a daily backup of all the Apex classes and triggers. Is there any way this can be done using the cli (sfdx)? If not, are there any other ways? The idea is to write a script ...
4
votes
2answers
168 views

How can I retrieve email templates from a sandbox using the Salesforce CLI?

I tried to use the force:source:retrieve command with the -m parameter as EmailTemplate but it doesn't retrieve the email templates in my connected sandbox. How can I retrieve the email templates?
2
votes
1answer
43 views

Scratch Org configuration gives error “SocialCustomerService is not a valid Features value”

I am creating a new scratch org with a configuration file to enable "SocialCustomerService" feature flag. But SFDX cli it not recognizing this feature flag. Getting an error "SocialCustomerService is ...
1
vote
1answer
21 views

How to print all EmailTemplate component names using SFDX CLI?

I run the below command and it prints undefined. ~sfdx force:mdapi:listmetadata --metadatatype=EmailTemplate --targetusername=mysandbox --folder=unfiled$public undefined When I run the above command ...
1
vote
1answer
62 views

Upserting records using SFDX CLI for a object with no External Id

Below are the available data related commands in CLI. If I want to insert records using SFDX CLI, how to do that? force:data:bulk:delete -- bulk delete records from a csv file force:data:bulk:...
0
votes
1answer
15 views

DX - List of Bundle/Prefix types?

With the DX CLI you can't deploy certain individual files - ex. aura and lightning components. You have to use syntax like sfdx force:source:deploy -m AuraDefinitionBundle:<aura bundle name>,...
0
votes
1answer
143 views

Lightning Web Component - Create Contact Error: afterRender threw an error in 'c:lWCDemoComponent' [Cannot read property 'objectApiName' of undefined]

I am trying to create a contact on the contact page... Just for learning and understanding Web Components. Below is the code I am getting an error of: afterRender threw an error in 'c:...
0
votes
1answer
26 views

Lightning Web Component - Create Contact

I am went through alot of the Trailheads for Salesforce. The documentation is interesting at best. With that said I tried an example from a Blog to understand the actual code and IDE of Visual Studio ...
1
vote
1answer
25 views

DX Custom Plugin Help

Trying to understand the right way to have my sfdx plugin command just return a string as the default output, but so far every example shows the returning of an object. Structure under the src folder ...
1
vote
1answer
44 views

DX - Custom Plugin Install

Usually DX CLI plugins are installed via sfdx plugins:install <plugin-name> The examples provided from sfdx plugins:install --help list these: $ sfdx plugins:install myplugin $ sfdx plugins:...
0
votes
0answers
23 views

Apex replay debugger is throwing Java 8 is required to run

I am following this trail and I have completed all the steps correctly. Even I able to download the debug logs. But Problem occurs when I am trying to run the following command > SFDX: Launch ...
2
votes
2answers
38 views

Retrieve a package with commas inside - sfdx force:mdapi:retrieve

I need to retrieve a package with a comma inside by command -> sfdx force:mdapi:retrieve -p "package, name". I understand -p accepts multiple packages in one go with comma as a separator. This ...
1
vote
2answers
49 views

Using sfdx force:package:list -v sandboxname results in error “Packaging is not enabled on this org.”

When attempting to list packages for a sandbox (Which is connected to a production org with devhub enabled and unlocked packages enabled) I get the following error: Packaging is not enabled on this ...
4
votes
1answer
65 views

How to push source to Scratch org if project code exceeds 50mb limit?

I have a managed application which I'm now trying to move to DX platform of development, but I'm getting an error of exceeding maximum storage: Maximum size of request reached. Maximum size of ...
0
votes
0answers
20 views

Validating deleted files on deployment using CLI

I am working on trying to build a deployment pipeline at my company using the Salesforce CLI. The barrier I am running in to is how to validate deleting files from higher environments on deployments. ...
1
vote
2answers
59 views

While creating scratch orgs getting this error “DML operation Delete not allowed on List<AccountShare>”

I am trying to create a scratch org. My codebase is having a class which is doing a dml on accountshare record. For deployment of this class we need to have account's OWD as private. (As well as of ...
2
votes
1answer
54 views

Access parent controller attribute from Visual force component

I have one Visualforce page and one Visualforce controller. I have different attributes defined in the controller of Visualforce page as shown below public boolean firstPanel{get;set;} public ...
0
votes
0answers
16 views

DX - Getting Metadata Without Eclipse Package.xml

Is there no built-in way within the DX CLI to retrieve all available metadata components from a target org (in my case sandbox), without generating a package.xml via Eclipse w/Force IDE? I'm well ...
0
votes
0answers
45 views

Force code extention not opening salesforce login page

I downloaded force code extension for visual studio code. When I'm trying to connect to specific org he doesn't open salesforce login screen in order to log in to the org. Is there any permission ...
0
votes
1answer
11 views

Reassign a namespace in the same dev org

Can you reassign the namespace in a developer org to another package? I currently have a manage package and in that package I've assigned my namespace. I created a Beta version for now. Ultimately I ...
0
votes
1answer
71 views

Jenkins + Sfdx Auth issue

I am trying to use Jenkins for my project CI. I followed the salesforce document and a few blogs for the setup. Here is my Jenkinsfile: #!groovy import groovy.json.JsonSlurperClassic node { def ...
0
votes
1answer
41 views

What are the correct steps to create Scratch Orgs with custom objects

I am trying to create a scratch org based on existing DEV sandbox. The problem is that I get a bunch of errors when trying to push the code into the scratch org: Invalid type: Quote (13:9) Invalid ...
1
vote
1answer
45 views

SFDX FORCE:DATA:TREE:EXPORT Nested __r Relationship Query

I am attempting to export data using the FORCE:DATA:TREE:EXPORT CLI command, using a nested query like the following (for use in our Scratch-Orgs): SELECT ...,(SELECT ... FROM My_Custom_Object__r) ...
1
vote
1answer
34 views

Package hosting options

There are two commands: sfdx force:package:create --name "MyApp" --description "MyApp" --packagetype Unlocked -r force-app sfdx force:package:version:create --package MyApp --installationkey ...
1
vote
1answer
46 views

How to retrieve new meta from the org

I have new classes, pages, etc in the my Salesforce org. Is it possible to update the project with all new files?
0
votes
2answers
127 views

VSCode Lists Erroneous Apex Problems

I'm using VSCode with Github and Deploying to a Sandbox. When I save my classes, VSCode lists problems which don't exist and which don't clear when the class is deployed successfully. For example, all ...
1
vote
1answer
39 views

Analysis for SFDX Apex || sonarqube Community Edition

Is there a way to support SFDX Apex Analysis with sonarqube Community Edition version 7.2 or above. If not then is there any previous Community version which may support it ? Many thanks in advance.
3
votes
1answer
27 views

Automatically close Output window in vsc running salesforce CLI

I have switched from Sublime to VSCode. I have found ways to make most of VSCode work the way I want. The main thing I wish I could do is when I deploy to the org if it is successful I would like ...