There were plans at one point to expose the Design Doctor through the API but it never happened. However, you can still get some failure or error information by interrogating the model. The VBA macro and function below check to see if any of the features in a part have problems. To do a full check you would also want to check the health state of sketches and work features.
Public Sub TestProblems()
Dim partDoc As PartDocument
Set partDoc = ThisApplication.ActiveDocument
If PartHasProblems(partDoc) Then
MsgBox "Part has problems"
Else
MsgBox "Part is OK"
End If
End Sub
Public Function PartHasProblems(partDoc As PartDocument) As Boolean
Dim feature As PartFeature
For Each feature In partDoc.ComponentDefinition.Features
If feature.HealthStatus <> kUpToDateHealth And _
feature.HealthStatus <> kBeyondStopNodeHealth And _
feature.HealthStatus <> kSuppressedHealth Then
PartHasProblems = True
Exit Function
End If
Next
PartHasProblems = False
End Function
---------------------------------------------------------------
Brian EkinsInventor and Fusion 360 API Expert
Website/Blog:
https://EkinsSolutions.com