I have the requirement to log in into Redmine using the REST API. Is it possible to login in Redmine using REST API? How can I handle it?
1 Answers
On the Redmine API wiki you can see the following:
Most of the time, the API requires authentication. To enable the API-style authentication, you have to check Enable REST API in Administration -> Settings -> Authentication.
Then, authentication can be done in 2 different ways:
using your regular login/password via HTTP Basic authentication.
using your API key which is a handy way to avoid putting a password in a script.
The API key may be attached to each request in one of the following way:
passed in as a "key" parameter
passed in as a username with a random password via HTTP Basic authentication
passed in as a "X-Redmine-API-Key" HTTP header (added in Redmine 1.1.0)
You can find your API key on your account page ( /my/account ) when logged in, on the right-hand pane of the default layout.
If you want to use HTTP Basic Authentication you could use this:
1.HTTP Basic auth – http://login:password@redmine.org/issues.xml
2.HTTP Basic auth with API token and login – http://login:RANDOM_KEY@redmine.org/issues.xml- (not supported yet)
3.HTTP Basic auth with API token – http://RANDOM_KEY:X@redmine.org/issues.xml
4.Full token auth – http://redmine.org/issues.xml?key=RANDOM_KEY

- 1,177
- 1
- 10
- 26
-
Yes I did that already, But i want login with my user name and password using rest API. Is it possible to do that. – Randhir Singh Nov 04 '14 at 11:41
-
@RandhirSingh I've bolded the part in my answer that answers your question. – Benjamin Diele Nov 04 '14 at 11:42
-
Yes but how can I can do it, you tell me some example or for that ?? – Randhir Singh Nov 04 '14 at 11:44
-
I just want to check that the requested username and password are from my redmine database . – Randhir Singh Nov 04 '14 at 11:45
-
I want to use http://login:password@redmine.org/issues.xml what do I have to set in user:password. My domain is http://redmine.geminus-qhom.com/redmine/ – Diego Unanue Dec 11 '14 at 19:24