function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
cmctamcmctam 

Can I disable a trigger using the SOAP API?

I want to use SOAP API to disable a trigger, run a script, then enable it again. Can someone advise if this is possible?
 
It looks like I could use the ApexTrigger class to set the “Status” to “Inactive”, however on its documentation: https://developer.salesforce.com/docs/atlas.en-us.api.meta/api/sforce_api_objects_apextrigger.htm it says that “Inactive is not valid for ApexClass. For more information, see the Metadata API Developer Guide.” However when looking at the link I can see the status field and it looks like “Inactive” is a valid entry: https://developer.salesforce.com/docs/atlas.en-us.212.0.api_meta.meta/api_meta/meta_triggers.htm?search_text=inactive