All Downloads are FREE. Search and download functionalities are using the official Maven repository.

specs.asyncapi.asyncapi-2.0.yaml Maven / Gradle / Ivy

The newest version!
name: AsyncAPI 2.0
version: 2.0
versions:
  - version: 2.0.0
    url: https://www.asyncapi.com/docs/reference/specification/v2.0.0
prefix: AsyncApi20
namespace: io.apicurio.datamodels.models.asyncapi.v20

traits:
  - name: Extensible
    properties:
      - name: '/^x-.+$/'
        type: any
        collection: extensions
  - name: Referenceable
    properties:
      - name: '$ref'
        type: string

entities:
  - name: Document
    root: true
    traits:
      - Extensible
    properties:
      - name: asyncapi
        type: string
      - name: id
        type: string
      - name: info
        type: Info
      - name: servers
        type: Servers
      - name: defaultContentType
        type: string
      - name: channels
        type: Channels
      - name: components
        type: Components
      - name: tags
        type: '[Tag]'
      - name: externalDocs
        type: ExternalDocumentation
    propertyOrder:
      - $this
      - $Extensible

  - name: Info
    traits:
      - Extensible
    properties:
      - name: title
        type: string
      - name: version
        type: string
      - name: description
        type: string
      - name: termsOfService
        type: string
      - name: contact
        type: Contact
      - name: license
        type: License
    propertyOrder:
      - $this
      - $Extensible

  - name: Contact
    traits:
      - Extensible
    properties:
      - name: name
        type: string
      - name: url
        type: string
      - name: email
        type: string
    propertyOrder:
      - $this
      - $Extensible

  - name: License
    traits:
      - Extensible
    properties:
      - name: name
        type: string
      - name: url
        type: string
    propertyOrder:
      - $this
      - $Extensible

  - name: Servers
    properties:
      - name: '*'
        type: Server
    propertyOrder:
      - $this

  - name: Server
    traits:
      - Extensible
    properties:
      - name: url
        type: string
      - name: protocol
        type: string
      - name: protocolVersion
        type: string
      - name: description
        type: string
      - name: variables
        type: '{ServerVariable}'
      - name: security
        type: '[SecurityRequirement]'
      - name: bindings
        type: ServerBindings
    propertyOrder:
      - $this
      - $Extensible

  - name: ServerVariable
    traits:
      - Extensible
    properties:
      - name: enum
        type: '[string]'
      - name: default
        type: string
      - name: description
        type: string
      - name: examples
        type: '[string]'
    propertyOrder:
      - $this
      - $Extensible

  - name: Channels
    properties:
      - name: '*'
        type: ChannelItem
    propertyOrder:
      - $this

  - name: ChannelItem
    traits:
      - Extensible
      - Referenceable
    properties:
      - name: description
        type: string
      - name: subscribe
        type: Operation
      - name: publish
        type: Operation
      - name: parameters
        type: Parameters
      - name: bindings
        type: ChannelBindings
    propertyOrder:
      - $Referenceable
      - $this
      - $Extensible

  - name: Operation
    traits:
      - Extensible
    properties:
      - name: operationId
        type: string
      - name: summary
        type: string
      - name: description
        type: string
      - name: tags
        type: '[Tag]'
      - name: externalDocs
        type: ExternalDocumentation
      - name: bindings
        type: OperationBindings
      - name: traits
        type: '[OperationTrait]'
      - name: message
        type: Message # TODO 'Message|OneOfMessages'
    propertyOrder:
      - $this
      - $Extensible

  - name: OperationTrait
    traits:
      - Extensible
      - Referenceable
    properties:
      - name: operationId
        type: string
      - name: summary
        type: string
      - name: description
        type: string
      - name: tags
        type: '[Tag]'
      - name: externalDocs
        type: ExternalDocumentation
      - name: bindings
        type: OperationBindings
    propertyOrder:
      - $Referenceable
      - $this
      - $Extensible

  - name: Parameters
    properties:
      - name: '*'
        type: Parameter
        collection: items
    propertyOrder:
      - $this

  - name: Parameter
    traits:
      - Extensible
      - Referenceable
    properties:
      - name: description
        type: string
      - name: schema
        type: Schema
      - name: location
        type: string
    propertyOrder:
      - $Referenceable
      - $this
      - $Extensible

  - name: ServerBindings
    properties:
      - name: http
        type: Binding
      - name: ws
        type: Binding
      - name: kafka
        type: Binding
      - name: amqp
        type: Binding
      - name: amqp1
        type: Binding
      - name: mqtt
        type: Binding
      - name: mqtt5
        type: Binding
      - name: nats
        type: Binding
      - name: jms
        type: Binding
      - name: sns
        type: Binding
      - name: sqs
        type: Binding
      - name: stomp
        type: Binding
      - name: redis
        type: Binding
    propertyOrder:
      - $this

  - name: ChannelBindings
    properties:
      - name: http
        type: Binding
      - name: ws
        type: Binding
      - name: kafka
        type: Binding
      - name: amqp
        type: Binding
      - name: amqp1
        type: Binding
      - name: mqtt
        type: Binding
      - name: mqtt5
        type: Binding
      - name: nats
        type: Binding
      - name: jms
        type: Binding
      - name: sns
        type: Binding
      - name: sqs
        type: Binding
      - name: stomp
        type: Binding
      - name: redis
        type: Binding
    propertyOrder:
      - $this

  - name: OperationBindings
    properties:
      - name: http
        type: Binding
      - name: ws
        type: Binding
      - name: kafka
        type: Binding
      - name: amqp
        type: Binding
      - name: amqp1
        type: Binding
      - name: mqtt
        type: Binding
      - name: mqtt5
        type: Binding
      - name: nats
        type: Binding
      - name: jms
        type: Binding
      - name: sns
        type: Binding
      - name: sqs
        type: Binding
      - name: stomp
        type: Binding
      - name: redis
        type: Binding
    propertyOrder:
      - $this

  - name: MessageBindings
    properties:
      - name: http
        type: Binding
      - name: ws
        type: Binding
      - name: kafka
        type: Binding
      - name: amqp
        type: Binding
      - name: amqp1
        type: Binding
      - name: mqtt
        type: Binding
      - name: mqtt5
        type: Binding
      - name: nats
        type: Binding
      - name: jms
        type: Binding
      - name: sns
        type: Binding
      - name: sqs
        type: Binding
      - name: stomp
        type: Binding
      - name: redis
        type: Binding
    propertyOrder:
      - $this

  - name: OneOfMessages
    properties:
      - name: oneOf
        type: '[Message]'
    propertyOrder:
      - $this

  - name: Message
    traits:
      - Extensible
      - Referenceable
    properties:
      - name: oneOf # TODO: remove this when union types are supported and Operation::message is updated 
        type: '[Message]'
      - name: headers
        type: Schema
      - name: payload
        type: any
      - name: correlationId
        type: CorrelationID
      - name: schemaFormat
        type: string
      - name: contentType
        type: string
      - name: name
        type: string
      - name: title
        type: string
      - name: summary
        type: string
      - name: description
        type: string
      - name: tags
        type: '[Tag]'
      - name: externalDocs
        type: ExternalDocumentation
      - name: bindings
        type: MessageBindings
      - name: examples
        type: '{any}'
      - name: traits
        type: '[MessageTrait]'
    propertyOrder:
      - $Referenceable
      - $this
      - $Extensible

  - name: MessageTrait
    traits:
      - Extensible
      - Referenceable
    properties:
      - name: headers
        type: Schema
      - name: correlationId
        type: CorrelationID
      - name: schemaFormat
        type: string
      - name: contentType
        type: string
      - name: name
        type: string
      - name: title
        type: string
      - name: summary
        type: string
      - name: description
        type: string
      - name: tags
        type: '[Tag]'
      - name: externalDocs
        type: ExternalDocumentation
      - name: bindings
        type: MessageBindings
      - name: examples
        type: '{any}'
    propertyOrder:
      - $Referenceable
      - $this
      - $Extensible

  - name: Tag
    traits:
      - Extensible
    properties:
      - name: name
        type: string
      - name: description
        type: string
      - name: externalDocs
        type: ExternalDocumentation
    propertyOrder:
      - $this
      - $Extensible

  - name: ExternalDocumentation
    traits:
      - Extensible
    properties:
      - name: description
        type: string
      - name: url
        type: string
    propertyOrder:
      - $this
      - $Extensible

  - name: Components
    traits:
      - Extensible
    properties:
      - name: schemas
        type: '{Schema}'
      - name: messages
        type: '{Message}'
      - name: securitySchemes
        type: '{SecurityScheme}'
      - name: parameters
        type: '{Parameter}'
      - name: correlationIds
        type: '{CorrelationID}'
      - name: operationTraits
        type: '{OperationTrait}'
      - name: messageTraits
        type: '{MessageTrait}'
      - name: serverBindings
        type: '{ServerBindings}'
      - name: channelBindings
        type: '{ChannelBindings}'
      - name: operationBindings
        type: '{OperationBindings}'
      - name: messageBindings
        type: '{MessageBindings}'
    propertyOrder:
      - $this
      - $Extensible

  - name: Schema
    traits:
      - Extensible
      - Referenceable
    properties:
      - name: title
        type: string
      - name: type
        type: string
      - name: required
        type: '[string]'
      - name: multipleOf
        type: number
      - name: maximum
        type: number
      - name: exclusiveMaximum
        type: number
      - name: minimum
        type: number
      - name: exclusiveMinimum
        type: number
      - name: maxLength
        type: integer
      - name: minLength
        type: integer
      - name: pattern
        type: string
      - name: maxItems
        type: integer
      - name: minItems
        type: integer
      - name: uniqueItems
        type: boolean
      - name: maxProperties
        type: integer
      - name: minProperties
        type: integer
      - name: enum
        type: '[any]'
      - name: const
        type: any
      - name: examples
        type: '[any]'
      - name: if
        type: Schema
      - name: then
        type: Schema
      - name: else
        type: Schema
      - name: readOnly
        type: boolean
      - name: writeOnly
        type: boolean
      - name: properties
        type: '{Schema}'
      - name: patternProperties
        type: '{string}'
      - name: additionalProperties
        type: 'boolean|Schema'
      - name: additionalItems
        type: Schema
      - name: items
        type: 'Schema|[Schema]'
      - name: propertyNames
        type: Schema
      - name: contains
        type: Schema
      - name: allOf
        type: '[Schema]'
      - name: oneOf
        type: '[Schema]'
      - name: anyOf
        type: '[Schema]'
      - name: not
        type: Schema
      - name: description
        type: string
      - name: format
        type: string
      - name: default
        type: any
      - name: discriminator
        type: string
      - name: externalDocs
        type: ExternalDocumentation
      - name: deprecated
        type: boolean
    propertyOrder:
      - $Referenceable
      - $this
      - $Extensible

  - name: SecurityScheme
    traits:
      - Extensible
      - Referenceable
    properties:
      - name: type
        type: string
      - name: description
        type: string
      - name: name
        type: string
      - name: in
        type: string
      - name: scheme
        type: string
      - name: bearerFormat
        type: string
      - name: flows
        type: OAuthFlows
      - name: openIdConnectUrl
        type: string
    propertyOrder:
      - $Referenceable
      - $this
      - $Extensible

  - name: OAuthFlows
    traits:
      - Extensible
    properties:
      - name: implicit
        type: OAuthFlow
      - name: password
        type: OAuthFlow
      - name: clientCredentials
        type: OAuthFlow
      - name: authorizationCode
        type: OAuthFlow
    propertyOrder:
      - $this
      - $Extensible

  - name: OAuthFlow
    traits:
      - Extensible
    properties:
      - name: authorizationUrl
        type: string
      - name: tokenUrl
        type: string
      - name: refreshUrl
        type: string
      - name: scopes
        type: '{string}'
    propertyOrder:
      - $this
      - $Extensible

  - name: SecurityRequirement
    properties:
      - name: '*'
        type: '[string]'
    propertyOrder:
      - $this

  - name: CorrelationID
    traits:
      - Extensible
      - Referenceable
    properties:
      - name: description
        type: string
      - name: location
        type: string
    propertyOrder:
      - $Referenceable
      - $this
      - $Extensible

  - name: Binding
    traits:
      - Extensible
    properties:
      - name: '*'
        type: any
    propertyOrder:
      - $this
      - $Extensible




© 2015 - 2024 Weber Informatics LLC | Privacy Policy