From my testing, only Office 365 Standard is enough to create a team, check your user's license to make sure it has the Microsoft Teams service enabled.
Also you need to make sure you are using a user with Office 365 Standard license to log in and get a token, your token must have your user info in it.
If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
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.