1. <i id='bibcK'><tr id='bibcK'><dt id='bibcK'><q id='bibcK'><span id='bibcK'><b id='bibcK'><form id='bibcK'><ins id='bibcK'></ins><ul id='bibcK'></ul><sub id='bibcK'></sub></form><legend id='bibcK'></legend><bdo id='bibcK'><pre id='bibcK'><center id='bibcK'></center></pre></bdo></b><th id='bibcK'></th></span></q></dt></tr></i><div id='bibcK'><tfoot id='bibcK'></tfoot><dl id='bibcK'><fieldset id='bibcK'></fieldset></dl></div>
      <tfoot id='bibcK'></tfoot><legend id='bibcK'><style id='bibcK'><dir id='bibcK'><q id='bibcK'></q></dir></style></legend>

        • <bdo id='bibcK'></bdo><ul id='bibcK'></ul>

        <small id='bibcK'></small><noframes id='bibcK'>

        如何正确设置 Swagger for PowerApps?

        时间:2023-10-24
        • <tfoot id='j9bn5'></tfoot>

              <small id='j9bn5'></small><noframes id='j9bn5'>

                <bdo id='j9bn5'></bdo><ul id='j9bn5'></ul>
                  <i id='j9bn5'><tr id='j9bn5'><dt id='j9bn5'><q id='j9bn5'><span id='j9bn5'><b id='j9bn5'><form id='j9bn5'><ins id='j9bn5'></ins><ul id='j9bn5'></ul><sub id='j9bn5'></sub></form><legend id='j9bn5'></legend><bdo id='j9bn5'><pre id='j9bn5'><center id='j9bn5'></center></pre></bdo></b><th id='j9bn5'></th></span></q></dt></tr></i><div id='j9bn5'><tfoot id='j9bn5'></tfoot><dl id='j9bn5'><fieldset id='j9bn5'></fieldset></dl></div>
                    <tbody id='j9bn5'></tbody>
                • <legend id='j9bn5'><style id='j9bn5'><dir id='j9bn5'><q id='j9bn5'></q></dir></style></legend>

                • 本文介绍了如何正确设置 Swagger for PowerApps?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  这是我想要连接到我的 PowerApps 的 Azure 函数

                  This is my Azure function I want to connect to my PowerApps

                          [FunctionName("ConvertMe")]
                      public static IActionResult RunAsync
                          ([HttpTrigger(AuthorizationLevel.Function, "get", Route = null)] HttpRequest req, ILogger log)
                      {
                          log.LogInformation($"Received a Request");
                          ConvertMe Converter = new ConvertMe();
                  
                          string test1 = req.Query["image1"];
                          string test2 = req.Query["image2"];
                  
                  
                          MagickImage _Main = new MagickImage(Convert.FromBase64String(test1), MagickFormat.Png);
                          MagickImage _Overlay = new MagickImage(Convert.FromBase64String(test2), MagickFormat.Png);
                  
                          using (MemoryStream memory = new MemoryStream())
                          {
                              Converter.ComebineBitmap(_Main, _Overlay).Write(memory, MagickFormat.Png);
                              memory.Position = 0;
                              return new FileContentResult(memory.ToArray(),"image/png");
                          }
                  
                      }
                  

                  它已经在本地运行,但我想在 PowerApps 中使用它.如何获得 Swagger 的返回值?

                  Its already working on local but I want to use it in PowerApps. How do I get my return value to Swagger ?

                  我目前的招摇文件

                      {
                    "swagger": "2.0",
                    "info": {
                      "version": "1.0.0",
                      "title": "MyAzureFunction"
                    },
                    "host": "xxx",
                    "paths": {
                      "/api/ConvertMe": {
                        "get": {
                          "description": "Calls my azure function over https",
                          "operationId": "ConvertMe",
                          "parameters": [
                            {
                              "name": "code",
                              "in": "query",
                              "description": "code",
                              "default": "code",
                              "type": "string"
                            },
                            {
                              "name": "image1",
                              "in": "query",
                              "required": true,
                              "type": "string"
                            },     
                            {
                              "name": "image2",
                              "in": "query",
                              "required": true,
                              "type": "string"
                            },
                  
                          ],
                          "responses": {
                            "200": {
                              "description": "Successful response",
                              "schema": {
                                "title": "The response of the api.",
                                "type": "string"
                              }
                            }
                          }
                        }
                      }
                    }
                  }
                  

                  我从未使用过 swagger,但我已经发现,最好是使用 base64 字符串.

                  Ive never worked with swagger but ive already found out, the best is to work with base64 string.

                  推荐答案

                  微软有一个 从无服务器 API 创建 OpenAPI 定义.如果您按照列出的步骤进行操作,您最终将获得下载 OpenAPI 定义步骤,您可以使用它来导入到 powerapps 以制作您的自定义连接器.

                  Microsoft has a tutorial for creating an OpenAPI definition from a server-less API. If you follow the steps laid out you will eventually get to the Download the OpenAPI definition step, which is what you can use to import into powerapps to make your custom connector.

                  这篇关于如何正确设置 Swagger for PowerApps?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  上一篇:错误索引方法“Class.Method"无法将参数“log"绑定到类型 TraceWriter 下一篇:如何在 Azure 函数应用中调用函数后动态更改内容

                  相关文章

                  <small id='VxNVg'></small><noframes id='VxNVg'>

                      <bdo id='VxNVg'></bdo><ul id='VxNVg'></ul>
                  1. <tfoot id='VxNVg'></tfoot>
                    <legend id='VxNVg'><style id='VxNVg'><dir id='VxNVg'><q id='VxNVg'></q></dir></style></legend>
                    <i id='VxNVg'><tr id='VxNVg'><dt id='VxNVg'><q id='VxNVg'><span id='VxNVg'><b id='VxNVg'><form id='VxNVg'><ins id='VxNVg'></ins><ul id='VxNVg'></ul><sub id='VxNVg'></sub></form><legend id='VxNVg'></legend><bdo id='VxNVg'><pre id='VxNVg'><center id='VxNVg'></center></pre></bdo></b><th id='VxNVg'></th></span></q></dt></tr></i><div id='VxNVg'><tfoot id='VxNVg'></tfoot><dl id='VxNVg'><fieldset id='VxNVg'></fieldset></dl></div>