Reputation: 57
I tried this way but I get the error Invalid type for parameter ProvisionedThroughput.ReadCapacityUnits, value: on-demand, type: <class 'str'>, valid types: <class 'int'>
ProvisionedThroughput={ 'ReadCapacityUnits': 'on-demand', 'WriteCapacityUnits': 'on-demand' }
Upvotes: 5
Views: 1738
Reputation: 1023
ddb.create_table(
TableName='my_table',
KeySchema=[
{'AttributeName': 'id', 'KeyType': 'HASH'},
],
AttributeDefinitions=[
{'AttributeName': 'id', 'AttributeType': 'S'},
],
BillingMode='PAY_PER_REQUEST',
)
Upvotes: 6