 fix #28926 pandas\api\test_api.py mypy errors
- [ ] xref  #28926 
- [ ] tests added / passed
- [x] passes `black pandas`
- [x] passes `git diff upstream/master -u -- "*.py" | flake8 --diff`
- [ ] whatsnew entry
