It looks like there might be something corrupt with the apidocs file itself. 
Are you able to share it?

 

 

 

From: <swagger-swaggersocket@googlegroups.com> on behalf of Vigfus A 
<vigfu...@gmail.com>
Reply-To: "swagger-swaggersocket@googlegroups.com" 
<swagger-swaggersocket@googlegroups.com>
Date: Monday, September 18, 2017 at 12:10
To: Swagger <swagger-swaggersocket@googlegroups.com>
Subject: Re: How to create a Swagger *.yaml or *.json definition file and 
project settings?

 

I saved the file and tried to import it to ReadyAPI. Unfortunately I got an 
error (see attached file). Is there anything else I can do or should I check 
with the guys over at ReadyAPI? 

 

Is it possible to upgrade to a newer version of the spec and still keep it 
compatible?



Den måndag 18 september 2017 kl. 10:33:59 UTC+2 skrev Ron: 

Yup, that’s the file. Unfortunately, it’s an old version of the spec, however I 
think SoapUI Pro would support it.

Save that file locally and try importing it.

 

 

From: <swagger-sw...@googlegroups.com> on behalf of Vigfus A <vigf...@gmail.com>
Reply-To: "swagger-sw...@googlegroups.com" <swagger-sw...@googlegroups.com>
Date: Monday, September 18, 2017 at 11:22
To: Swagger <swagger-sw...@googlegroups.com>
Subject: Re: How to create a Swagger *.yaml or *.json definition file and 
project settings?

 

There's no swagger.json, but in apidoc (see attached file) I found the 
following rows. Would that be the one? 

 

{apiVersion: "1", swaggerVersion: "1.2",…} 
apiVersion:"1"
apis:[{path: "/version", description: "Version av API"}, {path: "/admin", 
description: "Admin"},…]
swaggerVersion:"1.2"
Den måndag 18 september 2017 kl. 09:26:17 UTC+2 skrev Ron: 

No, unfortunately that’s not it.

 

It is most likely a file called ‘swagger.json’ or simply ‘apidocs’.

 

 

 

From: <swagger-sw...@googlegroups.com> on behalf of Vigfus A <vigf...@gmail.com>
Reply-To: "swagger-sw...@googlegroups.com" <swagger-sw...@googlegroups.com>
Date: Monday, September 18, 2017 at 09:54
To: Swagger <swagger-sw...@googlegroups.com>
Subject: Re: How to create a Swagger *.yaml or *.json definition file and 
project settings?

 

Good morning, 

 

I've looked through the Network tab and had a look in the swagger.js file (see 
attached pic if it's the correct file).

I came across two version notifications

At the top this was commented

// swagger.js

// version 2.0.41

 

and then further down this code which felt a bit odd since a developer just 
came by and said they were using version 1.3.6

        response: function (resp) {

          var responseObj = resp.obj || JSON.parse(resp.data);

          _this.swaggerVersion = responseObj.swaggerVersion;

          if (_this.swaggerVersion === "1.2") {

            return _this.buildFromSpec(responseObj);

          } else {

            return _this.buildFrom1_1Spec(responseObj);

          }

        }


Is that the information you need or should I look elsewhere?



Den fredag 15 september 2017 kl. 20:34:53 UTC+2 skrev Ron: 

Great, we’re making progress.

 

“Swagger” is the name of a set of open source project around the OpenAPI 
specification.

If you want to compare it to the SOAP days, the OpenAPI is to REST what WSDL is 
to SOAP.

 

The screenshot you’re sharing is from swagger-ui, one of our tools. That takes 
an OpenAPI specification and renders it.

 

The good news is that ‘xsd’ you’re looking for is hidden there. That would also 
be the file you can load into SoapUI Pro.

The bad news is that the swagger-ui version you’re using is very old and it 
might make things a bit trickier (might not even be supported by SoapUI Pro).

 

First thing first, lets try to find that swagger.json file.

 

Open the swagger-ui you have in your browser.

Then, open your browser’s developer tools, go to the network tab, and refresh 
the page.

That will show you a list of calls to load the files used in the page.

One of those files, that should be relatively up in the requests, would be a 
‘swagger.json’ file. You can save it from there.

 

After you have the file, open it and look for either ‘swagger’ or 
‘swaggerVersion’ in it, and let me know the value of that field.

 

 

