SSIS script task using RestSharp is saying that cookies and javascript not enabled

Luis Simoes 1 Reputation point
2021-04-01T06:37:57.363+00:00

I am currently trying to use a script to download the results of an API call using RestSharp.
The result of the call is a html page saying that Javascript and cookies are not enabled even though IE settings have all enabled.

I have tried moving the code to a console app c# running on same machine and all works well.

What might be causing the issue here?

Thank you

SQL Server Integration Services
SQL Server Integration Services
A Microsoft platform for building enterprise-level data integration and data transformations solutions.
2,458 questions
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,280 questions
0 comments No comments
{count} votes

3 answers

Sort by: Most helpful
  1. Olaf Helper 40,901 Reputation points
    2021-04-01T07:19:28.353+00:00

    Is this SSIS package running as a job under service account?
    A service account don't have a profile and so no Internet Explorer setting.


  2. Monalv-MSFT 5,896 Reputation points
    2021-04-01T08:20:44.627+00:00

    Hi @Luis Simoes ,

    Could you please share the example code in the Script Task?

    RestSharp is a comprehensive, open-source HTTP client library that works with all kinds of DotNet technologies. It can be used to build robust applications by making it easy to interface with public APIs and quickly access data without the complexity of dealing with raw HTTP requests. RestSharp combines myriad advantages and time-saving features with a simple, clean interface, making it one of the hottest REST tools being used today.

    Please refer to the following links:
    1.What is RestSharp? An Introduction to RestSharp’s Features and Functionality
    2.How To Consume Web API Through SSIS Package

    Best regards,
    Mona

    ----------

    If the answer is helpful, please click "Accept Answer" and upvote it.

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


  3. Luis Simoes 1 Reputation point
    2021-04-05T08:00:58.07+00:00

    Hi @Monalv-MSFT ,

    Any updates on this?

    Thank you

    Regards,
    LS

    0 comments No comments