API to retrieve QuickBooks Online General Ledger Data with Azure Data Factory - azure

I'm trying to use Azure Data Factory to connect to QuickBooks Online General Ledger using OAUTH2. My approach is to first create a pipeline with a Web Activity to perform a POST call to receive the authentication token, then create a Copy Activity to read a JSON returned from QuickBooks. My approach is based on this blog. from Alex Volok Consultancy.
I have been unable to use the Web Activity successfully. I am unsure of the parameters and how to configure the Web Activity but have tried many different combinations trying to get this to work.
My desired result is to get QuickBooks Online data into Azure, is this the correct approach?
If this is not the best approach, what is?
If this is the correct approach, the attached screenshot shows my attempt at creating the Web Activity parameters to retrieve the authentication token that is currently not working. Any help is appreciated.

Please follow the below approach. It will solve your problem.
Sample URL : http://restapi.adequateshop.com/api/authaccount/login
Postman:
Using Postman, I generated a bearer Token for testing.
I used the same URL with web Activity and generated a bearer Token in the Azure data factory.
Use Your User id and Password as Body.
Output:
For more information refer this SO Thread and Blog by Ashok Patel

Related

Azure ADF Web Activity Form data

I am using Web Activity to get the response from an API. The API takes a Csv file as its body parameter along with some string. I tried using this link How can i pass file as parameter in post request (Web Activity) Azure Data Factory? but could not succeed, I was getting the below error
The other help says to use logic apps for this , has anyone tried using web activity for posting form-data.

Get Records from Salesforce using Azure Logic Apps

I am trying to use Azure Logic Apps to read data from one of the Salesforce objects which has huge number of records. The Salesforce connector fetches the record and returns the pagination link as #odata.nextLink. But when I try to use a JSON parser to read the value it’s coming as null.
I tried to access the nextlink in a browser but it requires authentication. What authentication do we pass here ?
I would like to use an until action to iterate till I get a next link . So how do I check the condition for the until loop ?
nextLink doesn't look like core Salesforce thing, it might be the OData connector preprocessing the results for you. You'd have to consult the documentation for the connector (if any).
Salesforce's REST API will return field with nextRecordsUrl if there's next page of results, you'd call that in loop until the field disappears. You'd call it like any other REST API resource available after login, by passing Authorization: Bearer <sessionId also known as accessToken here>. Again - probably the connector abstracts this away from you. Don't think you can send headers like that in browser, you'd need curl, Postman, SoapUI or similar http client.
If you don't get better answer and documentation is scarce - consider using raw REST API. Or Azure Data Factory has an almost-decent Salesforce connector?
https://developer.salesforce.com/docs/atlas.en-us.api_rest.meta/api_rest/dome_query.htm

Constant Contact V3 API add new contact

I'm attempting to use the new Constant Contact V3 API to add a new email contact. I've been reading the docs: https://v3.developer.constantcontact.com/api_guide/client_flow.html, and trying it out and it seems like the only way to do this now is to make an authentication request, approve the request and then retrieve and access token that is valid for only 2 hours.
I need to have access from my server only and just send an add contact request to Constant Contact. I don't understand why I require to have a redirect uri now and an access token to use the V3 api instead of just using the api key.
With the V2 api I was able to make these types of requests directly from the server without hassle and that's exactly what I need now. The V2 documentation seems to be taken down so I can no longer do that so I'm stuck.
Any help is appreciated.
Based on this link: https://community.constantcontact.com/t5/Developer-Support-ask-questions/v2-or-v3-API-for-very-basic-integration/m-p/324777#M11434, it seems like server-to-server auth is not available still. For those of you who have the same issue, use Mail Chimp or another service that has basic api requirements.
You can get INITIAL Access Token without any code - just use your browser and curl. The Access Token is valid for 24 h, but you can automatically renew it using Refresh Token. You can renew it automatically every time it expires and never need to proceed through INITIAL flow over again. You can read about it here. If you are using C#, I have templates and instructions exactly for your scenario here: https://github.com/mikeks/constantcontact-v3.

How to dynamically pass MS Dynamics token to REST API setup in Azure Data Factory?

MS Dynamics 365 has exposed two REST APIs in order to get to the data. The first API is an URL that returns a token. I need to dynamically pass the token as header to the second REST API and pull the actual data. Can we use Logic Apps or Azure data factory to accomplish this? If yes, can you please provide the steps to accomplish this? Any help will be much appreciated. Thanks in advance.
Logic Apps has a native connector to the D365 Common Data Service, and it can be triggered using a REST call, so it could in effect replace the need for the native REST API, but it would not be my first choice because it will add some overhead (delay) to your round-trip depending on whether the Logic App has been used lately.

Netsuite Token Based Authentication (TBA) with PHPToolkit?

Does anyone have a working sample using Token Based Authentication with the Netsuite PHP Toolkit (Version 2017_1)? I have it working with User/Request based authentication using the sample files but need to move over to token based. I have generated both the consumer and user-based keys, and the integration works with my user/password.
I keep getting the error of "Your connection has timed out. Please log in again." The keys generated are brand new. Does anyone have any trouble with this integration that sounds similar to this?
Try creating a new login passport before each request made to the NetSuite API.
I work with C#, but had the same issue when I initially switched over to TBA. I have a method which creates the token passport and adds it to my NetSuite service object. I then call this method before each API call.
I hope this helps!

Resources