-
Notifications
You must be signed in to change notification settings - Fork 1.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Boto3 service quota's api list_services doesn't return all the service codes #4298
Comments
Hello @TejasRGitHub, thanks for reaching out. I used the code that you have provided and I was able to get the IAM service quota code. The output from my side was: "Service Code: iam, Service Name: AWS Identity and Access Management (IAM)". For a further look, could you please provide the full output from your code, full code and also by providing debug logs by adding " boto3.set_stream_logger('') " to your line of code ? Thanks. |
Code import boto3
def check_service_quota():
service_quota_client = boto3.client('service-quotas')
paginator = service_quota_client.get_paginator('list_services')
response = service_quota_client.list_services(MaxResults=100)
services = []
services.append(response['Services'])
while response.get('NextToken'):
response = service_quota_client.list_services(NextToken=response.get('NextToken'), MaxResults=100)
services.append(response['Services'])
# for page in paginator.paginate():
# services.extend(page.get('Services'))
print(services)
print("At the end now")
pass
check_service_quota() Logs :
|
Hi @adev-code , I think I figured why I was not able to get the iam code. The reason was becoz I was aws config has eu-west-1 as the region. Once I changed to us-east-1 then I am able to see "iam" code. |
Hi @TejasRGitHub, thanks for the update. Since IAM is a global service, the region has to be us-east-1. If you have any follow up questions, please do let me know. Thank you. |
Greetings! It looks like this issue hasn’t been active in longer than five days. We encourage you to check if this is still an issue in the latest release. In the absence of more information, we will be closing this issue soon. If you find that this is still a problem, please feel free to provide a comment or upvote with a reaction on the initial post to prevent automatic closure. If the issue is already closed, please feel free to open a new one. |
Describe the bug
I am trying to do this, but I am unable to list service quote code for 'AWS Identity and Access Management (IAM)'
Here's my code
I am using boto3 = 1.34.119
Regression Issue
Expected Behavior
I should be able to get the JSON of service quota code for 'AWS Identity and Access Management (IAM)' .
Current Behavior
API doesn't list the service quota code for 'AWS Identity and Access Management (IAM)' .
Reproduction Steps
As decribed in the description
Possible Solution
No response
Additional Information/Context
No response
SDK version used
1.34.119
Environment details (OS name and version, etc.)
mac
The text was updated successfully, but these errors were encountered: