Quickbooks Internet Integration C #

My company is using QuickBooks Online and I would like to write some C # scripts that retrieve very basic information like customer list and invoice list from QuickBooks Online subscription.

I would also like to send invoices and payments.

I created a QuickBooks IPP account (at developer.intuit.com).

I can fully authenticate myself (OAuth). My questions:

1) Do I need to authenticate every time I want to connect to QBO IPP (to get a list of clients, send an invoice, etc.)? Or can my application authenticate once and stay "connected" for months?

2) Is there any sample code for doing basic things like getting a customer list, submitting an invoice, etc.? I downloaded a sample MVC application from this link

And it was very helpful - but when I try to get some of the code to work, I just get errors - which leads me to my first question - can I authenticate myself ONCE and use these tokens (appToken and appTokenSecret) many times to do simple tasks (get a list of clients) or should I check myself every time?

Thank.

+3


source to share


1 answer


Re - 1) Do I need to authenticate every time I want to connect to QBO IPP (to fetch client list, send invoice, etc.)? Or can my application authenticate once and stay "connected" for months?

Below are the steps to get OAuth tokens with which you can make an API call against your QBO account. If you build your app in appcenter, you will get userKey and consumerSecret. https://developer.intuit.com/Application/Create/IA

Using the above two tokens, you can create accessToken and accessSecret with OAuthPlayground. https://appcenter.intuit.com/Playground/OAuth/IA PN - After finishing the C2QB (OAuth) stream, you must use the "App Menu API API". which will show you accessToken and accessSecret.

These tokens are valid for 180 days (maximum). When these tokens are more than 150 days old (and <180 days), you can call the Reconnect API call to validate them again. Ref https://developer.intuit.com/docs/0050_quickbooks_api/0020_authentication_and_authorization/oauth_management_api#Reconnect

This way, you can always transfer these tokens and reuse it.

In order for end users to connect their QB data with your SaaS application, you need to implement a wizard called "Connect to Quickbook". Using 3-legged Oauth, your application will be able to grab the acessToken and acessSecret corresponding to the end user's qbo account. Ref - https://developer.intuit.com/docs/0100_accounting/0060_authentication_and_authorization/connect_from_within_your_app#7._Add_the_Connect_to_QuickBooks_button



Re - 2) Is there any example code for doing basic things like getting a customer list, submitting an invoice, etc.?

Please refer to https://developer.intuit.com/docs/0100_accounting/0500_developer_kits/0150_ipp_.net_devkit_3.0/0002_synchronous_calls#/Data_Services_API

and how to add invoice or sale receipts Quick App api v3.0

Hope this will be helpful.

thank

+8


source







All Articles