For the purpose of an app I need to be able to perform some actions, either via apex code or workflow/process builder to update another object, however I can’t seem to find a documented way to do it. Is it possible on the platform
If TestField__c on Account is deleted (or the type is changed) the object Object_Status__c needs to be notified and register it. So I need the api name of the field and the action that was taken on it.
There isn’t currently a native way to detect and take actions immediately after a change to the Metadata occurs.
As kurunve commented, there is the SetupAuditTrail in the SOAP API.
Represents changes you or other admins made in your org’s Setup area for at least the last 180 days.
You would need to poll this on an interval to detect the change.
Likewise, you could also directly poll and compare metadata to detect changes such as a field added or deleted.
There was a discussion along similar lines on twitter recently about having an automation point to detect metadata changes. My position was that a trigger isn’t really the right place for such automation. A trigger that is itself described in metadata doesn’t seem like a great place to monitor metadata changes.
Platform events however would be useful for this as they would execute outside the actual deployment.