Get blob content using path - seems to be getting the content type instead of the actual content

Lewis Kirk 5 Reputation points
2023-03-09T12:04:02.34+00:00

So I have a logic app which get's the content of a blob json and then writes it somewhere else.

Yesterday it worked perfectly and I was able to run a test without issues, however, which it ran on it's own today instead of getting the contents of the file I get the following:

{

"$content-type": "application/octet-stream",

"$content": "//8nASDA9C.... extremely long string of random characters .....HOIUsA"

}

Any idea what might be causing this?

It's not showing any warnings and the connection I'm using uses an access key (I have recreated the connection and it's still not having it it)

Azure Blob Storage
Azure Blob Storage
An Azure service that stores unstructured data in the cloud as blobs.
3,193 questions
Azure Logic Apps
Azure Logic Apps
An Azure service that automates the access and use of data across clouds without writing code.
3,543 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Lewis Kirk 5 Reputation points
    2023-03-09T14:48:59.57+00:00

    I figured it out in the end, the file was a .json and for whatever reason the get blob storage doesn't seem to be able to see what's inide these but when I changed it to csv (and kept the json formatting within) it worked.

    1 person found this answer helpful.
    0 comments No comments

  2. MayankBargali-MSFT 70,936 Reputation points Moderator
    2023-03-10T06:23:50.4733333+00:00

    @Lewis Kirk Thanks for reaching out. When you use Get blob content using path (V2) action then the return is binary content of the file. Depending upon whether you have configured true value for Infer content type then if the content of file can be infer then it returns the string content of the file else it returns the content-type of the file. Based on the content-type parameter you can now leverage the base64ToString to convert your base64 content to the string.


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.