问题
I have an API deployed on AWS API Gateway. I will have multiple subscribers using my API and each customer would be unique. Is it possible that each customer will have a separate API key unique to him? Or will I have to create those many IAM users in order for them to be unique? If yes for the IAM users, then what is the upper limit of the number of users? I will be doing all this programmatically.
回答1:
By unique, if you mean that you should be able to identify which request came from who, then you can generate one API Key per subscriber. You can generate up to 10000 API keys per AWS account. More details about API keys here.
By unique, if you mean that each subscriber should have access to a unique set of API resources/methods/stages, then you can create different IAM roles with different levels of permissions and let the subscribers assume the roles. You can create up to 250 roles per account. More details about access permissions here.
来源:https://stackoverflow.com/questions/37409854/amazon-api-gateway-user-keys