awswrangler.timestream.create_database¶
- awswrangler.timestream.create_database(database: str, kms_key_id: Optional[str] = None, tags: Optional[Dict[str, str]] = None, boto3_session: Optional[Session] = None) str ¶
Create a new Timestream database.
Note
If the KMS key is not specified, the database will be encrypted with a Timestream managed KMS key located in your account.
- Parameters
database (str) – Database name.
kms_key_id (Optional[str]) – The KMS key for the database. If the KMS key is not specified, the database will be encrypted with a Timestream managed KMS key located in your account.
tags (Optional[Dict[str, str]]) – Key/Value dict to put on the database. Tags enable you to categorize databases and/or tables, for example, by purpose, owner, or environment. e.g. {“foo”: “boo”, “bar”: “xoo”})
boto3_session (boto3.Session(), optional) – Boto3 Session. The default boto3 Session will be used if boto3_session receive None.
- Returns
The Amazon Resource Name that uniquely identifies this database. (ARN)
- Return type
str
Examples
Creating a database.
>>> import awswrangler as wr >>> arn = wr.timestream.create_database("MyDatabase")