Layer7 API Management

  • 1.  Help with creation of a MIME multipart response

    Posted Mar 06, 2015 12:34 PM


    Hi All,

     

    I want to be able to return a basic MIME multipart response using the "Return Template Response to Requestor" assertion. The following picture is what I have:

    testpart.jpg

    This is what I am getting back from the gateway:

    gw_result.jpg

    I am thinking I somehow have the wrong syntax in the Response Body. Does anyone know how to make this actually return a MIME multipart response?

     

    Thanks in advance.

     

    -Rob



  • 2.  Re: Help with creation of a MIME multipart response
    Best Answer

    Posted Mar 06, 2015 05:13 PM


    I figured this out on my own today. The answer is to use a context variable for the parts, then feed the context var to the Response Body. The screenshots below show this:

    context_var.jpg

    using_context_var.jpg

    Using the context var above, the gateway now responds with what I want:

    good_result.jpg

    I am thinking the "Save Line Breaks as: CRLF" was the culprit here. The Response Body in the GUI is not using CRLF at the end of it's lines.

     

    -Rob