Error Code 11402 to Call REST API from Azure Data Factory

SarmisthaS 0 Reputation points
2024-04-11T09:17:24.7833333+00:00

Using Copy Activity with REST connector to call REST API. Getting error details - "Error Code 11402. The Remote name could not be resolved: "<Base URL>"." But I am using the same Base URL in Postman which is working . Can you suggest to call from ADF pipeline, do I need to take care anything else ? What can be the possible reasons to get that error in ADF ? Any kind of access certificates need to be granted from Source side ?

Please share your suggestion to resolve that issue in Azure Data Factory pipeline.

Azure Data Factory
Azure Data Factory
An Azure service for ingesting, preparing, and transforming data at scale.
9,567 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Amira Bedhiafi 15,446 Reputation points
    2024-04-11T11:43:19.9566667+00:00

    Based on this old thread, it expects the REST API json having basic authentication to be in this format:

    {
        "name": "RESTLinkedService",
        "properties": {
            "type": "RestService",
            "typeProperties": {
                "authenticationType": "Basic",
                "url" : "<REST endpoint>",
                "userName": "<user name>",
                "password": {
                    "type": "SecureString",
                    "value": "<password>"
                }
            },
            "connectVia": {
                "referenceName": "<name of Integration Runtime>",
                "type": "IntegrationRuntimeReference"
            }
        }
    }
    

    https://learn.microsoft.com/en-us/azure/data-factory/connector-rest?tabs=data-factory#use-basic-authentication

    The JSON for typeProperties should include only the fields authenticationType, url, userName, and password. Please ensure you've included these essential values to see if it resolves your issue. For sending POST, PUT, DELETE, or PATCH requests, consider using web activity where you can also specify a request body.