ADF call Collibra Rest API failed with Rest call failed with "client error, status code 406"

Thomas Zhang 10 Reputation points
2023-04-17T22:21:08.9433333+00:00

Hi, Was trying to connect to Collibra rest api with "Post". My curl command is successful. However, on ADF, I got "Client error, status code 406". I have additional headers set with "Content-type" as application/json. my curl cmd is:

curl -u 'username' -X 'POST' \                                                                                                  
  'https://org_name.collibra.com/rest/2.0/outputModule/export/csv?validationEnabled=false&headerRow=true' \
  -H 'accept: text/plain' \                                                        
  -H 'Content-Type: application/json' \                                         
  -d 'request_body_in_json_string'
Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
11,624 questions
{count} votes

2 answers

Sort by: Most helpful
  1. Thomas Zhang 10 Reputation points
    2023-04-21T12:12:40.0666667+00:00

    Had a support call with Microsoft and was suggested using HTTP service. It is not a perfect solution and had take quite a few workarounds. Really need this feature to be evaluated and issues corrected.

    2 people found this answer helpful.
    0 comments No comments

  2. ShaikMaheer-MSFT 38,546 Reputation points Microsoft Employee Moderator
    2023-04-18T16:32:52.3066667+00:00

    Hi Thomas Zhang,

    Thank you for posting query in Microsoft Q&A Platform.

    The error message you received indicates that the server cannot provide a response that matches the characteristics specified in your request headers.

    Based on the curl command you provided, it seems like you are requesting a CSV file export with a JSON request body. However, the "accept" header in your request specifies that you are expecting a plain text response. This could be causing the 406 error.

    To resolve this issue, you can try changing the "accept" header to "text/csv" to match the expected response format. Additionally, you may want to double-check that the request body you are sending is in the correct JSON format and that all required fields are included.

    If you are still having trouble after making these changes, please let me know and provide any additional information or error messages you receive.

    0 comments No comments

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.