REST API created, exposed and consumed in Outsystems

  
Good evening,

I'm trying to implement a REST API on an eSpace (to expose it) using the information from the Outsystems help, but I'm having a problem consuming it on another Outsystems application. Can anyone help me on this?
I did the following:



In terms of the "Receive In" property, I have:
Inputs - Username (text) - Header
           - Top (integer) - Header

Outputs - Counter (integer) - Header
              - UsersRL (Struct_User  List) - Body

Then, after publishing it, I opened the other eSpace from another application and tried to consume my REST API:

















How can I proceed? Is there a way to automatically generate the input and inputs?
I tried to set also the Response Format to JSON and I receive this message - "'GetByUsername' method requires an output parameter with 'List' or a Structure data type and the Receive In property set to 'Body' ".

This is my first custom REST API, so I would be grateful if someone could help me on this.

Kind Regards,
Gonçalo
Hello everybody,

I just found the solution on a post from João Rosado (my bad - I didn't found it yesterday):
http://www.outsystems.com/forums/discussion/14667/amsterdam-exposing-rest-apis/#Post54492   

http://fast.wistia.net/embed/iframe/bk030fjw96?popover=true