Comments (4)
Nevermind, I see the problem:
The document I'm using has the following content:
"paths": {
"/api/Quote": {
"post": {
"tags": [
"Quote"
],
"summary": "Generates a new quote in the Sales Office system.",
"parameters": [
{
"name": "application",
"in": "header"
},
{
"name": "user-key",
"in": "header"
}
],
RapiPdf seems to require that these have a schema
property, and according to the OpenApi 3 spec it seems that all parameters are required to have a schema
or content
property in which case that seems like an error within the document and not RapiPdf.
I manually create these headers in my backend code so I should be able to fix this, test it works and then close this ticket:
private static readonly OpenApiParameter ApplicationParameter = new OpenApiParameter
{
Name = "application",
In = ParameterLocation.Header,
Required = false
};
private static readonly OpenApiParameter UserKeyParameter = new OpenApiParameter
{
Name = "user-key",
In = ParameterLocation.Header,
Required = false
};
from rapipdf.
The PDF was generated once I fixed up the document that got created:
private static readonly OpenApiParameter ApplicationParameter = new OpenApiParameter
{
Name = "application",
In = ParameterLocation.Header,
Required = false,
Schema = new OpenApiSchema()
};
private static readonly OpenApiParameter UserKeyParameter = new OpenApiParameter
{
Name = "user-key",
In = ParameterLocation.Header,
Required = false,
Schema = new OpenApiSchema()
};
Is paramSchema.depricated
still meant to be paramSchema.deprecated
though?
from rapipdf.
yes paramSchema.depricated
should be paramSchema.deprecated
thanks for pointing it out, will get it fixed in our next patch
from rapipdf.
fixed in release 2.1.1
from rapipdf.
Related Issues (20)
- support for openapi v3.1 HOT 3
- Attribute pdf(-alternate)-color is not applied to toc HOT 1
- Using content to define serialization is not supported in query
- Tool randomly merges two words into one when having description. HOT 1
- anyOf does not work
- feat: add header
- Support images
- Tables aren't being formatted properly
- content application/json in header return error : rapipdf-min.js:33145 Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'deprecated')
- Add images from description markdown to PDF
- when 2 operations have the same input schema definitions, the requests in the PDF output are not displayed HOT 3
- 中文乱码,如何解决? HOT 3
- Demo pages don't work for private content HOT 6
- Feature Request: Support for Webhooks (Callbacks)
- Support Dictionary<string, string>
- Add response headers
- Wrong PDF rendering with basic OpenAPI description HOT 2
- Applying the format value to the type?
- The markdown in parameters property description or in response schema property description is not convert to right html text.
- Hide Request types
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from rapipdf.