Page 1 of 1
Tm1 restapi in C# app
Posted: Fri Aug 24, 2018 7:59 am
by kavitha2002
I would like to use TM1 RESTapi and Tm1web urlapi in C# application, for logging in into my application I am using TM1web urlapi as
$.ajax({
type: "POST",
url: "
http://localhost:9510/tm1web/dwrx/jsonp ... vice/login",
dataType: "json",
data: {
param0: sAdminHost,
param1: servername,
param2: user,
param3: password
}, - to access the websheet and views.
but for restapi Should i need any authorization?? or simply I can make a call as
http://localhost:8001 with Base64.encode(user + ":" + password);
How to use Tm1 restapi in c# application ?? any Ideas kindly share .. Thanks
Re: Tm1 restapi in C# app
Posted: Sat Aug 25, 2018 3:07 pm
by paulsimon
Hi
I suggest that you do a search online. There are documents on TM1RestAPI authentication. From what I can remember the login should pass back a number that you then need to give on all later calls. However, there are differences between standard TM1 Authentication and CAM
Regards
Paul Simon
Re: Tm1 restapi in C# app
Posted: Sat Aug 25, 2018 5:18 pm
by kavitha2002
Thanks for your reply. But I am using Standard Tm1 only.
But logging into the Tm1 webapi results in SessionToken, with that I can able to call Websheet and views from tm1.
Any ideas of how to handle the Tm1 restapi calls in c# app.
In the mean time i will also go through the docs.
Re: Tm1 restapi in C# app
Posted: Wed Aug 29, 2018 7:11 am
by Harvey
I have played around with the REST API in C#. I got my test scenarios working with authentication, but can't guarantee it'll work in every case.
If you continue to have issues, PM me and I'll send you some code examples. I probably won't have time to dig through the code until the weekend.
Re: Tm1 restapi in C# app
Posted: Sun Sep 02, 2018 7:35 pm
by kavitha2002
Hi,
Thanks for your reply.
In c# application how to make restapi call, and maintain the session. How do we initiate the connection establishment for the further MDX query? Is it something like we have to pass the authorization header as "Basic" and encode64 (userrname+password) and pass it in http client and make request as
http://host:8000/api/v1/ActiveSession???
What it does actually?? I am bit confused.