Boto3

AWS SimpleDB Boto3 Example

When looking into AWS SimpleDB, a quick search didn’t return any short Python Boto3 examples. So I decided to post one. (As with any services you to subscribe to, running this code below might cost you money …) from __future__ import print_function import boto3 def quote(string): return string.replace("'", "''").replace('"', '""').replace('`', '``') def put_attributes(sdb, domain, id, color): response = sdb.put_attributes( DomainName=domain, ItemName=id, Attributes=[ { 'Name': 'color', 'Value': color, 'Replace': True }, ], ) print(response) if __name__ == "__main__": domain = "TEST_DOMAIN" sdb = boto3.