Important Update: Some Community URL Redirects are Under Maintenance. Learn More. .

cancel
Showing results for 
Search instead for 
Did you mean: 

Get all Datafeed information into Records with Javascript transporter and API

aftab
Contributor II

Hi, 

we want to create a change control for datafeeds. This will allow us to track changes made to a datafeed. The current idea is to create an application within Archer, where each datafeed is a record.. After each day or hour a (JS)Datafeed writes down the latest information. A JavaScript datafeed will write down the latest information daily or hourly. If something is changed, it will be shown in the record itself through calculations and history will be kept of the changes.

The issue is, we want to use the Internal API for that, from there we are getting all the information we need. But it's using the "x-csrf-token" for authentification instead of "Session Token".  We think that the "x-csrf-token" is generated on the browser side and we cannot generate it ourselves using a user ID and password?!

Is it possible to get this information through a JavaScript transporter for example trough "window.sessionStorage.getItem"? We could also use a SQL datafeed, but it seems more complicated because all the information is written in one column and would need to be extracted afterwards.

Do you have any other ideas or suggestions?

Thanks for your help.

Regards,

Aftab 

2 ACCEPTED SOLUTIONS

Accepted Solutions

rishabhgupta273
Contributor III

Hi @aftab ,

are you trying to say that Archer internal API require "x-csrf-token" and it does not accept "Session Token"????

Upto my knowledge, I created so many scripts which uses Archer Internal API's and till now I have only used Session Token method for authentication purpose whether it is a GET request or POST request






Thank You
RISHABH GUPTA
|| certified archer specialist ||

View solution in original post

DavidPetty
Archer Employee
Archer Employee

@aftab an Archer JS feed doesn'tneed x-csrf-token, that typically is needed when calling the API within a custom object/iview.  You'd just need to create a session token and that's it.

 Advisory Consultant

View solution in original post

7 REPLIES 7

rishabhgupta273
Contributor III

Hi @aftab ,

are you trying to say that Archer internal API require "x-csrf-token" and it does not accept "Session Token"????

Upto my knowledge, I created so many scripts which uses Archer Internal API's and till now I have only used Session Token method for authentication purpose whether it is a GET request or POST request






Thank You
RISHABH GUPTA
|| certified archer specialist ||

DavidPetty
Archer Employee
Archer Employee

@aftab an Archer JS feed doesn'tneed x-csrf-token, that typically is needed when calling the API within a custom object/iview.  You'd just need to create a session token and that's it.

 Advisory Consultant

Absolutely correct @DavidPetty 

MontieroUMB
Contributor

@DavidPetty  can this work if you are a SaaS customer?

MontieroUMB
Contributor

@rishabhgupta273 would you mind providing a template for this?

Yes @MontieroUMB 

it is same for both SaaS and OnPrem type of infra.

Thank you for responding.  Do you have a script template on what you've used?