From: <swagger-sw...@googlegroups.com> on behalf of Vigfus A <vigf...@gmail.com>
Reply-To: "swagger-sw...@googlegroups.com" <swagger-sw...@googlegroups.com>
Date: Friday, September 15, 2017 at 20:47
To: Swagger <swagger-sw...@googlegroups.com>
Subject: Re: How to create a Swagger *.yaml or *.json definition file and 
project settings?

 

It might be my terminology that is off as I haven't used Swagger before, but 
there's an icon in the top left that looks like this  {...}  and links to 
swagger.wordnik.com. It might be a third party product that allows you to test 
your APIs and get simple responses. I was hoping I could get a file with the 
data shown in the pic below i.e. like the old XSD so I could import it into 
soapUI and soapUI would know what to expect if I call this API. In soapUI I can 
build Test suites, Test cases and import data so I can run a chain of tests 
whereas this interface only allows me to enter data.

 

(In case the pic below doesn't show the model just shows the respons parm)

parm 1 - string (optional)

parm 2 - string (optional)

parm 3 - string (optional)

parm 4 - string (optional)



Den fredag 15 september 2017 kl. 19:22:53 UTC+2 skrev Ron:

Before diving into it more, can you explain:

 

There are around 10 different APIs that I can reach in Swagger

 

What is Swagger in that sentence?

 

 

 

From: <swagger-sw...@googlegroups.com> on behalf of Vigfus A <vigf...@gmail.com>
Reply-To: "swagger-sw...@googlegroups.com" <swagger-sw...@googlegroups.com>
Date: Friday, September 15, 2017 at 19:16
To: Swagger <swagger-sw...@googlegroups.com>
Subject: Re: How to create a Swagger *.yaml or *.json definition file and 
project settings?

 

There are around 10 different APIs that I can reach in Swagger, but I can't see 
more than that the Response Content Type is "application/json; charset=UTF-8" 
together with Model/Model Schema. Last time I used APIs some 10 years ago we 
had XML and XSD, but I can see some resemblance between XSD and Model, but I 
can only see the response parms as information in Swagger. I've just assumed a 
Swagger definition sort of is like a XSD, but I can't that equivalent to the 
XSD file that I want to import to soapUI.

Not sure how big they are sizewise, but varies from a single parm to close to 
100 parms in the response.



Den fredag 15 september 2017 kl. 17:45:15 UTC+2 skrev Ron:

I assume you have an existing API.

 

Which language/library do you use to expose the API?

How big is your API?

 

 

 

From: <swagger-sw...@googlegroups.com> on behalf of Vigfus A <vigf...@gmail.com>
Reply-To: "swagger-sw...@googlegroups.com" <swagger-sw...@googlegroups.com>
Date: Friday, September 15, 2017 at 18:43
To: Swagger <swagger-sw...@googlegroups.com>
Subject: Re: How to create a Swagger *.yaml or *.json definition file and 
project settings?

 

Sorry if I was unclear. I want to know how to generate the API defintion file 
in Swagger :)

Den fredag 15 september 2017 kl. 17:27:03 UTC+2 skrev Ron: 

Are you asking how to use SoapUI Pro or how to generate an API definition for 
your API?

 

 

 

From: <swagger-sw...@googlegroups.com> on behalf of Vigfus A <vigf...@gmail.com>
Reply-To: "swagger-sw...@googlegroups.com" <swagger-sw...@googlegroups.com>
Date: Friday, September 15, 2017 at 18:16
To: Swagger <swagger-sw...@googlegroups.com>
Subject: How to create a Swagger *.yaml or *.json definition file and project 
settings?

 

Hi,

 

I'm using soapUI Pro and want to import a Swagger definition file as explained 
in

https://support.smartbear.com/readyapi/docs/projects/create/swagger.html

 

Can someone tell me how someone who has never used Swagger can go about to do 
this? Either a link or a step by step instruction would be awesome :)

 

Best Regards,

Vigfus

-- 
You received this message because you are subscribed to the Google Groups 
"Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to swagger-swaggersocket+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to swagger-swaggersocket+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to swagger-swaggersocket+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to swagger-swaggersocket+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to swagger-swaggersocket+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to swagger-swaggersocket+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

-- 
You received this message because you are subscribed to the Google Groups 
"Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to swagger-swaggersocket+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


-- 
You received this message because you are subscribed to the Google Groups 
"Swagger" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to swagger-swaggersocket+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to