API Configuration help ADF

  • Hi I am trying to connect to a HR system to simply pull down some data and copy in ASDB

    I have managed to get it to work in excel using the following code below in the advanced editor but dont even know where to start in terms of where i put this information in Azure Data Factory

    let url="https://api.peoplehr.net/Query",

    body="{""APIKey"": ""ENTER API KEY HERE"",""Action"": ""GetQueryResultByQueryName"",""QueryName"":""ENTER QUERY NAME HERE""}",

    Source = Json.Document(Web.Contents(url,[

    Headers = [ #"Content-Type"="application/json"],

    Content = Text.ToBinary(body)

    ]

    ))

    in Source

    my understanding is this is a REST api and i have an API key. I am very new to ADF and to API's in general, i have spent days on google trying to get a solution that works

    there is a guide here https://help.peoplehr.com/en/articles/2492019-people-queries-and-excel-power-bi

    that describes how to do it in excel which i basicall want to replicate in Azure Data Factory and create a table in SQL DB

    thanks in advance

    I have used the ingest wizard in ADF with the "Copy" function and the source set to REST

    The options on the source only allow me to pass Auth Headers and not additional headers and body (hope that makes sense)

  • Thanks for posting your issue and hopefully someone will answer soon.

    This is an automated bump to increase visibility of your question.

  • In the Source settings of the Copy Activity there is a section to add Additional Headers and if you are doing a Post then it shows the Request Body also.  Maybe they don't show in the wizard (I don't use it) but once you have a Copy Activity they are there.

  • This was removed by the editor as SPAM

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply