I want send json string to webrequest:
{'Type':'AAA','param':[{'paramName':'C1','paramValue':'25'}],'variables':{}}
Is right?
{'Type':'AAA','param':[{'paramName':'C1','paramValue':'25'}],'variables':{}}
B4X:
Dim Map1 As Map
Map1.Initialize
Map1.Clear
Dim Map2 As Map
Map2.Initialize
Map2.Clear
Map1.Put("Type","AAA")
Map1.Put("param",Map2)
Map2.Put("paramName","C1")
Map2.Put("paramValue","25")
Map1.Put("variables","{}")
Dim JSON As JSONGenerator
JSON.Initialize(Map1)
data= JSON.ToString
Is right?