intuitdeveloper / oauth2-dotnet_usingsdk Goto Github PK
View Code? Open in Web Editor NEWOAuth2 sample app for .Net using Intuit.Ipp.OAuth2PlatformClient lib/ Intuit's Oauth2 SDK
License: Apache License 2.0
OAuth2 sample app for .Net using Intuit.Ipp.OAuth2PlatformClient lib/ Intuit's Oauth2 SDK
License: Apache License 2.0
When downloading the repository, the solution can't find the project.
When loading the project manually all the references are unavailable.
The project can't find the scopeVal with the ConfigurationManager. I can see that they are in your build folder and not in the project configuration.
After commenting all the non working code, when I click on "Sign In With Intuit" or clicking on "Connect to QuickBooks" I get the error :
"We're sorry!
We're experiencing some problems. Please try again later."
After having downloaded this project as a .zip file, or cloned using CMD, and extracting all the files this project does not run.
Upon opening the .sln file the first error reads as...
C:\Users\nshrivastava\Documents\GitHub\V3-DotNet-SDK.git\IPPDotNetDevKitCSV3\Samples\SampleAppOAuth2Lib\SampleAppOAuth2_UsingSDK.csproj : error : The project file could not be loaded. Could not find a part of the path 'C:\Users\nshrivastava\Documents\GitHub\V3-DotNet-SDK.git\IPPDotNetDevKitCSV3\Samples\SampleAppOAuth2Lib\SampleAppOAuth2_UsingSDK.csproj'. C:\Users\nshrivastava\Documents\GitHub\V3-DotNet-SDK.git\IPPDotNetDevKitCSV3\Samples\SampleAppOAuth2Lib\SampleAppOAuth2_UsingSDK.csproj
The simple fix is to relocate the file path to the csproj file provided by this repo "OAuth2_SampleApp_Dotnet_UsingSDK.csproj" (where ever the project exists on your drive)
Then, reload the project.
Next error, which I am not sure if this is a problem with my environment or not (I suspect not) it reads...
The C# project "OAuth2_SampleApp_Dotnet_UsingSDK" is targeting ".NETFramework,Version=v4.6.1", which is not installed on this machine. To proceed, select an option below.
My options are the change the target framework to v4.5.2 or to download v4.6.1
After downloading the correct version, Windows tells me that I already have v4.6.1 installed... So, I am not sure what that is trying to telling me. Possibly the project looking for the correct files under your personal PC's User files, like before? (C:\Users\nshrivastava...)
So, I try the option to change the target version to v4.5.2.
This lets me open the solution without errors.
Then, after updating clientId, clientSecret, logPath, and redirectURI and rebuilding the solution I get the error of...
This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is ..\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.1.0.0\build\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.props. OAuth2_SampleApp_Dotnet_UsingSDK C:\Development\OAuth2-Dotnet_UsingSDK-master\OAuth2_SampleApp_Dotnet\OAuth2_SampleApp_Dotnet_UsingSDK.csproj
Making sure I have the "Allow nuget to restore packages" option is active I right-click on the solution and hit "Restore NuGet Packages".
The output after this is "All packages are already installed and there is nothing to restore"
I also checked and noticed that a "packages" folder did get downloaded along with the rest of this repo and on further investigation it looks like the folder "\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.1.0.0\build"
does not exist and only "content" and "tools" can be found.
I can't seem to get this example to run, is there any help that could be provided to get this to run?
Are there any plans to use an OAuth client credentials flow in the future?
I'm trying to retrieve the discovery document but I'm getting an error in the DiscoveryClient
that states Issuer name does not match authority: https://oauth.platform.intuit.com/op/v1
I see in the web.config that there is a setting but I've added it and it doesn't seem to be using it. I'm using a .NET Core web app that targets .netstandard 1.3.
Is there another way to set the url for the Authority or to bypass the check? The code example starting on line 288
is what I'm using:
DiscoveryPolicy dpolicy = new DiscoveryPolicy();
dpolicy.RequireHttps = true;
dpolicy.ValidateIssuerName = true;
//Assign the Sandbox Discovery url for the Apps' Dev clientid and clientsecret that you use
//Or
//Assign the Production Discovery url for the Apps' Production clientid and clientsecret that you use
if (discoveryUrl != null && clientID != null && clientSecret != null)
{
discoveryClient = new DiscoveryClient(discoveryUrl);
}
doc = await discoveryClient.GetAsync();
Also dpolicy
doesn't appear to be being used in the example.
Where are your Windows .net samples located for desktop applications that need to do this?
I have defined my ClientID, Secret, and Endpoint URIs in the webconfig and they match the settings in QB API settings in my sandbox.
In my logs:
7/3/2018 8:42:44 AM: Fetching Discovery Data..
7/3/2018 8:42:46 AM: Discovery error.
7/3/2018 8:42:46 AM: Intiating OAuth2 call to get code..
7/3/2018 8:42:46 AM: Setting up Authorize url.
7/3/2018 8:42:46 AM: Missing authorizationEndpoint url!.
I believe there is something wrong with the example or it is not configured correctly with QB. The intro says I add these things to the web.config and I am able to run.
try again workato
Testing integration
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.