Important Update: Community URLs redirect issues are partially resolved. Learn More. .

cancel
Showing results for 
Search instead for 
Did you mean: 

Content API

jsol5
Advocate II

Working with Content API and it's unclear the URL to pull back all records OR even the default count of records from an application.

*I thought I saw something that said it's 1000.  So, anything beyond that would be multiple calls.

 

Additionally, it's unclear if possible to specify the fields desired.

 

I can do something like this and get a specific record 

/contentapi/Applications(12345) 

 

However, this gives a 500 error 

/contentapi/Applications

 

This gives endpoint data (not what I want):

/contentapi/Applications/

1 ACCEPTED SOLUTION

Accepted Solutions

Anonymous
Not applicable

Jason,

 

There is no call the Content API currently that would pull back all records. A call to an endpoint will return up to 1000 records, and to get all of them you need to paginate through them using the "?skip=N" functionality from the RSA Archer 6.5 Content API Reference Guide‌. Loop through the calls until you get less than 1000 records back, and then you know you are done.

 

Your call to /contentapi/Applications is correct. I suspect the 500 Error you were getting is due to a bug we've since fixed in a recent CPR version. Check out the release notes, upgrade a dev/test environment, and let me know if that sets you straight.

View solution in original post

32 REPLIES 32

Anonymous
Not applicable

Jason,

 

There is no call the Content API currently that would pull back all records. A call to an endpoint will return up to 1000 records, and to get all of them you need to paginate through them using the "?skip=N" functionality from the RSA Archer 6.5 Content API Reference Guide‌. Loop through the calls until you get less than 1000 records back, and then you know you are done.

 

Your call to /contentapi/Applications is correct. I suspect the 500 Error you were getting is due to a bug we've since fixed in a recent CPR version. Check out the release notes, upgrade a dev/test environment, and let me know if that sets you straight.

VargheseJacob
Advocate

Dear Scott,

 

I am trying to get the data of the Security Incident using content API. But unfortunately till the application list only working but not the data from any specific application

For Example

Content api: https://appdev/RSAarcher/contentapi ( this is working)

Metadata : https://appdev/RSAarcher/contentapi/Security_Incidents/Security_Incidents (this is not working)

the below given error message is thrown.

This error (HTTP 500 Internal Server Error) means that the website you are visiting had a server problem which prevented the webpage from displaying.

Anonymous
Not applicable

What version of Archer are you using? We were receiving the 500 server error on 6.4 SP1, but it cleared up when we upgraded to 6.5 P1. I wasn't make a direct call like you are though. I was using Power BI and received the 500 error on specific applications.

Anonymous
Not applicable

Varghese,

 

That second URL doesn't look correct. To pull Security Incidents records out of stock Archer, the Content API URL would be:

 

By adding the extra "/Security_Incidents" on the end, you are telling the API to try to access a field within the Security Incidents application with that alias. If the field doesn't exist, you could be running into that 500 error. We should handle that more gracefully than we are, but I think that's what is going on.

Hi Scott,

 

Thanks for the reply, I have tried with https://appdev/RSAarcher/contentapi/Security_Incidents this link as well, but it gives me the same error of 500!

But for some application it works properly, but not for every application.

Another point:- it give result in UAT environment but not on PROD and DEV.

Hi Douglas,

 

Archer 6.4 P1 is our current version and planning to upgrade to 6.5 P1

Hi Scott, 

 

I found very helpful your guide about content API. So, I get the token and tried to use FeedOdata to connect powerbi to Archer url + "contentapi" using session-id and token as my Basic auth to log in. However, I am run into a 500 error. When I try by browser http:localhost/RSAarcher/contentapi I goes very fine and i can see the metadata and endpoints. Do you have any ideia what this error [500] can be about?

 

error.png

An HTTP 500 error is usually the result of an unhandled .NET exception. Please check your Archer log files and your system event log to find the corresponding log messages. This should give you a better idea of what exception is actually generating the 500.

SILLASCOSTA
Contributor

I am facing a really bad time trying to connect to Archer with PowerBi Feed Odata. While I get 200 response when use postman to acess "https:localhost/Archer/ws/contentapi/" , in Power bi I get an error as show below.  I don't know what else i can do in order to tackle this problem. I'd appreciate any help!! Ty power bi errror.PNG