Skip to main content
14-Alexandrite
September 18, 2023
Solved

Rest Api \ APi

  • September 18, 2023
  • 1 reply
  • 4772 views

I cannot find the API service. I entered the Windchill server in the localhost section, but when I try to access it via http://localhost:80/Windchill/servlet/rest/v1/contexts  or Swagger, I get the following error:

Failed to fetch. Possible Reasons:

CORS Network Failure URL scheme must be "http" or "https" for CORS request. It also gives a 404 error. I need to connect to the API in order to use it for my middleware application and perform operations, but I'm having trouble connecting to the API. In fact, I don't have a proper API at hand.

 

 

 

 

 

Best answer by HelesicPetr

Hi @ozclkonur 

Check REST API documentation directly in windchill

https://server.com/Windchill/netmarkets/html/wrs/doc.html

there are examples of the URLs

HelesicPetr_0-1695108083552.png

The swager works in my case

https://server.com/Windchill/servlet/rest/v1/contexts

json is returned. 

HelesicPetr_1-1695108281818.png

 

Check if you use correct login user and password

 

PetrH

1 reply

HelesicPetr
22-Sapphire II
22-Sapphire II
September 19, 2023

Hi @ozclkonur 

Check REST API documentation directly in windchill

https://server.com/Windchill/netmarkets/html/wrs/doc.html

there are examples of the URLs

HelesicPetr_0-1695108083552.png

The swager works in my case

https://server.com/Windchill/servlet/rest/v1/contexts

json is returned. 

HelesicPetr_1-1695108281818.png

 

Check if you use correct login user and password

 

PetrH

5-Regular Member
January 9, 2026

looks like the credentials are not valid in the url, and getting error !