Hi,
Trying the REST Web service but can't figure out how to authenticate.
Imported: https://raw.githubusercontent.com/OTRS/ ... orREST.yml
And use curl "http://helpdesk.company.com/otrs/nph-ge ... d=password"
and get "Error":{"ErrorCode":"TicketGet.AuthFail","ErrorMessage":"TicketGet: Authorization failing!
I've created a agent and use it for auth, is that the right way to do it?
REST Web service Authfail
Moderator: crythias
Re: REST Web service Authfail
Tried with the root@localhost account as well but doesn't work either.
Any ideas?
Any ideas?
-
- Znuny advanced
- Posts: 121
- Joined: 30 Aug 2011, 10:48
- Znuny Version: 3.3.8 && 4.0.9
- Real Name: Artjoms Petrovs
- Location: Latvia
Re: REST Web service Authfail
With another ssh session take a look with tcpdump -A port 80 if the request sent is well formed.
For me it seems, that you should escape ampersand symbol, when using curl
A.
For me it seems, that you should escape ampersand symbol, when using curl
Code: Select all
curl http://helpdesk.company.com/otrs/nph-genericinterface.pl/Webservice/GenericTicketConnectorREST/Ticket/8?UserLogin=User\&Password=password -X GET
Ar cieņu / Kind regards,
----------------------------------------
Artjoms Petrovs
Sistēmu analītiķis/Programmētājs /
Systems Analyst/Programmer
----------------------------------------
Artjoms Petrovs
Sistēmu analītiķis/Programmētājs /
Systems Analyst/Programmer
Re: REST Web service Authfail
ok tried that as well but no luck.
Have also been using advance rest client for chrome to set the password auth in the header but doesn't work either.
Can't figure out what's wrong.
The tcpdump gave no result.
Have also been using advance rest client for chrome to set the password auth in the header but doesn't work either.
Can't figure out what's wrong.
The tcpdump gave no result.
Re: REST Web service Authfail
Reading a ticket would look like this (GET)
Code: Select all
http://127.0.0.1/otrs/nph-genericinterface.pl/Webservice/GenericTicketConnectorREST/Ticket/1?Password=otrs&DynamicFields=0&UserLogin=jojo&AllArticles=0
"Production": OTRS™ 8, OTRS™ 7, STORM powered by OTRS
"Testing": ((OTRS Community Edition)) and git Master
Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
"Testing": ((OTRS Community Edition)) and git Master
Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
Re: REST Web service Authfail
Thanks that works!jojo wrote:Reading a ticket would look like this (GET)
Code: Select all
http://127.0.0.1/otrs/nph-genericinterface.pl/Webservice/GenericTicketConnectorREST/Ticket/1?Password=otrs&DynamicFields=0&UserLogin=jojo&AllArticles=0