Forum Discussion

hsravidatta's avatar
hsravidatta
New Contributor
3 years ago

Swagger Inspector returns response as Binary data

we are planning to convert one of our first sample API to OAS 3.0 however the first payload request on inspector platform return with the message

 

Same API Payload perfectly works on Postman and Insomnia platforms. Any thoughts pls?

 

Thank you!

 

 

6 Replies

  • richie's avatar
    richie
    Community Hero
    Hey hsravidatta,

    Sorry about the delay in replying. Ive been ill.

    It'll be a simple fix but we're going to need step by step instructions on exactly how you've created the endpoint to submit your request in readyapi.

    If you supply the full RAW details (request uri and headers) of what works in Postman and then submit your request in readyapi and provide the full RAW details of that request for comparison, thatll indicate what you need to alter in readyapi to get your requests to work.

    Cheers,

    Rich
    • hsravidatta's avatar
      hsravidatta
      New Contributor

      Hi Rich

       

      Thanks for your response. I can give certain steps which we followed in postman. 

       

      API URL (Method type is POST)

      https://application.domain.com/api_integration/REST/Summit_RESTWCF.svc/RESTService/CommonWS_JsonObjCall

       

      Body of payload may be something like below (json format)

       

         {
         "ServiceName":"SR_ServiceCatalogDetails",
         "objCommonParameters":{
           "_ProxyDetails":{
               "AuthType":"APIKEY",
               "APIKey":"<keygoes here>",
               "ProxyID":0,
               "ReturnType":"JSON"
            },
                "ServiceRequestProperty": {
                  "SearchKeyword""searchkeyword",
                  "EntitledService"false,
                  "CategoryOrCatalog""CATALOG",
                  "CategoryID"0,
                  "CatalogTypeID"0,
                  "OrgID""1",
                  "Instance""Info"
              }
         }
      }
       
      response would be some thig like this in (postman)
       
      {
      "Errors": "",
      "Message": "",
      "Output": "",
      "TokenID": "valid tokeid goes here",
      "OrgID": 0,
      "OutputObject": {
      "Details": {
      "CatalogDetail": [
      {
      "CatalogID": 142,
      "CategoryID": 144,
      "ShortCatalogName": "keyword matching information in shortcode",
      "CatalogName": "keyword matching information",
      "Description": "description",
      "IsVendor": false,
      "IsPackage": 0,
      "AncestorParent_CategoryID": 0,
      "IsEntitled": 0,
      "CategoryName": "Leave",
      "ServiceCatalogBGColor": "#ffffff",
      "PackageFirstCatalog": 0,
      "InfoCatalogTypeID": "CLOG"
      }
      ]

      }
      },
      "OutputID": 0,
      "Input": null
      }

       

      • richie's avatar
        richie
        Community Hero
        Hey hsravidatta,


        Need to compare the whole thing. Thats not just URI and payload, i mean the headers as well.

        Whatevers working in postman you need to alter your ReadyAPI request to match the headers as well as URI and payload.

        Ta

        Rich