Wouldn't that API then just give someone else (presumably the intelligence agency) unrestrained access to all phone lines? Someone outside should be responsible for providing access, you can argue Huawei shouldn't have been chosen but I find it hard to blame them for doing their job.
Unless people inventing such API thought that the domestic telco equipment will be operated by foregin companies. And I somehow suspect they've thought exactly the opposite: that they can rely on domestic providers be domestic firms, easily supervised by the domestic law enforcement agencies.