Comments (4)
@RPS044 I don't think you read my response. This isn't something we can help with here. You need to open an issue with the OpenAPI library you're using.
from json-schema-spec.
I think you're going to need to go to the particular OAS implementation you're using and ask them. This repo (and organization) manages the JSON Schema spec itself, not any particular library.
Some other things to note:
- OAS 3.0 uses its own flavor of JSON Schema that's based on but isn't exactly draft 4.
discriminator
is an OAS-only thing.
When you file an issue with them, see if you can replicate the problem with a small example, and provide that to them. Just posting the error without context isn't helpful.
Sorry we can't be of more help.
from json-schema-spec.
@gregsdennis could you please check now
components:
schemas:
BillableItemsPost:
title: Billable Items Post Request
description: Object defines JSON schema of SAP OTC Billable Items post request
type: object
discriminator:
propertyName: product
mapping:
Generic: '#/components/schemas/BillableItemsPost'
properties:
billableHeader:
description: Billable Item request header
type: object
additionalProperties: false
properties:
product:
description: A discriminator property to identify the schema specifics
type: string
enum:
- Generic
- Airlcl
example: Generic
discriminator:
propertyName: product
mapping:
Generic: '#/components/schemas/BillableItemsPost'
sourceSystem:
description: Upstream System Name **Required for CW1**
type: string
minLength: 1
maxLength: 6
example: GCSS
sourceTransactionType:
description: >-
Source Transaction Type(O- Booking Confirmed, L- Issue Verify
Copy or Pre- Invoice Event, I- Invoice) **Required for CW1**
type: string
enum:
- BOOKING_CONFIRMED
- ISSUE_VERIFY_COPY
- INVOICE
- CREDIT
- CREATE_REV
- UPDATE_REV
- CANCEL_REV
- UPDATE_COST
- CANCEL_COST
- CANCEL_INVOICE
example: INVOICE
eventType:
description: Event Type (Ad-hoc, Batch)
type: string
enum:
- AD-HOC
- BATCH
example: BATCH
messageCreationDatetime:
description: >-
Message Creation Timstamp, used for the message synchronizing to
ensure message is picked in correct sequence **Required for
CW1**
type: string
format: timestamp
example: '20220811140203'
timeZoneCode:
description: >-
Time Zone, Will be used if needed along-with TimeStamp
**Required for CW1**
type: string
minLength: 1
maxLength: 4
example: GMT
isBulkProcessing:
paths:
/billable-items:
post:
summary: Create Billable Item
description: Creates a new Billable Item in S/4 HANA
tags:
- Billable Item
operationId: billable-item-post
requestBody:
content:
application/json:
schema:
x-field-extra-annotation: '@com.fasterxml.jackson.annotation.JsonTypeInfo(
use = com.fasterxml.jackson.annotation.JsonTypeInfo.Id.NAME,
include = com.fasterxml.jackson.annotation.JsonTypeInfo.As.PROPERTY,
property = "product")'
x-class-extra-annotation: '@com.fasterxml.jackson.annotation.@JsonSubTypes({
@JsonSubTypes.Type(value = BillableItemsPost.class, name = "Generic"),
@JsonSubTypes.Type(value = BillableItemsPostAirlcl.class, name = "Airlcl")})'
oneOf:
- $ref: '#/components/schemas/BillableItemsPost'
- $ref: '#/components/schemas/BillableItemsPostAirlcl'
discriminator:
propertyName: product
mapping:
Generic: '#/components/schemas/BillableItemsPost'
Airlcl: '#/components/schemas/BillableItemsPostAirlcl'
from json-schema-spec.
@gregsdennis you should close this one
from json-schema-spec.
Related Issues (20)
- Encountering `$schema` during meta-schema validation HOT 22
- Should we have a supplementary spec template for proposals? HOT 2
- Clean-up of stable features and removal of unstable features HOT 5
- Fixing `contains` and `minContains` HOT 3
- Applicator, Assertion, and Annotation as behaviors not categories HOT 5
- No standard way to define schema for key in "Record-like" objects HOT 2
- Patato HOT 1
- Specification page leads to 404 HOT 2
- If-Then-Else supported? HOT 4
- Core regex should permit "."
- Intended interplay between "type" and "enum" HOT 2
- Validation Regex Description (section 7.3.8) should follow format of other string validation types
- Enum : Clarification HOT 2
- Build failure due to Relative JSON Pointer specification HOT 1
- Pattern: clarification on whether leading and trailing delimiters are allowed or required HOT 2
- Omitted `prefixItems` vs empty HOT 1
- Evaluation path: relative to $ref resolved schema or resource/document root? HOT 4
- JSON
- Feature Request: Constraint for single occurrence of a property structure in JSON Schema HOT 1
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 json-schema-spec.