Jump to content

Recommended Posts

Posted

Is it possible to send out an emby connect invite via  the api?

 

I see that I can generate a new user, if I generate a user, then specify their emby connect info, with emby automatically invite them?

Posted

Yes, but i would stay away from this for now. We are going to revamp Emby Connect throughout the remainder of Q1. I would strongly suggest working with what we're going to be building, once that's available, rather than what we currently have. Perhaps in the next month or so we'll make an announcement about what is coming. Thanks.

Posted

Interesting, thanks for the tip!

Posted

Yes, but i would stay away from this for now. We are going to revamp Emby Connect throughout the remainder of Q1. I would strongly suggest working with what we're going to be building, once that's available, rather than what we currently have. Perhaps in the next month or so we'll make an announcement about what is coming. Thanks.

Does this apply to local authentication also?

 

I'm doing some testing... I'm able to authenticate with the a user. But i'm unable to reset the users password once I have the X-Emby-Token

 

Step 1:

Authenticate as user 'success' with the password 'set' using. success's id = 9106d249f0ae47a9af49fcc880684758

http://swagger.emby.media/?url=http://localhost:8096/emby/openapi&api_key=1c1f34fa3c5b4564aff2eb6e62cccbf7#/UserService/postUsersAuthenticatebyname

 

Copy the AccessToken from the response body

Step 2:

Change password from 'set' to 'password'

curl -X POST "http://localhost:8096/emby/Users/9106d249f0ae47a9af49fcc880684758/Password"-H "X-Emby-Token: 600bb07672534c47bee8010b9bebd64e" -H  "accept: */*" -H  "Content-Type: application/json" -d "{\"Id\":\"9106d249f0ae47a9af49fcc880684758\",\"CurrentPw\":\"set\",\"NewPw\":\"password\",\"ResetPassword\":true}"

 

End result:

The users password is removed completely. When I log into the GUI via that user, the user is logged in automatically.

Posted

local authentication won't change.

 

regarding password change, i would use the chrome debugger to compare your request to the web app.

Posted (edited)

I reviewed the web gui developer console in chrome. I see that the web-browser uses the X-Emby-Authorization header with a Token set. I also noticed that after changing the password an HTTP status of 204 is returned.

 

Due to me authenticating with that user whom's password is to be reset I need to use X-Emby-Token.. according to https://github.com/MediaBrowser/Emby/wiki/User-Authentication

 

I have coded it this way, but am still trying to figure out why the password isn't changing. The dashboard is showing the following activity. Note that there is no password initially set for this user, and when I logged in via the web interface after the password change a password was not requested.

2f3b205c-5de5-4e9f-a77b-f96c96d8559f.png

 

I log requests within my application and the logs are below as follows. Note the 204 HTTP status.

 

----------------------

2019-01-20 19:38:59,501 Method: /Users/9431bee7f286432c9c9b31747cb33fb2/Password
Headers:
{'accept': 'application/json', 'Content-Type': 'application/json', 'X-Emby-Token': '052bd42ab2e54d01a4b16e591a512e03'}
Data:
{'Id': '9431bee7f286432c9c9b31747cb33fb2', 'CurrentPw': '', 'NewPw': 'password', 'ResetPassword': True}
2019-01-20 19:38:59,505 Starting new HTTP connection (1): 127.0.0.1:8096
2019-01-20 19:38:59,522 http://127.0.0.1:8096 "POST /emby/Users/9431bee7f286432c9c9b31747cb33fb2/Password HTTP/1.1" 204 0

----------------------

 

The source code for my project can be found here: https://github.com/tiedtoastar/emby-account-automation

 

Let me know if I need to prove my premiere membership for this level of support :D

 

One idea that I had is to change the Update the user to have: HasConfiguredPassword HasPassword to true

Let me know if this is the right way to go down

Edited by tiedToAStar
Posted

Thank you this helped me find my problem. It works now! I was going off the swagger API documentation.

See below:

I was passing the ResetPassword variable, when I don't/shouldn't. The swagger api doc may want to be updated?

UpdateUserPassword{

Id string($guid) CurrentPassword string CurrentPw string NewPw string ResetPassword boolean

}

Posted

You would only use that for resetting rather than changing the password. Yes we should update the docs on that. Thanks.

  • 11 months later...
DRAGUNSLAYER
Posted

Yes, but i would stay away from this for now. We are going to revamp Emby Connect throughout the remainder of Q1. I would strongly suggest working with what we're going to be building, once that's available, rather than what we currently have. Perhaps in the next month or so we'll make an announcement about what is coming. Thanks.

How 'bought now?

Posted

HI, apologies for the delay. We got a little slowed down on this over the year due to other projects, but yes it is still something we are working on.

  • 1 year later...
ShadowKindjal
Posted
On 1/18/2019 at 1:05 AM, Luke said:

Yes, but i would stay away from this for now. We are going to revamp Emby Connect throughout the remainder of Q1. I would strongly suggest working with what we're going to be building, once that's available, rather than what we currently have. Perhaps in the next month or so we'll make an announcement about what is coming. Thanks.

How about now?

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...