I am trying to connect to a Amazon SQS via the python boto library.
import boto3
sqs= boto3.resource('sqs')
for queue in sqs.queues.all():
print(queue.url)
I have stored my credentials on the ~/.aws/credentials file
[default]
aws_access_key_id=XXX
aws_secret_access_key=YYY
region=us-west-2
But when I execute the code I get an error
botocore.exceptions.ClientError: An error occurred (AccessDenied) when calling the ListQueues operation: Access to the resource https://us-west-2.queue.amazonaws.com/ is denied.
I tried connecting directly to the queue. LCqueue = sqs.get_queue_by_name(QueueName='myQueue')
But then it tells me there is no such queue. Even though I can see it on the AWS management console. Any ideas ?
I also get an error on my IAS managment console. where I cant list any users.