arjunrajas1231
4 years agoNew Contributor
error while deployed locally Failed to fetch. Possible Reasons: CORS Network Failure
I tried deploying Swagger locally and i was able to open it in browser with the given below url
and also used the Yaml code as given below
swagger: '2.0'
info:
description: A Simple IP Address API
title: ipify
version: v1
host: "192.168.56.1:3001"
schemes:
- https
- http
basePath: /
consumes:
- application/json
produces:
- application/json
paths:
/hello:
x-swagger-router-controller: hello_world
get:
tags:
- hello_world
operationId: hello
parameters:
- name: name
type: string
in: query
description: the name
responses:
"400":
description: "Invalid ID supplied"
"404":
description: "Pet not found"
"405":
description: "Validation exception"
when testing it in Swagger UI i get the error as given below in the screen shot
please help to overcome this error