cancel
Showing results for 
Search instead for 
Did you mean: 

Rest API 403 Error after a few requests

Paul_Hoecherl
Confirmed Champ
Confirmed Champ

We are developing document operations against the OnBase (Foundation EP3) Rest API.

 

Per the docs, we generate a fresh bearer token with every request, and the server will respond normally for an number of requests (number varies).

 

However, the server will eventually start returning "403: The system is out of requested licenses or not licensed for the requested License Type." responses, refusing any further requests after a random number of sequential requests (sometimes it happens after < 10 requests).

 

When the Rest API server is in this "403 state", the session console shows many (many) sessions with "Concurrent Client" product license.

It also indicates that each of the sessions uses the same Username.

 

Each of these sessions appears to correspond to one of the previous test requests, based on the LoginTime it displays.

 

(The Identify provider remains unaffected, always returning valid bearer tokens.)

 

If we wait long enough (30 mins?) eventually the sessions clear and normal operations resumes.

 

Restarting IIS has the same effect.

 

It seems like there is something misconfigured on the Rest API service.

 

Is this a known issue?

 

Any ideas appreciated... 

 

 

 

 

1 ACCEPTED ANSWER

Daniel_Quill
Elite Collaborator
Elite Collaborator

Hi @Paul Hoecherl (ClarkPUD), 

 

This is likely a session management issue.  With every token request will generate a new OnBase session.  In order to continue using a single session you will need to grab the Hyland Cookie and apply it to the next request.  The cookie contains the session information.

 

I do not believe this to be a configuration issue but a code case and handling sessions when using the REST API.  The below link is some additional information about Session/Cookie Handling. 

 

https://sdk.onbase.com/rest/OnBase/FoundationEP5/document/programmers-guide/authentication.html#onba...

View answer in original post

6 REPLIES 6

Daniel_Quill
Elite Collaborator
Elite Collaborator

Hi @Paul Hoecherl (ClarkPUD), 

 

This is likely a session management issue.  With every token request will generate a new OnBase session.  In order to continue using a single session you will need to grab the Hyland Cookie and apply it to the next request.  The cookie contains the session information.

 

I do not believe this to be a configuration issue but a code case and handling sessions when using the REST API.  The below link is some additional information about Session/Cookie Handling. 

 

https://sdk.onbase.com/rest/OnBase/FoundationEP5/document/programmers-guide/authentication.html#onba...

So with the REST API, are we no longer able to use alternative licensing options like the query meter license?

Hi @David Taylor ,

 

Query Metering is supported with the REST API.  Here is a post on how to configure it ...

 

https://community.hyland.com/forum/threads/79055-querymetering-with-restapi

 

Best wishes.

Paul_Hoecherl
Confirmed Champ
Confirmed Champ

Thanks Daniel: That looks like a solution, and I will investigate that implementation change.

 

We also have a number of applications using the API via the Unity (Hyland) dlls.

 

So on our scenario, where we have both Rest API and Unity DLL api being used, does the Rest API typically use the same (metered) license as the Unity API?