I've a Dynamo Db table with following
{
"primary_key": {
"S": "series"
},
"sort_key": {
"S": "type-of-brokers"
},
"title": {
"S": "Types Of Brokers"
}
,
{
"primary_key": {
"S": "series"
},
"sort_key": {
"S": "type-of-brokers-2"
},
"title": {
"S": "Types Of Brokers-2"
}
Following this I've implemented application/json body mapping template:
{
"TableName": "table_name",
"Key" :{
"primary_key" :{
"S": "series"
},
"sort_key" : {
"S": "type-of-brokers"
}
}
}
It returns one item that matched primary and sort key!
Now I want to return all the matched primary_key
items i.e. without sort_key
How do I achieve that? with API gateway body mapping template?
Also, can api return common json rather than "S" kind, here it specify attributes , can it be done by not hard coding in integration response