Can I Extract Diagnostic Wi-Fi Data in macOS Through the API?

Can we make an API call to extract this data from a MacBook?