Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add a couple of logins (request) #109

Open
softwaretech opened this issue Jul 20, 2017 · 0 comments
Open

Add a couple of logins (request) #109

softwaretech opened this issue Jul 20, 2017 · 0 comments

Comments

@softwaretech
Copy link

Hi Team,

I'm wondering if you would be able to add a couple of other login options. I was able to go into the workfront.js and add a second login option.

The process is this:

User logs in as API user. After logging in, a sessionID is created. Using that sessionID, a new project/task/etc... can be created as another user logging as as user with sessionID.

Instead of username:username password:password, use username:username sessionID:sessionID. The value of the sessionID would come from the initial API login. Within my code, I duplicated the login:

t.prototype.**login**=function(e,n){var r=this;return this.request("**login**",{username:e,password:n},null,t.Methods.POST).then(function(t){return r.setSessionID(t.sessionID),t})},t.prototype.**login_as**=function(e,s){ var r=this;return this.request("**login**",{username:e,sessionID:s},null,t.Methods.POST).then(function(t){return r.setSessionID(t.sessionID),t})}

The third option to be included would be an API login:

GET /attask/api-internal/project/abc123xxxxx?apiKey=123abcxxxxxxxxx

https://developers.workfront.com/api-docs/#API_key

Thank you so much for developing this code!! Having run this in PHP compared to NodeJS, I've noticed a MUCH faster response using your code in Node.JS. Just a compliment. :)

Let me know if I can answer any questions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants