1개 답변
- 최신
- 최다 투표
- 가장 많은 댓글
0
Hello,
You may just try this $util.urlDecode($input.params('myJson')) and provide the query string value GET /api/endpoint?myJson=%7B%22x%22%3A123%7D and it should work as you expect. you need not to worry about parsing as you are providing json string value of json with encode, hence by decoding you will get json string back. if you like to use stringify version containing "/" then you have to replace "/" with nothing to get json string. hope it helps. thanks
Code snippet:
"myParsedJson" : $util.urlDecode($input.params('myJson'))
output:
myParsedJson : {"x":123}
답변함 일 년 전
관련 콘텐츠
- AWS 공식업데이트됨 일 년 전