Hi I want to send the data from a blob file to the API in adf. the data is in json form like this { "Name":"" "Id":"" "data":[{},{}]
}
I have tried the web activity but in web activity I need to provide the body how can I get the content of the file. the file is of 40mb so lookup won't work I tried the rest as sink in copy activity but rest support accept application/json whereas I need content-Type application/json
I tried to add header
Content-type : application/jsonin the sink of Rest Api but its throwing error as Content-Type conflicts in AuthHeaders/AdditionalHeaders Is because ADF by default taking header asContent-type : application/jsonno need to mention explicitly if you blob hasContent-type : application/jsonwithout this header it worked for me.As the dataset you have is large file around 40 mb but the Lookup activity, web activity can give you the output around 4 mb (It's a limitation of Azure data factory activities). You cannot read that much big data in ADF and call it in Rest Api body.
There are workaround is as below:
Using azure logic app using blob connector you can read the data from Json file and pass it to the rest Api post request to get the desired output. Here the blob connector in logic app has the limit to read and write the data of 50 mb.
Take a trigger as
when blob is added or updatedit will trigger this logic app flow:Then take
Read blob contentaction to read the data from blob file.Then take HTTP action and pass the response from read blob content to body of http action add your header.
Refer this document to read data from blob using logic app