Hello,
I'm having troubles inserting an item in DynamoDB with this Structure from Step Functions.
{
"id":{
"S":""
},
"state_machine_execution_id":{
"S":""
},
"timestamp":{
"S":""
},
"map_param1":{
"M":{
"sub_map1":{
"M":{ }
},
"sub_map2":{
"S":""
},
"sub_map3":{
"M":{ }
},
"sub_mapN":{
"M":{ }
},
"List_1":{
"L":[ ]
},
"List_2":{
"L":[ ]
}
}
}
}
This is the statement that I am trying to make it work without success
{
"DynamoDB Save Item":{
"Type":"Task",
"Resource":"arn:aws:states:::dynamodb:putItem",
"Parameters":{
"TableName.$":"$.TableName",
"Item":{
"id.$":"$.id",
"state_machine_execution_id.$":"$$.Execution.Id",
"timestamp.$":"$.timestamp",
"map_param1":{
"M":{
"M.$":"$.var_for_map_params",
"List_1":{
"L.$":"$.List_1"
},
"List_2":{
"L.$":"$.List_2"
}
}
}
}
}
}
}
I'm getting this error
The Parameters "{A lot of data flow} "could not be used to start the Task: [The field \"foo\" is not supported by Step Functions]"
This "foo" field, has nothing to do, if make changes to the Parameters: map_param1 statement in Step Function works
example
This works ok
"map_param1":{
"M.$":"$.var_for_map_params"
}
And This works ok too
"map_param1":{
"M":{
"List_1":{
"L.$":"$.List_1"
},
"List_2":{
"L.$":"$.List_2"
}
}
}
But not this (the combination)
"map_param1":{
"M":{
"M.$":"$.var_for_map_params",
"List_1":{
"L.$":"$.List_1"
},
"List_2":{
"L.$":"$.List_2"
}
}
}
Can someone help me?
thanks a lot
Regards