0

So from the client side (android app) i want to pass an array of strings to the method request. But it only accepts string parameters? How do i go about this?

And when i made an input request body for this, it simply did not read my input, and only reads the input from the query string params.

Hope to hear an answer soon! enter image description here

TheQ
  • 1,949
  • 10
  • 38
  • 63
  • try this http://stackoverflow.com/questions/12756688/is-it-possible-to-send-an-array-with-the-postman-chrome-extension – D.J Jan 04 '17 at 05:31
  • 3
    try to set the array in request body – Nainal Jan 04 '17 at 06:10
  • API Gateway doesn't support array parameter in query string and header, but you can pass your array parameter in request body and send it to your integration endpoint. – Ka Hou Ieong Jan 11 '17 at 22:45

1 Answers1

0

From the comments, i was able to figure it out (thanks guys).

A couple points. 1.If you're making a get method. DO NOT USE INPUT BODIES. You can only make query string parameters. So that means, you cannot take in booleans, ints, arrays (you name it). 1a. If you make a get method. You must define an integration request as well.

2.If you want to take in other data types such as int,boolean, arrays (etc). Then make a post method (my suggestion). And make an input model for the request body in your method request. 2a. DO NOT (FOR THE LOVE OF GOD) define an integration request (JUST DONT TOUCH IT) if you're making a post method (trust me, i was getting errors and couldnt figure out why it was never working).

TheQ
  • 1,949
  • 10
  • 38
  • 63