Forum Discussion

aaronpliu's avatar
aaronpliu
Frequent Contributor
7 years ago

is there a way to solve duplicate parameter in both header and query

I imported Swagger (.json) file to ReadyAPI. However, there are duplicate parameter name in header and Query, then one of them will be missed. is there a way to resolve it when import?

  • Lucian's avatar
    Lucian
    Community Hero

    Hey,

     

    Can you attach your swagger file so we can better see what this is about?

    • aaronpliu's avatar
      aaronpliu
      Frequent Contributor

      I did not have a sample swagger file for your reference currently. As soapUI limitation, cannot have duplicate parameter in request params. However, some of swagger defined the same name parameter in header(MetaHeader) and query, then one of them is ignored.

      For instance, if swagger defined a parameter in metaHeader, called "itemID", and the endpoint looks like /abc/{itemID}/account, how does soapUI distinguish them? just see a parameter in request table of test step.

       

      I may manually update them so that I can use this endpoint, but I cannot update definition of swagger in SoapUI if swagger update in future. becuase my manual update will be lost.

       

      Have anyone run into such import issue with swagger? Please let me know if you have better solution for it.

       

      Thanks in advance

      • aaronpliu's avatar
        aaronpliu
        Frequent Contributor

        Anyone else meet such issue (as captioned) when you working on swagger? If some of properties are defined in header(MetaHeader) and there are the same name property defined as query parameter. ReayAPI just show one of them in request panel. Not sure if ReadyAPI (SoapUI) has an alternative approach to settle it. Please let me know if you can help on it.

         

        Thanks in advance