web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Custom connecter - Iss...
Power Apps
Unanswered

Custom connecter - Issue while creating a definition with Open API and common parameters

(0) ShareShare
ReportReport
Posted on by 2

Hi everyone,

 

We faced a strange behavior of Power Apps Custom connectors, when declaring a new Custom connector using Open API definition: if the Open API definition has common parameters (see "Common parameters" in https://swagger.io/docs/specification/describing-parameters), like common parameters for all methods of a path, they are not taken into account and so the added API is not valid until we manually add the details of the parameters.

 

I summarized the case with a quick demo with 2 valid Open API definitions:

 

#1 - Using parameters at the method level, it will be correctly added

 

 

{
 "swagger": "2.0",
 "info": {
 "description": "Sample description",
 "version": "1.0.0",
 "title": "Swagger Demo"
 },
 "host": "myendpoint.demo.com",
 "basePath": "/v0",
 "schemes": [
 "https"
 ],
 "paths": {
 "/store/order/{orderId}": {
 "get": {
 "summary": "Find purchase order by ID",
 "description": "Quick description of the order by Id operation",
 "operationId": "getOrderById",
 "parameters": [
 {
 "name": "orderId",
 "in": "path",
 "description": "ID of pet that needs to be fetched",
 "required": true,
 "type": "integer",
 "format": "int64"
 }
 ],
 "produces": [
 "application/json"
 ],
 "responses": {
 "200": {
 "description": "successful operation",
 "schema": {
 "$ref": "#/definitions/Order"
 }
 }
 }
 }
 }
 },
 "definitions": {
 "Order": {
 "type": "object",
 "properties": {
 "id": {
 "type": "integer",
 "format": "int64"
 },
 "petId": {
 "type": "integer",
 "format": "int64"
 }
 }
 }
 }
}

 

 

 

Definition is OK:

nrobert_1-1619190697078.png

 

#2 - Using common parameters for the route, the parameter 'orderId' will be missing in the import and the connector will throw an error:

 

 

{
 "swagger": "2.0",
 "info": {
 "description": "Sample description",
 "version": "1.0.0",
 "title": "Swagger Demo"
 },
 "host": "myendpoint.demo.com",
 "basePath": "/v0",
 "schemes": [
 "https"
 ],
 "paths": {
 "/store/order/{orderId}": {
 "parameters": [
 {
 "name": "orderId",
 "in": "path",
 "description": "ID of pet that needs to be fetched",
 "required": true,
 "type": "integer",
 "format": "int64"
 }
 ],
 "get": {
 "summary": "Find purchase order by ID",
 "description": "Quick description of the order by Id operation",
 "operationId": "getOrderById",
 "produces": [
 "application/json"
 ],
 "responses": {
 "200": {
 "description": "successful operation",
 "schema": {
 "$ref": "#/definitions/Order"
 }
 }
 }
 }
 }
 },
 "definitions": {
 "Order": {
 "type": "object",
 "properties": {
 "id": {
 "type": "integer",
 "format": "int64"
 },
 "petId": {
 "type": "integer",
 "format": "int64"
 }
 }
 }
 }
}

 

 

 In the "Definition" tab, there will be the following error:

 Path parameter 'orderId' is referenced in path but not defined.

 

nrobert_0-1619190646494.png

 

 

Any idea of the reason of this issue? When using Swagger editor, both Open API definitions are valid and have the exactly the same result.

Categories:
I have the same question (0)
  • nrobert Profile Picture
    2 on at

    Any chance something faced the same or understand why it happened?

  • Community member Profile Picture
    on at

    #2 is not a valid OpenAPI 2.0 spec.

    It is a gap in the platform.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 534

#2
WarrenBelz Profile Picture

WarrenBelz 416 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 306

Last 30 days Overall leaderboard