简体   繁体   English

具有基本身份验证的Azure Logic App自定义连接器

[英]Azure Logic App Custom Connector With Basic Auth

I have an external API. 我有一个外部API。 I connect to it with Postman via basic auth and all is well. 我通过基本身份验证与邮递员连接,一切都很好。

在此处输入图片说明

The blacked out part is the base64 encoded username:password combination. 涂黑的部分是base64编码的username:password组合。

I save this route as a Postman collection and that collection contains the following, relevant block: 我将此路线另存为Postman集合,并且该集合包含以下相关块:

"headerData": [
{
     "key": "Authorization",
     "value": "Basic <redacted>",
     "description": "",
     "enabled": true
}

At this point, I'm expecting that I will be able to upload the collection file to Azure and it will create me a custom connector that uses my username:password to authenticate. 现在,我希望能够将收集文件上传到Azure,它将创建一个使用我的用户名:密码进行身份验证的自定义连接器。

But it does not: 但这不是:

在此处输入图片说明

Instead, Azure is aware that it will need to use basic auth, but it will not be using the credentials I supplied, nor will it allow me to enter credentials. 相反,Azure知道它将需要使用基本身份验证,但它不会使用我提供的凭据,也不会允许我输入凭据。

1) How would a user enter a valid username/password to use this connector? 1)用户将如何输入有效的用户名/密码来使用此连接器?

2) I want this connector to work autonomously, without user intervention. 2)我希望该连接器能够自主运行,而无需用户干预。 Am I misunderstanding something? 我误会了吗?

EDIT: 编辑:

It's apparently possible to provide the username/password via the logic app itself, but I am never prompted, nor is there anywhere to insert the information: 显然可以通过逻辑应用程序本身提供用户名/密码,但是我从未得到提示,也没有地方插入信息:

在此处输入图片说明

That's the custom connector there with GETReservations . 那是带有GETReservations的自定义连接器。 Basic point still stands. 基本点仍然存在。 I want this to be unattended, no user interaction (after initial setup, of course). 我希望这是无人值守的,没有用户交互(当然,在初始设置之后)。

The Basic authentication screen you have shown is just configuring the labels for username/password that will be displayed when you use the connector within a Logic App. 您显示的基本身份验证屏幕只是为用户名/密码配置标签,这些标签将在您在Logic App中使用连接器时显示。

So if I understand your issue correctly, it should just be a matter of using that custom connector within a Logic App at which point you will be prompted for the username and password. 因此,如果我正确理解了您的问题,那只不过是在Logic App中使用该自定义连接器的问题,此时将提示您输入用户名和密码。

You add the credential when you create the connection in the logic app. 在逻辑应用程序中创建连接时,可以添加凭据。 You have to create a new connection (click on change connection and make a new one). 您必须创建一个新连接(单击更改连接并建立一个新连接)。

This will create a new Api. 这将创建一个新的Api。

You can see you R25LogicAppCustomConnector as an API object in your resource group. 您可以在资源组中看到R25LogicAppCustomConnector作为API对象。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM