nepda / youtrack-client

A PHP client library for the popular YouTrack bugtracker from jetBrains.
BSD 3-Clause "New" or "Revised" License
25 stars 32 forks source link

Use OAuth for authentication #31

Closed the-JJ closed 7 years ago

the-JJ commented 7 years ago

There should be support for using Hub's OAuth authentication instead of plain username & password

https://www.jetbrains.com/help/hub/2.5/OAuth-2.0-Authorization.html

nepda commented 7 years ago

Good idea, I'll look into this as soon as more time is available. Feel free to create a patch and open a pull request ;)

andreasciamanna commented 7 years ago

Now that they've introduced permanent tokens, this feature became even more useful.

See https://www.jetbrains.com/help/youtrack/incloud/2017.1/Log-in-to-YouTrack.html

the-JJ commented 7 years ago

I made the fork today. Still have to test it a bit, but looks like it's working: https://github.com/the-JJ/youtrack/tree/permanent-token

nepda commented 7 years ago

Nice, thank you! I'll look into it ASAP.

the-JJ commented 7 years ago

Great! I am still not sure how it would behave in case of errors (invalid token, etc), so that has to be checked (and probably some verification implemented).

andreasciamanna commented 7 years ago

I've just started using your library and, for now, I'll stick to the standard user/password authentication.

Once I'm done with my work (*) unless you are faster than me, I'll be happy to fork your project and see if I can propose something for this request.

(*) It may take some time, as it's that kind of "side projects" to work on the little spare time

nepda commented 7 years ago

This feature will be available in v2. This new version is not compatible with the current v1 branch and I've just startet the development. As soon as a working code-base exists I'll push into branch v2.0.0-alpha.

nepda commented 7 years ago

I've added the permanent token login in v1.7.0. Just read the updated README.md for usage information of the new feature.