Post

3 followers Follow
0
Avatar

API 503 Service Unavailable Error

Hi,

I have a .net website built outside of the Clarizen software that calls into the Clarizen API to retrieve various pieces of information in order to build an internal reporting system. This has been working fine for several months now however over the last week or so we’ve suddenly started getting 503 errors when calling the API. The code is calling this url;

https://eu1.clarizen.com/v2.0/services/

and using some of the various end points (for example authentication/login and data/resourceManagementQuery). When the calls fail, it can be at any of the end points I used and when it fails I’m getting the following error back;

Service Unavailable
HTTP Error 503. The service is unavailable.

This happens both on my application and on a QlickView report that works independently of my code. 

We have raised a support case but I don't think they have understood the issue and directed us to here.

Lewis Answered

Please sign in to leave a comment.

6 comments

0
Avatar

Hi Lewis,

One of the best practices of using the Clarizen API is calling GetServerDefinition first to get the correct base URL to use with the API.

The end point address you specified is not an address we use for the API, and though it may work it may have issues.

I suggest you start with https://apie1.clarizen.com/v2.0/services/ and call GetServerDefinition first thing in your application to verify/change the base url if required.

Check the REST API documentation for further information. 

 

An HTTP 503 error could also suggest service disruption, so we'd better make sure it isn't an issue of using the wrong address.  

Hope this helps,

Ophir

Ophir Kenig 0 votes
Comment actions Permalink
0
Avatar

Hi Ophir,

I had the call to the GetServerDefinition already in, however I stopped using it as I'm unable to authorise my user against the new endpoint that gets returned - I get a username \ password do not match error. This is using the same credentials I've used for all other API calls (that work fine) and I use to login to the web front end.

Is there a particular permission that my user needs or a new user altogether?

I have already looked in the docs for this information but haven't been able to find anything specific.

 

Thanks for your help so far (and on the other questions I've had)

Lewis 0 votes
Comment actions Permalink
0
Avatar

Hi Lewis,

First thing you should definitely do is use https://apie1.clarizen.com/v2.0/services/   

As I mentioned, this is the correct API address for the Europe data center. 

Changing the address may resolve your issues, as the address you used is routed differently.  

 

Anyway:

Username/password do not match error should return only if you tried to access the wrong server or you sent a wrong username/password combination.

Just to verify, did you use the serverLocation returned from GetServerDefinition?

If you can post comment here with the code you used to handle GetServerDefinition and Login I may be able to see what went wrong. 

You could also (not a must) comment your username/password in the support ticket you opened. That'll allow us to check if there's something unusual about the particular Clarizen user, though it's rarely the case.

Hope this helps,

Ophir

Ophir Kenig 0 votes
Comment actions Permalink
0
Avatar

Hi Ophir,

I've had chance to investigate this again and have resolved it. My main problem seemed to be the credentials that I was using. When calling the old URI (https://eu1.clarizen.com/v2.0/services/) I could log in using my federated credetials. Using the new URL that you posted (https://apie1.clarizen.com/v2.0/services/) I need to use my Clarizen Id. Once I'd figured this out my code works as expected. 

Thanks for your help.

 

Lewis 0 votes
Comment actions Permalink
0
Avatar

Hi Lewis,

Indeed Federated authentication was intended to be used with the application, not the API.

You have to use username & password with the API.

If you have further issues or questions you're welcome to use this forum or contact the support team.

Ophir

Ophir Kenig 0 votes
Comment actions Permalink
0
Avatar

A 503 Service Unavailable Error is an HTTP response status code indicating that your web server operates properly, but it can't temporarily handle the request at the moment. This error happen for a wide variety of reasons. Normally, this error can be due to a temporary overloading or maintenance being performed on the server and it is resolved after a period of time or once another thread has been released by web-server application.

How to fix HTTP 503 errors

  • Reload (Refresh) the page
  • Restart Your Devices
  • Scan for Malware
  • Clear Temporary Files
  • Visiting the website later
  • Contact server admin

 

william hold 0 votes
Comment actions Permalink