Skip to content

Salesforce metadata typescript types #2937

Answered by mshanemc
tomcarman asked this question in Q&A
Discussion options

You must be logged in to vote

Yeah! We started that pretty recently. Currently, @salesforce/types is generated from the WSDL. A lot of that was initiated/contributed by Andrés Catalán.

we're starting to use it like
https://github.com/salesforcecli/plugin-sobject/blob/a8289d74cd0ba9c209b8b15e5dca34cc784300c4/src/shared/types.ts#L8
https://github.com/salesforcecli/plugin-sobject/blob/a8289d74cd0ba9c209b8b15e5dca34cc784300c4/src/shared/prompts/nameField.ts#L12
etc.

they're also mostly correct in the newer jsforce (v3) and (recommended for cli-plugins) @jsforce/jsforce-node packages but somewhat out of date. For long-standing things that haven't changed much (ex: CustomObject) you might find it workable.

Tooling API !== m…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@tomcarman
Comment options

@WillieRuemmele
Comment options

Answer selected by tomcarman
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants