API Authentication

  • 8 Replies
  • 1651 Views

0 Members and 5 Guests are viewing this topic.

*

Offline alex_noyes

  • Newbie
  • *
  • 4
  • 1
API Authentication
« on: June 18, 2018, 03:04:50 PM »
Looking at the Swagger page for the magic info premium server api's, I am unable to find some more documentation on how to setup authentication.
What do the headers looks like for the POST request? I just keep getting a 401 error... is there anything I need to configure on the server for API access or token generation?

Thanks,
Alex.

DIGITAL SIGNAGE HELP AND SUPPORT

API Authentication
« on: June 18, 2018, 03:04:50 PM »

*

Offline Pepijn

  • Major Guru
  • **
  • 39
  • 26
Re: API Authentication
« Reply #1 on: June 20, 2018, 03:11:30 PM »
Dear Alex,

Hope this guide will help you:
http://displaysolutions.samsung.com/docs/display/MS1/Open+API

Kind regards,
Pepijn.

*

Offline alex_noyes

  • Newbie
  • *
  • 4
  • 1
Re: API Authentication
« Reply #2 on: June 20, 2018, 03:37:43 PM »
Thanks Pepijn,

That was the first API page I saw, it does not tell me what format the username and password need to be in. Am I sending them as Basic Auth or as parameters in the post?

Thanks,
Alex.

*

Offline chris.porter

  • Newbie
  • *
  • 1
  • 0
Re: API Authentication
« Reply #3 on: August 21, 2018, 04:22:33 PM »
did you find an answer to this?  I'm struggling with authentication as well

DIGITAL SIGNAGE HELP AND SUPPORT

Re: API Authentication
« Reply #3 on: August 21, 2018, 04:22:33 PM »

*

Offline alex_noyes

  • Newbie
  • *
  • 4
  • 1
Re: API Authentication
« Reply #4 on: August 21, 2018, 04:56:43 PM »
Hey Chris,
I am still no further forward with this.

Cheers,
Alex.

*

Offline vllanten

  • Newbie
  • *
  • 3
  • 2
Re: API Authentication
« Reply #5 on: January 02, 2019, 03:02:00 PM »
Effectively, there is no documentation on how to do the login, however it works as follows:

curl -X POST http://127.0.0.1:7001/MagicInfo/auth -H 'content-type: application/json' -d '{ "username" : "admin", "password" : "admin2016"}'

a POST request to the authentication path, sent json parameters, (username / password)

Regards!!

*

Online Kmilo1488

  • Newbie
  • *
  • 1
  • 4
Re: API Authentication
« Reply #6 on: March 30, 2019, 03:45:19 PM »

Hi, I made this example, I hope I help you, https://github.com/Kmilo1488/magic_info

*

Offline baby.bear85

  • Newbie
  • *
  • 2
  • 0
Re: API Authentication
« Reply #7 on: April 18, 2019, 02:06:08 PM »
Hi all,

I'm quite new to MagicInfo API, as far as I know, the Open API have been "replaced" by Rest API, but there are so much details about the authentication step (http://displaysolutions.samsung.com/docs/display/MS1/Open+API) and I'm still stuck on this.

Is there any similiar GET to  " url: "http://192.168.10.74:7001/MagicInfo/openapi/auth?cmd=getAuthToken&id="+id+"&pw="+pw+""?

How can I pass my username and password, using the Rest API?

I only get this:

loadingTime: "500", mobileUrl: "/MagicInfo/...", mobileVersion: null, retryCount: "5", serverVersion: "MagicInfo S...", sizePerMonitoring: "50", sizePerPage: "20", urlPrefixV1: "/restapi/v1.0"}

*

Offline alex_noyes

  • Newbie
  • *
  • 4
  • 1
Re: API Authentication
« Reply #8 on: Yesterday at 03:02:10 PM »
Hi, I made this example, I hope I help you, https://github.com/Kmilo1488/magic_info

Thanks for this Kmilo. I was under the impression that the OpenAPI stuff has been depreciated and the RestAPI was now in use "/MagicInfo/swagger-ui.html#!/"

I will look into it further and report back soon  :)

Cheers,
Alex.

DIGITAL SIGNAGE HELP AND SUPPORT

Re: API Authentication
« Reply #8 on: Yesterday at 03:02:10 PM »