简体   繁体   中英

I want to write from AWS API Gateway to RDS directly

I want to post the json data by ajax to AWS API Gateway, and write to RDS directly.

I have to input the mapping template to API Gateway setting. But I can not found the sample for write to RDS. If you know the sample or tutorial, or will not you tell us?

This is the code for write to DynamoDB. I run the same process to RDS.

 { "TableName": "$stageVariables.tablename", "Item": { "id": { "S": "$context.requestId" }, "url": { "S": "$input.path('$.url')" }, "event_type": { "S": "$input.path('$.event_type')" }, "data": { "S": "$input.path('$.data')" }, "created_at": { "S": "$input.path('$.event_datetime')" } } }

I write that AWS Service is RDS to Integrated Request Setting. But Not in RDS instance name and table name.

Thanks.

您可以在两者之间使用 Lambda,以便您可以直接向 RDS 进行查询或调用过程。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM