I'm tryin to create Api Proxy off of a swagger import. After clicking on Use OpenApi button and importing the URL where swagger lives, I'm getting this error
Request has been terminated Possible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.
The URL I'm adding is generated by ngrok, which exposes my localhost as a public URL.
Can you explain what the cause of this error is?
,Hi
I'm using ngrok to try to import swagger as URL for api proxy part.
Basically, ngrok turns your localhost into a public facing url. So under API Proxies, UseOpenApi option, I used ngrok's url and inserted it into the import url for the swagger json file but I'm getting this error
Request has been terminated Possible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.
Thanks
Solved! Go to Solution.
Hi @Vicente Lee, maybe it is because you are using localhost as public URL & it doesnt have enough permissions to share swagger/oas with Apigee.
You can try to upload the oas to GitHub & then use the raw format URL in Apigee and it will work.
Example
https://github.com/OAI/OpenAPI-Specification/blob/master/examples/v2.0/json/api-with-examples.json
Hi @Vicente Lee, maybe it is because you are using localhost as public URL & it doesnt have enough permissions to share swagger/oas with Apigee.
You can try to upload the oas to GitHub & then use the raw format URL in Apigee and it will work.
Example
https://github.com/OAI/OpenAPI-Specification/blob/master/examples/v2.0/json/api-with-examples.json