[Bug]: The swagger schema have errors and warnings
See original GitHub issueWhat is your BTCPay version?
1.6.12
How did you deploy BTCPay Server?
docker
What happened?
Errors on the swagger schema reported by user.
Errors:
-paths.'/api/v1/stores/{storeId}/custodian-accounts'. Declared path parameter storeId needs to be defined as a path parameter in path or operation level
-attribute components.schemas.CustodianData.items is missing
-paths.'/api/v1/stores/{storeId}/custodian-accounts/{accountId}'. Declared path parameter accountId needs to be defined as a path parameter in path or operation level
-paths.'/api/v1/stores/{storeId}/users'. Declared path parameter storeId needs to be defined as a path parameter in path or operation level
-paths.'/api/v1/stores/{storeId}/custodian-accounts/{accountId}'. Declared path parameter storeId needs to be defined as a path parameter in path or operation level
Warnings:
-paths.'/api/v1/stores/{storeId}/custodian-accounts'. Declared path parameter storeId needs to be defined as a path parameter in path or operation level
-attribute components.schemas.CustodianData.items is missing
-paths.'/api/v1/stores/{storeId}/custodian-accounts/{accountId}'. Declared path parameter accountId needs to be defined as a path parameter in path or operation level
-paths.'/api/v1/stores/{storeId}/users'. Declared path parameter storeId needs to be defined as a path parameter in path or operation level
-paths.'/api/v1/stores/{storeId}/custodian-accounts/{accountId}'. Declared path parameter storeId needs to be defined as a path parameter in path or operation level
this is using maven’s plugin openapi-generator-maven-plugin
How did you encounter this bug?
using https://docs.btcpayserver.org/API/Greenfield/v1/swagger.json
Relevant log output
No response
What browser do you use?
No response
Additional information
No response
Are you sure this is a bug report?
- I confirm this is a bug report
Issue Analytics
- State:
- Created a year ago
- Comments:14 (11 by maintainers)
Top Results From Across the Web
Missing warnings and errors · Issue #1355 · swagger-api ...
In my spec file I wrongly wrongly defined a parameter as "in: query" instead of "in: path". Swagger Editor v2.0 did not give...
Read more >Swagger file with warning
1 Answer 1 · In the beginning, change 'swagger' to "swagger" . JSON requires double quotes around strings. · Remove extra comma at...
Read more >Swagger schema validation failed
trying to import a URL and got this error: Swagger schema validation failed. Data does not match any schemas from 'anyOf' at ...
Read more >Fix Swagger Validator errors in Power Platform connectors
Your swagger has a parameter definition that is incorrectly using '$ref' to point to another definition. ParamtersWithSameNameMustHave
Read more >Describing Responses
For example, you can describe the conditions for error responses. ... In this case, define the response schema with type: file and specify...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
This is what we have decided to do as well for our PHP library.
It might be caused by https://docs.btcpayserver.org/API/Greenfield/v1/swagger.json not being in sync with the latest version from https://mainnet.demo.btcpayserver.org/swagger/v1/swagger.json
Ping @dennisreimann