It seems that this feature is not supported now. This article has something to do with your question, you can refer to it.
As we are mainly responsible for general issue of Microsoft Teams. If you want to use API methods to realize this feature, it is out of our scope.
You could post a new case in Teams Developer forum to get the most qualified pool of respondents, and other partners who read the forums regularly can either share their knowledge or learn from your interaction.
Thanks for your understanding.
If the response is helpful, please click "Accept Answer" and upvote it.
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.