I'm playing with boto and trying to get my account balance using FPS. I've exported the AWS access key and secret.
$ env | grep AWS
AWS_SECRET_ACCESS_KEY=xxxxxxxxxxxx
AWS_ACCESS_KEY_ID=xxxxxxxxxxxx
When I try to connect to ec2 and get all instances, my code works fine. But, when I try to use FPS using python's interactive mode, I get this error:
>>> import boto
>>> fc=boto.connect_fps('fps.amazonaws.com')
>>> fc.get_account_balance()
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Library/Python/2.7/site-packages/boto/fps/connection.py", line 95, in wrapper
return func(self, action, response, *args, **kw)
File "/Library/Python/2.7/site-packages/boto/fps/connection.py", line 183, in get_account_balance
return self.get_object(action, {}, response)
File "/Library/Python/2.7/site-packages/boto/connection.py", line 1204, in get_object
raise self.ResponseError(response.status, response.reason, body)
boto.fps.exception.InvalidClientTokenId: FPS Response Error: 403 InvalidClientTokenId
The AWS Access Key Id you provided does not exist in our records.
The AWS Access Key Id you provided does not exist in our records.
What am I doing wrong? Is there a different AWS Access Key I should be using? My AWS access key has admin rights and I have activated IAM for billing. What am I doing wrong?
FPS is not supported by IAM. You have to use the root account or root + MFA.
Services supported by IAM