OAuth2 authentication

%3CLINGO-SUB%20id%3D%22lingo-sub-558772%22%20slang%3D%22en-US%22%3EOAuth2%20authentication%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-558772%22%20slang%3D%22en-US%22%3E%3CP%3EHi.%20I'm%20trying%20to%20access%20information%20from%20our%20Project%20Online%20installation%20from%20a%20remote%20server%20using%20the%20REST%20interface.%20I'm%20having%20trouble%20getting%20anything%20other%20than%20a%20403%20on%20api%20calls.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EWhat%20I've%20done%3A%3C%2FP%3E%3CP%3E-%20Registered%20the%20app%20using%20the%20AppRegNew.aspx%20page.%20Successfully%20got%20a%20client%20id%20and%20secret.%3C%2FP%3E%3CP%3E-%20Set%20the%20permissions%20using%20the%20AppInv.aspx%20page.%20Included%20all%20the%20scopes%20for%20sharepoint%20as%20%22FullControl%22%20as%20well%20as%20all%20the%20Project%20specific%20scopes.%3C%2FP%3E%3CP%3E-%20Obtained%20a%20token%20successfully%2C%20but%20the%20token%20gave%20me%20authorization%20errors.%26nbsp%3B%3C%2FP%3E%3CP%3E-%20Was%20told%20that%20the%20Project%20REST%20resources%20require%20user%20permissions%20-%20I%20added%20the%20attribute%20AllowAppOnlyPolicy%3D%22false%22%20to%20the%20AppPermisionsRequests%20element%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ENow%2C%20when%20I%20try%20to%20obtain%20a%20token%20I%20do%20indeed%20need%20to%20enter%20a%20user%20id%20and%20password.%20However%2C%20when%20I%20enter%20my%20credentials%20(which%20are%20the%20same%20as%20used%20to%20register%20the%20app%2C%20and%20as%20far%20as%20I%20know%20have%20maximum%20permissions%20on%20every%20asset%2C%20since%20I%20created%20the%20account%20and%20manage%20the%20subscriptions)%2C%20it%20gives%20me%20an%20authentication%20error%20and%20won't%20issue%20a%20token.%20The%20message%20on%20the%20error%20is%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20style%3D%22width%3A%20518px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Fgxcuf89792.i.lithium.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F112949i98E6CFB978C9553F%2Fimage-dimensions%2F518x362%3Fv%3D1.0%22%20width%3D%22518%22%20height%3D%22362%22%20alt%3D%22Screen%20Shot%202019-05-10%20at%209.03.30%20AM.png%22%20title%3D%22Screen%20Shot%202019-05-10%20at%209.03.30%20AM.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ESo%20I'm%20pretty%20stalled...%20any%20trailhead%20to%20trying%20something%20different%20would%20be%20greatly%20appreciated!%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EThanks%2C%3CBR%20%2F%3ERod%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
New Contributor

Hi. I'm trying to access information from our Project Online installation from a remote server using the REST interface. I'm having trouble getting anything other than a 403 on api calls.

 

What I've done:

- Registered the app using the AppRegNew.aspx page. Successfully got a client id and secret.

- Set the permissions using the AppInv.aspx page. Included all the scopes for sharepoint as "FullControl" as well as all the Project specific scopes.

- Obtained a token successfully, but the token gave me authorization errors. 

- Was told that the Project REST resources require user permissions - I added the attribute AllowAppOnlyPolicy="false" to the AppPermisionsRequests element

 

Now, when I try to obtain a token I do indeed need to enter a user id and password. However, when I enter my credentials (which are the same as used to register the app, and as far as I know have maximum permissions on every asset, since I created the account and manage the subscriptions), it gives me an authentication error and won't issue a token. The message on the error is:

 

Screen Shot 2019-05-10 at 9.03.30 AM.png

 

So I'm pretty stalled... any trailhead to trying something different would be greatly appreciated!

 

Thanks,
Rod

0 Replies