3

I am experimenting with tooling api and it is possible to create apex classes, triggers using tooling api.

As name "tooling" suggests that it is used for developing IDEs. I was wondering can we deploy code using tooling api in production.

I could have checked by running the same code on production. But I don't want to experiment with production.

If anyone has any experience then please share.

2

No you cannot create classes and triggers in Production.I have seen apps where people have written tooling API code to dynamically build visualforce tags or show test coverage graphs but not apex triggers and apex classes.

Salesforce does not allow writing classes or triggers in PROD directly .It has to be deployed from sandbox or IDE using Metadata API .

  • Is there any other REST based approach for deploying ApexClass,Triggers,Components and VF pages? – Kiran Machhewar Jan 15 '16 at 11:39
  • No..For PROD you can use metadata API only to deploy code. – Mohith Shrivastava Jan 15 '16 at 13:00
  • You can use the Metadata API to create Apex Classes and Apex Triggers in Production. Andrew Fawcett has shared an example. – Jochen Nov 3 '16 at 21:23

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.