microsoftgraph / microsoftgraph/msgraph-metadata

Invalid Path Parameters in openapi.yaml

Open
#424 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
XSLT
Stars
166
Forks
55
Avg merge
16h 12m
Merged PRs (30d)
14

Description

Hi,

it has come to my attention there is inconsistencies in the description document:

aiopenapi3.errors.OperationParameterValidationError: ("/applications(appId='{appId}')", 'delete', 'applications.application.DeleteApplicationByAppId', 'Parameter name not found in path: uniqueName')
aiopenapi3.errors.OperationParameterValidationError: ("/applications(uniqueName='{uniqueName}')", 'patch', 'applications.application.UpdateApplicationByUniqueName', 'Parameter name not found in path: appId')

The parameter in question is

--- x.yml	2023-09-01 08:05:48.391776426 +0200
+++ msgraph-metadata-openapi.yaml	2023-09-01 00:14:15.347979028 +0200
@@ -31133,13 +31133,13 @@
         schema:
           type: string
           nullable: true
-      - name: uniqueName
-        in: path
-        description: Alternate key of application
-        required: true
-        schema:
-          type: string
-          nullable: true
   '/applications(uniqueName=''{uniqueName}'')':
     description: Provides operations to manage the collection of application entities.
     get:
@@ -31298,13 +31298,6 @@
           $ref: '#/components/responses/error'
       x-ms-docs-operation-type: operation
     parameters:
-      - name: appId
-        in: path
-        description: Alternate key of application
-        required: true
-        schema:
-          type: string
-          nullable: true
       - name: uniqueName
         in: path
         description: Alternate key of application

I think required for path parameters is … required, even when declared nullable.

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the referenced Microsoft Graph openapi.yaml document and inspect the /applications(appId='{appId}') and /applications(uniqueName='{uniqueName}') operations. Compare each path template with its declared path parameters, then validate the document to confirm the parameter-name errors are resolved.

Written by the indexing model from the issue text.

Assessment

Tech stack
openapi
Domain
api
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.