AWS API
Last updated
Was this helpful?
Last updated
Was this helpful?
It's possible to interact with different AWS services that support access via HTTP API and using the AWS API Connection.
An example of such request could be the creation of an S3 bucket. Let's review the steps needed to implement this use case in UI Bakery:
.
When running UI Bakery in the Production environment, we strongly recommend limiting IAM user's access only to the operations they are allowed to perform. For more information, please refer to .
.
.
.
On the Data sources page, click Connect, and select AWS API in the Data sources list.
Paste the Access key ID and Secret access key ID you've created before.
Configure the region where you want to create your bucket, for example, us-west-2
.
For the AWS service name, use s3
.
Click Test connection to check whether the data source can be connected, and then click Connect Datasource.
Once your datasource is configured, you can go to your project and open the actions panel. There, create a new action of the HTTP Request type and select the datasource you configured in the previous step.
Once the action is configured, you can execute it and check if the S3 bucket was created.
According to , in order to create an S3 bucket, you need to send a PUT request to https://<your-new-bucket-name>.s3.<your-aws-region>.amazonaws.com
with the body containing the following XML (replace LocationConstraint
contents with your region):
You can set the bucket name dynamically in the URL field based on the value of some input. For more information, refer to .