diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/ExtendableObject.java b/asyncapi-core/src/main/java/com/asyncapi/v3/ExtendableObject.java new file mode 100644 index 00000000..23f75dc5 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/ExtendableObject.java @@ -0,0 +1,43 @@ +package com.asyncapi.v3; + +import com.fasterxml.jackson.annotation.JsonAnyGetter; +import com.fasterxml.jackson.annotation.JsonAnySetter; +import com.fasterxml.jackson.annotation.JsonIgnoreProperties; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.NoArgsConstructor; +import org.jetbrains.annotations.Nullable; + +import java.util.HashMap; +import java.util.Map; +import java.util.regex.Pattern; + +@Data +@NoArgsConstructor +@AllArgsConstructor +@JsonIgnoreProperties({"extensionFields"}) +public class ExtendableObject { + + private static final Pattern extensionPropertyNamePattern = Pattern.compile("^x-[\\w\\d\\-\\_]+$"); + + /** + * Extension fields in the form x-extension-field-name for the exposed API. + */ + @Nullable + @JsonAnyGetter + protected Map extensionFields; + + @JsonAnySetter + protected final void readExtensionProperty(String name, Object value) { + if (extensionPropertyNamePattern.matcher(name).matches()) { + if (extensionFields == null) { + extensionFields = new HashMap<>(); + } + + extensionFields.put(name, value); + } else { + throw new IllegalArgumentException(String.format("\"%s\" is not valid extension property", name)); + } + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/Reference.java b/asyncapi-core/src/main/java/com/asyncapi/v3/Reference.java new file mode 100644 index 00000000..bd4b78c7 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/Reference.java @@ -0,0 +1,38 @@ +package com.asyncapi.v3; + +import com.fasterxml.jackson.annotation.JsonProperty; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.NoArgsConstructor; +import org.jetbrains.annotations.NotNull; + +/** + * A simple object to allow referencing other components in the specification, internally and externally. + *

+ * The Reference Object is defined by JSON Reference and follows the same structure, behavior and rules. + * A JSON Reference SHALL only be used to refer to a schema that is formatted in either JSON or YAML. + * In the case of a YAML-formatted Schema, the JSON Reference SHALL be applied to the JSON representation of + * that schema. The JSON representation SHALL be made by applying the conversion described here. + *

+ * For this specification, reference resolution is done as defined by the JSON Reference specification and not by + * the JSON Schema specification. + * + * @version 3.0.0 + * @see Reference + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +public class Reference { + + /** + * Required. + *

+ * The reference string. + */ + @NotNull + @JsonProperty(value = "$ref") + private String ref = ""; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/ExternalDocumentationDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/ExternalDocumentationDeserializer.java new file mode 100644 index 00000000..b09ac314 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/ExternalDocumentationDeserializer.java @@ -0,0 +1,23 @@ +package com.asyncapi.v3._0_0.jackson.model; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.asyncapi.v3.jackson.ReferenceOrObjectDeserializer; + +/** + * Deserializes external documentation. + * + * @author Pavel Bodiachevskii + */ +public class ExternalDocumentationDeserializer extends ReferenceOrObjectDeserializer { + + @Override + public Class objectTypeClass() { + return ExternalDocumentation.class; + } + + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/TagsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/TagsDeserializer.java new file mode 100644 index 00000000..71e39397 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/TagsDeserializer.java @@ -0,0 +1,24 @@ +package com.asyncapi.v3._0_0.jackson.model; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.Tag; +import com.asyncapi.v3.jackson.ListOfReferencesOrObjectsDeserializer; + +/** + * Deserializes tags. + * + * @author Pavel Bodiachevskii + */ +public class TagsDeserializer extends ListOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Tag.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/ChannelParametersDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/ChannelParametersDeserializer.java new file mode 100644 index 00000000..88e86b94 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/ChannelParametersDeserializer.java @@ -0,0 +1,25 @@ +package com.asyncapi.v3._0_0.jackson.model.channel; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.channel.Parameter; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +/** + * Serializes {@link com.asyncapi.v3._0_0.model.channel.Parameter} variables map. + * + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +public class ChannelParametersDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Parameter.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/ChannelsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/ChannelsDeserializer.java new file mode 100644 index 00000000..c5cc3c01 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/ChannelsDeserializer.java @@ -0,0 +1,24 @@ +package com.asyncapi.v3._0_0.jackson.model.channel; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.channel.Channel; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +/** + * Serializes component channels map. + * + * @author Pavel Bodiachevskii + */ +public class ChannelsDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Channel.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessageCorrelationIdDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessageCorrelationIdDeserializer.java new file mode 100644 index 00000000..7c0988c2 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessageCorrelationIdDeserializer.java @@ -0,0 +1,23 @@ +package com.asyncapi.v3._0_0.jackson.model.channel.message; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.channel.message.CorrelationId; +import com.asyncapi.v3.jackson.ReferenceOrObjectDeserializer; + +/** + * Serializes message correlation id. + * + * @author Pavel Bodiachevskii + */ +public class MessageCorrelationIdDeserializer extends ReferenceOrObjectDeserializer { + + @Override + public Class objectTypeClass() { + return CorrelationId.class; + } + + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessageHeadersDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessageHeadersDeserializer.java new file mode 100644 index 00000000..6bcb98c0 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessageHeadersDeserializer.java @@ -0,0 +1,77 @@ +package com.asyncapi.v3._0_0.jackson.model.channel.message; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3.schema.Schema; +import com.asyncapi.v3.schema.MultiFormatSchema; +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.JsonProcessingException; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.DeserializationContext; +import com.fasterxml.jackson.databind.JsonDeserializer; +import com.fasterxml.jackson.databind.JsonNode; +import com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException; +import org.jetbrains.annotations.NotNull; + +import java.io.IOException; + +/** + * Serializes message traits list. + * + * @author Pavel Bodiachevskii + */ +public class MessageHeadersDeserializer extends JsonDeserializer { + + @Override + public Object deserialize(JsonParser p, DeserializationContext ctxt) throws IOException, JsonProcessingException { + ObjectCodec objectCodec = p.getCodec(); + JsonNode node = objectCodec.readTree(p); + + /* + Problem: + Both, Reference class and Schema class have $ref field. + So, this is only reason why I receive next exception: + "com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: + Unrecognized field "title" (class com.asyncapi.v2._6_0.model.Reference), + not marked as ignorable (one known property: "$ref"])" + in case when Schema contains $ref. + Solution: + Try to deserialize reference. In case of exception, try to deserialize it as given ObjectType. In case of + one more exception, throw it. + TODO: Think how to improve. + */ + try { + return chooseKnownPojo(node, objectCodec); + } catch (UnrecognizedPropertyException unrecognizedPropertyException) { + return readAsObject(node, objectCodec); + } + } + + private Object chooseKnownPojo(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + JsonNode ref = jsonNode.get("$ref"); + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + if (isMultiFormatSchema(jsonNode)) { + return jsonParser.readValueAs(MultiFormatSchema.class); + } + + if (ref != null) { + return jsonParser.readValueAs(Reference.class); + } else { + return jsonParser.readValueAs(Schema.class); + } + } + } + + private Object readAsObject(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + return jsonParser.readValueAs(Schema.class); + } + } + + private boolean isMultiFormatSchema(@NotNull JsonNode jsonNode) { + JsonNode schemaFormat = jsonNode.get("schemaFormat"); + JsonNode schema = jsonNode.get("schema"); + + return (schemaFormat != null) && (schema != null); + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessagePayloadDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessagePayloadDeserializer.java new file mode 100644 index 00000000..dcf51156 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessagePayloadDeserializer.java @@ -0,0 +1,77 @@ +package com.asyncapi.v3._0_0.jackson.model.channel.message; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3.schema.MultiFormatSchema; +import com.asyncapi.v3.schema.Schema; +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.JsonProcessingException; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.DeserializationContext; +import com.fasterxml.jackson.databind.JsonDeserializer; +import com.fasterxml.jackson.databind.JsonNode; +import com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException; +import org.jetbrains.annotations.NotNull; + +import java.io.IOException; + +/** + * Serializes message traits list. + * + * @author Pavel Bodiachevskii + */ +public class MessagePayloadDeserializer extends JsonDeserializer { + + @Override + public Object deserialize(JsonParser p, DeserializationContext ctxt) throws IOException, JsonProcessingException { + ObjectCodec objectCodec = p.getCodec(); + JsonNode node = objectCodec.readTree(p); + + /* + Problem: + Both, Reference class and Schema class have $ref field. + So, this is only reason why I receive next exception: + "com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: + Unrecognized field "title" (class com.asyncapi.v2._6_0.model.Reference), + not marked as ignorable (one known property: "$ref"])" + in case when Schema contains $ref. + Solution: + Try to deserialize reference. In case of exception, try to deserialize it as given ObjectType. In case of + one more exception, throw it. + TODO: Think how to improve. + */ + try { + return chooseKnownPojo(node, objectCodec); + } catch (UnrecognizedPropertyException unrecognizedPropertyException) { + return readAsObject(node, objectCodec); + } + } + + private Object chooseKnownPojo(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + JsonNode ref = jsonNode.get("$ref"); + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + if (isMultiFormatSchema(jsonNode)) { + return jsonParser.readValueAs(MultiFormatSchema.class); + } + + if (ref != null) { + return jsonParser.readValueAs(Reference.class); + } else { + return jsonParser.readValueAs(Schema.class); + } + } + } + + private Object readAsObject(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + return jsonParser.readValueAs(Schema.class); + } + } + + private boolean isMultiFormatSchema(@NotNull JsonNode jsonNode) { + JsonNode schemaFormat = jsonNode.get("schemaFormat"); + JsonNode schema = jsonNode.get("schema"); + + return (schemaFormat != null) && (schema != null); + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessageTraitsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessageTraitsDeserializer.java new file mode 100644 index 00000000..c5e5058a --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessageTraitsDeserializer.java @@ -0,0 +1,24 @@ +package com.asyncapi.v3._0_0.jackson.model.channel.message; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.channel.message.MessageTrait; +import com.asyncapi.v3.jackson.ListOfReferencesOrObjectsDeserializer; + +/** + * Deserializes message traits. + * + * @author Pavel Bodiachevskii + */ +public class MessageTraitsDeserializer extends ListOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return MessageTrait.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessagesDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessagesDeserializer.java new file mode 100644 index 00000000..8438ddc2 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/channel/message/MessagesDeserializer.java @@ -0,0 +1,25 @@ +package com.asyncapi.v3._0_0.jackson.model.channel.message; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.channel.message.Message; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +/** + * Serializes {@link Message} variables map. + * + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +public class MessagesDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Message.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsChannelsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsChannelsDeserializer.java new file mode 100644 index 00000000..3a233979 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsChannelsDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.channel.Channel; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsChannelsDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Channel.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsCorrelationIdsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsCorrelationIdsDeserializer.java new file mode 100644 index 00000000..3ca82f14 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsCorrelationIdsDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.channel.message.CorrelationId; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsCorrelationIdsDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return CorrelationId.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsExternalDocsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsExternalDocsDeserializer.java new file mode 100644 index 00000000..238f3197 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsExternalDocsDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsExternalDocsDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return ExternalDocumentation.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsMessageTraitsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsMessageTraitsDeserializer.java new file mode 100644 index 00000000..766c33c1 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsMessageTraitsDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.channel.message.MessageTrait; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsMessageTraitsDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return MessageTrait.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsMessagesDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsMessagesDeserializer.java new file mode 100644 index 00000000..26c6c2e6 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsMessagesDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.channel.message.Message; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsMessagesDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Message.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsOperationTraitsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsOperationTraitsDeserializer.java new file mode 100644 index 00000000..23e65e59 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsOperationTraitsDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.operation.OperationTrait; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsOperationTraitsDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return OperationTrait.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsOperationsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsOperationsDeserializer.java new file mode 100644 index 00000000..d78264e2 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsOperationsDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.operation.Operation; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsOperationsDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Operation.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsParametersDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsParametersDeserializer.java new file mode 100644 index 00000000..b35829d3 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsParametersDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.channel.Parameter; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsParametersDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Parameter.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsRepliesDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsRepliesDeserializer.java new file mode 100644 index 00000000..97f5e213 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsRepliesDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.operation.reply.OperationReply; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsRepliesDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return OperationReply.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsReplyAddressesDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsReplyAddressesDeserializer.java new file mode 100644 index 00000000..369f9154 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsReplyAddressesDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.operation.reply.OperationReplyAddress; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsReplyAddressesDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return OperationReplyAddress.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsSchemasDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsSchemasDeserializer.java new file mode 100644 index 00000000..713d49b5 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsSchemasDeserializer.java @@ -0,0 +1,95 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3.schema.MultiFormatSchema; +import com.asyncapi.v3.schema.Schema; +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.JsonProcessingException; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.DeserializationContext; +import com.fasterxml.jackson.databind.JsonDeserializer; +import com.fasterxml.jackson.databind.JsonNode; +import org.jetbrains.annotations.NotNull; + +import java.io.IOException; +import java.util.HashMap; +import java.util.Map; + +public class ComponentsSchemasDeserializer extends JsonDeserializer { + + public Class objectTypeClass() { + return Schema.class; + } + + public Class referenceClass() { + return Reference.class; + } + + @Override + public Map deserialize(JsonParser jsonParser, + DeserializationContext deserializationContext + ) throws IOException, JsonProcessingException { + ObjectCodec objectCodec = jsonParser.getCodec(); + JsonNode map = objectCodec.readTree(jsonParser); + + Map parameters = new HashMap<>(); + + map.fieldNames().forEachRemaining( + fieldName -> { + /* + Problem: + Both, Reference class and Schema class have $ref field. + So, this is only reason why I receive next exception: + "com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: + Unrecognized field "title" (class com.asyncapi.v2._6_0.model.Reference), + not marked as ignorable (one known property: "$ref"])" + in case when Schema contains $ref. + Solution: + Try to deserialize reference. In case of exception, try to deserialize it as given ObjectType. In case of + one more exception, throw it. + TODO: Think how to improve. + */ + try { + parameters.put(fieldName, chooseKnownPojo(map.get(fieldName), objectCodec)); + } catch (IOException ignore) { + try { + parameters.put(fieldName, readAsObject(map.get(fieldName), objectCodec)); + } catch (IOException e) { + e.printStackTrace(); + } + } + } + ); + + return parameters; + } + + private Object chooseKnownPojo(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + JsonNode ref = jsonNode.get("$ref"); + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + if (isMultiFormatSchema(jsonNode)) { + return jsonParser.readValueAs(MultiFormatSchema.class); + } + + if (ref != null) { + return jsonParser.readValueAs(referenceClass()); + } else { + return jsonParser.readValueAs(objectTypeClass()); + } + } + } + + private Object readAsObject(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + return jsonParser.readValueAs(objectTypeClass()); + } + } + + private boolean isMultiFormatSchema(@NotNull JsonNode jsonNode) { + JsonNode schemaFormat = jsonNode.get("schemaFormat"); + JsonNode schema = jsonNode.get("schema"); + + return (schemaFormat != null) && (schema != null); + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsSecuritySchemesDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsSecuritySchemesDeserializer.java new file mode 100644 index 00000000..57f0dbbd --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsSecuritySchemesDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; +import com.asyncapi.v3.security_scheme.SecurityScheme; + +public class ComponentsSecuritySchemesDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return SecurityScheme.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsServerVariablesDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsServerVariablesDeserializer.java new file mode 100644 index 00000000..2836d0df --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsServerVariablesDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.server.ServerVariable; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsServerVariablesDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return ServerVariable.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsServersDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsServersDeserializer.java new file mode 100644 index 00000000..64e77bfd --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsServersDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.server.Server; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsServersDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Server.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsTagsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsTagsDeserializer.java new file mode 100644 index 00000000..ef193b9f --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/component/ComponentsTagsDeserializer.java @@ -0,0 +1,19 @@ +package com.asyncapi.v3._0_0.jackson.model.component; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.Tag; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +public class ComponentsTagsDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Tag.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/OperationTraitsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/OperationTraitsDeserializer.java new file mode 100644 index 00000000..ee7cf16b --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/OperationTraitsDeserializer.java @@ -0,0 +1,24 @@ +package com.asyncapi.v3._0_0.jackson.model.operation; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.operation.OperationTrait; +import com.asyncapi.v3.jackson.ListOfReferencesOrObjectsDeserializer; + +/** + * Serializes operation traits list. + * + * @author Pavel Bodiachevskii + */ +public class OperationTraitsDeserializer extends ListOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return OperationTrait.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/OperationsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/OperationsDeserializer.java new file mode 100644 index 00000000..12e3b8b8 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/OperationsDeserializer.java @@ -0,0 +1,24 @@ +package com.asyncapi.v3._0_0.jackson.model.operation; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.operation.Operation; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +/** + * Serializes component operations map. + * + * @author Pavel Bodiachevskii + */ +public class OperationsDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Operation.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/reply/OperationReplyAddressDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/reply/OperationReplyAddressDeserializer.java new file mode 100644 index 00000000..08d220cc --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/reply/OperationReplyAddressDeserializer.java @@ -0,0 +1,22 @@ +package com.asyncapi.v3._0_0.jackson.model.operation.reply; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.operation.reply.OperationReplyAddress; +import com.asyncapi.v3.jackson.ReferenceOrObjectDeserializer; + +/** + * Serializes operation reply address + * @author Pavel Bodiachevskii + */ +public class OperationReplyAddressDeserializer extends ReferenceOrObjectDeserializer { + + @Override + public Class objectTypeClass() { + return OperationReplyAddress.class; + } + + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/reply/OperationReplyDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/reply/OperationReplyDeserializer.java new file mode 100644 index 00000000..b019f92e --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/operation/reply/OperationReplyDeserializer.java @@ -0,0 +1,22 @@ +package com.asyncapi.v3._0_0.jackson.model.operation.reply; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.operation.reply.OperationReply; +import com.asyncapi.v3.jackson.ReferenceOrObjectDeserializer; + +/** + * Serializes operation reply + * @author Pavel Bodiachevskii + */ +public class OperationReplyDeserializer extends ReferenceOrObjectDeserializer { + + @Override + public Class objectTypeClass() { + return OperationReply.class; + } + + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/server/ServerVariablesDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/server/ServerVariablesDeserializer.java new file mode 100644 index 00000000..2f31028a --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/server/ServerVariablesDeserializer.java @@ -0,0 +1,25 @@ +package com.asyncapi.v3._0_0.jackson.model.server; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.server.ServerVariable; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +/** + * Serializes {@link com.asyncapi.v3._0_0.model.server.Server} variables map. + * + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +public class ServerVariablesDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return ServerVariable.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/server/ServersDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/server/ServersDeserializer.java new file mode 100644 index 00000000..9639ed77 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/jackson/model/server/ServersDeserializer.java @@ -0,0 +1,24 @@ +package com.asyncapi.v3._0_0.jackson.model.server; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.server.Server; +import com.asyncapi.v3.jackson.MapOfReferencesOrObjectsDeserializer; + +/** + * Serializes component servers map. + * + * @author Pavel Bodiachevskii + */ +public class ServersDeserializer extends MapOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return Server.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/AsyncAPI.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/AsyncAPI.java new file mode 100644 index 00000000..fdb84f26 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/AsyncAPI.java @@ -0,0 +1,136 @@ +package com.asyncapi.v3._0_0.model; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.jackson.model.channel.ChannelsDeserializer; +import com.asyncapi.v3._0_0.jackson.model.operation.OperationsDeserializer; +import com.asyncapi.v3._0_0.jackson.model.server.ServersDeserializer; +import com.asyncapi.v3._0_0.model.channel.Channel; +import com.asyncapi.v3._0_0.model.component.Components; +import com.asyncapi.v3._0_0.model.info.Info; +import com.asyncapi.v3._0_0.model.operation.Operation; +import com.asyncapi.v3._0_0.model.server.Server; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.HashMap; +import java.util.Map; + +/** + * This is the root document object for the API specification. + * It combines resource listing and API declaration together into one document. + * + * @version 3.0.0 + * @see AsyncAPI + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class AsyncAPI extends ExtendableObject { + + /** + * Required. + *

+ * Specifies the AsyncAPI Specification version being used. + * It can be used by tooling Specifications and clients to interpret the version. + * The structure shall be major.minor.patch, where patch versions must be compatible + * with the existing major.minor tooling. + *

+ * Typically patch versions will be introduced to address errors in the documentation, + * and tooling should typically be compatible with the corresponding major.minor (1.0.*). + * Patch versions will correspond to patches of this document. + */ + @NotNull + @Builder.Default + private final String asyncapi = "3.0.0"; + + /** + * Identifier of the application the AsyncAPI document is defining. + *

+ * This field represents a unique universal identifier of the application the AsyncAPI document is defining. + * It must conform to the URI format, according to RFC3986. + *

+ * It is RECOMMENDED to use a URN to globally and uniquely identify the application during long periods of time, + * even after it becomes unavailable or ceases to exist. + */ + @Nullable + private String id; + + /** + * A string representing the default content type to use when encoding/decoding a message's payload. + * The value MUST be a specific media type (e.g. application/json). + * This value MUST be used by schema parsers when the contentType property is omitted. + *

+ * In case a message can't be encoded/decoded using this value, schema parsers MUST use their default content type. + */ + @Nullable + private String defaultContentType; + + /** + * Required. + *

+ * Provides metadata about the API. The metadata can be used by the clients if needed. + */ + @NotNull + @Builder.Default + private Info info = new Info(); + + /** + * Provides connection details of servers. + *

+ * MUST BE: + *

    + *
  • {@link Server}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @Builder.Default + @JsonDeserialize(using = ServersDeserializer.class) + private Map servers = new HashMap<>(); + + /** + * The available channels and messages for the API. + *

+ * Holds the relative paths to the individual channel and their operations. Channel paths are relative to servers. + *

+ * Channels are also known as "topics", "routing keys", "event types" or "paths". + *

+ * MUST BE: + *

    + *
  • {@link Channel}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @Builder.Default + @JsonDeserialize(using = ChannelsDeserializer.class) + private Map channels = new HashMap<>(); + + /** + * The available operations for the API. + *

+ * MUST BE: + *

    + *
  • {@link Operation}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @Builder.Default + @JsonDeserialize(using = OperationsDeserializer.class) + private Map operations = new HashMap<>(); + + /** + * An element to hold various schemas for the specification. + */ + @Nullable + private Components components; + +} + diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/ExternalDocumentation.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/ExternalDocumentation.java new file mode 100644 index 00000000..5dc4595e --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/ExternalDocumentation.java @@ -0,0 +1,37 @@ +package com.asyncapi.v3._0_0.model; + +import com.asyncapi.v3.ExtendableObject; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * Allows referencing an external resource for extended documentation. + * + * @version 3.0.0 + * @see ExternalDocumentation + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class ExternalDocumentation extends ExtendableObject { + + /** + * A short description of the target documentation. CommonMark syntax can be used for rich text representation. + */ + @Nullable + private String description; + + /** + * Required. + *

+ * The URL for the target documentation. Value MUST be in the format of a URL. + */ + @NotNull + @Builder.Default + private String url = ""; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/Tag.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/Tag.java new file mode 100644 index 00000000..3ae2df83 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/Tag.java @@ -0,0 +1,50 @@ +package com.asyncapi.v3._0_0.model; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.jackson.model.ExternalDocumentationDeserializer; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * Allows adding meta data to a single tag. + * + * @version 3.0.0 + * @see Tag + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class Tag extends ExtendableObject { + + /** + * Required. The name of the tag. + */ + @NotNull + @Builder.Default + private String name = ""; + + /** + * A short description for the tag. CommonMark syntax can be used for rich text representation. + */ + @Nullable + private String description; + + /** + * Additional external documentation for this tag. + * MUST BE: + *

    + *
  • {@link ExternalDocumentation}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ExternalDocumentationDeserializer.class) + private Object externalDocs; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/Channel.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/Channel.java new file mode 100644 index 00000000..91d91de9 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/Channel.java @@ -0,0 +1,147 @@ +package com.asyncapi.v3._0_0.model.channel; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.jackson.model.ExternalDocumentationDeserializer; +import com.asyncapi.v3._0_0.jackson.model.TagsDeserializer; +import com.asyncapi.v3._0_0.jackson.model.channel.message.MessagesDeserializer; +import com.asyncapi.v3._0_0.jackson.model.channel.ChannelParametersDeserializer; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.asyncapi.v3._0_0.model.Tag; +import com.asyncapi.v3._0_0.model.channel.message.Message; +import com.asyncapi.v3.binding.channel.ChannelBinding; +import com.asyncapi.v3.jackson.binding.channel.ChannelBindingsDeserializer; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.List; +import java.util.Map; + +/** + * Describes a shared communication channel. + * + * @version 3.0.0 + * @see ChannelItem + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class Channel extends ExtendableObject { + + /** + * An optional string representation of this channel's address. The address is typically the "topic name", + * "routing key", "event type", or "path". When null or absent, it MUST be interpreted as unknown. + * This is useful when the address is generated dynamically at runtime or can't be known upfront. + *

+ * It MAY contain Channel Address Expressions. + */ + @Nullable + private String address; + + /** + * A human-friendly title for the channel. + */ + @Nullable + private String title; + + /** + * A short summary of the channel. + */ + @Nullable + private String summary; + + /** + * An optional description of this channel. + *

+ * CommonMark syntax can be used for rich text representation. + */ + @Nullable + private String description; + + /** + * An array of $ref pointers to the definition of the servers in which this channel is available. + *

+ * If servers is absent or empty, this channel MUST be available on all the servers defined in the Servers Object. + * Please note the servers property value MUST be an array of Reference Objects and, therefore, + * MUST NOT contain an array of Server Objects. + *

+ * However, it is RECOMMENDED that parsers (or other software) dereference this property + * for a better development experience. + */ + @Nullable + private List servers; + + /** + * A map of the parameters included in the channel address. + *

+ * It MUST be present only when the address contains Channel Address Expressions. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link Parameter}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ChannelParametersDeserializer.class) + private Map parameters; + + /** + * A map of the messages that will be sent to this channel by any application at any time. + * Every message sent to this channel MUST be valid against one, and only one, of the message + * objects defined in this map. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link Message}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = MessagesDeserializer.class) + private Map messages; + + /** + * A map where the keys describe the name of the protocol and the values describe protocol-specific definitions for the channel. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link ChannelBinding}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ChannelBindingsDeserializer.class) + private Map bindings; + + /** + * A list of tags for logical grouping of channels. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link Tag}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = TagsDeserializer.class) + private List tags; + + /** + * Additional external documentation for this channel. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link ExternalDocumentation}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ExternalDocumentationDeserializer.class) + private Object externalDocs; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/Parameter.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/Parameter.java new file mode 100644 index 00000000..c624bb4d --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/Parameter.java @@ -0,0 +1,56 @@ +package com.asyncapi.v3._0_0.model.channel; + +import com.asyncapi.v3.ExtendableObject; +import com.fasterxml.jackson.annotation.JsonProperty; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * Describes a parameter included in a channel address. + * + * @version 3.0.0 + * @see Parameter + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class Parameter extends ExtendableObject { + + /** + * An optional description for the parameter. CommonMark syntax MAY be used for rich text representation. + */ + @Nullable + private String description; + + /** + * The default value to use for substitution, and to send, if an alternate value is not supplied. + */ + @Nullable + @JsonProperty("default") + private String defaultValue; + + /** + * An enumeration of string values to be used if the substitution options are from a limited set. + */ + @Nullable + @JsonProperty("enum") + private List enumValues; + + /** + * An array of examples of the parameter value. + */ + @Nullable + private List examples; + + /** + * A runtime expression that specifies the location of the parameter value. + */ + @Nullable + private String location; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/CorrelationId.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/CorrelationId.java new file mode 100644 index 00000000..09b97a06 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/CorrelationId.java @@ -0,0 +1,39 @@ +package com.asyncapi.v3._0_0.model.channel.message; + +import com.asyncapi.v3.ExtendableObject; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * An object that specifies an identifier at design time that can used for message tracing and correlation. + *
+ * For specifying and computing the location of a Correlation ID, a runtime expression is used. + * + * @version 3.0.0 + * @see CorrelationId + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class CorrelationId extends ExtendableObject { + + /** + * An optional description of the identifier. CommonMark syntax can be used for rich text representation. + */ + @Nullable + private String description; + + /** + * REQUIRED. + *

+ * A runtime expression that specifies the location of the correlation ID. + */ + @NotNull + @Builder.Default + private String location = ""; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/Message.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/Message.java new file mode 100644 index 00000000..c8ab1ea0 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/Message.java @@ -0,0 +1,184 @@ +package com.asyncapi.v3._0_0.model.channel.message; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.jackson.model.ExternalDocumentationDeserializer; +import com.asyncapi.v3._0_0.jackson.model.TagsDeserializer; +import com.asyncapi.v3._0_0.jackson.model.channel.message.MessageCorrelationIdDeserializer; +import com.asyncapi.v3._0_0.jackson.model.channel.message.MessageTraitsDeserializer; +import com.asyncapi.v3._0_0.jackson.model.channel.message.MessageHeadersDeserializer; +import com.asyncapi.v3._0_0.jackson.model.channel.message.MessagePayloadDeserializer; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.asyncapi.v3._0_0.model.Tag; +import com.asyncapi.v3.jackson.binding.message.MessageBindingsDeserializer; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.List; +import java.util.Map; + +/** + * Describes a message received on a given channel and operation. + * + * @version 3.0.0 + * @see Message + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class Message extends ExtendableObject { + + /** + * Unique string used to identify the message. + *

+ * The id MUST be unique among all messages described in the API. The messageId value is case-sensitive. + * Tools and libraries MAY use the messageId to uniquely identify a message, therefore, it is RECOMMENDED to + * follow common programming naming conventions. + */ + @Nullable + private String messageId; + + /** + * Schema definition of the application headers. + *

+ * Schema MUST be a map of key-value pairs. + *

+ * It MUST NOT define the protocol headers. + *

+ * If this is a Schema Object, then the schemaFormat will be assumed to + * be "application/vnd.aai.asyncapi+json;version=asyncapi" where the version + * is equal to the AsyncAPI Version String. + *

+ * MUST BE: + *

    + *
  • {@link com.asyncapi.v3.Reference}
  • + *
  • {@link com.asyncapi.v3.schema.Schema}
  • + *
  • {@link com.asyncapi.v3.schema.MultiFormatSchema}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = MessageHeadersDeserializer.class) + private Object headers; + + /** + * Definition of the message payload. If this is a Schema Object, then the schemaFormat will be assumed to be + * "application/vnd.aai.asyncapi+json;version=asyncapi" where the version is equal to the AsyncAPI Version String. + *

+ * MUST BE: + *

    + *
  • {@link com.asyncapi.v3.Reference}
  • + *
  • {@link com.asyncapi.v3.schema.Schema}
  • + *
  • {@link com.asyncapi.v3.schema.MultiFormatSchema}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = MessagePayloadDeserializer.class) + private Object payload; + + /** + * Definition of the correlation ID used for message tracing or matching. + *

+ * MUST BE: + *

    + *
  • {@link com.asyncapi.v3.Reference}
  • + *
  • {@link CorrelationId}
  • + *
+ */ + @JsonDeserialize(using = MessageCorrelationIdDeserializer.class) + private Object correlationId; + + /** + * The content type to use when encoding/decoding a message's payload. The value MUST be a specific media type + * (e.g. application/json). When omitted, the value MUST be the one specified on the defaultContentType field. + */ + @Nullable + private String contentType; + + /** + * A machine-friendly name for the message. + */ + @Nullable + private String name; + + /** + * A human-friendly title for the message. + */ + @Nullable + private String title; + + /** + * A short summary of what the message is about. + */ + @Nullable + private String summary; + + /** + * A verbose explanation of the message. CommonMark syntax can be used for rich text representation. + */ + @Nullable + private String description; + + /** + * A map where the keys describe the name of the protocol and the values describe protocol-specific definitions for the message. + *

+ * MUST BE: + *

    + *
  • {@link com.asyncapi.v3.Reference}
  • + *
  • {@link com.asyncapi.v3.binding.message.MessageBinding}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = MessageBindingsDeserializer.class) + private Map bindings; + + /** + * List of examples. + */ + @Nullable + private List examples; + + /** + * A list of traits to apply to the message object. Traits MUST be merged using traits merge mechanism. + * The resulting object MUST be a valid Message Object. + *

+ * MUST BE: + *

    + *
  • {@link com.asyncapi.v3.Reference}
  • + *
  • {@link com.asyncapi.v3._0_0.model.channel.message.MessageTrait}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = MessageTraitsDeserializer.class) + private List traits; + + /** + * A list of tags for logical grouping and categorization of messages. + *

+ * MUST BE: + *

    + *
  • {@link com.asyncapi.v3.Reference}
  • + *
  • {@link Tag}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = TagsDeserializer.class) + private List tags; + + /** + * Additional external documentation for this channel. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link ExternalDocumentation}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ExternalDocumentationDeserializer.class) + private Object externalDocs; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/MessageExample.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/MessageExample.java new file mode 100644 index 00000000..dd31f990 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/MessageExample.java @@ -0,0 +1,43 @@ +package com.asyncapi.v3._0_0.model.channel.message; + +import com.asyncapi.v3.ExtendableObject; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.Map; + +/** + * Message Example Object represents an example of a {@link Message} Object and MUST contain either headers and/or payload fields. + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MessageExample extends ExtendableObject { + + /** + * The value of this field MUST validate against the {@link Message#getHeaders()} headers field. + */ + @Nullable + public Map headers; + + /** + * The value of this field MUST validate against the Message {@link Message#getPayload()} field. + */ + @Nullable + public Map payload; + + /** + * A machine-friendly name. + */ + @Nullable + private String name; + + /** + * A short summary of what the example is about. + */ + @Nullable + private String summary; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/MessageTrait.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/MessageTrait.java new file mode 100644 index 00000000..19417966 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/channel/message/MessageTrait.java @@ -0,0 +1,156 @@ +package com.asyncapi.v3._0_0.model.channel.message; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.jackson.model.ExternalDocumentationDeserializer; +import com.asyncapi.v3._0_0.jackson.model.TagsDeserializer; +import com.asyncapi.v3._0_0.jackson.model.channel.message.MessageCorrelationIdDeserializer; +import com.asyncapi.v3._0_0.jackson.model.channel.message.MessageHeadersDeserializer; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.asyncapi.v3._0_0.model.Tag; +import com.asyncapi.v3.binding.message.MessageBinding; +import com.asyncapi.v3.jackson.binding.message.MessageBindingsDeserializer; +import com.asyncapi.v3.schema.MultiFormatSchema; +import com.asyncapi.v3.schema.Schema; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.List; +import java.util.Map; + +/** + * Describes a message received on a given channel and operation. + * + * @version 3.0.0 + * @see Message + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MessageTrait extends ExtendableObject { + + /** + * Unique string used to identify the message. + *

+ * The id MUST be unique among all messages described in the API. The messageId value is case-sensitive. + * Tools and libraries MAY use the messageId to uniquely identify a message, therefore, it is RECOMMENDED to + * follow common programming naming conventions. + */ + @Nullable + private String messageId; + + /** + * Schema definition of the application headers. + *

+ * Schema MUST be a map of key-value pairs. + *

+ * It MUST NOT define the protocol headers. + *

+ * If this is a Schema Object, then the schemaFormat will be assumed to + * be "application/vnd.aai.asyncapi+json;version=asyncapi" where the version + * is equal to the AsyncAPI Version String. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link Schema}
  • + *
  • {@link MultiFormatSchema}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = MessageHeadersDeserializer.class) + private Object headers; + + /** + * Definition of the correlation ID used for message tracing or matching. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link CorrelationId}
  • + *
+ */ + @JsonDeserialize(using = MessageCorrelationIdDeserializer.class) + private Object correlationId; + + /** + * The content type to use when encoding/decoding a message's payload. The value MUST be a specific media type + * (e.g. application/json). When omitted, the value MUST be the one specified on the defaultContentType field. + */ + @Nullable + private String contentType; + + /** + * A machine-friendly name for the message. + */ + @Nullable + private String name; + + /** + * A human-friendly title for the message. + */ + @Nullable + private String title; + + /** + * A short summary of what the message is about. + */ + @Nullable + private String summary; + + /** + * A verbose explanation of the message. CommonMark syntax can be used for rich text representation. + */ + @Nullable + private String description; + + /** + * A map where the keys describe the name of the protocol and the values describe protocol-specific definitions for the message. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link MessageBinding}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = MessageBindingsDeserializer.class) + private Map bindings; + + /** + * List of examples. + */ + @Nullable + private List examples; + + /** + * A list of tags for logical grouping and categorization of messages. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link Tag}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = TagsDeserializer.class) + private List tags; + + /** + * Additional external documentation for this channel. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link ExternalDocumentation}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ExternalDocumentationDeserializer.class) + private Object externalDocs; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/component/Components.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/component/Components.java new file mode 100644 index 00000000..c53538ac --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/component/Components.java @@ -0,0 +1,293 @@ +package com.asyncapi.v3._0_0.model.component; + +import com.asyncapi.v3._0_0.jackson.model.component.*; +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.asyncapi.v3._0_0.model.Tag; +import com.asyncapi.v3._0_0.model.channel.Channel; +import com.asyncapi.v3._0_0.model.channel.Parameter; +import com.asyncapi.v3._0_0.model.channel.message.CorrelationId; +import com.asyncapi.v3._0_0.model.channel.message.Message; +import com.asyncapi.v3._0_0.model.channel.message.MessageTrait; +import com.asyncapi.v3._0_0.model.operation.Operation; +import com.asyncapi.v3._0_0.model.operation.OperationTrait; +import com.asyncapi.v3._0_0.model.operation.reply.OperationReply; +import com.asyncapi.v3._0_0.model.operation.reply.OperationReplyAddress; +import com.asyncapi.v3._0_0.model.server.Server; +import com.asyncapi.v3._0_0.model.server.ServerVariable; +import com.asyncapi.v3.binding.channel.ChannelBinding; +import com.asyncapi.v3.binding.message.MessageBinding; +import com.asyncapi.v3.binding.operation.OperationBinding; +import com.asyncapi.v3.binding.server.ServerBinding; +import com.asyncapi.v3.jackson.binding.channel.ChannelBindingsDeserializer; +import com.asyncapi.v3.jackson.binding.message.MessageBindingsDeserializer; +import com.asyncapi.v3.jackson.binding.operation.OperationBindingsDeserializer; +import com.asyncapi.v3.jackson.binding.server.ServerBindingsDeserializer; +import com.asyncapi.v3.schema.MultiFormatSchema; +import com.asyncapi.v3.schema.Schema; +import com.asyncapi.v3.security_scheme.SecurityScheme; +import com.asyncapi.v3.ExtendableObject; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.Map; + +/** + * Holds a set of reusable objects for different aspects of the AsyncAPI specification. + * All objects defined within the components object will have no effect on the API unless they are explicitly referenced + * from properties outside the components object. + * + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class Components extends ExtendableObject { + + /** + * An object to hold reusable {@link }Schema Objects. + *

+ * MUST BE: + *

    + *
  • {@link Schema}
  • + *
  • {@link MultiFormatSchema}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsSchemasDeserializer.class) + private Map schemas; + + /** + * An object to hold reusable {@link Server} Objects. + *

+ * MUST BE: + *

    + *
  • {@link Server}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsServersDeserializer.class) + private Map servers; + + /** + * An object to hold reusable {@link ServerVariable} Objects. + *

+ * MUST BE: + *

    + *
  • {@link ServerVariable}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsServerVariablesDeserializer.class) + private Map serverVariables; + + /** + * An object to hold reusable {@link Channel} Objects. + *

+ * MUST BE: + *

    + *
  • {@link Channel}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsChannelsDeserializer.class) + private Map channels; + + /** + * An object to hold reusable {@link Operation} Objects. + *

+ * MUST BE: + *

    + *
  • {@link Operation}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsOperationsDeserializer.class) + private Map operations; + + /** + * An object to hold reusable {@link OperationReply} Objects. + *

+ * MUST BE: + *

    + *
  • {@link OperationReply}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsRepliesDeserializer.class) + private Map replies; + + /** + * An object to hold reusable {@link OperationReplyAddress} Objects. + *

+ * MUST BE: + *

    + *
  • {@link OperationReplyAddress}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsReplyAddressesDeserializer.class) + private Map replyAddresses; + + /** + * An object to hold reusable {@link Message} Objects. + *

+ * MUST BE: + *

    + *
  • {@link Message}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsMessagesDeserializer.class) + private Map messages; + + /** + * An object to hold reusable {@link SecurityScheme} Objects. + *

+ * MUST BE: + *

    + *
  • {@link SecurityScheme}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsSecuritySchemesDeserializer.class) + private Map securitySchemes; + + /** + * An object to hold reusable {@link Parameter} Objects. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link Parameter}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsParametersDeserializer.class) + private Map parameters; + + /** + * An object to hold reusable {@link CorrelationId} Objects. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link CorrelationId}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsCorrelationIdsDeserializer.class) + private Map correlationIds; + + /** + * An object to hold reusable {@link OperationTrait} Objects. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link OperationTrait}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsOperationTraitsDeserializer.class) + private Map operationTraits; + + /** + * An object to hold reusable {@link MessageTrait} Objects. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link MessageTrait}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsMessageTraitsDeserializer.class) + private Map messageTraits; + + /** + * An object to hold reusable {@link ServerBinding} Objects. + * MUST BE: + *
    + *
  • {@link Reference}
  • + *
  • {@link ServerBinding}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ServerBindingsDeserializer.class) + private Map serverBindings; + + /** + * An object to hold reusable {@link ChannelBinding} Objects. + * MUST BE: + *
    + *
  • {@link Reference}
  • + *
  • {@link ChannelBinding}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ChannelBindingsDeserializer.class) + private Map channelBindings; + + /** + * An object to hold reusable {@link OperationBinding} Objects. + * MUST BE: + *
    + *
  • {@link Reference}
  • + *
  • {@link OperationBinding}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = OperationBindingsDeserializer.class) + private Map operationBindings; + + /** + * An object to hold reusable {@link MessageBinding} Objects. + * MUST BE: + *
    + *
  • {@link Reference}
  • + *
  • {@link MessageBinding}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = MessageBindingsDeserializer.class) + private Map messageBindings; + + /** + * An object to hold reusable {@link ExternalDocumentation} Objects. + * MUST BE: + *
    + *
  • {@link Reference}
  • + *
  • {@link ExternalDocumentation}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsExternalDocsDeserializer.class) + private Map externalDocs; + + /** + * An object to hold reusable {@link Tag} Objects. + * MUST BE: + *
    + *
  • {@link Reference}
  • + *
  • {@link Tag}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ComponentsTagsDeserializer.class) + private Map tags; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/info/Contact.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/info/Contact.java new file mode 100644 index 00000000..ec6fd3c6 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/info/Contact.java @@ -0,0 +1,39 @@ +package com.asyncapi.v3._0_0.model.info; + +import com.asyncapi.v3.ExtendableObject; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Contact information for the exposed API. + * + * @version 3.0.0 + * @see Contact + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class Contact extends ExtendableObject { + + /** + * The identifying name of the contact person/organization. + */ + @Nullable + private String name; + + /** + * The URL pointing to the contact information. MUST be in the format of a URL. + */ + @Nullable + private String url; + + /** + * The email address of the contact person/organization. MUST be in the format of an email address. + */ + @Nullable + private String email; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/info/Info.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/info/Info.java new file mode 100644 index 00000000..ed8d7b4e --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/info/Info.java @@ -0,0 +1,107 @@ +package com.asyncapi.v3._0_0.model.info; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.jackson.model.ExternalDocumentationDeserializer; +import com.asyncapi.v3._0_0.jackson.model.TagsDeserializer; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.asyncapi.v3._0_0.model.Tag; +import com.asyncapi.v3.ExtendableObject; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * The object provides metadata about the API. The metadata can be used by the clients if needed. + * + * @version 3.0.0 + * @see Info + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class Info extends ExtendableObject { + + /** + * Required. + *

+ * The title of the application. + */ + @NotNull + @JsonProperty + @Builder.Default + private String title = ""; + + /** + * Required. + *

+ * Provides the version of the application API (not to be confused with the specification version). + */ + @NotNull + @JsonProperty + @Builder.Default + private String version = ""; + + /** + * A short description of the application. CommonMark syntax can be used for rich text representation. + */ + @Nullable + @JsonProperty + private String description; + + /** + * A URL to the Terms of Service for the API. MUST be in the format of a URL. + */ + @Nullable + @JsonProperty + private String termsOfService; + + /** + * The contact information for the exposed API. + */ + @Nullable + @JsonProperty + private Contact contact; + + /** + * The license information for the exposed API. + */ + @Nullable + @JsonProperty + private License license; + + /** + * A list of tags for application API documentation control. Tags can be used for logical grouping of applications. + *

+ * MUST BE: + *

    + *
  • {@link Tag}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonProperty + @JsonDeserialize(using = TagsDeserializer.class) + private List tags; + + /** + * Additional external documentation of the exposed API. + *

+ * MUST BE: + *

    + *
  • {@link ExternalDocumentation}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonProperty + @JsonDeserialize(using = ExternalDocumentationDeserializer.class) + private Object externalDocs; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/info/License.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/info/License.java new file mode 100644 index 00000000..a8737428 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/info/License.java @@ -0,0 +1,35 @@ +package com.asyncapi.v3._0_0.model.info; + +import com.asyncapi.v3.ExtendableObject; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * License information for the exposed API. + * + * @version 3.0.0 + * @see License + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class License extends ExtendableObject { + + /** + * Required. The license name used for the API. + */ + @NotNull + @Builder.Default + private String name = ""; + + /** + * A URL to the license used for the API. MUST be in the format of a URL. + */ + @Nullable + private String url; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/Operation.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/Operation.java new file mode 100644 index 00000000..71e08da5 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/Operation.java @@ -0,0 +1,167 @@ +package com.asyncapi.v3._0_0.model.operation; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.jackson.model.ExternalDocumentationDeserializer; +import com.asyncapi.v3._0_0.jackson.model.TagsDeserializer; +import com.asyncapi.v3._0_0.jackson.model.operation.OperationTraitsDeserializer; +import com.asyncapi.v3._0_0.jackson.model.operation.reply.OperationReplyDeserializer; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.asyncapi.v3._0_0.model.Tag; +import com.asyncapi.v3._0_0.model.operation.reply.OperationReply; +import com.asyncapi.v3.binding.operation.OperationBinding; +import com.asyncapi.v3.jackson.binding.operation.OperationBindingsDeserializer; +import com.asyncapi.v3.jackson.security_scheme.SecuritySchemesDeserializer; +import com.asyncapi.v3.security_scheme.SecurityScheme; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.List; +import java.util.Map; + +/** + * Describes a specific operation. + * + * @version 3.0.0 + * @see Operation + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class Operation extends ExtendableObject { + + /** + * Required. + *

+ * Use send when it's expected that the application will send a message to the given channel, and receive when + * the application should expect receiving messages from the given channel. + */ + @NotNull + private OperationAction action; + + /** + * Required. + *

+ * A $ref pointer to the definition of the channel in which this operation is performed. + * Please note the channel property value MUST be a Reference Object and, therefore, MUST NOT contain a Channel Object. + * However, it is RECOMMENDED that parsers (or other software) dereference this property for a better development experience. + */ + @NotNull + private Reference channel; + + /** + * A human-friendly title for the operation. + */ + @Nullable + private String title; + + /** + * A short summary of what the operation is about. + */ + @Nullable + private String summary; + + /** + * A verbose explanation of the operation. CommonMark syntax can be used for rich text representation. + */ + @Nullable + private String description; + + /** + * A declaration of which security schemes are associated with this operation. + * Only one of the security scheme objects MUST be satisfied to authorize an operation. + * In cases where Server Security also applies, it MUST also be satisfied. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link SecurityScheme}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = SecuritySchemesDeserializer.class) + private List security; + + /** + * A list of tags for logical grouping and categorization of operations. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link Tag}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = TagsDeserializer.class) + private List tags; + + /** + * Additional external documentation for this channel. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link ExternalDocumentation}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ExternalDocumentationDeserializer.class) + private Object externalDocs; + + /** + * A map where the keys describe the name of the protocol and the values describe protocol-specific definitions for the operation. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link OperationBinding}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = OperationBindingsDeserializer.class) + private Map bindings; + + /** + * A list of traits to apply to the operation object. Traits MUST be merged using traits merge mechanism. + * The resulting object MUST be a valid Operation Object. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link OperationTrait}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = OperationTraitsDeserializer.class) + private List traits; + + /** + * A list of $ref pointers pointing to the supported Message Objects that can be processed by this operation. + * It MUST contain a subset of the messages defined in the channel referenced in this operation. + * Every message processed by this operation MUST be valid against one, and only one, of the message objects + * referenced in this list. Please note the messages property value MUST be a list of Reference Objects and, + * therefore, MUST NOT contain Message Objects. However, it is RECOMMENDED that parsers (or other software) + * dereference this property for a better development experience. + */ + @Nullable + private List messages; + + /** + * The definition of the reply in a request-reply operation. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link OperationReply}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = OperationReplyDeserializer.class) + private Object reply; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/OperationAction.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/OperationAction.java new file mode 100644 index 00000000..17bd85b7 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/OperationAction.java @@ -0,0 +1,13 @@ +package com.asyncapi.v3._0_0.model.operation; + +import com.fasterxml.jackson.annotation.JsonProperty; + +public enum OperationAction { + + @JsonProperty("send") + SEND, + + @JsonProperty("receive") + RECEIVE + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/OperationTrait.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/OperationTrait.java new file mode 100644 index 00000000..891a5ed2 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/OperationTrait.java @@ -0,0 +1,133 @@ +package com.asyncapi.v3._0_0.model.operation; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.jackson.model.ExternalDocumentationDeserializer; +import com.asyncapi.v3._0_0.jackson.model.TagsDeserializer; +import com.asyncapi.v3._0_0.jackson.model.operation.reply.OperationReplyDeserializer; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.asyncapi.v3._0_0.model.Tag; +import com.asyncapi.v3._0_0.model.operation.reply.OperationReply; +import com.asyncapi.v3.binding.operation.OperationBinding; +import com.asyncapi.v3.jackson.binding.operation.OperationBindingsDeserializer; +import com.asyncapi.v3.jackson.security_scheme.SecuritySchemesDeserializer; +import com.asyncapi.v3.security_scheme.SecurityScheme; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.List; +import java.util.Map; + +/** + * Describes a trait that MAY be applied to an Operation Object. This object MAY contain any property from the + * Operation Object, except the action, channel and traits ones. + * + * @version 3.0.0 + * @see Operation + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class OperationTrait extends ExtendableObject { + + /** + * A human-friendly title for the operation. + */ + @Nullable + private String title; + + /** + * A short summary of what the operation is about. + */ + @Nullable + private String summary; + + /** + * A verbose explanation of the operation. CommonMark syntax can be used for rich text representation. + */ + @Nullable + private String description; + + /** + * A declaration of which security schemes are associated with this operation. + * Only one of the security scheme objects MUST be satisfied to authorize an operation. + * In cases where Server Security also applies, it MUST also be satisfied. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link SecurityScheme}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = SecuritySchemesDeserializer.class) + private List security; + + /** + * A list of tags for logical grouping and categorization of operations. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link Tag}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = TagsDeserializer.class) + private List tags; + + /** + * Additional external documentation for this channel. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link ExternalDocumentation}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ExternalDocumentationDeserializer.class) + private Object externalDocs; + + /** + * A map where the keys describe the name of the protocol and the values describe protocol-specific definitions for the operation. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link OperationBinding}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = OperationBindingsDeserializer.class) + private Map bindings; + + /** + * A list of $ref pointers pointing to the supported Message Objects that can be processed by this operation. + * It MUST contain a subset of the messages defined in the channel referenced in this operation. + * Every message processed by this operation MUST be valid against one, and only one, of the message objects + * referenced in this list. Please note the messages property value MUST be a list of Reference Objects and, + * therefore, MUST NOT contain Message Objects. However, it is RECOMMENDED that parsers (or other software) + * dereference this property for a better development experience. + */ + @Nullable + private List messages; + + /** + * The definition of the reply in a request-reply operation. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link OperationReply}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = OperationReplyDeserializer.class) + private Object reply; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/reply/OperationReply.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/reply/OperationReply.java new file mode 100644 index 00000000..b362e8a7 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/reply/OperationReply.java @@ -0,0 +1,60 @@ +package com.asyncapi.v3._0_0.model.operation.reply; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.jackson.model.operation.reply.OperationReplyAddressDeserializer; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * Describes the reply part that MAY be applied to an Operation Object. If an operation implements the request/reply + * pattern, the reply object represents the response message. + * + * @version 3.0.0 + * @see Operation + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class OperationReply extends ExtendableObject { + + /** + * Definition of the address that implementations MUST use for the reply. + *

+ * MUST BE: + *

    + *
  • {@link Reference}
  • + *
  • {@link OperationReplyAddress}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = OperationReplyAddressDeserializer.class) + private Object address; + + /** + * A $ref pointer to the definition of the channel in which this operation is performed. + * When address is specified, the address property of the channel referenced by this property MUST be either null + * or not defined. Please note the channel property value MUST be a Reference Object and, therefore, MUST NOT contain + * a Channel Object. However, it is RECOMMENDED that parsers (or other software) dereference this property for + * a better development experience. + */ + @Nullable + private Reference channel; + + /** + * A list of $ref pointers pointing to the supported Message Objects that can be processed by this operation as reply. + * It MUST contain a subset of the messages defined in the channel referenced in this operation reply. Every message + * processed by this operation MUST be valid against one, and only one, of the message objects referenced in this list. + * Please note the messages property value MUST be a list of Reference Objects and, therefore, MUST NOT contain Message Objects. + * However, it is RECOMMENDED that parsers (or other software) dereference this property for a better development experience. + */ + @Nullable + private List messages; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/reply/OperationReplyAddress.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/reply/OperationReplyAddress.java new file mode 100644 index 00000000..768711d0 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/operation/reply/OperationReplyAddress.java @@ -0,0 +1,37 @@ +package com.asyncapi.v3._0_0.model.operation.reply; + +import com.asyncapi.v3.ExtendableObject; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * An object that specifies where an operation has to send the reply. + *

+ * For specifying and computing the location of a reply address, a runtime expression is used. + * + * @version 3.0.0 + * @see Operation + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class OperationReplyAddress extends ExtendableObject { + + /** + * An optional description of the address. CommonMark syntax can be used for rich text representation. + */ + @Nullable + private String description; + + /** + * REQUIRED. + *

+ * A runtime expression that specifies the location of the reply address. + */ + @Nullable + private String location; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/server/Server.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/server/Server.java new file mode 100644 index 00000000..669f1668 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/server/Server.java @@ -0,0 +1,172 @@ +package com.asyncapi.v3._0_0.model.server; + +import com.asyncapi.v3.jackson.binding.server.ServerBindingsDeserializer; +import com.asyncapi.v3._0_0.jackson.model.server.ServerVariablesDeserializer; +import com.asyncapi.v3.binding.server.ServerBinding; +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.Reference; +import com.asyncapi.v3._0_0.jackson.model.ExternalDocumentationDeserializer; +import com.asyncapi.v3._0_0.jackson.model.TagsDeserializer; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.asyncapi.v3._0_0.model.Tag; +import com.asyncapi.v3.jackson.security_scheme.SecuritySchemesDeserializer; +import com.asyncapi.v3.security_scheme.SecurityScheme; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.List; +import java.util.Map; + +/** + * An object representing a message broker, a server or any other kind of computer program capable of sending and/or + * receiving data. This object is used to capture details such as URIs, protocols and security configuration. + * Variable substitution can be used so that some details, for example usernames and passwords, can be injected by + * code generation tools. + * + * @version 3.0.0 + * @see Server + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class Server extends ExtendableObject { + + /** + * REQUIRED. + *

+ * The server host name. It MAY include the port. This field supports Server Variables. + * Variable substitutions will be made when a variable is named in {braces}. + */ + @NotNull + @JsonProperty + @Builder.Default + private String host = ""; + + /** + * REQUIRED. + *

+ * The protocol this URL supports for connection. Supported protocol include, but are not limited to: + * amqp, amqps, http, https, jms, kafka, kafka-secure, mqtt, secure-mqtt, stomp, stomps, ws, wss. + */ + @NotNull + @JsonProperty + @Builder.Default + private String protocol = ""; + + /** + * The version of the protocol used for connection. For instance: AMQP 0.9.1, HTTP 2.0, Kafka 1.0.0, etc. + */ + @Nullable + @JsonProperty + private String protocolVersion; + + /** + * The path to a resource in the host. This field supports Server Variables. + * Variable substitutions will be made when a variable is named in {braces}. + */ + @Nullable + @JsonProperty + private String pathname; + + /** + * An optional string describing the host designated by the URL. CommonMark syntax MAY be used for rich text + * representation. + */ + @Nullable + @JsonProperty + private String description; + + /** + * A human-friendly title for the server. + */ + @Nullable + @JsonProperty + private String title; + + /** + * A short summary of the server. + */ + @Nullable + @JsonProperty + private String summary; + + /** + * A map between a variable name and its value. + * The value is used for substitution in the server's host and pathname template. + *

+ * MUST BE: + *

    + *
  • {@link ServerVariable}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonProperty + @JsonDeserialize(using = ServerVariablesDeserializer.class) + private Map variables; + + /** + * A declaration of which security schemes can be used with this server. The list of values includes alternative + * security scheme objects that can be used. Only one of the security scheme objects need to be satisfied to + * authorize a connection or operation. + *

+ * MUST BE: + *

    + *
  • {@link SecurityScheme}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonProperty + @JsonDeserialize(using = SecuritySchemesDeserializer.class) + private List security; + + /** + * A list of tags for logical grouping and categorization of servers. + *

+ * MUST BE: + *

    + *
  • {@link Tag}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonProperty + @JsonDeserialize(using = TagsDeserializer.class) + private List tags; + + /** + * Additional external documentation of the exposed API. + *

+ * MUST BE: + *

    + *
  • {@link ExternalDocumentation}
  • + *
  • {@link Reference}
  • + *
+ */ + @Nullable + @JsonProperty + @JsonDeserialize(using = ExternalDocumentationDeserializer.class) + private Object externalDocs; + + /** + * A map where the keys describe the name of the protocol and the values describe protocol-specific definitions + * for the server. + *

+ * MUST be one of: + *

    + *
  • {@link Reference}
  • + *
  • {@link ServerBinding}
  • + *
+ */ + @Nullable + @JsonDeserialize(using = ServerBindingsDeserializer.class) + private Map bindings; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/server/ServerVariable.java b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/server/ServerVariable.java new file mode 100644 index 00000000..9e20243f --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/_0_0/model/server/ServerVariable.java @@ -0,0 +1,50 @@ +package com.asyncapi.v3._0_0.model.server; + +import com.asyncapi.v3.ExtendableObject; +import com.fasterxml.jackson.annotation.JsonProperty; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * An object representing a Server Variable for server URL template substitution. + * + * @version 3.0.0 + * @see ServerVariable + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class ServerVariable extends ExtendableObject { + + /** + * An enumeration of string values to be used if the substitution options are from a limited set. + */ + @Nullable + @JsonProperty(value = "enum") + private List enumValues; + + /** + * The default value to use for substitution, and to send, if an alternate value is not supplied. + */ + @Nullable + @JsonProperty("default") + private String defaultValue; + + /** + * An optional description for the server variable. CommonMark syntax MAY be used for rich text representation. + */ + @Nullable + private String description; + + /** + * An array of examples of the server variable. + */ + @Nullable + private List examples; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ChannelBinding.java new file mode 100644 index 00000000..f73b6f3e --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ChannelBinding.java @@ -0,0 +1,13 @@ +package com.asyncapi.v3.binding.channel; + +import com.asyncapi.v3.ExtendableObject; +import lombok.EqualsAndHashCode; + +/** + * Describes AsyncAPI channel binding. + * + * @author Pavel Bodiachevskii + */ +@EqualsAndHashCode(callSuper = true) +public class ChannelBinding extends ExtendableObject { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/AMQPChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/AMQPChannelBinding.java new file mode 100644 index 00000000..bed4fa16 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/AMQPChannelBinding.java @@ -0,0 +1,62 @@ +package com.asyncapi.v3.binding.channel.amqp; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import com.asyncapi.v3.binding.channel.amqp.exchange.AMQPChannelExchangeProperties; +import com.asyncapi.v3.binding.channel.amqp.queue.AMQPChannelQueueProperties; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * Describes AMQP 0-9-1 channel binding. + *

+ * Contains information about the channel representation in AMQP. + * + * @version 0.2.0 + * @see AMQP channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes AMQP 0-9-1 channel binding.") +public class AMQPChannelBinding extends ChannelBinding { + + /** + * Defines what type of channel is it. Can be either queue or routingKey (default). + */ + @NotNull + @Builder.Default + @javax.validation.constraints.NotNull + @JsonProperty(value = "is", required = true, defaultValue = "routingKey") + @JsonPropertyDescription("Defines what type of channel is it. Can be either queue or routingKey (default).") + private AMQPChannelType is = AMQPChannelType.ROUTING_KEY; + + /** + * When is=routingKey, this object defines the exchange properties. + */ + @Nullable + @JsonProperty("exchange") + @JsonPropertyDescription("When is=routingKey, this object defines the exchange properties.") + private AMQPChannelExchangeProperties exchange; + + /** + * When is=queue, this object defines the queue properties. + */ + @Nullable + @JsonProperty("queue") + @JsonPropertyDescription("When is=queue, this object defines the queue properties.") + private AMQPChannelQueueProperties queue; + + @Nullable + @Builder.Default + @JsonProperty(value = "bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private final String bindingVersion = "0.2.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/AMQPChannelType.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/AMQPChannelType.java new file mode 100644 index 00000000..e6fe8c81 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/AMQPChannelType.java @@ -0,0 +1,24 @@ +package com.asyncapi.v3.binding.channel.amqp; + +import com.fasterxml.jackson.annotation.JsonAlias; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Describes AMQP 0-9-1 channel type. + *

+ * Contains information about the type of channel in AMQP. + * + * @version 0.2.0 + * @see AMQP channel binding + * @author Pavel Bodiachevskii + */ +public enum AMQPChannelType { + + @JsonProperty("queue") + QUEUE, + + @JsonProperty("routingKey") + @JsonAlias("routingKey") + ROUTING_KEY + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/exchange/AMQPChannelExchangeProperties.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/exchange/AMQPChannelExchangeProperties.java new file mode 100644 index 00000000..6c7b0465 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/exchange/AMQPChannelExchangeProperties.java @@ -0,0 +1,71 @@ +package com.asyncapi.v3.binding.channel.amqp.exchange; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes AMQP 0-9-1 channel exchange properties. + *

+ * Contains information about the channel exchange properties in AMQP. + * + * @version 0.2.0 + * @see AMQP channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode +@JsonClassDescription("Describes AMQP 0-9-1 channel exchange properties.") +public class AMQPChannelExchangeProperties { + + /** + * The name of the exchange. It MUST NOT exceed 255 characters long. + */ + @Nullable + @javax.validation.constraints.Size( + max = 255, + message = "Exchange name must not exceed 255 characters long." + ) + @JsonProperty("name") + @JsonPropertyDescription("The name of the exchange. It MUST NOT exceed 255 characters long.") + private String name; + + /** + * The type of the exchange. Can be either topic, direct, fanout, default or headers. + */ + @Nullable + @JsonProperty("type") + @JsonPropertyDescription("The type of the exchange. Can be either topic, direct, fanout, default or headers.") + private AMQPChannelExchangeType type; + + /** + * Whether the exchange should survive broker restarts or not. + */ + @Nullable + @JsonProperty("durable") + @JsonPropertyDescription("Whether the exchange should survive broker restarts or not.") + private Boolean durable; + + /** + * Whether the exchange should be deleted when the last queue is unbound from it. + */ + @Nullable + @JsonProperty("autoDelete") + @JsonPropertyDescription("Whether the exchange should be deleted when the last queue is unbound from it.") + private Boolean autoDelete; + + /** + * The virtual host of the exchange. Defaults to /. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "vhost", defaultValue = "/") + @JsonPropertyDescription("The virtual host of the exchange. Defaults to /.") + private String vhost = "/"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/exchange/AMQPChannelExchangeType.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/exchange/AMQPChannelExchangeType.java new file mode 100644 index 00000000..6a4211bc --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/exchange/AMQPChannelExchangeType.java @@ -0,0 +1,33 @@ +package com.asyncapi.v3.binding.channel.amqp.exchange; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Describes AMQP 0-9-1 channel exchange type. + *

+ * Contains information about the channel exchange type in AMQP. + * + * @version 0.2.0 + * @see AMQP channel binding + * @author Pavel Bodiachevskii + */ +@JsonClassDescription("Describes AMQP 0-9-1 channel exchange type.") +public enum AMQPChannelExchangeType { + + @JsonProperty("topic") + TOPIC, + + @JsonProperty("direct") + DIRECT, + + @JsonProperty("fanout") + FANOUT, + + @JsonProperty("default") + DEFAULT, + + @JsonProperty("headers") + HEADERS + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/queue/AMQPChannelQueueProperties.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/queue/AMQPChannelQueueProperties.java new file mode 100644 index 00000000..18f49c26 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp/queue/AMQPChannelQueueProperties.java @@ -0,0 +1,71 @@ +package com.asyncapi.v3.binding.channel.amqp.queue; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes AMQP 0-9-1 channel queue properties. + *

+ * Contains information about the queue exchange properties in AMQP. + * + * @version 0.2.0 + * @see AMQP channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode +@JsonClassDescription("Describes AMQP 0-9-1 channel queue properties.") +public class AMQPChannelQueueProperties { + + /** + * The name of the queue. It MUST NOT exceed 255 characters long. + */ + @Nullable + @javax.validation.constraints.Size( + max = 255, + message = "Queue name must not exceed 255 characters long." + ) + @JsonProperty("name") + @JsonPropertyDescription("The name of the queue. It MUST NOT exceed 255 characters long.") + private String name; + + /** + * Whether the queue should survive broker restarts or not. + */ + @Nullable + @JsonProperty("durable") + @JsonPropertyDescription("Whether the queue should survive broker restarts or not.") + private Boolean durable; + + /** + * Whether the queue should be used only by one connection or not. + */ + @Nullable + @JsonProperty("exclusive") + @JsonPropertyDescription("Whether the queue should be used only by one connection or not.") + private Boolean exclusive; + + /** + * Whether the queue should be deleted when the last consumer unsubscribes. + */ + @Nullable + @JsonProperty("autoDelete") + @JsonPropertyDescription("Whether the queue should be deleted when the last consumer unsubscribes.") + private Boolean autoDelete; + + /** + * The virtual host of the queue. Defaults to /. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "vhost", defaultValue = "/") + @JsonPropertyDescription("The virtual host of the queue. Defaults to /.") + private String vhost = "/"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp1/AMQP1ChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp1/AMQP1ChannelBinding.java new file mode 100644 index 00000000..b9d5b157 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/amqp1/AMQP1ChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.amqp1; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes AMQP 1.0 channel binding. + * + * @version 0.1.0 + * @see AMQP 1.0 channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class AMQP1ChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/anypointmq/AnypointMQChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/anypointmq/AnypointMQChannelBinding.java new file mode 100644 index 00000000..84c63a06 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/anypointmq/AnypointMQChannelBinding.java @@ -0,0 +1,58 @@ +package com.asyncapi.v3.binding.channel.anypointmq; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Anypoint MQ channel binding. + * + * @version 0.0.1 + * @see Anypoint MQ channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes Anypoint MQ channel binding.") +public class AnypointMQChannelBinding extends ChannelBinding { + + /** + * OPTIONAL, defaults to the channel name. + *

+ * The destination (queue or exchange) name for this channel. SHOULD only be specified if the channel name differs + * from the actual destination name, such as when the channel name is not a valid destination name in Anypoint MQ. + */ + @Nullable + @JsonProperty("destination") + @JsonPropertyDescription("The destination (queue or exchange) name for this channel. SHOULD only be specified if the channel name differs from the actual destination name, such as when the channel name is not a valid destination name in Anypoint MQ.") + private String destination; + + /** + * OPTIONAL, defaults to queue. + *

+ * The type of destination, which MUST be either exchange or queue or fifo-queue. + * SHOULD be specified to document the messaging model (publish/subscribe, point-to-point, strict message ordering) + * supported by this channel. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "destinationType", defaultValue = "queue") + @JsonPropertyDescription("The type of destination, which MUST be either exchange or queue or fifo-queue. SHOULD be specified to document the messaging model (publish/subscribe, point-to-point, strict message ordering) supported by this channel.") + private AnypointMQChannelDestinationType destinationType = AnypointMQChannelDestinationType.QUEUE; + + /** + * The version of this binding. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.0.1"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/anypointmq/AnypointMQChannelDestinationType.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/anypointmq/AnypointMQChannelDestinationType.java new file mode 100644 index 00000000..3f42233c --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/anypointmq/AnypointMQChannelDestinationType.java @@ -0,0 +1,25 @@ +package com.asyncapi.v3.binding.channel.anypointmq; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Describes Anypoint MQ channel destination type. + * + * @version 0.0.1 + * @see Anypoint MQ channel binding + * @author Pavel Bodiachevskii + */ +@JsonClassDescription("Describes Anypoint MQ channel destination type.") +public enum AnypointMQChannelDestinationType { + + @JsonProperty("exchange") + EXCHANGE, + + @JsonProperty("queue") + QUEUE, + + @JsonProperty("fifo-queue") + FIFO_QUEUE + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelBinding.java new file mode 100644 index 00000000..1f93f6c2 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelBinding.java @@ -0,0 +1,83 @@ +package com.asyncapi.v3.binding.channel.googlepubsub; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.Map; + +/** + * Describes Google Cloud Pub/Sub channel binding. + *

+ * The Channel Bindings Object is used to describe the Google Cloud Pub/Sub specific Topic details with AsyncAPI. + * + * @version 0.1.0 + * @see Google Cloud Pub/Sub channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes Google Cloud Pub/Sub channel binding.") +public class GooglePubSubChannelBinding extends ChannelBinding { + + /** + * The Google Cloud Pub/Sub Topic name. + */ + @NotNull + @Builder.Default + @javax.validation.constraints.NotNull + @JsonProperty(value = "topic", required = true) + @JsonPropertyDescription("The Google Cloud Pub/Sub Topic name.") + private String topic = ""; + + /** + * An object of key-value pairs (These are used to categorize Cloud Resources like Cloud Pub/Sub Topics.) + */ + @Nullable + @JsonProperty("labels") + @JsonPropertyDescription("An object of key-value pairs (These are used to categorize Cloud Resources like Cloud Pub/Sub Topics.)") + private Map labels; + + /** + * Indicates the minimum duration to retain a message after it is published to the topic (Must be a valid Duration.) + */ + @Nullable + @JsonProperty("messageRetentionDuration") + @JsonPropertyDescription("Indicates the minimum duration to retain a message after it is published to the topic (Must be a valid https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#google.protobuf.Duration.)") + private String messageRetentionDuration; + + /** + * Policy constraining the set of Google Cloud Platform regions where messages published to the topic may be stored + */ + @Nullable + @JsonProperty("messageStoragePolicy") + @JsonPropertyDescription("Policy constraining the set of Google Cloud Platform regions where messages published to the topic may be stored") + private GooglePubSubChannelMessageStoragePolicy messageStoragePolicy; + + /** + * Settings for validating messages published against a schema + */ + @NotNull + @Builder.Default + @javax.validation.constraints.NotNull + @JsonProperty(value = "schemaSettings", required = true) + @JsonPropertyDescription("Settings for validating messages published against a schema") + private GooglePubSubChannelSchemaSettings schemaSettings = new GooglePubSubChannelSchemaSettings(); + + /** + * The version of this binding. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelMessageStoragePolicy.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelMessageStoragePolicy.java new file mode 100644 index 00000000..2f236cc6 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelMessageStoragePolicy.java @@ -0,0 +1,36 @@ +package com.asyncapi.v3.binding.channel.googlepubsub; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * Describes Google Cloud Pub/Sub MessageStoragePolicy. + *

+ * The Message Storage Policy Object is used to describe the Google Cloud Pub/Sub MessageStoragePolicy Object with AsyncAPI. + * + * @version 0.1.0 + * @see Google Cloud Pub/Sub channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode +@JsonClassDescription("Describe the Google Cloud Pub/Sub MessageStoragePolicy") +public class GooglePubSubChannelMessageStoragePolicy { + + /** + * A list of IDs of GCP regions where messages that are published to the topic may be persisted in storage + */ + @Nullable + @JsonProperty("allowedPersistenceRegions") + @JsonPropertyDescription("A list of IDs of GCP regions where messages that are published to the topic may be persisted in storage") + private List allowedPersistenceRegions; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelSchemaSettings.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelSchemaSettings.java new file mode 100644 index 00000000..ce5f807e --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelSchemaSettings.java @@ -0,0 +1,59 @@ +package com.asyncapi.v3.binding.channel.googlepubsub; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Google Cloud Pub/Sub SchemaSettings. + *

+ * The Schema Settings Object is used to describe the Google Cloud Pub/Sub SchemaSettings Object with AsyncAPI. + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode +@JsonClassDescription("Describe the Google Cloud Pub/Sub SchemaSettings") +public class GooglePubSubChannelSchemaSettings { + + /** + * The encoding of the message (Must be one of the possible Encoding values.) + */ + @NotNull + @Builder.Default + @javax.validation.constraints.NotNull + @JsonProperty(value = "encoding", required = true) + @JsonPropertyDescription("The encoding of the message (Must be one of the possible https://cloud.google.com/pubsub/docs/reference/rest/v1/projects.topics#encoding values.)") + private String encoding = ""; + + /** + * The minimum (inclusive) revision allowed for validating messages + */ + @Nullable + @JsonProperty("firstRevisionId") + @JsonPropertyDescription("The minimum (inclusive) revision allowed for validating messages") + private String firstRevisionId; + + /** + * The maximum (inclusive) revision allowed for validating messages + */ + @Nullable + @JsonProperty("lastRevisionId") + @JsonPropertyDescription("The maximum (inclusive) revision allowed for validating messages") + private String lastRevisionId; + + /** + * The name of the schema that messages published should be validated against (The format is projects/{project}/schemas/{schema}.) + */ + @NotNull + @Builder.Default + @javax.validation.constraints.NotNull + @JsonProperty(value = "name", required = true) + @JsonPropertyDescription("The name of the schema that messages published should be validated against (The format is projects/{project}/schemas/{schema}.)") + private String name = ""; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/http/HTTPChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/http/HTTPChannelBinding.java new file mode 100644 index 00000000..3419cdc2 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/http/HTTPChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.http; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes HTTP channel binding. + * + * @version 0.1.0 + * @see HTTP channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class HTTPChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelBinding.java new file mode 100644 index 00000000..bb637b2a --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelBinding.java @@ -0,0 +1,88 @@ +package com.asyncapi.v3.binding.channel.ibmmq; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes IBM MQ channel binding. + *

+ * This object contains information about the channel representation in IBM MQ. Each channel corresponds to a Queue or Topic within IBM MQ. + * + * @version 0.1.0 + * @see IBM MQ channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes IBM MQ channel binding.") +public class IBMMQChannelBinding extends ChannelBinding { + + /** + * Defines the type of AsyncAPI channel. + *

+ * MUST be either topic or queue. For type topic, the AsyncAPI channel name MUST be assumed for the IBM MQ topic string unless overridden. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "destinationType", defaultValue = "topic") + @JsonPropertyDescription("Defines the type of AsyncAPI channel.") + private IBMMQChannelDestinationType destinationType = IBMMQChannelDestinationType.TOPIC; + + /** + * REQUIRED if destinationType = queue + *

+ * queue and topic fields MUST NOT coexist within a channel binding + */ + @Nullable + @JsonProperty("queue") + @JsonPropertyDescription("Defines the properties of a queue.") + private IBMMQChannelQueueProperties queue; + + /** + * Defines the properties of a topic. + *

+ * OPTIONAL if destinationType = topic + *

+ * queue and topic fields MUST NOT coexist within a channel binding. + */ + @Nullable + @JsonProperty("topic") + @JsonPropertyDescription("Defines the properties of a topic.") + private IBMMQChannelTopicProperties topic; + + /** + * The maximum length of the physical message (in bytes) accepted by the Topic or Queue. Messages produced that are + * greater in size than this value may fail to be delivered. More information on the maximum message length can be + * found on this page in the IBM MQ Knowledge Center. + *

+ * MUST be 0-104,857,600 bytes (100 MB). + */ + @Nullable + @javax.validation.constraints.Min( + value = 0, + message = "Maximum length of the physical message (in bytes) must be greater or equals to 0" + ) + @javax.validation.constraints.Max( + value = 104857600, + message = "Maximum length of the physical message (in bytes) must be lower or equals to 104857600" + ) + @JsonProperty("maxMsgLength") + @JsonPropertyDescription("The maximum length of the physical message (in bytes) accepted by the Topic or Queue. Messages produced that are greater in size than this value may fail to be delivered. More information on the maximum message length can be found on this [page](https://www.ibm.com/support/knowledgecenter/SSFKSJ_latest/com.ibm.mq.ref.dev.doc/q097520_.html) in the IBM MQ Knowledge Center.") + private Integer maxMsgLength; + + /** + * The version of this binding. + */ + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelDestinationType.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelDestinationType.java new file mode 100644 index 00000000..13609498 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelDestinationType.java @@ -0,0 +1,20 @@ +package com.asyncapi.v3.binding.channel.ibmmq; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Describes IBM MQ channel destination type. + * + * @version 0.1.0 + * @see IBM MQ channel binding + * @author Pavel Bodiachevskii + */ +public enum IBMMQChannelDestinationType { + + @JsonProperty("topic") + TOPIC, + + @JsonProperty("queue") + QUEUE + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelQueueProperties.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelQueueProperties.java new file mode 100644 index 00000000..4c4586ab --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelQueueProperties.java @@ -0,0 +1,62 @@ +package com.asyncapi.v3.binding.channel.ibmmq; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * Describes IBM MQ channel queue properties. + * + * @version 0.1.0 + * @see IBM MQ channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode +@JsonClassDescription("Describes IBM MQ channel queue properties.") +public class IBMMQChannelQueueProperties { + + /** + * Defines the name of the IBM MQ queue associated with the channel. + *

+ * A value MUST be specified. MUST NOT exceed 48 characters in length. MUST be a valid IBM MQ queue name + */ + @NotNull + @javax.validation.constraints.NotNull + @javax.validation.constraints.Size( + max = 48, + message = "Name of the IBM MQ queue must be less or equals to 48" + ) + @Builder.Default + @JsonProperty("objectName") + @JsonPropertyDescription("Defines the name of the IBM MQ queue associated with the channel.") + private String objectName = ""; + + /** + * Defines if the queue is a cluster queue and therefore partitioned. If true, a binding option MAY be specified + * when accessing the queue. More information on binding options can be found on this page in the IBM MQ Knowledge Center. + *

+ * If false, binding options SHOULD NOT be specified when accessing the queue. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "isPartitioned", defaultValue = "false") + @JsonPropertyDescription("Defines if the queue is a cluster queue and therefore partitioned. If 'true', a binding option MAY be specified when accessing the queue. More information on binding options can be found on this page in the IBM MQ Knowledge Center.") + private Boolean isPartitioned = false; + + /** + * Specifies if it is recommended to open the queue exclusively. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "exclusive", defaultValue = "false") + @JsonPropertyDescription("Specifies if it is recommended to open the queue exclusively.") + private Boolean exclusive = false; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelTopicProperties.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelTopicProperties.java new file mode 100644 index 00000000..7fe8544e --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelTopicProperties.java @@ -0,0 +1,74 @@ +package com.asyncapi.v3.binding.channel.ibmmq; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes IBM MQ channel topic properties. + * + * @version 0.1.0 + * @see IBM MQ channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode +public class IBMMQChannelTopicProperties { + + /** + * The value of the IBM MQ topic string to be used. + *

+ * OPTIONAL + * Note: if specified, SHALL override AsyncAPI channel name. + *

+ * MUST NOT exceed 10240 characters in length. MAY coexist with topic.objectName + */ + @Nullable + @javax.validation.constraints.Max( + value = 10240, + message = "Maximum length of topic string must be lower or equals to 10240" + ) + @JsonProperty("string") + @JsonPropertyDescription("The value of the IBM MQ topic string to be used.") + private String string; + + /** + * The name of the IBM MQ topic object. + *

+ * OPTIONAL + * Note: if specified, SHALL override AsyncAPI channel name. + *

+ * MUST NOT exceed 48 characters in length. MAY coexist with topic.string + */ + @Nullable + @javax.validation.constraints.Max( + value = 48, + message = "Maximum length of topic name must be lower or equals to 48" + ) + @JsonProperty("objectName") + @JsonPropertyDescription("The name of the IBM MQ topic object.") + private String objectName; + + /** + * Defines if the subscription may be durable. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "durablePermitted", defaultValue = "true") + @JsonPropertyDescription("Defines if the subscription may be durable.") + private Boolean durablePermitted = true; + + /** + * Defines if the last message published will be made available to new subscriptions. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "lastMsgRetained", defaultValue = "false") + @JsonPropertyDescription("Defines if the last message published will be made available to new subscriptions.") + private Boolean lastMsgRetained = false; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/jms/JMSChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/jms/JMSChannelBinding.java new file mode 100644 index 00000000..3d74dac6 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/jms/JMSChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.jms; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes JMS channel binding. + * + * @version 0.1.0 + * @see JMS channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class JMSChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/kafka/KafkaChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/kafka/KafkaChannelBinding.java new file mode 100644 index 00000000..66b61ea5 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/kafka/KafkaChannelBinding.java @@ -0,0 +1,76 @@ +package com.asyncapi.v3.binding.channel.kafka; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Kafka channel binding. + * + * @version 0.4.0 + * @see Kafka channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes Kafka channel binding.") +public class KafkaChannelBinding extends ChannelBinding { + + /** + * Kafka topic name if different from channel name. + */ + @Nullable + @JsonProperty("topic") + @JsonPropertyDescription("Kafka topic name if different from channel name.") + private String topic; + + /** + * Number of partitions configured on this topic (useful to know how many parallel consumers you may run). + *

+ * MUST be positive. + */ + @Nullable + @javax.validation.constraints.Min( + value = 1, + message = "Number of partitions must be greater or equals to 1" + ) + @JsonProperty("partitions") + @JsonPropertyDescription("Number of partitions configured on this topic (useful to know how many parallel consumers you may run).") + private Integer partitions; + + /** + * Number of replicas configured on this topic. + *

+ * MUST be positive. + */ + @Nullable + @javax.validation.constraints.Min( + value = 1, + message = "Number of replicas must be greater or equals to 1" + ) + @JsonProperty("replicas") + @JsonPropertyDescription("Number of replicas configured on this topic.") + private Integer replicas; + + /** + * Topic configuration properties that are relevant for the API. + */ + @Nullable + @JsonProperty("topicConfiguration") + @JsonPropertyDescription("Topic configuration properties that are relevant for the API.") + private KafkaChannelTopicConfiguration topicConfiguration; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + private String bindingVersion = "0.4.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/kafka/KafkaChannelTopicCleanupPolicy.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/kafka/KafkaChannelTopicCleanupPolicy.java new file mode 100644 index 00000000..a58e764a --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/kafka/KafkaChannelTopicCleanupPolicy.java @@ -0,0 +1,13 @@ +package com.asyncapi.v3.binding.channel.kafka; + +import com.fasterxml.jackson.annotation.JsonProperty; + +public enum KafkaChannelTopicCleanupPolicy { + + @JsonProperty("compact") + COMPACT, + + @JsonProperty("delete") + DELETE + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/kafka/KafkaChannelTopicConfiguration.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/kafka/KafkaChannelTopicConfiguration.java new file mode 100644 index 00000000..63ed484c --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/kafka/KafkaChannelTopicConfiguration.java @@ -0,0 +1,83 @@ +package com.asyncapi.v3.binding.channel.kafka; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.AllArgsConstructor; +import lombok.Builder; +import lombok.Data; +import lombok.NoArgsConstructor; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * This objects contains information about the API relevant topic configuration in Kafka. + * + * @version 0.4.0 + * @see Kafka channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +public class KafkaChannelTopicConfiguration { + + /** + * The cleanup.policy configuration option. + *

+ * array may only contain delete and/or compact + */ + @Nullable + @JsonProperty("cleanup.policy") + private List cleanupPolicy; + + /** + * The retention.ms configuration option. + */ + @Nullable + @javax.validation.constraints.Min( + value = -1, + message = "retention.ms must be greater or equals to -1" + ) + @JsonProperty("retention.ms") + @JsonPropertyDescription("The [`retention.ms`](https://kafka.apache.org/documentation/#topicconfigs_retention.ms) configuration option.") + private Integer retentionMs; + + /** + * The retention.bytes configuration option. + */ + @Nullable + @javax.validation.constraints.Min( + value = -1, + message = "retention.bytes must be greater or equals to -1" + ) + @JsonProperty("retention.bytes") + @JsonPropertyDescription("The [`retention.bytes`](https://kafka.apache.org/documentation/#topicconfigs_retention.bytes) configuration option.") + private Integer retentionBytes; + + /** + * The delete.retention.ms configuration option. + */ + @Nullable + @javax.validation.constraints.Min( + value = 0, + message = "delete.retention.ms must be greater or equals to 0" + ) + @JsonProperty("delete.retention.ms") + @JsonPropertyDescription("The [`delete.retention.ms`](https://kafka.apache.org/documentation/#topicconfigs_delete.retention.ms) configuration option.") + private Integer deleteRetentionMs; + + /** + * The max.message.bytes configuration option. + */ + @Nullable + @javax.validation.constraints.Min( + value = 0, + message = "max.message.bytes must be greater or equals to 0" + ) + @JsonProperty("max.message.bytes") + @JsonPropertyDescription("The [`max.message.bytes`](https://kafka.apache.org/documentation/#topicconfigs_max.message.bytes) configuration option.") + private Integer maxMessageBytes; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/mercure/MercureChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/mercure/MercureChannelBinding.java new file mode 100644 index 00000000..8cdb274b --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/mercure/MercureChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.mercure; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Mercure channel binding. + * + * @version 0.1.0 + * @see Mercure channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MercureChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/mqtt/MQTTChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/mqtt/MQTTChannelBinding.java new file mode 100644 index 00000000..8f1ad80b --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/mqtt/MQTTChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.mqtt; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes MQTT channel binding. + * + * @version 0.1.0 + * @see MQTT channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MQTTChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/mqtt5/MQTT5ChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/mqtt5/MQTT5ChannelBinding.java new file mode 100644 index 00000000..6386770b --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/mqtt5/MQTT5ChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.mqtt5; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes MQTT 5 channel binding. + * + * @version 0.2.0 + * @see MQTT 5 channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MQTT5ChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/nats/NATSChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/nats/NATSChannelBinding.java new file mode 100644 index 00000000..c069aabe --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/nats/NATSChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.nats; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes NATS channel binding. + * + * @version 0.1.0 + * @see NATS channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class NATSChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelBinding.java new file mode 100644 index 00000000..df114f94 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelBinding.java @@ -0,0 +1,101 @@ +package com.asyncapi.v3.binding.channel.pulsar; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * Describes Pulsar channel binding. + * + * @version 0.1.0 + * @see Pulsar channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes Pulsar channel binding.") +public class PulsarChannelBinding extends ChannelBinding { + + /** + * The namespace the channel is associated with. + */ + @NotNull + @Builder.Default + @javax.validation.constraints.NotNull + @JsonProperty("namespace") + @JsonPropertyDescription("The namespace the channel is associated with.") + private String namespace = ""; + + /** + * Persistence of the topic in Pulsar. It MUST be either persistent or non-persistent. + */ + @NotNull + @Builder.Default + @javax.validation.constraints.NotNull + @JsonProperty(value = "persistence", defaultValue = "persistent") + @JsonPropertyDescription("Persistence of the topic in Pulsar. It MUST be either persistent or non-persistent.") + private PulsarChannelPersistence persistence = PulsarChannelPersistence.PERSISTENT; + + /** + * Topic compaction threshold given in Megabytes. + */ + @Nullable + @javax.validation.constraints.Min( + value = 0, + message = "Topic compaction threshold must be greater or equals to 0." + ) + @JsonProperty("compaction") + @JsonPropertyDescription("Topic compaction threshold given in Megabytes.") + private Integer compaction; + + /** + * A list of clusters the topic is replicated to. + */ + @Nullable + @JsonProperty("geo-replication") + @JsonPropertyDescription("A list of clusters the topic is replicated to.") + private List geoReplication; + + /** + * Topic retention policy. + */ + @Nullable + @JsonProperty("retention") + @JsonPropertyDescription("Topic retention policy.") + private PulsarChannelRetentionDefinition retention; + + /** + * Message time-to-live in seconds. + */ + @Nullable + @JsonProperty("ttl") + @JsonPropertyDescription("Message time-to-live in seconds.") + private Integer ttl; + + /** + * Message deduplication. When true, it ensures that each message produced on Pulsar topics is persisted to disk only once. + */ + @Nullable + @JsonProperty("deduplication") + @JsonPropertyDescription("Message deduplication. When true, it ensures that each message produced on Pulsar topics is persisted to disk only once.") + private Boolean deduplication; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelPersistence.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelPersistence.java new file mode 100644 index 00000000..8af581a8 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelPersistence.java @@ -0,0 +1,22 @@ +package com.asyncapi.v3.binding.channel.pulsar; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Describes Pulsar channel persistence. + * + * @version 0.1.0 + * @see Pulsar channel binding + * @author Pavel Bodiachevskii + */ +@JsonClassDescription("Describes Pulsar channel persistence.") +public enum PulsarChannelPersistence { + + @JsonProperty("persistent") + PERSISTENT, + + @JsonProperty("non-persistent") + NON_PERSISTENT + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelRetentionDefinition.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelRetentionDefinition.java new file mode 100644 index 00000000..badd4b15 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelRetentionDefinition.java @@ -0,0 +1,44 @@ +package com.asyncapi.v3.binding.channel.pulsar; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Pulsar channel retention definition. + *

+ * The Retention Definition Object is used to describe the Pulsar Retention policy. + * + * @version 0.1.0 + * @see Pulsar channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode +@JsonClassDescription("Describes Pulsar channel retention definition.") +public class PulsarChannelRetentionDefinition { + + /** + * Time given in Minutes. + */ + @Nullable + @Builder.Default + @JsonProperty("time") + @JsonPropertyDescription("Time given in Minutes.") + private Integer time = 0; + + /** + * Size given in MegaBytes. + */ + @Nullable + @Builder.Default + @JsonProperty("size") + @JsonPropertyDescription("Size given in MegaBytes.") + private Integer size = 0; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/redis/RedisChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/redis/RedisChannelBinding.java new file mode 100644 index 00000000..a061a679 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/redis/RedisChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.redis; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Redis channel binding. + * + * @version 0.1.0 + * @see Redis channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class RedisChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/sns/SNSChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/sns/SNSChannelBinding.java new file mode 100644 index 00000000..f2e8b833 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/sns/SNSChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.sns; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes SNS channel binding. + * + * @version 0.1.0 + * @see SNS channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class SNSChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/solace/SolaceChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/solace/SolaceChannelBinding.java new file mode 100644 index 00000000..cbd31a55 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/solace/SolaceChannelBinding.java @@ -0,0 +1,23 @@ +package com.asyncapi.v3.binding.channel.solace; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Builder; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Solace channel binding. + * + * @version 0.3.0 + * @see Solace channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class SolaceChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/sqs/SQSChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/sqs/SQSChannelBinding.java new file mode 100644 index 00000000..961a8ad6 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/sqs/SQSChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.sqs; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes SQS channel binding. + * + * @version 0.1.0 + * @see SQS channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class SQSChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/stomp/STOMPChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/stomp/STOMPChannelBinding.java new file mode 100644 index 00000000..f4b13a98 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/stomp/STOMPChannelBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.channel.stomp; + +import com.asyncapi.v3.binding.channel.ChannelBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes STOMP channel binding. + * + * @version 0.1.0 + * @see STOMP channel binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class STOMPChannelBinding extends ChannelBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ws/WebSocketsChannelBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ws/WebSocketsChannelBinding.java new file mode 100644 index 00000000..d1255317 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ws/WebSocketsChannelBinding.java @@ -0,0 +1,66 @@ +package com.asyncapi.v3.binding.channel.ws; + +import com.asyncapi.v3.schema.Schema; +import com.asyncapi.v3.binding.channel.ChannelBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes WebSockets channel binding. + *

+ * When using WebSockets, the channel represents the connection. Unlike other protocols that support multiple virtual + * channels (topics, routing keys, etc.) per connection, WebSockets doesn't support virtual channels or, put it another + * way, there's only one channel and its characteristics are strongly related to the protocol used for the handshake, + * i.e., HTTP. + * + * @version 0.1.0 + * @see WebSockets channel binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes WebSockets channel binding.") +public class WebSocketsChannelBinding extends ChannelBinding { + + /** + * The HTTP method to use when establishing the connection. Its value MUST be either GET or POST. + */ + @Nullable + @JsonProperty("method") + @JsonPropertyDescription("The HTTP method to use when establishing the connection. Its value MUST be either GET or POST.") + private WebSocketsChannelMethod method; + + /** + * A Schema object containing the definitions for each query parameter. This schema MUST be of type + * object and have a properties key. + */ + @Nullable + @JsonProperty("query") + @JsonPropertyDescription("A Schema object containing the definitions for each query parameter. This schema MUST be of type object and have a properties key.") + private Schema query; + + /** + * A Schema object containing the definitions of the HTTP headers to use when establishing the connection. + * This schema MUST be of type object and have a properties key. + */ + @Nullable + @JsonProperty("headers") + @JsonPropertyDescription("A Schema object containing the definitions of the HTTP headers to use when establishing the connection. This schema MUST be of type object and have a properties key.") + private Schema headers; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ws/WebSocketsChannelMethod.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ws/WebSocketsChannelMethod.java new file mode 100644 index 00000000..48362411 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/channel/ws/WebSocketsChannelMethod.java @@ -0,0 +1,13 @@ +package com.asyncapi.v3.binding.channel.ws; + +import com.fasterxml.jackson.annotation.JsonProperty; + +public enum WebSocketsChannelMethod { + + @JsonProperty("GET") + GET, + + @JsonProperty("POST") + POST + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/MessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/MessageBinding.java new file mode 100644 index 00000000..2f75d7d8 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/MessageBinding.java @@ -0,0 +1,13 @@ +package com.asyncapi.v3.binding.message; + +import com.asyncapi.v3.ExtendableObject; +import lombok.EqualsAndHashCode; + +/** + * Describes AsyncAPI message binding. + * + * @author Pavel Bodiachevskii + */ +@EqualsAndHashCode(callSuper = true) +public class MessageBinding extends ExtendableObject { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/amqp/AMQPMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/amqp/AMQPMessageBinding.java new file mode 100644 index 00000000..820202c6 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/amqp/AMQPMessageBinding.java @@ -0,0 +1,52 @@ +package com.asyncapi.v3.binding.message.amqp; + +import com.asyncapi.v3.binding.message.MessageBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes AMQP 0-9-1 message binding. + *

+ * Contains information about the message representation in AMQP. + * + * @version 0.2.0 + * @see AMQP message binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes AMQP 0-9-1 message binding.") +public class AMQPMessageBinding extends MessageBinding { + + /** + * A MIME encoding for the message content. + */ + @Nullable + @JsonProperty("contentEncoding") + @JsonPropertyDescription("A MIME encoding for the message content.") + private String contentEncoding; + + /** + * Application-specific message type. + */ + @Nullable + @JsonProperty("messageType") + @JsonPropertyDescription("Application-specific message type.") + private String messageType; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.2.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/amqp1/AMQP1MessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/amqp1/AMQP1MessageBinding.java new file mode 100644 index 00000000..73617ca1 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/amqp1/AMQP1MessageBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.message.amqp1; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes AMQP 1.0 message binding. + * + * @version 0.1.0 + * @see AMQP message binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class AMQP1MessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/anypointmq/AnypointMQMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/anypointmq/AnypointMQMessageBinding.java new file mode 100644 index 00000000..07f8b497 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/anypointmq/AnypointMQMessageBinding.java @@ -0,0 +1,45 @@ +package com.asyncapi.v3.binding.message.anypointmq; + +import com.asyncapi.v3.schema.Schema; +import com.asyncapi.v3.binding.message.MessageBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Anypoint MQ message binding. + * + * @version 0.0.1 + * @see Anypoint MQ message binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes Anypoint MQ message binding.") +public class AnypointMQMessageBinding extends MessageBinding { + + /** + * A Schema object containing the definitions for Anypoint MQ-specific headers (so-called protocol headers). + * This schema MUST be of type object and have a properties key. Examples of Anypoint MQ protocol headers are + * messageId and messageGroupId. + */ + @Nullable + @JsonProperty("headers") + @JsonPropertyDescription("A Schema object containing the definitions for Anypoint MQ-specific headers (so-called protocol headers). This schema MUST be of type object and have a properties key. Examples of Anypoint MQ protocol headers are messageId and messageGroupId.") + private Schema headers; + + /** + * The version of this binding. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.0.1"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageBinding.java new file mode 100644 index 00000000..5f6373de --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageBinding.java @@ -0,0 +1,62 @@ +package com.asyncapi.v3.binding.message.googlepubsub; + +import com.asyncapi.v3.binding.message.MessageBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Google Cloud Pub/Sub message binding. + *

+ * The Message Binding Object is used to describe the Google Cloud Pub/Sub specific PubsubMessage details, alongside with + * pertintent parts of the Google Cloud Pub/Sub Schema Object, with AsyncAPI. + * + * @version 0.1.0 + * @see Google Cloud Pub/Sub message binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes Google Cloud Pub/Sub message binding.") +public class GooglePubSubMessageBinding extends MessageBinding { + + /** + * If non-empty, identifies related messages for which publish order should be respected (For more information, see ordering messages.) + */ + @Nullable + @JsonProperty("orderingKey") + @JsonPropertyDescription("If non-empty, identifies related messages for which publish order should be respected (For more information, see https://cloud.google.com/pubsub/docs/ordering messages") + private String orderingKey; + + /** + * Attributes for this message (If this field is empty, the message must contain non-empty data. This can be used to + * filter messages on the subscription.) + */ + @Nullable + @JsonProperty("attributes") + @JsonPropertyDescription("Attributes for this message (If this field is empty, the message must contain non-empty data. This can be used to filter messages on the subscription.)") + private Object attributes; + + /** + * Describes the schema used to validate the payload of this message + */ + @Nullable + @JsonProperty("schema") + @JsonPropertyDescription("Describes the schema used to validate the payload of this message") + private GooglePubSubMessageSchemaDefinition schema; + + /** + * The version of this binding. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageSchemaDefinition.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageSchemaDefinition.java new file mode 100644 index 00000000..277061b3 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageSchemaDefinition.java @@ -0,0 +1,49 @@ +package com.asyncapi.v3.binding.message.googlepubsub; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.NotNull; + +/** + * Describes Google Cloud Pub/Sub message schema definition. + *

+ * The Schema Definition Object is used to describe the Google Cloud Pub/Sub Schema Object with AsyncAPI. + * While some of this information could be, or is, described using native AsyncAPI, for consistency it makes sense to + * provide this information here at all times, especially for cases where AsyncAPI does not natively support describing + * payloads using a supported Google Cloud Pub/Sub schema format like Protobuf. + * + * @version 0.1.0 + * @see Google Cloud Pub/Sub message binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode +@JsonClassDescription("Describes Google Cloud Pub/Sub message schema definition.") +public class GooglePubSubMessageSchemaDefinition { + + /** + * The name of the schema + */ + @NotNull + @Builder.Default + @javax.validation.constraints.NotNull + @JsonProperty(value = "name", required = true) + @JsonPropertyDescription("The name of the schema") + private String name = ""; + + /** + * The type of the schema + */ + @NotNull + @Builder.Default + @javax.validation.constraints.NotNull + @JsonProperty(value = "type", required = true) + @JsonPropertyDescription("The type of the schema") + private GooglePubSubMessageSchemaDefinitionType type = GooglePubSubMessageSchemaDefinitionType.PROTOBUF; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageSchemaDefinitionType.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageSchemaDefinitionType.java new file mode 100644 index 00000000..f7dd4bc3 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageSchemaDefinitionType.java @@ -0,0 +1,23 @@ +package com.asyncapi.v3.binding.message.googlepubsub; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Describes Google Cloud Pub/Sub message schema definition type. + * + * @version 0.1.0 + * @see Google Cloud Pub/Sub message binding + * @see Types of schemas + * @author Pavel Bodiachevskii + */ +@JsonClassDescription("Describes Google Cloud Pub/Sub message schema definition type.") +public enum GooglePubSubMessageSchemaDefinitionType { + + @JsonProperty("avro") + AVRO, + + @JsonProperty("protobuf") + PROTOBUF + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/http/HTTPMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/http/HTTPMessageBinding.java new file mode 100644 index 00000000..664f1e40 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/http/HTTPMessageBinding.java @@ -0,0 +1,44 @@ +package com.asyncapi.v3.binding.message.http; + +import com.asyncapi.v3.schema.Schema; +import com.asyncapi.v3.binding.message.MessageBinding; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes HTTP message binding. + *

+ * Contains information about the message representation in HTTP. + * + * @version 0.1.0 + * @see HTTP message binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class HTTPMessageBinding extends MessageBinding { + + /** + * A Schema object containing the definitions for each query parameter. This schema MUST be of type object + * and have a properties key.* + */ + @Nullable + @JsonProperty("headers") + @JsonPropertyDescription("A Schema object containing the definitions for each query parameter. This schema MUST be of type object and have a properties key.") + private Schema headers; + + /** + * The version of this binding. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/ibmmq/IBMMQMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/ibmmq/IBMMQMessageBinding.java new file mode 100644 index 00000000..72efcf1a --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/ibmmq/IBMMQMessageBinding.java @@ -0,0 +1,89 @@ +package com.asyncapi.v3.binding.message.ibmmq; + +import com.asyncapi.v3.binding.message.MessageBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes IBM MQ message binding. + *

+ * This object contains information about the message representation in IBM MQ. + * + * @version 0.1.0 + * @see IBM MQ message binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes IBM MQ message binding.") +public class IBMMQMessageBinding extends MessageBinding { + + /** + * The type of the message. + *

+ * MUST be either string, jms or binary + */ + @Nullable + @Builder.Default + @JsonProperty(value = "type", defaultValue = "string") + @JsonPropertyDescription("The type of the message.") + private IBMMQMessageType type = IBMMQMessageType.STRING; + + /** + * Defines the IBM MQ message headers to include with this message. More than one header can be specified as a comma + * separated list. Supporting information on IBM MQ message formats can be found on this page in the IBM MQ Knowledge Center. + *

+ * OPTIONAL if type = binary + *

+ * headers MUST NOT be specified if type = string or jms + */ + @Nullable + @JsonProperty("headers") + @JsonPropertyDescription("Defines the IBM MQ message headers to include with this message. More than one header can be specified as a comma separated list.") + private String headers; + + /** + * Provides additional information for application developers: describes the message type or format. + *

+ * The description field of the IBM MQ message binding object MAY include CommonMark markdown formatting. + * A minimum markdown syntax as described by CommonMark 0.27 is assumed. + */ + @Nullable + @JsonProperty("description") + @JsonPropertyDescription("Provides additional information for application developers: describes the message type or format.") + private String description; + + /** + * The recommended setting the client should use for the TTL (Time-To-Live) of the message. + * This is a period of time expressed in milliseconds and set by the application that puts the message. + * expiry values are API dependant e.g., MQI and JMS use different units of time and default values for unlimited. + * General information on IBM MQ message expiry can be found on this page in the IBM MQ Knowledge Center. + *

+ * expiry value MUST be either zero (unlimited) or greater than zero. + */ + @Nullable + @Builder.Default + @javax.validation.constraints.Min( + value = 0, + message = "Expiry must be greater or equals to 0" + ) + @JsonProperty(value = "expiry", defaultValue = "0") + @JsonPropertyDescription("The recommended setting the client should use for the TTL (Time-To-Live) of the message. This is a period of time expressed in milliseconds and set by the application that puts the message. 'expiry' values are API dependant e.g., MQI and JMS use different units of time and default values for 'unlimited'. General information on IBM MQ message expiry can be found on this [page](https://www.ibm.com/docs/en/ibm-mq/9.2?topic=mqmd-expiry-mqlong) in the IBM MQ Knowledge Center.") + private Integer expiry = 0; + + /** + * The version of this binding. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/ibmmq/IBMMQMessageType.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/ibmmq/IBMMQMessageType.java new file mode 100644 index 00000000..171f8a2f --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/ibmmq/IBMMQMessageType.java @@ -0,0 +1,25 @@ +package com.asyncapi.v3.binding.message.ibmmq; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Describes IBM MQ message type. + *

+ * This object contains information about the message type in IBM MQ. + * + * @version 0.1.0 + * @see IBM MQ message binding + * @author Pavel Bodiachevskii + */ +public enum IBMMQMessageType { + + @JsonProperty("string") + STRING, + + @JsonProperty("jms") + JMS, + + @JsonProperty("binary") + BINARY + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/jms/JMSMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/jms/JMSMessageBinding.java new file mode 100644 index 00000000..f44eec50 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/jms/JMSMessageBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.message.jms; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes JMS message binding. + * + * @version 0.1.0 + * @see JMS message binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class JMSMessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/kafka/KafkaMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/kafka/KafkaMessageBinding.java new file mode 100644 index 00000000..52070204 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/kafka/KafkaMessageBinding.java @@ -0,0 +1,67 @@ +package com.asyncapi.v3.binding.message.kafka; + +import com.asyncapi.v3.schema.Schema; +import com.asyncapi.v3.binding.message.MessageBinding; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Kafka message binding. + *

+ * Contains information about the message representation in Kafka. + * + * @version 0.1.0 + * @see Kafka message binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class KafkaMessageBinding extends MessageBinding { + + /** + * The message key. + */ + @Nullable + @JsonProperty("key") + @JsonPropertyDescription("The message key.") + private Schema key; + + /** + * If a Schema Registry is used when performing this operation, tells where the id of schema is stored (e.g. header or payload). + */ + @Nullable + @JsonProperty("schemaIdLocation") + @JsonPropertyDescription("If a Schema Registry is used when performing this operation, tells where the id of schema is stored (e.g. header or payload).") + private KafkaMessageSchemaIdLocation schemaIdLocation; + + /** + * Number of bytes or vendor specific values when schema id is encoded in payload (e.g confluent/ apicurio-legacy / apicurio-new). + */ + @Nullable + @JsonProperty("schemaIdPayloadEncoding") + @JsonPropertyDescription("Number of bytes or vendor specific values when schema id is encoded in payload (e.g confluent/ apicurio-legacy / apicurio-new).") + private String schemaIdPayloadEncoding; + + /** + * Freeform string for any naming strategy class to use. Clients should default to the vendor default if not supplied. + */ + @Nullable + @JsonProperty("schemaLookupStrategy") + @JsonPropertyDescription("Freeform string for any naming strategy class to use. Clients should default to the vendor default if not supplied.") + private String schemaLookupStrategy; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.4.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/kafka/KafkaMessageSchemaIdLocation.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/kafka/KafkaMessageSchemaIdLocation.java new file mode 100644 index 00000000..e0a16f88 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/kafka/KafkaMessageSchemaIdLocation.java @@ -0,0 +1,20 @@ +package com.asyncapi.v3.binding.message.kafka; + +import com.fasterxml.jackson.annotation.JsonProperty; + +/** + * Describes Kafka message schema id location. + * + * @version 0.1.0 + * @see Kafka message binding + * @author Pavel Bodiachevskii + */ +public enum KafkaMessageSchemaIdLocation { + + @JsonProperty("header") + HEADER, + + @JsonProperty("payload") + PAYLOAD + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/mercure/MercureMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/mercure/MercureMessageBinding.java new file mode 100644 index 00000000..aa3ead1c --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/mercure/MercureMessageBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.message.mercure; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Mercure message binding. + * + * @version 0.1.0 + * @see Mercure message binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MercureMessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/mqtt/MQTTMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/mqtt/MQTTMessageBinding.java new file mode 100644 index 00000000..cbaa824d --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/mqtt/MQTTMessageBinding.java @@ -0,0 +1,34 @@ +package com.asyncapi.v3.binding.message.mqtt; + +import com.asyncapi.v3.binding.message.MessageBinding; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes MQTT message binding. + *

+ * Contains information about the message representation in MQTT. + * + * @version 0.1.0 + * @see MQTT message binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MQTTMessageBinding extends MessageBinding { + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/mqtt5/MQTT5MessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/mqtt5/MQTT5MessageBinding.java new file mode 100644 index 00000000..e344426e --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/mqtt5/MQTT5MessageBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.message.mqtt5; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes MQTT 5 message binding. + * + * @version 0.2.0 + * @see MQTT 5 message binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MQTT5MessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/nats/NATSMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/nats/NATSMessageBinding.java new file mode 100644 index 00000000..8557fc15 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/nats/NATSMessageBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.message.nats; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes NATS message binding. + * + * @version 0.1.0 + * @see NATS message binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class NATSMessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/pulsar/PulsarMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/pulsar/PulsarMessageBinding.java new file mode 100644 index 00000000..257d9948 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/pulsar/PulsarMessageBinding.java @@ -0,0 +1,23 @@ +package com.asyncapi.v3.binding.message.pulsar; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Builder; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * Describes Pulsar message binding. + *

+ * This object MUST NOT contain any properties. Its name is reserved for future use. + * + * @version 0.1.0 + * @see Pulsar message binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class PulsarMessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/redis/RedisMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/redis/RedisMessageBinding.java new file mode 100644 index 00000000..37b5980a --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/redis/RedisMessageBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.message.redis; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Redis message binding. + * + * @version 0.1.0 + * @see Redis message binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class RedisMessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/sns/SNSMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/sns/SNSMessageBinding.java new file mode 100644 index 00000000..17a72455 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/sns/SNSMessageBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.message.sns; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes SNS message binding. + * + * @version 0.1.0 + * @see SNS message binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class SNSMessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/solace/SolaceMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/solace/SolaceMessageBinding.java new file mode 100644 index 00000000..29b24c2b --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/solace/SolaceMessageBinding.java @@ -0,0 +1,23 @@ +package com.asyncapi.v3.binding.message.solace; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Builder; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Solace message binding. + * + * @version 0.3.0 + * @see Solace message binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class SolaceMessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/sqs/SQSMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/sqs/SQSMessageBinding.java new file mode 100644 index 00000000..9defa798 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/sqs/SQSMessageBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.message.sqs; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes SQS message binding. + * + * @version 0.1.0 + * @see SQS message binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class SQSMessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/stomp/STOMPMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/stomp/STOMPMessageBinding.java new file mode 100644 index 00000000..3e786247 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/stomp/STOMPMessageBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.message.stomp; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes STOMP message binding. + * + * @version 0.1.0 + * @see STOMP message binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class STOMPMessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/ws/WebSocketsMessageBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/ws/WebSocketsMessageBinding.java new file mode 100644 index 00000000..24dd7274 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/message/ws/WebSocketsMessageBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.message.ws; + +import com.asyncapi.v3.binding.message.MessageBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes WebSockets message binding. + * + * @version 0.1.0 + * @see WebSockets message binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class WebSocketsMessageBinding extends MessageBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/OperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/OperationBinding.java new file mode 100644 index 00000000..091629c8 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/OperationBinding.java @@ -0,0 +1,13 @@ +package com.asyncapi.v3.binding.operation; + +import com.asyncapi.v3.ExtendableObject; +import lombok.EqualsAndHashCode; + +/** + * Describes AsyncAPI operation binding. + * + * @author Pavel Bodiachevskii + */ +@EqualsAndHashCode(callSuper = true) +public class OperationBinding extends ExtendableObject { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/amqp/AMQPOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/amqp/AMQPOperationBinding.java new file mode 100644 index 00000000..56d53677 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/amqp/AMQPOperationBinding.java @@ -0,0 +1,150 @@ +package com.asyncapi.v3.binding.operation.amqp; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * Describes AMQP 0-9-1 operation binding. + *

+ * Contains information about the operation representation in AMQP. + * + * @version 0.2.0 + * @see AMQP operation binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes AMQP 0-9-1 operation binding.") +public class AMQPOperationBinding extends OperationBinding { + + /** + * TTL (Time-To-Live) for the message. It MUST be greater than or equal to zero. + *

+ * Applies to: publish, subscribe + */ + @Nullable + @javax.validation.constraints.Min( + value = 0, + message = "TTL (Time-To-Live) for the message must be greater than or equal to zero" + ) + @JsonProperty("expiration") + @JsonPropertyDescription("TTL (Time-To-Live) for the message. It MUST be greater than or equal to zero.") + private Integer expiration; + + /** + * Identifies the user who has sent the message. + *

+ * Applies to: publish, subscribe + */ + @Nullable + @JsonProperty("userId") + @JsonPropertyDescription("Identifies the user who has sent the message.") + private String userId; + + /** + * The routing keys the message should be routed to at the time of publishing. + *

+ * Applies to: publish, subscribe + */ + @Nullable + @JsonProperty("cc") + @JsonPropertyDescription("The routing keys the message should be routed to at the time of publishing.") + private List cc; + + /** + * A priority for the message. + *

+ * Applies to: publish, subscribe + */ + @Nullable + @JsonProperty("priority") + @JsonPropertyDescription("A priority for the message.") + private Integer priority; + + /** + * Delivery mode of the message. Its value MUST be either 1 (transient) or 2 (persistent). + *

+ * Applies to: publish, subscribe + */ + @Nullable + @javax.validation.constraints.Min( + value = 1, + message = "Delivery mode of the message must be either 1 (transient) or 2 (persistent)" + ) + @javax.validation.constraints.Max( + value = 2, + message = "Delivery mode of the message must be either 1 (transient) or 2 (persistent)" + ) + @JsonProperty("deliveryMode") + @JsonPropertyDescription("Delivery mode of the message. Its value MUST be either 1 (transient) or 2 (persistent).") + private Integer deliveryMode; + + /** + * Whether the message is mandatory or not. + *

+ * Applies to: publish + */ + @Nullable + @JsonProperty("mandatory") + @JsonPropertyDescription("Whether the message is mandatory or not.") + private Boolean mandatory; + + /** + * Like {@link #cc} but consumers will not receive this information. + *

+ * Applies to: publish + */ + @Nullable + @JsonProperty("bcc") + @JsonPropertyDescription("Like cc but consumers will not receive this information.") + private List bcc; + + /** + * Name of the queue where the consumer should send the response. + *

+ * Applies to: publish, subscribe + */ + @Nullable + @JsonProperty("replyTo") + @JsonPropertyDescription("Name of the queue where the consumer should send the response.") + private String replyTo; + + /** + * Whether the message should include a timestamp or not. + *

+ * Applies to: publish, subscribe + */ + @Nullable + @JsonProperty("timestamp") + @JsonPropertyDescription("Whether the message should include a timestamp or not.") + private Boolean timestamp; + + /** + * Whether the consumer should ack the message or not. + *

+ * Applies to: subscribe + */ + @Nullable + @JsonProperty("ack") + @JsonPropertyDescription("Whether the consumer should ack the message or not.") + private Boolean ack; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.2.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/amqp1/AMQP1OperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/amqp1/AMQP1OperationBinding.java new file mode 100644 index 00000000..29a7ce02 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/amqp1/AMQP1OperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.amqp1; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes AMQP 1.0 operation binding. + * + * @version 0.1.0 + * @see AMQP operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class AMQP1OperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/anypointmq/AnypointMQOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/anypointmq/AnypointMQOperationBinding.java new file mode 100644 index 00000000..8555af46 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/anypointmq/AnypointMQOperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.anypointmq; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Anypoint MQ operation binding. + * + * @version 0.0.1 + * @see Anypoint MQ operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class AnypointMQOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/googlepubsub/GooglePubSubOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/googlepubsub/GooglePubSubOperationBinding.java new file mode 100644 index 00000000..7b074d70 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/googlepubsub/GooglePubSubOperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.googlepubsub; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Google Cloud Pub/Sub operation binding. + * + * @version 0.1.0 + * @see Google Cloud Pub/Sub operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class GooglePubSubOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/http/HTTPOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/http/HTTPOperationBinding.java new file mode 100644 index 00000000..50a6c961 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/http/HTTPOperationBinding.java @@ -0,0 +1,66 @@ +package com.asyncapi.v3.binding.operation.http; + +import com.asyncapi.v3.schema.Schema; +import com.asyncapi.v3.binding.operation.OperationBinding; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * Describes HTTP operation binding. + *

+ * Contains information about the operation representation in HTTP. + * + * @version 0.1.0 + * @see HTTP operation binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class HTTPOperationBinding extends OperationBinding { + + /** + * Required. + *

+ * Type of operation. Its value MUST be either request or response. + */ + @NotNull + @Builder.Default + @javax.validation.constraints.NotNull + @JsonProperty(value = "type", required = true) + @JsonPropertyDescription("Type of operation. Its value MUST be either request or response.") + private HTTPOperationType type = HTTPOperationType.REQUEST; + + /** + * When type is request, this is the HTTP method, otherwise it MUST be ignored. Its value MUST be one of + * GET, POST, PUT, PATCH, DELETE, HEAD, OPTIONS, CONNECT, and TRACE. + */ + @Nullable + @JsonProperty("method") + @JsonPropertyDescription("When type is request, this is the HTTP method, otherwise it MUST be ignored. Its value MUST be one of GET, POST, PUT, PATCH, DELETE, HEAD, OPTIONS, CONNECT, and TRACE.") + private HTTPOperationMethod method; + + /** + * A Schema object containing the definitions for each query parameter. This schema MUST be of type object + * and have a properties key. + */ + @Nullable + @JsonProperty("query") + @JsonPropertyDescription("A Schema object containing the definitions for each query parameter. This schema MUST be of type object and have a properties key.") + private Schema query; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/http/HTTPOperationMethod.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/http/HTTPOperationMethod.java new file mode 100644 index 00000000..d71ddf2a --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/http/HTTPOperationMethod.java @@ -0,0 +1,22 @@ +package com.asyncapi.v3.binding.operation.http; + +/** + * Describes HTTP operation type. + *

+ * Contains information about the operation type. + * + * @version 0.1.0 + * @see HTTP operation binding + * @author Pavel Bodiachevskii + */ +public enum HTTPOperationMethod { + GET, + PUT, + POST, + PATCH, + DELETE, + HEAD, + OPTIONS, + CONNECT, + TRACE +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/http/HTTPOperationType.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/http/HTTPOperationType.java new file mode 100644 index 00000000..0c7d5031 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/http/HTTPOperationType.java @@ -0,0 +1,13 @@ +package com.asyncapi.v3.binding.operation.http; + +import com.fasterxml.jackson.annotation.JsonProperty; + +public enum HTTPOperationType { + + @JsonProperty("request") + REQUEST, + + @JsonProperty("response") + RESPONSE + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/ibmmq/IBMMQOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/ibmmq/IBMMQOperationBinding.java new file mode 100644 index 00000000..0313e97f --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/ibmmq/IBMMQOperationBinding.java @@ -0,0 +1,23 @@ +package com.asyncapi.v3.binding.operation.ibmmq; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Builder; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * Describes IBM MQ operation binding. + *

+ * This object MUST NOT contain any properties. Its name is reserved for future use. + * + * @version 0.1.0 + * @see IBM MQ operation binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class IBMMQOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/jms/JMSOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/jms/JMSOperationBinding.java new file mode 100644 index 00000000..f3a1f1a8 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/jms/JMSOperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.jms; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes JMS operation binding. + * + * @version 0.1.0 + * @see JMS operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class JMSOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/kafka/KafkaOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/kafka/KafkaOperationBinding.java new file mode 100644 index 00000000..c0558d01 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/kafka/KafkaOperationBinding.java @@ -0,0 +1,49 @@ +package com.asyncapi.v3.binding.operation.kafka; + +import com.asyncapi.v3.schema.Schema; +import com.asyncapi.v3.binding.operation.OperationBinding; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Kafka operation binding. + *

+ * Contains information about the operation representation in Kafka. + * + * @version 0.1.0 + * @see Kafka operation binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class KafkaOperationBinding extends OperationBinding { + + /** + * Id of the consumer group. + */ + @Nullable + @JsonProperty("groupId") + @JsonPropertyDescription("Id of the consumer group.") + private Schema groupId; + + /** + * Id of the consumer inside a consumer group. + */ + @Nullable + @JsonProperty("clientId") + @JsonPropertyDescription("Id of the consumer inside a consumer group.") + private Schema clientId; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + private String bindingVersion = "0.4.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/mercure/MercureOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/mercure/MercureOperationBinding.java new file mode 100644 index 00000000..10dcaa96 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/mercure/MercureOperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.mercure; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Mercure operation binding. + * + * @version 0.1.0 + * @see Mercure operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MercureOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/mqtt/MQTTOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/mqtt/MQTTOperationBinding.java new file mode 100644 index 00000000..c9f36c7c --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/mqtt/MQTTOperationBinding.java @@ -0,0 +1,67 @@ +package com.asyncapi.v3.binding.operation.mqtt; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes MQTT operation binding. + *

+ * Contains information about the operation representation in MQTT. + * + * @version 0.1.0 + * @see MQTT operation binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes MQTT operation binding.") +public class MQTTOperationBinding extends OperationBinding { + + /** + * Defines how hard the broker/client will try to ensure that a message is received. + * Its value MUST be either 0, 1 or 2. + *

+ * Applies to: publish, subscribe + */ + @Nullable + @javax.validation.constraints.Min( + value = 0, + message = "QoS must be greater or equals to 0." + ) + @javax.validation.constraints.Max( + value = 2, + message = "QoS must be lower or equals to 0." + ) + @JsonProperty("qos") + @JsonPropertyDescription("Defines the Quality of Service (QoS) levels for the message flow between client and server. Its value MUST be either 0 (At most once delivery), 1 (At least once delivery), or 2 (Exactly once delivery).") + private Integer qos; + + /** + * Whether the broker should retain the message or not. + *

+ * Applies to: publish, subscribe + */ + @Nullable + @JsonProperty("retain") + @JsonPropertyDescription("Whether the broker should retain the message or not.") + private Boolean retain; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + *

+ * Applies to: publish, subscribe + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/mqtt5/MQTT5OperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/mqtt5/MQTT5OperationBinding.java new file mode 100644 index 00000000..2964aad6 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/mqtt5/MQTT5OperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.mqtt5; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes MQTT 5 operation binding. + * + * @version 0.2.0 + * @see MQTT 5 operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MQTT5OperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/nats/NATSOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/nats/NATSOperationBinding.java new file mode 100644 index 00000000..9a6c2cf2 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/nats/NATSOperationBinding.java @@ -0,0 +1,46 @@ +package com.asyncapi.v3.binding.operation.nats; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes NATS operation binding. + * + * @version 0.1.0 + * @see NATS operation binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes NATS operation binding.") +public class NATSOperationBinding extends OperationBinding { + + /** + * Defines the name of the queue to use. It MUST NOT exceed 255 characters. + */ + @Nullable + @javax.validation.constraints.Size( + max = 255, + message = "Queue name must be lower or equals to 255." + ) + @JsonProperty("queue") + @JsonPropertyDescription("Defines the name of the queue to use. It MUST NOT exceed 255 characters.") + private String queue; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/pulsar/PulsarOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/pulsar/PulsarOperationBinding.java new file mode 100644 index 00000000..3670d242 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/pulsar/PulsarOperationBinding.java @@ -0,0 +1,23 @@ +package com.asyncapi.v3.binding.operation.pulsar; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Builder; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * Describes Pulsar operation binding. + *

+ * This object MUST NOT contain any properties. Its name is reserved for future use. + * + * @version 0.1.0 + * @see Pulsar operation binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class PulsarOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/redis/RedisOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/redis/RedisOperationBinding.java new file mode 100644 index 00000000..0c4eb8e0 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/redis/RedisOperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.redis; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Redis operation binding. + * + * @version 0.1.0 + * @see Redis operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class RedisOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/sns/SNSOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/sns/SNSOperationBinding.java new file mode 100644 index 00000000..e0445fc8 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/sns/SNSOperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.sns; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes SNS operation binding. + * + * @version 0.1.0 + * @see SNS operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class SNSOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/SolaceOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/SolaceOperationBinding.java new file mode 100644 index 00000000..bd87d8a7 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/SolaceOperationBinding.java @@ -0,0 +1,46 @@ +package com.asyncapi.v3.binding.operation.solace; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * Describes Solace operation binding. + *

+ * Contains information about the operation representation in Solace PubSub+ Broker. + * + * @version 0.3.0 + * @see Solace operation binding + * @author Dennis Brinley, Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes Solace operation binding.") +public class SolaceOperationBinding extends OperationBinding { + + /** + * List of destinations + */ + @Nullable + @JsonProperty("destinations") + @JsonPropertyDescription("List of destinations") + private List destinations; + + /** + * The version of this binding. (e.g. bindingVersion: 0.3.0) + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.3.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/SolaceOperationDestination.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/SolaceOperationDestination.java new file mode 100644 index 00000000..ef959dfb --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/SolaceOperationDestination.java @@ -0,0 +1,83 @@ +package com.asyncapi.v3.binding.operation.solace; + +import com.asyncapi.v3.binding.operation.solace.queue.SolaceOperationQueue; +import com.asyncapi.v3.binding.operation.solace.topic.SolaceOperationTopic; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.AllArgsConstructor; +import lombok.Builder; +import lombok.Data; +import lombok.NoArgsConstructor; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Solace destination. + *

+ * Contains information about the destination in Solace PubSub+ Broker. + * + * @version 0.3.0 + * @see Solace operation binding + * @author Dennis Brinley, Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@JsonClassDescription("Describes Solace destination.") +public class SolaceOperationDestination { + + /** + * 'queue' or 'topic'. If the type is queue, then the subscriber can bind to the queue, which in turn will + * subscribe to the topic as represented by the channel name or to the provided topicSubscriptions. + */ + @Nullable + @JsonProperty("destinationType") + @JsonPropertyDescription("'queue' or 'topic'. If the type is queue, then the subscriber can bind to the queue, which in turn will subscribe to the topic as represented by the channel name or to the provided topicSubscriptions.") + private Type destinationType; + + /** + * 'direct' or 'persistent'. This determines the quality of service for publishing messages as documented here. + * Default is 'persistent'. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "deliveryMode", defaultValue = "persistent") + @JsonPropertyDescription("'direct' or 'persistent'. This determines the quality of service for publishing messages as documented at https://docs.solace.com/Get-Started/Core-Concepts-Message-Delivery-Modes.htm. Default is 'persistent'.") + private DeliveryMode deliveryMode = DeliveryMode.PERSISTENT; + + /** + * Solace queue destination details. + */ + @Nullable + @JsonProperty("queue") + @JsonPropertyDescription("Solace queue destination details.") + private SolaceOperationQueue queue; + + /** + * Solace topic destination details. + */ + @Nullable + @JsonProperty("topic") + @JsonPropertyDescription("Solace topic destination details.") + private SolaceOperationTopic topic; + + public enum Type { + + @JsonProperty("queue") + QUEUE, + @JsonProperty("topic") + TOPIC + + } + + public enum DeliveryMode { + + @JsonProperty("direct") + DIRECT, + @JsonProperty("persistent") + PERSISTENT + + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/queue/SolaceOperationQueue.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/queue/SolaceOperationQueue.java new file mode 100644 index 00000000..d2c3f5c7 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/queue/SolaceOperationQueue.java @@ -0,0 +1,82 @@ +package com.asyncapi.v3.binding.operation.solace.queue; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.AllArgsConstructor; +import lombok.Builder; +import lombok.Data; +import lombok.NoArgsConstructor; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * Describes Solace queue. + *

+ * Contains information about the queue in Solace PubSub+ Broker. + * + * @version 0.3.0 + * @see Solace operation binding + * @author Dennis Brinley, Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@JsonClassDescription("Describes Solace queue.") +public class SolaceOperationQueue { + + /** + * The name of the queue, only applicable when destinationType is 'queue'. + */ + @Nullable + @JsonProperty("name") + @JsonPropertyDescription("The name of the queue, only applicable when destinationType is 'queue'.") + private String name; + + /** + * A list of topics that the queue subscribes to, only applicable when destinationType is 'queue'. + * If none is given, the queue subscribes to the topic as represented by the channel name. + */ + @Nullable + @JsonProperty("topicSubscriptions") + @JsonPropertyDescription("A list of topics that the queue subscribes to, only applicable when destinationType is 'queue'. If none is given, the queue subscribes to the topic as represented by the channel name.") + private List topicSubscriptions; + + /** + * 'exclusive' or 'nonexclusive'. This is documented here. Only applicable when destinationType is 'queue'. + */ + @Nullable + @JsonProperty("accessType") + @JsonPropertyDescription("'exclusive' or 'nonexclusive'. This is documented at https://docs.solace.com/Messaging/Guaranteed-Msg/Endpoints.htm#Queues. Only applicable when destinationType is 'queue'.") + private AccessType accessType; + + /** + * The maximum amount of message spool that the given queue may use. This is documented here. + * Only applicable when destinationType is 'queue'. + */ + @Nullable + @JsonProperty("maxMsgSpoolSize") + @JsonPropertyDescription("The maximum amount of message spool that the given queue may use. This is documented at https://docs.solace.com/Messaging/Guaranteed-Msg/Message-Spooling.htm#max-spool-usage. Only applicable when destinationType is 'queue'.") + private String maxMsgSpoolSize; + + /** + * The maximum TTL to apply to messages to be spooled. This is documented here. + * Only applicable when destinationType is 'queue'. + */ + @Nullable + @JsonProperty("maxTtl") + @JsonPropertyDescription("The maximum TTL to apply to messages to be spooled. This is documented at https://docs.solace.com/Messaging/Guaranteed-Msg/Configuring-Queues.htm. Only applicable when destinationType is 'queue'.") + private String maxTtl; + + public enum AccessType { + + @JsonProperty("exclusive") + EXCLUSIVE, + @JsonProperty("non-exclusive") + NON_EXCLUSIVE + + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/topic/SolaceOperationTopic.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/topic/SolaceOperationTopic.java new file mode 100644 index 00000000..9d20880d --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/solace/topic/SolaceOperationTopic.java @@ -0,0 +1,39 @@ +package com.asyncapi.v3.binding.operation.solace.topic; + +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.AllArgsConstructor; +import lombok.Builder; +import lombok.Data; +import lombok.NoArgsConstructor; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * Describes Solace topic. + *

+ * Contains information about the topic in Solace PubSub+ Broker. + * + * @version 0.3.0 + * @see Solace operation binding + * @author Dennis Brinley, Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@JsonClassDescription("Describes Solace topic.") +public class SolaceOperationTopic { + + /** + * A list of topics that the client subscribes to, only applicable when destinationType is 'topic'. + * If none is given, the client subscribes to the topic as represented by the channel name. + */ + @Nullable + @JsonProperty("topicSubscriptions") + @JsonPropertyDescription("A list of topics that the client subscribes to, only applicable when destinationType is 'topic'. If none is given, the client subscribes to the topic as represented by the channel name.") + protected List topicSubscriptions; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/sqs/SQSOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/sqs/SQSOperationBinding.java new file mode 100644 index 00000000..de34599b --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/sqs/SQSOperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.sqs; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes SQS operation binding. + * + * @version 0.1.0 + * @see SQS operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class SQSOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/stomp/STOMPOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/stomp/STOMPOperationBinding.java new file mode 100644 index 00000000..5679be40 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/stomp/STOMPOperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.stomp; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes STOMP operation binding. + * + * @version 0.1.0 + * @see STOMP operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class STOMPOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/ws/WebSocketsOperationBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/ws/WebSocketsOperationBinding.java new file mode 100644 index 00000000..a2e14bc5 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/operation/ws/WebSocketsOperationBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.ws; + +import com.asyncapi.v3.binding.operation.OperationBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes WebSockets operation binding. + * + * @version 0.1.0 + * @see WebSockets operation binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class WebSocketsOperationBinding extends OperationBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/ServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/ServerBinding.java new file mode 100644 index 00000000..531cf95d --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/ServerBinding.java @@ -0,0 +1,14 @@ +package com.asyncapi.v3.binding.server; + +import com.asyncapi.v3.ExtendableObject; +import lombok.EqualsAndHashCode; + +/** + * Describes AsyncAPI server binding. + * + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +@EqualsAndHashCode(callSuper = true) +public class ServerBinding extends ExtendableObject { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/amqp/AMQPServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/amqp/AMQPServerBinding.java new file mode 100644 index 00000000..17294433 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/amqp/AMQPServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.amqp; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes AMQP 0-9-1 server binding. + * + * @version 0.2.0 + * @see AMQP server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class AMQPServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/amqp1/AMQP1ServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/amqp1/AMQP1ServerBinding.java new file mode 100644 index 00000000..a97dbc33 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/amqp1/AMQP1ServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.amqp1; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes AMQP 1.0 server binding. + * + * @version 0.1.0 + * @see AMQP server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class AMQP1ServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/anypointmq/AnypointMQServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/anypointmq/AnypointMQServerBinding.java new file mode 100644 index 00000000..5771573a --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/anypointmq/AnypointMQServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.anypointmq; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Anypoint MQ server binding. + * + * @version 0.0.1 + * @see Anypoint MQ server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class AnypointMQServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/googlepubsub/GooglePubSubServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/googlepubsub/GooglePubSubServerBinding.java new file mode 100644 index 00000000..a8ff818f --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/googlepubsub/GooglePubSubServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.googlepubsub; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Google Cloud Pub/Sub server binding. + * + * @version 0.1.0 + * @see Google Cloud Pub/Sub server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class GooglePubSubServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/http/HTTPServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/http/HTTPServerBinding.java new file mode 100644 index 00000000..85c7e333 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/http/HTTPServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.http; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes HTTP server binding. + * + * @version 0.1.0 + * @see HTTP server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class HTTPServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/ibmmq/IBMMQServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/ibmmq/IBMMQServerBinding.java new file mode 100644 index 00000000..5b424552 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/ibmmq/IBMMQServerBinding.java @@ -0,0 +1,102 @@ +package com.asyncapi.v3.binding.server.ibmmq; + +import com.asyncapi.v3.binding.server.ServerBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes IBM MQ server binding. + *

+ * This object contains server connection information about the IBM MQ server, referred to as an IBM MQ queue manager. + * This object contains additional connectivity information not possible to represent within the core AsyncAPI specification. + * + * @version 0.1.0 + * @see IBM MQ server binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes IBM MQ server binding.") +public class IBMMQServerBinding extends ServerBinding { + + /** + * Defines a logical group of IBM MQ server objects. This is necessary to specify multi-endpoint configurations used + * in high availability deployments. If omitted, the server object is not part of a group. + *

+ * MUST NOT be specified for URI Scheme http:// or file:// + */ + @Nullable + @JsonProperty("groupId") + @JsonPropertyDescription("Defines a logical group of IBM MQ server objects. This is necessary to specify multi-endpoint configurations used in high availability deployments. If omitted, the server object is not part of a group.") + private String groupId; + + /** + * The name of the IBM MQ queue manager to bind to in the CCDT file. + *

+ * MUST NOT be specified for URI Scheme ibmmq:// + */ + @Nullable + @Builder.Default + @JsonProperty(value = "ccdtQueueManagerName", defaultValue = "*") + @JsonPropertyDescription("The name of the IBM MQ queue manager to bind to in the CCDT file.") + private String ccdtQueueManagerName = "*"; + + /** + * The recommended cipher specification used to establish a TLS connection between the client and the IBM MQ queue manager. + * More information on SSL/TLS cipher specifications supported by IBM MQ can be found on this page in the IBM MQ Knowledge Center. + *

+ * MUST NOT be specified for protocol ibmmq or URI Scheme file:// or http:// + */ + @Nullable + @Builder.Default + @JsonProperty(value = "cipherSpec", defaultValue = "ANY") + @JsonPropertyDescription("The recommended cipher specification used to establish a TLS connection between the client and the IBM MQ queue manager. More information on SSL/TLS cipher specifications supported by IBM MQ can be found on this page in the IBM MQ Knowledge Center.") + private String cipherSpec = "ANY"; + + /** + * If multiEndpointServer is true then multiple connections can be workload balanced and applications should not make + * assumptions as to where messages are processed. Where message ordering, or affinity to specific message resources + * is necessary, a single endpoint (multiEndpointServer = false) may be required. + *

+ * MUST NOT be specified for URI Scheme file:// or http:// + */ + @Builder.Default + @JsonProperty(value = "multiEndpointServer", defaultValue = "false") + @JsonPropertyDescription("If multiEndpointServer is true then multiple connections can be workload balanced and applications should not make assumptions as to where messages are processed. Where message ordering, or affinity to specific message resources is necessary, a single endpoint (multiEndpointServer = false) may be required. MUST NOT be specified for URI Scheme file:// or http://") + private Boolean multiEndpointServer = false; + + /** + * The recommended value (in seconds) for the heartbeat sent to the queue manager during periods of inactivity. + * A value of zero means that no heart beats are sent. A value of 1 means that the client will use the value defined by the queue manager. + * More information on heart beat interval can be found on this page in the IBM MQ Knowledge Center. + *

+ * MUST be 0-999999 + */ + @Builder.Default + @javax.validation.constraints.Min( + value = 0, + message = "Heart beat interval must be greater or equals to 0" + ) + @javax.validation.constraints.Max( + value = 999999, + message = "Heart beat interval must be less or equals to 999999" + ) + @JsonProperty(value = "heartBeatInterval", defaultValue = "300") + @JsonPropertyDescription("The recommended value (in seconds) for the heartbeat sent to the queue manager during periods of inactivity. A value of zero means that no heart beats are sent. A value of 1 means that the client will use the value defined by the queue manager.") + private int heartBeatInterval = 300; + + /** + * The version of this binding. + */ + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/jms/JMSServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/jms/JMSServerBinding.java new file mode 100644 index 00000000..406ac082 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/jms/JMSServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.jms; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes JMS server binding. + * + * @version 0.1.0 + * @see JMS server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class JMSServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/kafka/KafkaServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/kafka/KafkaServerBinding.java new file mode 100644 index 00000000..b0122269 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/kafka/KafkaServerBinding.java @@ -0,0 +1,52 @@ +package com.asyncapi.v3.binding.server.kafka; + +import com.asyncapi.v3.binding.server.ServerBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Kafka server binding. + * + * @version 0.4.0 + * @see Kafka server binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes Kafka server binding.") +public class KafkaServerBinding extends ServerBinding { + + /** + * API URL for the Schema Registry used when producing Kafka messages (if a Schema Registry was used) + */ + @Nullable + @JsonProperty("schemaRegistryUrl") + @JsonPropertyDescription("API URL for the Schema Registry used when producing Kafka messages (if a Schema Registry was used)") + private String schemaRegistryUrl; + + /** + * MUST NOT be specified if schemaRegistryUrl is not specified + *

+ * The vendor of Schema Registry and Kafka serdes library that should be used (e.g. apicurio, confluent, ibm, or karapace) + */ + @Nullable + @JsonProperty("schemaRegistryVendor") + @JsonPropertyDescription("The vendor of Schema Registry and Kafka serdes library that should be used (e.g. apicurio, confluent, ibm, or karapace)") + private String schemaRegistryVendor; + + /** + * The version of this binding. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.4.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mercure/MercureServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mercure/MercureServerBinding.java new file mode 100644 index 00000000..6919e41d --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mercure/MercureServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.mercure; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Mercure server binding. + * + * @version 0.1.0 + * @see Mercure server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MercureServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mqtt/MQTTServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mqtt/MQTTServerBinding.java new file mode 100644 index 00000000..29a261d0 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mqtt/MQTTServerBinding.java @@ -0,0 +1,68 @@ +package com.asyncapi.v3.binding.server.mqtt; + +import com.asyncapi.v3.binding.server.ServerBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes MQTT server binding. + *

+ * Contains information about the server representation in MQTT. + * + * @version 0.1.0 + * @see MQTT server binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes MQTT server binding.") +public class MQTTServerBinding extends ServerBinding { + + /** + * The client identifier. + */ + @Nullable + @JsonProperty("clientId") + @JsonPropertyDescription("The client identifier.") + private String clientId; + + /** + * Whether to create a persisten connection or not. When false, the connection will be persistent. + */ + @Nullable + @JsonProperty("cleanSession") + @JsonPropertyDescription("Whether to create a persisten connection or not. When false, the connection will be persistent.") + private Boolean cleanSession; + + /** + * Last Will and Testament configuration. + */ + @Nullable + @JsonProperty("lastWill") + @JsonPropertyDescription("Last Will and Testament configuration.") + private MQTTServerLastWillConfiguration lastWill; + + /** + * Interval in seconds of the longest period of time the broker and the client can endure without sending a message. + */ + @Nullable + @JsonProperty("keepAlive") + @JsonPropertyDescription("Interval in seconds of the longest period of time the broker and the client can endure without sending a message.") + private Integer keepAlive; + + /** + * The version of this binding. If omitted, "latest" MUST be assumed. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mqtt/MQTTServerLastWillConfiguration.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mqtt/MQTTServerLastWillConfiguration.java new file mode 100644 index 00000000..99e63a48 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mqtt/MQTTServerLastWillConfiguration.java @@ -0,0 +1,65 @@ +package com.asyncapi.v3.binding.server.mqtt; + +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.AllArgsConstructor; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; +import org.jetbrains.annotations.Nullable; + +/** + * Describes MQTT server last will configuration. + * + * @version 0.1.0 + * @see MQTT server binding + * @author Pavel Bodiachevskii + */ +@Data +@EqualsAndHashCode +@NoArgsConstructor +@AllArgsConstructor +public class MQTTServerLastWillConfiguration { + + /** + * The topic where the Last Will and Testament message will be sent. + */ + @Nullable + @JsonProperty("topic") + @JsonPropertyDescription("The topic where the Last Will and Testament message will be sent.") + private String topic; + + /** + * Defines how hard the broker/client will try to ensure that the Last Will and Testament message is received. + * Its value MUST be either 0, 1 or 2. + */ + @Nullable + @javax.validation.constraints.Min( + value = 0, + message = "QoS must be greater or equals to 0." + ) + @javax.validation.constraints.Max( + value = 2, + message = "QoS must be lower or equals to 0." + ) + @JsonProperty("qos") + @JsonPropertyDescription("Defines how hard the broker/client will try to ensure that the Last Will and Testament message is received. Its value MUST be either 0, 1 or 2.") + private Integer qos; + + /** + * Last Will message. + */ + @Nullable + @JsonProperty("message") + @JsonPropertyDescription("Last Will message.") + private String message; + + /** + * Whether the broker should retain the Last Will and Testament message or not. + */ + @Nullable + @JsonProperty("retain") + @JsonPropertyDescription("Whether the broker should retain the Last Will and Testament message or not.") + private Boolean retain; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mqtt5/MQTT5ServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mqtt5/MQTT5ServerBinding.java new file mode 100644 index 00000000..a9522e04 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/mqtt5/MQTT5ServerBinding.java @@ -0,0 +1,29 @@ +package com.asyncapi.v3.binding.server.mqtt5; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.*; + +/** + * Describes MQTT 5 server binding. + * + * @version 0.2.0 + * @see MQTT 5 server binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MQTT5ServerBinding extends ServerBinding { + + /** + * TODO: support reference, Schema object + * Session Expiry Interval in seconds or a Schema Object containing the definition of the interval. + */ + private int sessionExpiryInterval; + + @Builder.Default + private String bindingVersion = "0.2.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/nats/NATSServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/nats/NATSServerBinding.java new file mode 100644 index 00000000..00331b04 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/nats/NATSServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.nats; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes NATS channel binding. + * + * @version 0.1.0 + * @see NATS server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class NATSServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/pulsar/PulsarServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/pulsar/PulsarServerBinding.java new file mode 100644 index 00000000..b67d8ef0 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/pulsar/PulsarServerBinding.java @@ -0,0 +1,43 @@ +package com.asyncapi.v3.binding.server.pulsar; + +import com.asyncapi.v3.binding.server.ServerBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Pulsar server binding. + * + * @version 0.1.0 + * @see Redis server binding + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes Pulsar server binding.") +public class PulsarServerBinding extends ServerBinding { + + /** + * The pulsar tenant. If omitted, "public" MUST be assumed. + */ + @Nullable + @Builder.Default + @JsonProperty(value = "tenant", defaultValue = "public") + @JsonPropertyDescription("The pulsar tenant. If omitted, \"public\" MUST be assumed.") + private String tenant = "public"; + + /** + * The version of this binding. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.1.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/redis/RedisServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/redis/RedisServerBinding.java new file mode 100644 index 00000000..bea734b6 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/redis/RedisServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.redis; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes Redis server binding. + * + * @version 0.1.0 + * @see Redis server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class RedisServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/sns/SNSServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/sns/SNSServerBinding.java new file mode 100644 index 00000000..87b7dc42 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/sns/SNSServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.sns; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes SNS server binding. + * + * @version 0.1.0 + * @see SNS server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class SNSServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/solace/SolaceServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/solace/SolaceServerBinding.java new file mode 100644 index 00000000..c98e8470 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/solace/SolaceServerBinding.java @@ -0,0 +1,44 @@ +package com.asyncapi.v3.binding.server.solace; + +import com.asyncapi.v3.binding.server.ServerBinding; +import com.fasterxml.jackson.annotation.JsonClassDescription; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonPropertyDescription; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Describes Solace server binding. + * + * @version 0.3.0 + * @see Solace server binding + * @author Dennis Brinley, Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +@JsonClassDescription("Describes Solace server binding.") +public class SolaceServerBinding extends ServerBinding { + + /** + * Message VPN of the Solace Broker + *

+ * e.g. msgVpn: solace-broker-msg-vpn + */ + @Nullable + @JsonProperty("msgVpn") + @JsonPropertyDescription("Message VPN of the Solace Broker") + private String msgVpn; + + /** + * The version of this binding. + */ + @Nullable + @Builder.Default + @JsonProperty("bindingVersion") + @JsonPropertyDescription("The version of this binding.") + private String bindingVersion = "0.3.0"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/sqs/SQSServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/sqs/SQSServerBinding.java new file mode 100644 index 00000000..ce8f6962 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/sqs/SQSServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.sqs; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes SQS server binding. + * + * @version 0.1.0 + * @see SQS server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class SQSServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/stomp/STOMPServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/stomp/STOMPServerBinding.java new file mode 100644 index 00000000..871557c8 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/stomp/STOMPServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.stomp; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes STOMP server binding. + * + * @version 0.1.0 + * @see STOMP server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class STOMPServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/ws/WebSocketsServerBinding.java b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/ws/WebSocketsServerBinding.java new file mode 100644 index 00000000..b76ab214 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/binding/server/ws/WebSocketsServerBinding.java @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.server.ws; + +import com.asyncapi.v3.binding.server.ServerBinding; +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; + +/** + * This class MUST NOT contain any properties. Its name is reserved for future use. + *

+ * Describes WebSockets server binding. + * + * @version 0.1.0 + * @see WebSockets server binding + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class WebSocketsServerBinding extends ServerBinding { +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/BindingsMapDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/BindingsMapDeserializer.java new file mode 100644 index 00000000..d4e782c6 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/BindingsMapDeserializer.java @@ -0,0 +1,44 @@ +package com.asyncapi.v3.jackson; + +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.JsonProcessingException; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.DeserializationContext; +import com.fasterxml.jackson.databind.JsonDeserializer; +import com.fasterxml.jackson.databind.JsonNode; + +import java.io.IOException; +import java.util.HashMap; +import java.util.Map; + +/** + * Deserializes AsyncAPI bindings map. + */ +public abstract class BindingsMapDeserializer extends JsonDeserializer> { + + public abstract Object chooseKnownPojo(String bindingKey, JsonNode binding, ObjectCodec objectCodec) throws IOException; + + @Override + public Map deserialize( + JsonParser p, + DeserializationContext ctxt + ) throws IOException, JsonProcessingException { + ObjectCodec objectCodec = p.getCodec(); + JsonNode node = objectCodec.readTree(p); + + Map bindings = new HashMap<>(); + + node.fieldNames().forEachRemaining( + fieldName -> { + try { + bindings.put(fieldName, chooseKnownPojo(fieldName, node.get(fieldName), objectCodec)); + } catch (IOException e) { + e.printStackTrace(); + } + } + ); + + return bindings; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/ListOfReferencesOrObjectsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/ListOfReferencesOrObjectsDeserializer.java new file mode 100644 index 00000000..e4212093 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/ListOfReferencesOrObjectsDeserializer.java @@ -0,0 +1,51 @@ +package com.asyncapi.v3.jackson; + +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.JsonProcessingException; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.DeserializationContext; +import com.fasterxml.jackson.databind.JsonDeserializer; +import com.fasterxml.jackson.databind.JsonNode; + +import java.io.IOException; +import java.util.ArrayList; +import java.util.List; + +public abstract class ListOfReferencesOrObjectsDeserializer extends JsonDeserializer> { + + abstract public Class objectTypeClass(); + + abstract public Class referenceClass(); + + @Override + public List deserialize(JsonParser p, DeserializationContext ctxt) throws IOException, JsonProcessingException { + ObjectCodec objectCodec = p.getCodec(); + JsonNode node = objectCodec.readTree(p); + + List traits = new ArrayList<>(); + + node.forEach( + traitsValue -> { + try { + traits.add(chooseKnownPojo(traitsValue, objectCodec)); + } catch (IOException e) { + e.printStackTrace(); + } + } + ); + + return traits; + } + + private Object chooseKnownPojo(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + JsonNode ref = jsonNode.get("$ref"); + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + if (ref != null) { + return jsonParser.readValueAs(referenceClass()); + } else { + return jsonParser.readValueAs(objectTypeClass()); + } + } + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/MapOfReferencesOrObjectsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/MapOfReferencesOrObjectsDeserializer.java new file mode 100644 index 00000000..53d967a7 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/MapOfReferencesOrObjectsDeserializer.java @@ -0,0 +1,80 @@ +package com.asyncapi.v3.jackson; + +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.JsonProcessingException; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.DeserializationContext; +import com.fasterxml.jackson.databind.JsonDeserializer; +import com.fasterxml.jackson.databind.JsonNode; + +import java.io.IOException; +import java.util.HashMap; +import java.util.Map; + +/** + * Deserializes AsyncAPI map of parameters + * @param object + */ +public abstract class MapOfReferencesOrObjectsDeserializer extends JsonDeserializer> { + + abstract public Class objectTypeClass(); + + abstract public Class referenceClass(); + + @Override + public Map deserialize(JsonParser jsonParser, + DeserializationContext deserializationContext + ) throws IOException, JsonProcessingException { + ObjectCodec objectCodec = jsonParser.getCodec(); + JsonNode map = objectCodec.readTree(jsonParser); + + Map parameters = new HashMap<>(); + + map.fieldNames().forEachRemaining( + fieldName -> { + /* + Problem: + Both, Reference class and Schema class have $ref field. + So, this is only reason why I receive next exception: + "com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: + Unrecognized field "title" (class com.asyncapi.v2._6_0.model.Reference), + not marked as ignorable (one known property: "$ref"])" + in case when Schema contains $ref. + Solution: + Try to deserialize reference. In case of exception, try to deserialize it as given ObjectType. In case of + one more exception, throw it. + TODO: Think how to improve. + */ + try { + parameters.put(fieldName, chooseKnownPojo(map.get(fieldName), objectCodec)); + } catch (IOException ignore) { + try { + parameters.put(fieldName, readAsObject(map.get(fieldName), objectCodec)); + } catch (IOException e) { + e.printStackTrace(); + } + } + } + ); + + return parameters; + } + + private Object chooseKnownPojo(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + JsonNode ref = jsonNode.get("$ref"); + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + if (ref != null) { + return jsonParser.readValueAs(referenceClass()); + } else { + return jsonParser.readValueAs(objectTypeClass()); + } + } + } + + private Object readAsObject(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + return jsonParser.readValueAs(objectTypeClass()); + } + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/ReferenceOrObjectDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/ReferenceOrObjectDeserializer.java new file mode 100644 index 00000000..b9b34882 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/ReferenceOrObjectDeserializer.java @@ -0,0 +1,61 @@ +package com.asyncapi.v3.jackson; + +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.JsonProcessingException; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.DeserializationContext; +import com.fasterxml.jackson.databind.JsonDeserializer; +import com.fasterxml.jackson.databind.JsonNode; +import com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException; + +import java.io.IOException; + +public abstract class ReferenceOrObjectDeserializer extends JsonDeserializer { + + abstract public Class objectTypeClass(); + + abstract public Class referenceClass(); + + @Override + public Object deserialize(JsonParser p, DeserializationContext ctxt) throws IOException, JsonProcessingException { + ObjectCodec objectCodec = p.getCodec(); + JsonNode node = objectCodec.readTree(p); + + /* + Problem: + Both, Reference class and Schema class have $ref field. + So, this is only reason why I receive next exception: + "com.fasterxml.jackson.databind.exc.UnrecognizedPropertyException: + Unrecognized field "title" (class com.asyncapi.v2._6_0.model.Reference), + not marked as ignorable (one known property: "$ref"])" + in case when Schema contains $ref. + Solution: + Try to deserialize reference. In case of exception, try to deserialize it as given ObjectType. In case of + one more exception, throw it. + TODO: Think how to improve. + */ + try { + return chooseKnownPojo(node, objectCodec); + } catch (UnrecognizedPropertyException unrecognizedPropertyException) { + return readAsObject(node, objectCodec); + } + } + + private Object chooseKnownPojo(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + JsonNode ref = jsonNode.get("$ref"); + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + if (ref != null) { + return jsonParser.readValueAs(referenceClass()); + } else { + return jsonParser.readValueAs(objectTypeClass()); + } + } + } + + private Object readAsObject(JsonNode jsonNode, ObjectCodec objectCodec) throws IOException { + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + return jsonParser.readValueAs(objectTypeClass()); + } + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/channel/ChannelBindingsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/channel/ChannelBindingsDeserializer.java new file mode 100644 index 00000000..38ffac56 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/channel/ChannelBindingsDeserializer.java @@ -0,0 +1,68 @@ +package com.asyncapi.v3.jackson.binding.channel; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3.binding.channel.amqp.AMQPChannelBinding; +import com.asyncapi.v3.binding.channel.amqp1.AMQP1ChannelBinding; +import com.asyncapi.v3.binding.channel.anypointmq.AnypointMQChannelBinding; +import com.asyncapi.v3.binding.channel.googlepubsub.GooglePubSubChannelBinding; +import com.asyncapi.v3.binding.channel.http.HTTPChannelBinding; +import com.asyncapi.v3.binding.channel.ibmmq.IBMMQChannelBinding; +import com.asyncapi.v3.binding.channel.jms.JMSChannelBinding; +import com.asyncapi.v3.binding.channel.kafka.KafkaChannelBinding; +import com.asyncapi.v3.binding.channel.mercure.MercureChannelBinding; +import com.asyncapi.v3.binding.channel.mqtt.MQTTChannelBinding; +import com.asyncapi.v3.binding.channel.mqtt5.MQTT5ChannelBinding; +import com.asyncapi.v3.binding.channel.nats.NATSChannelBinding; +import com.asyncapi.v3.binding.channel.pulsar.PulsarChannelBinding; +import com.asyncapi.v3.binding.channel.redis.RedisChannelBinding; +import com.asyncapi.v3.binding.channel.sns.SNSChannelBinding; +import com.asyncapi.v3.binding.channel.solace.SolaceChannelBinding; +import com.asyncapi.v3.binding.channel.sqs.SQSChannelBinding; +import com.asyncapi.v3.binding.channel.stomp.STOMPChannelBinding; +import com.asyncapi.v3.binding.channel.ws.WebSocketsChannelBinding; +import com.asyncapi.v3.jackson.BindingsMapDeserializer; +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.JsonNode; + +import java.io.IOException; + +/** + * Serializes channel bindings map. + * + * @author Pavel Bodiachevskii + */ +public class ChannelBindingsDeserializer extends BindingsMapDeserializer { + + public Object chooseKnownPojo(String bindingKey, JsonNode binding, ObjectCodec objectCodec) throws IOException { + try (JsonParser jsonParser = binding.traverse(objectCodec)) { + if (binding.get("$ref" ) != null) { + return jsonParser.readValueAs(Reference.class); + } + + switch (bindingKey) { + case "amqp": return jsonParser.readValueAs(AMQPChannelBinding.class); + case "amqp1": return jsonParser.readValueAs(AMQP1ChannelBinding.class); + case "anypointmq": return jsonParser.readValueAs(AnypointMQChannelBinding.class); + case "googlepubsub": return jsonParser.readValueAs(GooglePubSubChannelBinding.class); + case "http": return jsonParser.readValueAs(HTTPChannelBinding.class); + case "ibmmq": return jsonParser.readValueAs(IBMMQChannelBinding.class); + case "jms": return jsonParser.readValueAs(JMSChannelBinding.class); + case "kafka": return jsonParser.readValueAs(KafkaChannelBinding.class); + case "mercure": return jsonParser.readValueAs(MercureChannelBinding.class); + case "mqtt": return jsonParser.readValueAs(MQTTChannelBinding.class); + case "mqtt5": return jsonParser.readValueAs(MQTT5ChannelBinding.class); + case "nats": return jsonParser.readValueAs(NATSChannelBinding.class); + case "pulsar": return jsonParser.readValueAs(PulsarChannelBinding.class); + case "redis": return jsonParser.readValueAs(RedisChannelBinding.class); + case "sns": return jsonParser.readValueAs(SNSChannelBinding.class); + case "solace": return jsonParser.readValueAs(SolaceChannelBinding.class); + case "sqs": return jsonParser.readValueAs(SQSChannelBinding.class); + case "stomp": return jsonParser.readValueAs(STOMPChannelBinding.class); + case "ws": return jsonParser.readValueAs(WebSocketsChannelBinding.class); + default: return null; + } + } + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/message/MessageBindingsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/message/MessageBindingsDeserializer.java new file mode 100644 index 00000000..a40a2fe1 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/message/MessageBindingsDeserializer.java @@ -0,0 +1,68 @@ +package com.asyncapi.v3.jackson.binding.message; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3.binding.message.amqp.AMQPMessageBinding; +import com.asyncapi.v3.binding.message.amqp1.AMQP1MessageBinding; +import com.asyncapi.v3.binding.message.anypointmq.AnypointMQMessageBinding; +import com.asyncapi.v3.binding.message.googlepubsub.GooglePubSubMessageBinding; +import com.asyncapi.v3.binding.message.http.HTTPMessageBinding; +import com.asyncapi.v3.binding.message.ibmmq.IBMMQMessageBinding; +import com.asyncapi.v3.binding.message.jms.JMSMessageBinding; +import com.asyncapi.v3.binding.message.kafka.KafkaMessageBinding; +import com.asyncapi.v3.binding.message.mercure.MercureMessageBinding; +import com.asyncapi.v3.binding.message.mqtt.MQTTMessageBinding; +import com.asyncapi.v3.binding.message.mqtt5.MQTT5MessageBinding; +import com.asyncapi.v3.binding.message.nats.NATSMessageBinding; +import com.asyncapi.v3.binding.message.pulsar.PulsarMessageBinding; +import com.asyncapi.v3.binding.message.redis.RedisMessageBinding; +import com.asyncapi.v3.binding.message.sns.SNSMessageBinding; +import com.asyncapi.v3.binding.message.solace.SolaceMessageBinding; +import com.asyncapi.v3.binding.message.sqs.SQSMessageBinding; +import com.asyncapi.v3.binding.message.stomp.STOMPMessageBinding; +import com.asyncapi.v3.binding.message.ws.WebSocketsMessageBinding; +import com.asyncapi.v3.jackson.BindingsMapDeserializer; +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.JsonNode; + +import java.io.IOException; + +/** + * Serializes message bindings map. + * + * @author Pavel Bodiachevskii + */ +public class MessageBindingsDeserializer extends BindingsMapDeserializer { + + public Object chooseKnownPojo(String bindingKey, JsonNode binding, ObjectCodec objectCodec) throws IOException { + try (JsonParser jsonParser = binding.traverse(objectCodec)) { + if (binding.get("$ref" ) != null) { + return jsonParser.readValueAs(Reference.class); + } + + switch (bindingKey) { + case "amqp": return jsonParser.readValueAs(AMQPMessageBinding.class); + case "amqp1": return jsonParser.readValueAs(AMQP1MessageBinding.class); + case "anypointmq": return jsonParser.readValueAs(AnypointMQMessageBinding.class); + case "googlepubsub": return jsonParser.readValueAs(GooglePubSubMessageBinding.class); + case "http": return jsonParser.readValueAs(HTTPMessageBinding.class); + case "ibmmq": return jsonParser.readValueAs(IBMMQMessageBinding.class); + case "jms": return jsonParser.readValueAs(JMSMessageBinding.class); + case "kafka": return jsonParser.readValueAs(KafkaMessageBinding.class); + case "mercure": return jsonParser.readValueAs(MercureMessageBinding.class); + case "mqtt": return jsonParser.readValueAs(MQTTMessageBinding.class); + case "mqtt5": return jsonParser.readValueAs(MQTT5MessageBinding.class); + case "nats": return jsonParser.readValueAs(NATSMessageBinding.class); + case "pulsar": return jsonParser.readValueAs(PulsarMessageBinding.class); + case "redis": return jsonParser.readValueAs(RedisMessageBinding.class); + case "sns": return jsonParser.readValueAs(SNSMessageBinding.class); + case "solace": return jsonParser.readValueAs(SolaceMessageBinding.class); + case "sqs": return jsonParser.readValueAs(SQSMessageBinding.class); + case "stomp": return jsonParser.readValueAs(STOMPMessageBinding.class); + case "ws": return jsonParser.readValueAs(WebSocketsMessageBinding.class); + default: return null; + } + } + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/operation/OperationBindingsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/operation/OperationBindingsDeserializer.java new file mode 100644 index 00000000..0b4b86e1 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/operation/OperationBindingsDeserializer.java @@ -0,0 +1,69 @@ +package com.asyncapi.v3.jackson.binding.operation; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3.binding.operation.amqp.AMQPOperationBinding; +import com.asyncapi.v3.binding.operation.amqp1.AMQP1OperationBinding; +import com.asyncapi.v3.binding.operation.anypointmq.AnypointMQOperationBinding; +import com.asyncapi.v3.binding.operation.googlepubsub.GooglePubSubOperationBinding; +import com.asyncapi.v3.binding.operation.http.HTTPOperationBinding; +import com.asyncapi.v3.binding.operation.ibmmq.IBMMQOperationBinding; +import com.asyncapi.v3.binding.operation.jms.JMSOperationBinding; +import com.asyncapi.v3.binding.operation.kafka.KafkaOperationBinding; +import com.asyncapi.v3.binding.operation.mercure.MercureOperationBinding; +import com.asyncapi.v3.binding.operation.mqtt.MQTTOperationBinding; +import com.asyncapi.v3.binding.operation.mqtt5.MQTT5OperationBinding; +import com.asyncapi.v3.binding.operation.nats.NATSOperationBinding; +import com.asyncapi.v3.binding.operation.pulsar.PulsarOperationBinding; +import com.asyncapi.v3.binding.operation.redis.RedisOperationBinding; +import com.asyncapi.v3.binding.operation.sns.SNSOperationBinding; +import com.asyncapi.v3.binding.operation.solace.SolaceOperationBinding; +import com.asyncapi.v3.binding.operation.sqs.SQSOperationBinding; +import com.asyncapi.v3.binding.operation.stomp.STOMPOperationBinding; +import com.asyncapi.v3.binding.operation.ws.WebSocketsOperationBinding; +import com.asyncapi.v3.jackson.BindingsMapDeserializer; +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.JsonNode; + +import java.io.IOException; + +/** + * Serializes operation bindings map. + * + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +public class OperationBindingsDeserializer extends BindingsMapDeserializer { + + public Object chooseKnownPojo(String bindingKey, JsonNode binding, ObjectCodec objectCodec) throws IOException { + try (JsonParser jsonParser = binding.traverse(objectCodec)) { + if (binding.get("$ref" ) != null) { + return jsonParser.readValueAs(Reference.class); + } + + switch (bindingKey) { + case "amqp": return jsonParser.readValueAs(AMQPOperationBinding.class); + case "amqp1": return jsonParser.readValueAs(AMQP1OperationBinding.class); + case "anypointmq": return jsonParser.readValueAs(AnypointMQOperationBinding.class); + case "googlepubsub": return jsonParser.readValueAs(GooglePubSubOperationBinding.class); + case "http": return jsonParser.readValueAs(HTTPOperationBinding.class); + case "ibmmq": return jsonParser.readValueAs(IBMMQOperationBinding.class); + case "jms": return jsonParser.readValueAs(JMSOperationBinding.class); + case "kafka": return jsonParser.readValueAs(KafkaOperationBinding.class); + case "mercure": return jsonParser.readValueAs(MercureOperationBinding.class); + case "mqtt": return jsonParser.readValueAs(MQTTOperationBinding.class); + case "mqtt5": return jsonParser.readValueAs(MQTT5OperationBinding.class); + case "nats": return jsonParser.readValueAs(NATSOperationBinding.class); + case "pulsar": return jsonParser.readValueAs(PulsarOperationBinding.class); + case "redis": return jsonParser.readValueAs(RedisOperationBinding.class); + case "sns": return jsonParser.readValueAs(SNSOperationBinding.class); + case "solace": return jsonParser.readValueAs(SolaceOperationBinding.class); + case "sqs": return jsonParser.readValueAs(SQSOperationBinding.class); + case "stomp": return jsonParser.readValueAs(STOMPOperationBinding.class); + case "ws": return jsonParser.readValueAs(WebSocketsOperationBinding.class); + default: return null; + } + } + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/server/ServerBindingsDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/server/ServerBindingsDeserializer.java new file mode 100644 index 00000000..c6cfbe04 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/binding/server/ServerBindingsDeserializer.java @@ -0,0 +1,70 @@ +package com.asyncapi.v3.jackson.binding.server; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3.binding.server.amqp.AMQPServerBinding; +import com.asyncapi.v3.binding.server.amqp1.AMQP1ServerBinding; +import com.asyncapi.v3.binding.server.anypointmq.AnypointMQServerBinding; +import com.asyncapi.v3.binding.server.googlepubsub.GooglePubSubServerBinding; +import com.asyncapi.v3.binding.server.http.HTTPServerBinding; +import com.asyncapi.v3.binding.server.ibmmq.IBMMQServerBinding; +import com.asyncapi.v3.binding.server.jms.JMSServerBinding; +import com.asyncapi.v3.binding.server.kafka.KafkaServerBinding; +import com.asyncapi.v3.binding.server.mercure.MercureServerBinding; +import com.asyncapi.v3.binding.server.mqtt.MQTTServerBinding; +import com.asyncapi.v3.binding.server.mqtt5.MQTT5ServerBinding; +import com.asyncapi.v3.binding.server.nats.NATSServerBinding; +import com.asyncapi.v3.binding.server.pulsar.PulsarServerBinding; +import com.asyncapi.v3.binding.server.redis.RedisServerBinding; +import com.asyncapi.v3.binding.server.sns.SNSServerBinding; +import com.asyncapi.v3.binding.server.solace.SolaceServerBinding; +import com.asyncapi.v3.binding.server.sqs.SQSServerBinding; +import com.asyncapi.v3.binding.server.stomp.STOMPServerBinding; +import com.asyncapi.v3.binding.server.ws.WebSocketsServerBinding; +import com.asyncapi.v3.jackson.BindingsMapDeserializer; +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.JsonNode; + +import java.io.IOException; + +/** + * Serializes server bindings map. + * + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +public class ServerBindingsDeserializer extends BindingsMapDeserializer { + + @Override + public Object chooseKnownPojo(String bindingKey, JsonNode binding, ObjectCodec objectCodec) throws IOException { + try (JsonParser jsonParser = binding.traverse(objectCodec)) { + if (binding.get("$ref" ) != null) { + return jsonParser.readValueAs(Reference.class); + } + + switch (bindingKey) { + case "amqp": return jsonParser.readValueAs(AMQPServerBinding.class); + case "amqp1": return jsonParser.readValueAs(AMQP1ServerBinding.class); + case "anypointmq": return jsonParser.readValueAs(AnypointMQServerBinding.class); + case "googlepubsub": return jsonParser.readValueAs(GooglePubSubServerBinding.class); + case "http": return jsonParser.readValueAs(HTTPServerBinding.class); + case "ibmmq": return jsonParser.readValueAs(IBMMQServerBinding.class); + case "jms": return jsonParser.readValueAs(JMSServerBinding.class); + case "kafka": return jsonParser.readValueAs(KafkaServerBinding.class); + case "mercure": return jsonParser.readValueAs(MercureServerBinding.class); + case "mqtt": return jsonParser.readValueAs(MQTTServerBinding.class); + case "mqtt5": return jsonParser.readValueAs(MQTT5ServerBinding.class); + case "nats": return jsonParser.readValueAs(NATSServerBinding.class); + case "pulsar": return jsonParser.readValueAs(PulsarServerBinding.class); + case "redis": return jsonParser.readValueAs(RedisServerBinding.class); + case "sns": return jsonParser.readValueAs(SNSServerBinding.class); + case "solace": return jsonParser.readValueAs(SolaceServerBinding.class); + case "sqs": return jsonParser.readValueAs(SQSServerBinding.class); + case "stomp": return jsonParser.readValueAs(STOMPServerBinding.class); + case "ws": return jsonParser.readValueAs(WebSocketsServerBinding.class); + default: return null; + } + } + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/schema/SchemasAdditionalPropertiesDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/schema/SchemasAdditionalPropertiesDeserializer.java new file mode 100644 index 00000000..659d70fe --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/schema/SchemasAdditionalPropertiesDeserializer.java @@ -0,0 +1,36 @@ +package com.asyncapi.v3.jackson.schema; + +import com.asyncapi.v3.schema.Schema; +import com.fasterxml.jackson.core.JsonParser; +import com.fasterxml.jackson.core.JsonProcessingException; +import com.fasterxml.jackson.core.ObjectCodec; +import com.fasterxml.jackson.databind.DeserializationContext; +import com.fasterxml.jackson.databind.JsonDeserializer; +import com.fasterxml.jackson.databind.JsonNode; + +import java.io.IOException; + +/** + * @author Guillaume LAMIRAND (guillaume.lamirand at graviteesource.com) + * @author GraviteeSource Team + */ +public class SchemasAdditionalPropertiesDeserializer extends JsonDeserializer { + + @Override + public Object deserialize(JsonParser p, DeserializationContext ctxt) throws IOException, JsonProcessingException { + ObjectCodec objectCodec = p.getCodec(); + JsonNode node = objectCodec.readTree(p); + + return chooseKnownPojo(node, objectCodec); + } + + private Object chooseKnownPojo(JsonNode jsonNode, final ObjectCodec objectCodec) throws IOException { + try (JsonParser jsonParser = jsonNode.traverse(objectCodec)) { + if (jsonNode.isBoolean()) { + return jsonNode.asBoolean(); + } else { + return jsonParser.readValueAs(Schema.class); + } + } + } +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/security_scheme/SecuritySchemesDeserializer.java b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/security_scheme/SecuritySchemesDeserializer.java new file mode 100644 index 00000000..93a1429b --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/jackson/security_scheme/SecuritySchemesDeserializer.java @@ -0,0 +1,24 @@ +package com.asyncapi.v3.jackson.security_scheme; + +import com.asyncapi.v3.Reference; +import com.asyncapi.v3.jackson.ListOfReferencesOrObjectsDeserializer; +import com.asyncapi.v3.security_scheme.SecurityScheme; + +/** + * Deserializes security schemes. + * + * @author Pavel Bodiachevskii + */ +public class SecuritySchemesDeserializer extends ListOfReferencesOrObjectsDeserializer { + + @Override + public Class objectTypeClass() { + return SecurityScheme.class; + } + + @Override + public Class referenceClass() { + return Reference.class; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/schema/MultiFormatSchema.java b/asyncapi-core/src/main/java/com/asyncapi/v3/schema/MultiFormatSchema.java new file mode 100644 index 00000000..64192dc5 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/schema/MultiFormatSchema.java @@ -0,0 +1,51 @@ +package com.asyncapi.v3.schema; + +import com.asyncapi.v3.ExtendableObject; +import lombok.*; +import org.jetbrains.annotations.NotNull; + +/** + * The Multi Format Schema Object represents a schema definition. It differs from the Schema Object in that it supports + * multiple schema formats or languages (e.g., JSON Schema, Avro, etc.). + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class MultiFormatSchema extends ExtendableObject { + + /** + * Required. + *

+ * A string containing the name of the schema format that is used to define the information. If schemaFormat is missing, + * it MUST default to application/vnd.aai.asyncapi+json;version={{asyncapi}} where {{asyncapi}} matches the AsyncAPI Version String. + * In such a case, this would make the Multi Format Schema Object equivalent to the Schema Object. When using Reference Object + * within the schema, the schemaFormat of the resource being referenced MUST match the schemaFormat of the schema that contains the + * initial reference. + * For example, if you reference Avro schema, then schemaFormat of referencing resource and the resource being reference MUST match. + *

+ * Check out the supported schema formats table for more information. Custom values are allowed but their implementation is OPTIONAL. + * A custom value MUST NOT refer to one of the schema formats listed in the table. + *

+ * When using Reference Objects within the schema, the schemaFormat of the referenced resource MUST match the schemaFormat + * of the schema containing the reference. + */ + @NotNull + private String schemaFormat; + + /** + * Required. + *

+ * Definition of the message payload. + *

+ * It can be of any type but defaults to Schema Object. + *

+ * It MUST match the schema format defined in schemaFormat, including the encoding type. E.g., Avro should be + * inlined as either a YAML or JSON object instead of as a string to be parsed as YAML or JSON. Non-JSON-based + * schemas (e.g., Protobuf or XSD) MUST be inlined as a string. + */ + @NotNull + private Object schema; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/schema/Schema.java b/asyncapi-core/src/main/java/com/asyncapi/v3/schema/Schema.java new file mode 100644 index 00000000..7085d8e1 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/schema/Schema.java @@ -0,0 +1,691 @@ +package com.asyncapi.v3.schema; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.jackson.schema.SchemasAdditionalPropertiesDeserializer; +import com.asyncapi.v3._0_0.model.ExternalDocumentation; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.databind.annotation.JsonDeserialize; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +import java.math.BigDecimal; +import java.util.List; +import java.util.Map; + +// TODO: Finish. Not all properties are present. +// TODO: Write tests + +/** + * The Schema Object allows the definition of input and output data types. These types can be objects, + * but also primitives and arrays. This object is a superset of the JSON Schema Specification Draft 07. + *
+ * Further information about the properties can be found in JSON Schema Core and JSON Schema Validation. + * Unless stated otherwise, the property definitions follow the JSON Schema specification as referenced here. + *

+ * The AsyncAPI Schema Object is a JSON Schema vocabulary which extends JSON Schema Core and Validation vocabularies. + * As such, any keyword available for those vocabularies is by definition available in AsyncAPI, and will work the + * exact same way, including but not limited to defined properties. + *

+ * New properties may appear in this class after community requests. + * + * @see AnyncAPI Schema Object + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class Schema extends ExtendableObject { + + /* + Schema Annotations + + Schema validation is a useful mechanism for annotating instance data + with additional information. The rules for determining when and how + annotations are associated with an instance are outlined in section + 3.3. + + These general-purpose annotation keywords provide commonly used + information for documentation and user interface display purposes. + They are not intended to form a comprehensive set of features. + Rather, additional vocabularies can be defined for more complex + annotation-based applications. + */ + + /** + * The value of these keyword MUST be a string. + *

+ * This keywords can be used to decorate a user interface with information about the data produced by this user + * interface. + *

+ * A title will preferably be short + */ + @Nullable + @JsonProperty + public String title; + + /** + * The value of these keyword MUST be a string. + *

+ * This property definition was adjusted to the AsyncAPI Specification. + * CommonMark syntax can be used for rich text representation. + *

+ * This keywords can be used to decorate a user interface with information about the data produced by this user + * interface. + *

+ * A description will provide explanation about the purpose of the instance described by this schema. + */ + @Nullable + @JsonProperty + public String description; + + /** + * There are no restrictions placed on the value of this keyword. When multiple occurrences of this keyword are + * applicable to a single sub-instance, implementations SHOULD remove duplicates. + *

+ * This keyword can be used to supply a default JSON value associated with a particular schema. + * It is RECOMMENDED that a default value be valid against the associated schema. + *

+ * This property definition was adjusted to the AsyncAPI Specification. + * The default value represents what would be assumed by the consumer of the input as the value of the schema if one + * is not provided. Unlike JSON Schema, the value MUST conform to the defined type for the Schema Object defined at + * the same level. For example, of type is string, then default can be "foo" but cannot be 1. + */ + @Nullable + @JsonProperty("default") + public Object defaultValue; + + /** + * The value of this keyword MUST be a boolean. When multiple occurrences of this keyword are applicable to a + * single sub-instance, the resulting value MUST be true if any occurrence specifies a true value, and MUST be false otherwise. + *

+ * If "readOnly" has a value of boolean true, it indicates that the value of the instance is managed exclusively by the owning authority, + * and attempts by an application to modify the value of this property are expected to be ignored or rejected by that owning authority. + *

+ * An instance document that is marked as "readOnly for the entire document MAY be ignored if sent to the owning authority, or MAY + * result in an error, at the authority's discretion. + *

+ * For example, "readOnly" would be used to mark a database-generated serial number as read-only, while "writeOnly" would be used to mark a + * password input field. + *

+ * This keyword can be used to assist in user interface instance generation. In particular, an application MAY choose to use a widget + * that hides input values as they are typed for write-only fields. + *

+ * Omitting this keyword has the same behavior as values of false. + */ + @Nullable + @JsonProperty + public Boolean readOnly; + + /** + * The value of this keyword MUST be a boolean. When multiple occurrences of this keyword are applicable to a + * single sub-instance, the resulting value MUST be true if any occurrence specifies a true value, and MUST be false otherwise. + *

+ * If "writeOnly" has a value of boolean true, it indicates that the value is never present when the instance is retrieved from the owning + * authority. It can be present when sent to the owning authority to update or create the document (or the resource it represents), but it + * will not be included in any updated or newly created version of the instance. + *

+ * An instance document that is marked as "writeOnly" for the entire document MAY be returned as a blank document of some sort, or MAY + * produce an error upon retrieval, or have the retrieval request ignored, at the authority's discretion. + *

+ * This keyword can be used to assist in user interface instance generation. In particular, an application MAY choose to use a widget + * that hides input values as they are typed for write-only fields. + *

+ * Omitting this keyword has the same behavior as values of false. + */ + @Nullable + @JsonProperty + public Boolean writeOnly; + + /** + * The value of this keyword MUST be an array. There are no restrictions placed on the values within the array. + * When multiple occurrences of this keyword are applicable to a single sub-instance, implementations MUST provide + * a flat array of all values rather than an array of arrays. + *

+ * This keyword can be used to provide sample JSON values associated with a particular schema, for the purpose of + * illustrating usage. It is RECOMMENDED that these values be valid against the associated schema. + *

+ * Implementations MAY use the value(s) of "default", if present, as an additional example. If "examples" is absent, + * "default" MAY still be used in this manner. + */ + @Nullable + @JsonProperty + public List examples; + + @Nullable + @JsonProperty("$ref") + private String ref; + + /* + String-Encoding Non-JSON Data + + Foreword + + Properties defined in this section indicate that an instance contains + non-JSON data encoded in a JSON string. They describe the type of + content and how it is encoded. + + These properties provide additional information required to interpret + JSON data as rich multimedia documents. + + Implementation Requirements + + The content keywords function as both annotations (Section 3.3) and + as assertions (Section 3.2). While no special effort is required to + implement them as annotations conveying how applications can + interpret the data in the string, implementing validation of + conformance to the media type and encoding is non-trivial. + + Implementations MAY support the "contentMediaType" and + "contentEncoding" keywords as validation assertions. Should they + choose to do so, they SHOULD offer an option to disable validation + for these keywords. + */ + + /** + * If the instance value is a string, this property defines that the string SHOULD be interpreted as binary data and + * decoded using the encoding named by this property. RFC 2045, Sec 6.1 [RFC2045] lists the possible values for this property. + *

+ * The value of this property MUST be a string. + *

+ * The value of this property SHOULD be ignored if the instance described is not a string. + */ + @Nullable + @JsonProperty + private String contentEncoding; + + /** + * The value of this property must be a media type, as defined by RFC 2046 [RFC2046]. This property defines the media + * type of instances which this schema defines. + *

+ * The value of this property MUST be a string. + *

+ * The value of this property SHOULD be ignored if the instance described is not a string. + *

+ * If the "contentEncoding" property is not present, but the instance value is a string, then the value of this property SHOULD specify a + * text document type, and the character set SHOULD be the character set into which the JSON string value was decoded (for which the default + * is Unicode). + */ + @Nullable + @JsonProperty + private String contentMediaType; + + /* + Validation. + */ + + /* + Validation Keywords for Any Instance Type + */ + + /** + * The value of this keyword MUST be either a string or an array. If it is an array, elements of the array MUST + * be strings and MUST be unique. + *
+ * String values MUST be one of the six primitive types ("null", "boolean", "object", "array", "number", or "string"), + * or "integer" which matches any number with a zero fractional part. + *
+ * An instance validates if and only if the instance is in any of the sets listed for this keyword. + * + */ + @Nullable + @JsonProperty + public Object type; + + /** + * The value of this keyword MUST be an array. This array SHOULD have at least one element. Elements in the array SHOULD be unique. + *
+ * An instance validates successfully against this keyword if its value is equal to one of the elements in this keyword's array value. + *
+ * Elements in the array might be of any value, including null. + */ + @Nullable + @JsonProperty("enum") + public List enumValue; + + /** + * The value of this keyword MAY be of any type, including null. + *
+ * An instance validates successfully against this keyword if its value is equal to the value of the keyword. + */ + @Nullable + @JsonProperty("const") + public Object constValue; + + /* + Validation Keywords for Numeric Instances (number and integer) + */ + + /** + * The value of "multipleOf" MUST be a number, strictly greater than 0. + *
+ * A numeric instance is valid only if division by this keyword's value results in an integer. + */ + @Nullable + @JsonProperty + public Integer multipleOf; + + /** + * The value of "maximum" MUST be a number, representing an inclusive upper limit for a numeric instance. + *
+ * If the instance is a number, then this keyword validates only if the instance is less than or exactly equal to "maximum". + */ + @Nullable + @JsonProperty + public BigDecimal maximum; + + /** + * The value of "exclusiveMaximum" MUST be number, representing an exclusive upper limit for a numeric instance. + *
+ * If the instance is a number, then the instance is valid only if it has a value strictly less than (not equal to) "exclusiveMaximum". + */ + @Nullable + @JsonProperty + public BigDecimal exclusiveMaximum; + + /** + * The value of "minimum" MUST be a number, representing an inclusive lower limit for a numeric instance. + *
+ * If the instance is a number, then this keyword validates only if the instance is greater than or exactly equal to "minimum". + */ + @Nullable + @JsonProperty + public BigDecimal minimum; + + /** + * The value of "exclusiveMinimum" MUST be number, representing an exclusive lower limit for a numeric instance. + *
+ * If the instance is a number, then the instance is valid only if it has a value strictly greater than (not equal to) "exclusiveMinimum". + */ + @Nullable + @JsonProperty + public BigDecimal exclusiveMinimum; + + /* + Validation Keywords for Strings + */ + + /** + * The value of this keyword MUST be a non-negative integer. + *
+ * A string instance is valid against this keyword if its length is less than, or equal to, the value of this keyword. + *
+ * The length of a string instance is defined as the number of its characters as defined by RFC 7159 [RFC7159]. + */ + @Nullable + @JsonProperty + public Integer maxLength; + + /** + * The value of this keyword MUST be a non-negative integer. + *
+ * A string instance is valid against this keyword if its length is greater than, or equal to, the value of this keyword. + *
+ * The length of a string instance is defined as the number of its characters as defined by RFC 7159 [RFC7159]. + *
+ * Omitting this keyword has the same behavior as a value of 0. + */ + @Nullable + @JsonProperty + public Integer minLength; + + /** + * The value of this keyword MUST be a string. This string SHOULD be a valid regular expression, according + * to the ECMA 262 regular expression dialect. + *
+ * A string instance is considered valid if the regular expression matches the instance successfully. + * Recall: regular expressions are not implicitly anchored. + */ + @Nullable + @JsonProperty + public String pattern; + + /* + Validation Keywords for Arrays + */ + + /** + * The value of "items" MUST be either a valid JSON Schema or an array of valid JSON Schemas. + *
+ * This keyword determines how child instances validate for arrays, and does not directly validate the immediate instance itself. + *
+ * If "items" is a schema, validation succeeds if all elements in the array successfully validate against that schema. + *
+ * If "items" is an array of schemas, validation succeeds if each element of the instance validates against the schema at the same + * position, if any. + *
+ * Omitting this keyword has the same behavior as an empty schema. + */ + @Nullable + @JsonProperty + public Object items; + + /** + * The value of "additionalItems" MUST be a valid JSON Schema. + *
+ * This keyword determines how child instances validate for arrays, and does not directly validate the immediate instance itself. + *
+ * If "items" is an array of schemas, validation succeeds if every instance element at a position greater than the size of "items" + * validates against "additionalItems". + *
+ * Otherwise, "additionalItems" MUST be ignored, as the "items" schema (possibly the default value of an empty schema) is applied + * to all elements. + *
+ * Omitting this keyword has the same behavior as an empty schema. + */ + @Nullable + public Schema additionalItems; + + /** + * The value of this keyword MUST be a non-negative integer. + *
+ * An array instance is valid against "maxItems" if its size is less than, or equal to, the value of this keyword. + */ + @Nullable + @JsonProperty + public Integer maxItems; + + /** + * The value of this keyword MUST be a non-negative integer. + *
+ * An array instance is valid against "minItems" if its size is greater than, or equal to, the value of this keyword. + *
+ * Omitting this keyword has the same behavior as a value of 0. + */ + @Nullable + @JsonProperty + public Integer minItems; + + /** + * The value of this keyword MUST be a boolean. + *
+ * If this keyword has boolean value false, the instance validates successfully. If it has boolean value true, + * the instance validates successfully if all of its elements are unique. + *
+ * Omitting this keyword has the same behavior as a value of false. + */ + @Nullable + @JsonProperty + public Boolean uniqueItems; + + /** + * The value of this keyword MUST be a valid JSON Schema. + *
+ * An array instance is valid against "contains" if at least one of its elements is valid against the given schema. + */ + @Nullable + @JsonProperty + public Schema contains; + + /* + Validation Keywords for Objects + */ + + /** + * The value of this keyword MUST be a non-negative integer. + *
+ * An object instance is valid against "maxProperties" if its number of properties is less than, or equal to, + * the value of this keyword. + */ + @Nullable + @JsonProperty + public Integer maxProperties; + + /** + * The value of this keyword MUST be a non-negative integer. + *

+ * An object instance is valid against "minProperties" if its number of properties is greater than, or equal to, + * the value of this keyword. + *

+ * Omitting this keyword has the same behavior as a value of 0. + */ + @Nullable + @JsonProperty + public Integer minProperties; + + /** + * The value of this keyword MUST be an array. Elements of this array, if any, MUST be strings, and MUST be unique. + *

+ * An object instance is valid against this keyword if every item in the array is the name of a property in the instance. + *

+ * Omitting this keyword has the same behavior as an empty array. + */ + @Nullable + @JsonProperty + public List required; + + /** + * The value of "properties" MUST be an object. Each value of this object MUST be a valid JSON Schema. + *

+ * This keyword determines how child instances validate for objects, and does not directly validate the immediate + * instance itself. + *

+ * Validation succeeds if, for each name that appears in both the instance and as a name within this keyword's value, + * the child instance for that name successfully validates against the corresponding schema. + *

+ * Omitting this keyword has the same behavior as an empty object. + */ + @Nullable + @JsonProperty + public Map properties; + + /** + * The value of "patternProperties" MUST be an object. Each property name of this object SHOULD be a valid regular + * expression, according to the ECMA 262 regular expression dialect. Each property value of this object MUST be a + * valid JSON Schema. + *

+ * This keyword determines how child instances validate for objects, and does not directly validate the immediate + * instance itself. Validation of the primitive instance type against this keyword always succeeds. + *

+ * Validation succeeds if, for each instance name that matches any regular expressions that appear as a property name + * in this keyword's value, the child instance for that name successfully validates against each schema that corresponds + * to a matching regular expression. + *

+ * Omitting this keyword has the same behavior as an empty object. + */ + @Nullable + @JsonProperty + public Map patternProperties; + + /** + * The value of "additionalProperties" MUST be a valid JSON Schema. + *

+ * This keyword determines how child instances validate for objects, and does not directly validate the immediate + * instance itself. + *

+ * Validation with "additionalProperties" applies only to the child values of instance names that do not match any + * names in "properties", and do not match any regular expression in "patternProperties". + *

+ * For all such properties, validation succeeds if the child instance validates against the "additionalProperties" schema. + *

+ * Omitting this keyword has the same behavior as an empty schema. + */ + @Nullable + @JsonProperty + @JsonDeserialize(using = SchemasAdditionalPropertiesDeserializer.class) + public Object additionalProperties; + + /** + * [[CREF1: This keyword may be split into two, with the variation that uses an array of property names rather than a + * subschema getting a new name. The dual behavior is confusing and relatively difficult to implement. In the previous + * draft, we proposed dropping the keyword altogether, or dropping one of its forms, but we received feedback in support of + * keeping it. See issues #442 and #528 at https://github.com/json-schema-org/json-schema-spec/issues for further discussion. + * Further feedback is encouraged.]] + *

+ * This keyword specifies rules that are evaluated if the instance is an object and contains a certain property. + *

+ * This keyword's value MUST be an object. Each property specifies a dependency. Each dependency value MUST be an array + * or a valid JSON Schema. + *

+ * If the dependency value is a subschema, and the dependency key is a property in the instance, the entire instance must validate + * against the dependency value. + *

+ * If the dependency value is an array, each element in the array, if any, MUST be a string, and MUST be unique. If the dependency + * key is a property in the instance, each of the items in the dependency value must be a property that exists in the instance. + *

+ * Omitting this keyword has the same behavior as an empty object. + */ + @Nullable + @JsonProperty + public Object dependencies; + + /** + * The value of "propertyNames" MUST be a valid JSON Schema. + *

+ * If the instance is an object, this keyword validates if every property name in the instance validates against the provided schema. + * Note the property name that the schema is testing will always be a string. + *

+ * Omitting this keyword has the same behavior as an empty schema. + */ + @Nullable + @JsonProperty + public Schema propertyNames; + + /* + Keywords for Applying Subschemas Conditionally + + These keywords work together to implement conditional application of + a subschema based on the outcome of another subschema. + + These keywords MUST NOT interact with each other across subschema + boundaries. In other words, an "if" in one branch of an "allOf" MUST + NOT have an impact on a "then" or "else" in another branch. + + There is no default behavior for any of these keywords when they are + not present. In particular, they MUST NOT be treated as if present + with an empty schema, and when "if" is not present, both "then" and + "else" MUST be entirely ignored. + */ + + /** + * This keyword's value MUST be a valid JSON Schema. + *

+ * This validation outcome of this keyword's subschema has no direct effect on the overall validation result. + * Rather, it controls which of the "then" or "else" keywords are evaluated. + *

+ * Instances that successfully validate against this keyword's subschema MUST also be valid against the subschema + * value of the "then" keyword, if present. + *

+ * Instances that fail to validate against this keyword's subschema MUST also be valid against the subschema value of + * the "else" keyword, if present. + *

+ * If annotations (Section 3.3) are being collected, they are collected from this keyword's subschema in the usual way, + * including when the keyword is present without either "then" or "else". + */ + @JsonProperty("if") + @Nullable + public Schema ifValue; + + /** + * This keyword's value MUST be a valid JSON Schema. + *

+ * When "if" is present, and the instance successfully validates against its subschema, then valiation succeeds against + * this keyword if the instance also successfully validates against this keyword's subschema. + *

+ * This keyword has no effect when "if" is absent, or when the instance fails to validate against its subschema. + * Implementations MUST NOT evaluate the instance against this keyword, for either validation or annotation collection + * purposes, in such cases. + */ + @JsonProperty("then") + @Nullable + public Schema thenValue; + + /** + * This keyword's value MUST be a valid JSON Schema. + *

+ * When "if" is present, and the instance fails to validate against its subschema, then valiation succeeds against this + * keyword if the instance successfully validates against this keyword's subschema. + *

+ * This keyword has no effect when "if" is absent, or when the instance successfully validates against its subschema. + * Implementations MUST NOT evaluate the instance against this keyword, for either validation or annotation collection + * purposes, in such cases. + */ + @JsonProperty("else") + @Nullable + public Schema elseValue; + + /* + Keywords for Applying Subschemas With Boolean Logic + */ + + /** + * This keyword's value MUST be a non-empty array. Each item of the array MUST be a valid JSON Schema. + *

+ * An instance validates successfully against this keyword if it validates successfully against all schemas defined + * by this keyword's value. + */ + @Nullable + @JsonProperty + public List allOf; + + /** + * This keyword's value MUST be a non-empty array. Each item of the array MUST be a valid JSON Schema. + *

+ * An instance validates successfully against this keyword if it validates successfully against at least one schema + * defined by this keyword's value. + */ + @Nullable + @JsonProperty + public List anyOf; + + /** + * This keyword's value MUST be a non-empty array. Each item of the array MUST be a valid JSON Schema. + *

+ * An instance validates successfully against this keyword if it validates successfully against exactly one schema + * defined by this keyword's value. + */ + @Nullable + @JsonProperty + public List oneOf; + + /** + * This keyword's value MUST be a valid JSON Schema. + *

+ * An instance is valid against this keyword if it fails to validate successfully against the schema defined by this keyword. + */ + @Nullable + @JsonProperty + public Schema not; + + // Fields defined in AsyncAPI below + + /* + The following properties are taken from the JSON Schema definition but their definitions were adjusted to the AsyncAPI Specification. + */ + /** + * See Data Type Formats for further details. + * While relying on JSON Schema's defined formats, the AsyncAPI Specification offers a few additional predefined formats. + */ + @Nullable + @JsonProperty + public Object format; + + /* + In addition to the JSON Schema fields, the following AsyncAPI vocabulary fields MAY be used for further schema documentation: + */ + /** + * Adds support for polymorphism. The discriminator is the schema property name that is used to differentiate between + * other schema that inherit this schema. + *

+ * The property name used MUST be defined at this schema and it MUST be in the required property list. + * When used, the value MUST be the name of this schema or any schema that inherits it. See Composition and Inheritance for more details. + */ + @Nullable + @JsonProperty + public String discriminator; + /** + * Additional external documentation for this schema. + */ + @Nullable + @JsonProperty + public ExternalDocumentation externalDocs; + + /** + * Specifies that a schema is deprecated and SHOULD be transitioned out of usage. Default value is false. + */ + @Nullable + @JsonProperty + public Boolean deprecated; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/schema/Type.java b/asyncapi-core/src/main/java/com/asyncapi/v3/schema/Type.java new file mode 100644 index 00000000..957e6b30 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/schema/Type.java @@ -0,0 +1,16 @@ +package com.asyncapi.v3.schema; + +/** + * @author Pavel Bodiachevskii + */ +public class Type { + + public final static String NULL = "null"; + public final static String BOOLEAN = "boolean"; + public final static String OBJECT = "object"; + public final static String ARRAY = "array"; + public final static String NUMBER = "number"; + public final static String STRING = "string"; + public final static String INTEGER = "integer"; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/ApiKeySecurityScheme.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/ApiKeySecurityScheme.java new file mode 100644 index 00000000..86a20335 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/ApiKeySecurityScheme.java @@ -0,0 +1,43 @@ +package com.asyncapi.v3.security_scheme; + +import com.fasterxml.jackson.annotation.JsonProperty; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * @version 2.6.0 + * @see SecurityScheme + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class ApiKeySecurityScheme extends SecurityScheme { + + /** + * REQUIRED. + *

+ * The location of the API key. + */ + @NotNull + private ApiKeyLocation in = ApiKeyLocation.USER; + + @Builder(builderMethodName = "apiKeyBuilder") + public ApiKeySecurityScheme(@Nullable String description, + @NotNull ApiKeyLocation in) { + super(Type.API_KEY, description); + this.in = in; + } + + public enum ApiKeyLocation { + + @JsonProperty("user") + USER, + @JsonProperty("password") + PASSWORD + + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/OpenIdConnectSecurityScheme.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/OpenIdConnectSecurityScheme.java new file mode 100644 index 00000000..ff0febc3 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/OpenIdConnectSecurityScheme.java @@ -0,0 +1,43 @@ +package com.asyncapi.v3.security_scheme; + +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * @version 2.6.0 + * @see SecurityScheme + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class OpenIdConnectSecurityScheme extends SecurityScheme { + + /** + * REQUIRED. + *

+ * OpenId Connect URL to discover OAuth2 configuration values. This MUST be in the form of a URL. + */ + @NotNull + private String openIdConnectUrl = ""; + + /** + * List of the needed scope names. + */ + @Nullable + private List scopes; + + @Builder(builderMethodName = "openIdBuilder") + public OpenIdConnectSecurityScheme(@Nullable String description, + @NotNull String openIdConnectUrl, + @Nullable List scopes) { + super(Type.OPENID_CONNECT, description); + this.openIdConnectUrl = openIdConnectUrl; + this.scopes = scopes; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/SecurityScheme.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/SecurityScheme.java new file mode 100644 index 00000000..795fcb20 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/SecurityScheme.java @@ -0,0 +1,119 @@ +package com.asyncapi.v3.security_scheme; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.security_scheme.http.HttpApiKeySecurityScheme; +import com.asyncapi.v3.security_scheme.http.HttpSecurityScheme; +import com.asyncapi.v3.security_scheme.oauth2.OAuth2SecurityScheme; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonSubTypes; +import com.fasterxml.jackson.annotation.JsonTypeInfo; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * Defines a security scheme that can be used by the operations. Supported schemes are: + *

    + *
  • User/Password.
  • + *
  • API key (either as user or as password).
  • + *
  • X.509 certificate.
  • + *
  • End-to-end encryption (either symmetric or asymmetric).
  • + *
  • HTTP authentication.
  • + *
  • HTTP API key.
  • + *
  • OAuth2’s common flows (Implicit, Resource Owner Protected Credentials, Client Credentials and Authorization Code) as defined in RFC6749.
  • + *
  • OpenID Connect Discovery.
  • + *
  • SASL (Simple Authentication and Security Layer) as defined in RFC4422.
  • + *
+ * + * This object MAY be extended with Specification Extensions. + * + * @version 3.0.0 + * @see Security Scheme Object + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@JsonTypeInfo( + use = JsonTypeInfo.Id.NAME, + include = JsonTypeInfo.As.EXISTING_PROPERTY, + property = "type", + visible = true +) +@JsonSubTypes({ + @JsonSubTypes.Type(value = SecurityScheme.class, name = "userPassword"), + @JsonSubTypes.Type(value = ApiKeySecurityScheme.class, name = "apiKey"), + @JsonSubTypes.Type(value = SecurityScheme.class, name = "X509"), + @JsonSubTypes.Type(value = SecurityScheme.class, name = "symmetricEncryption"), + @JsonSubTypes.Type(value = SecurityScheme.class, name = "asymmetricEncryption"), + @JsonSubTypes.Type(value = HttpApiKeySecurityScheme.class, name = "httpApiKey"), + @JsonSubTypes.Type(value = HttpSecurityScheme.class, name = "http"), + @JsonSubTypes.Type(value = OAuth2SecurityScheme.class, name = "oauth2"), + @JsonSubTypes.Type(value = OpenIdConnectSecurityScheme.class, name = "openIdConnect"), + @JsonSubTypes.Type(value = SecurityScheme.class, name = "plain"), + @JsonSubTypes.Type(value = SecurityScheme.class, name = "scramSha256"), + @JsonSubTypes.Type(value = SecurityScheme.class, name = "scramSha512"), + @JsonSubTypes.Type(value = SecurityScheme.class, name = "gssapi"), +}) +@EqualsAndHashCode(callSuper = true) +public class SecurityScheme extends ExtendableObject { + + /** + * REQUIRED. + *

+ * The type of the security scheme. Valid values are: + *

    + *
  • userPassword
  • + *
  • apiKey
  • + *
  • X509
  • + *
  • symmetricEncryption
  • + *
  • asymmetricEncryption
  • + *
  • httpApiKey
  • + *
  • http
  • + *
  • oauth2
  • + *
  • openIdConnect
  • + *
+ */ + @NotNull + @Builder.Default + private Type type = Type.USER_PASSWORD; + + /** + * A short description for security scheme. CommonMark syntax MAY be used for rich text representation. + */ + @Nullable + private String description; + + public enum Type { + + @JsonProperty("userPassword") + USER_PASSWORD, + @JsonProperty("apiKey") + API_KEY, + @JsonProperty("X509") + X509, + @JsonProperty("symmetricEncryption") + SYMMETRIC_ENCRYPTION, + @JsonProperty("asymmetricEncryption") + ASYMMETRIC_ENCRYPTION, + @JsonProperty("httpApiKey") + HTTP_API_KEY, + @JsonProperty("http") + HTTP, + @JsonProperty("oauth2") + OAUTH2, + @JsonProperty("openIdConnect") + OPENID_CONNECT, + @JsonProperty("plain") + PLAIN, + @JsonProperty("scramSha256") + SCRAM_SHA256, + @JsonProperty("scramSha512") + SCRAM_SHA512, + @JsonProperty("gssapi") + GSSAPI + + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/http/HttpApiKeySecurityScheme.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/http/HttpApiKeySecurityScheme.java new file mode 100644 index 00000000..7ef9ecd8 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/http/HttpApiKeySecurityScheme.java @@ -0,0 +1,56 @@ +package com.asyncapi.v3.security_scheme.http; + +import com.asyncapi.v3.security_scheme.SecurityScheme; +import com.fasterxml.jackson.annotation.JsonProperty; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * @version 3.0.0 + * @see SecurityScheme + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class HttpApiKeySecurityScheme extends SecurityScheme { + + /** + * REQUIRED. + *

+ * The name of the header, query or cookie parameter to be used. + */ + @NotNull + private String name = ""; + + /** + * REQUIRED. + *

+ * The location of the API key. + */ + @Nullable + private ApiKeyLocation in; + + @Builder(builderMethodName = "httpApiKeyBuilder") + public HttpApiKeySecurityScheme(@Nullable String description, + @NotNull String name, + @Nullable ApiKeyLocation in) { + super(Type.HTTP_API_KEY, description); + this.name = name; + this.in = in; + } + + public enum ApiKeyLocation { + + @JsonProperty("query") + QUERY, + @JsonProperty("header") + HEADER, + @JsonProperty("cookie") + COOKIE + + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/http/HttpSecurityScheme.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/http/HttpSecurityScheme.java new file mode 100644 index 00000000..a85fc92f --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/http/HttpSecurityScheme.java @@ -0,0 +1,43 @@ +package com.asyncapi.v3.security_scheme.http; + +import com.asyncapi.v3.security_scheme.SecurityScheme; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +/** + * @version 3.0.0 + * @see SecurityScheme + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class HttpSecurityScheme extends SecurityScheme { + + /** + * REQUIRED. + *

+ * The name of the HTTP Authorization scheme to be used in the Authorization header as defined in RFC7235. + */ + @NotNull + private String scheme = ""; + + /** + * A hint to the client to identify how the bearer token is formatted. Bearer tokens are usually generated + * by an authorization server, so this information is primarily for documentation purposes. + */ + @Nullable + private String bearerFormat; + + @Builder(builderMethodName = "httpBuilder") + public HttpSecurityScheme(@Nullable String description, + @NotNull String scheme, + @Nullable String bearerFormat) { + super(Type.HTTP, description); + this.scheme = scheme; + this.bearerFormat = bearerFormat; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/OAuth2SecurityScheme.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/OAuth2SecurityScheme.java new file mode 100644 index 00000000..e1000944 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/OAuth2SecurityScheme.java @@ -0,0 +1,44 @@ +package com.asyncapi.v3.security_scheme.oauth2; + +import com.asyncapi.v3.security_scheme.SecurityScheme; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.List; + +/** + * @version 3.0.0 + * @see SecurityScheme + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class OAuth2SecurityScheme extends SecurityScheme { + + /** + * REQUIRED. + *

+ * An object containing configuration information for the flow types supported. + */ + @NotNull + private OAuthFlows flows = new OAuthFlows(); + + /** + * List of the needed scope names. + */ + @Nullable + private List scopes; + + @Builder(builderMethodName = "oauth2Builder") + public OAuth2SecurityScheme(@Nullable String description, + @NotNull OAuthFlows flows, + @Nullable List scopes) { + super(Type.OAUTH2, description); + this.flows = flows; + this.scopes = scopes; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/OAuthFlows.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/OAuthFlows.java new file mode 100644 index 00000000..9f33cdb0 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/OAuthFlows.java @@ -0,0 +1,51 @@ +package com.asyncapi.v3.security_scheme.oauth2; + +import com.asyncapi.v3.ExtendableObject; +import com.asyncapi.v3.security_scheme.oauth2.flow.AuthorizationCodeOAuthFlow; +import com.asyncapi.v3.security_scheme.oauth2.flow.ClientCredentialsOAuthFlow; +import com.asyncapi.v3.security_scheme.oauth2.flow.ImplicitOAuthFlow; +import com.asyncapi.v3.security_scheme.oauth2.flow.PasswordOAuthFlow; +import lombok.*; +import org.jetbrains.annotations.Nullable; + +/** + * Allows configuration of the supported OAuth Flows. + *

+ * This object MAY be extended with Specification Extensions. + * + * @version 3.0.0 + * @see OAuth Flows Object + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class OAuthFlows extends ExtendableObject { + + /** + * Configuration for the OAuth Implicit flow + */ + @Nullable + private ImplicitOAuthFlow implicit; + + /** + * Configuration for the OAuth Resource Owner Protected Credentials flow + */ + @Nullable + private PasswordOAuthFlow password; + + /** + * Configuration for the OAuth Client Credentials flow. + */ + @Nullable + private ClientCredentialsOAuthFlow clientCredentials; + + /** + * Configuration for the OAuth Authorization Code flow + */ + @Nullable + private AuthorizationCodeOAuthFlow authorizationCode; + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/AuthorizationCodeOAuthFlow.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/AuthorizationCodeOAuthFlow.java new file mode 100644 index 00000000..0d2351d6 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/AuthorizationCodeOAuthFlow.java @@ -0,0 +1,46 @@ +package com.asyncapi.v3.security_scheme.oauth2.flow; + +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.Map; + +/** + * This object MAY be extended with Specification Extensions. + * + * @version 3.0.0 + * @see OAuth Flow Object + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class AuthorizationCodeOAuthFlow extends OAuthFlow { + + /** + * REQUIRED. + *

+ * The authorization URL to be used for this flow. This MUST be in the form of an absolute URL. + */ + @NotNull + private String authorizationUrl = ""; + + /** + * The token URL to be used for this flow. This MUST be in the form of an absolute URL. + */ + @Nullable + private String tokenUrl = ""; + + @Builder(builderMethodName = "authorizationCodeBuilder") + public AuthorizationCodeOAuthFlow(@Nullable String refreshUrl, + @NotNull Map scopes, + @NotNull String authorizationUrl, + @Nullable String tokenUrl) { + super(refreshUrl, scopes); + this.authorizationUrl = authorizationUrl; + this.tokenUrl = tokenUrl; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/ClientCredentialsOAuthFlow.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/ClientCredentialsOAuthFlow.java new file mode 100644 index 00000000..b927fdda --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/ClientCredentialsOAuthFlow.java @@ -0,0 +1,36 @@ +package com.asyncapi.v3.security_scheme.oauth2.flow; + +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.Map; + +/** + * @version 3.0.0 + * @see OAuth Flow Object + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class ClientCredentialsOAuthFlow extends OAuthFlow { + + /** + * REQUIRED. + *

+ * The token URL to be used for this flow. This MUST be in the form of a URL. + */ + @NotNull + private String tokenUrl = ""; + + @Builder(builderMethodName = "clientCredentialsBuilder") + public ClientCredentialsOAuthFlow(@Nullable String refreshUrl, + @NotNull Map scopes, + @NotNull String tokenUrl) { + super(refreshUrl, scopes); + this.tokenUrl = tokenUrl; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/ImplicitOAuthFlow.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/ImplicitOAuthFlow.java new file mode 100644 index 00000000..3c7fada4 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/ImplicitOAuthFlow.java @@ -0,0 +1,36 @@ +package com.asyncapi.v3.security_scheme.oauth2.flow; + +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.Map; + +/** + * @version 3.0.0 + * @see OAuth Flow Object + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class ImplicitOAuthFlow extends OAuthFlow { + + /** + * REQUIRED. + *

+ * The authorization URL to be used for this flow. This MUST be in the form of a URL + */ + @NotNull + private String authorizationUrl = ""; + + @Builder(builderMethodName = "implicitBuilder") + public ImplicitOAuthFlow(@Nullable String refreshUrl, + @NotNull Map scopes, + @NotNull String authorizationUrl) { + super(refreshUrl, scopes); + this.authorizationUrl = authorizationUrl; + } + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/OAuthFlow.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/OAuthFlow.java new file mode 100644 index 00000000..06715a94 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/OAuthFlow.java @@ -0,0 +1,43 @@ +package com.asyncapi.v3.security_scheme.oauth2.flow; + +import com.asyncapi.v3.ExtendableObject; +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.HashMap; +import java.util.Map; + +/** + * Configuration details for a supported OAuth Flow + *

+ * This object MAY be extended with Specification Extensions. + * + * @version 3.0.0 + * @see OAuth Flow Object + * @author Pavel Bodiachevskii + */ +@Data +@Builder +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class OAuthFlow extends ExtendableObject { + + /** + * The URL to be used for obtaining refresh tokens. This MUST be in the form of an absolute URL. + */ + @Nullable + @Builder.Default + private String refreshUrl = ""; + + /** + * REQUIRED. + *

+ * The available scopes for the OAuth2 security scheme. A map between the scope name and a short description for it. + */ + @NotNull + @Builder.Default + private Map scopes = new HashMap<>(); + +} diff --git a/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/PasswordOAuthFlow.java b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/PasswordOAuthFlow.java new file mode 100644 index 00000000..49ebd511 --- /dev/null +++ b/asyncapi-core/src/main/java/com/asyncapi/v3/security_scheme/oauth2/flow/PasswordOAuthFlow.java @@ -0,0 +1,36 @@ +package com.asyncapi.v3.security_scheme.oauth2.flow; + +import lombok.*; +import org.jetbrains.annotations.NotNull; +import org.jetbrains.annotations.Nullable; + +import java.util.Map; + +/** + * @version 3.0.0 + * @see OAuth Flow Object + * @author Pavel Bodiachevskii + */ +@Data +@NoArgsConstructor +@AllArgsConstructor +@EqualsAndHashCode(callSuper = true) +public class PasswordOAuthFlow extends OAuthFlow { + + /** + * REQUIRED. + *

+ * The token URL to be used for this flow. This MUST be in the form of a URL. + */ + @NotNull + private String tokenUrl = ""; + + @Builder(builderMethodName = "passwordBuilder") + public PasswordOAuthFlow(@Nullable String refreshUrl, + @NotNull Map scopes, + @NotNull String tokenUrl) { + super(refreshUrl, scopes); + this.tokenUrl = tokenUrl; + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/AsyncAPITest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/AsyncAPITest.kt index dcc8e411..ea9fd0c1 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/AsyncAPITest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/AsyncAPITest.kt @@ -13,11 +13,11 @@ class AsyncAPITest: SerDeTest() { override fun objectClass() = AsyncAPI::class.java - override fun baseObjectJson() = "/json/2.0.0/model/asyncapi.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/asyncapi.json" - override fun extendedObjectJson() = "/json/2.0.0/model/asyncapi - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/asyncapi - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/asyncapi - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/asyncapi - wrongly extended.json" override fun build(): AsyncAPI { return AsyncAPI( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/ExternalDocumentationTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/ExternalDocumentationTest.kt index f1951086..c6b51a18 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/ExternalDocumentationTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/ExternalDocumentationTest.kt @@ -9,11 +9,11 @@ class ExternalDocumentationTest: SerDeTest() { override fun objectClass() = ExternalDocumentation::class.java - override fun baseObjectJson() = "/json/2.0.0/model/externalDocumentation.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/externalDocumentation.json" - override fun extendedObjectJson() = "/json/2.0.0/model/externalDocumentation - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/externalDocumentation - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/externalDocumentation - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/externalDocumentation - wrongly extended.json" override fun build(): ExternalDocumentation { return ExternalDocumentation( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/ReferenceTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/ReferenceTest.kt index 5620f4c6..e5075e24 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/ReferenceTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/ReferenceTest.kt @@ -14,7 +14,7 @@ class ReferenceTest { @Test @DisplayName("Compare hand crafted model with parsed json") fun compareModelWithParsedJson() { - val model = ClasspathUtils.readAsString("/json/2.0.0/model/reference.json") + val model = ClasspathUtils.readAsString("/json/v2/2.0.0/model/reference.json") Assertions.assertEquals( objectMapper.readValue(model, Reference::class.java), diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/TagTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/TagTest.kt index c700d28f..9e44b483 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/TagTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/TagTest.kt @@ -9,11 +9,11 @@ class TagTest: SerDeTest() { override fun objectClass() = Tag::class.java - override fun baseObjectJson() = "/json/2.0.0/model/tag.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/tag.json" - override fun extendedObjectJson() = "/json/2.0.0/model/tag - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/tag - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/tag - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/tag - wrongly extended.json" override fun build(): Tag { return Tag( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/ChannelItemTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/ChannelItemTest.kt index 8f6b7322..64d42f9a 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/ChannelItemTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/ChannelItemTest.kt @@ -29,11 +29,11 @@ class ChannelItemTest: SerDeTest() { override fun objectClass() = ChannelItem::class.java - override fun baseObjectJson() = "/json/2.0.0/model/channel/channelItem.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/channel/channelItem.json" - override fun extendedObjectJson() = "/json/2.0.0/model/channel/channelItem - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/channel/channelItem - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/channel/channelItem - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/channel/channelItem - wrongly extended.json" override fun build(): ChannelItem { val subscribe = OperationWithReferenceToMessageTest().build() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/ParameterTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/ParameterTest.kt index c6e0ebb6..d0fb8dfa 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/ParameterTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/ParameterTest.kt @@ -10,11 +10,11 @@ class ParameterTest: SerDeTest() { override fun objectClass() = Parameter::class.java - override fun baseObjectJson() = "/json/2.0.0/model/channel/parameter.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/channel/parameter.json" - override fun extendedObjectJson() = "/json/2.0.0/model/channel/parameter - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/channel/parameter - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/channel/parameter - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/channel/parameter - wrongly extended.json" override fun build(): Parameter { return Parameter.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/CorrelationIdTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/CorrelationIdTest.kt index 472764f2..ec179bdc 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/CorrelationIdTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/CorrelationIdTest.kt @@ -9,11 +9,11 @@ class CorrelationIdTest: SerDeTest() { override fun objectClass() = CorrelationId::class.java - override fun baseObjectJson() = "/json/2.0.0/model/channel/message/correlationId.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/channel/message/correlationId.json" - override fun extendedObjectJson() = "/json/2.0.0/model/channel/message/correlationId - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/channel/message/correlationId - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/channel/message/correlationId - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/channel/message/correlationId - wrongly extended.json" override fun build(): CorrelationId { return CorrelationId.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/MessageTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/MessageTest.kt index cf119d6d..bf0043dd 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/MessageTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/MessageTest.kt @@ -33,11 +33,11 @@ class MessageTest: SerDeTest() { override fun objectClass() = Message::class.java - override fun baseObjectJson() = "/json/2.0.0/model/channel/message/message.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/channel/message/message.json" - override fun extendedObjectJson() = "/json/2.0.0/model/channel/message/message - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/channel/message/message - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/channel/message/message - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/channel/message/message - wrongly extended.json" override fun build(): Message { return Message.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/MessageTraitTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/MessageTraitTest.kt index 05d5d666..359fd0e4 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/MessageTraitTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/message/MessageTraitTest.kt @@ -31,11 +31,11 @@ class MessageTraitTest: SerDeTest() { override fun objectClass() = MessageTrait::class.java - override fun baseObjectJson() = "/json/2.0.0/model/channel/message/messageTrait.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/channel/message/messageTrait.json" - override fun extendedObjectJson() = "/json/2.0.0/model/channel/message/messageTrait - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/channel/message/messageTrait - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/channel/message/messageTrait - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/channel/message/messageTrait - wrongly extended.json" override fun build(): MessageTrait { return MessageTrait.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/operation/OperationTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/operation/OperationTest.kt index 041055ed..470e1b24 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/operation/OperationTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/operation/OperationTest.kt @@ -33,11 +33,11 @@ class OperationWithReferenceToMessageTest: SerDeTest() { override fun objectClass() = Operation::class.java - override fun baseObjectJson() = "/json/2.0.0/model/channel/operation/operation with reference to message.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/channel/operation/operation with reference to message.json" - override fun extendedObjectJson() = "/json/2.0.0/model/channel/operation/operation with reference to message - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/channel/operation/operation with reference to message - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/channel/operation/operation with reference to message - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/channel/operation/operation with reference to message - wrongly extended.json" override fun build(): Operation { return Operation.builder() @@ -67,11 +67,11 @@ class OperationWithMessageTest: SerDeTest() { override fun objectClass() = Operation::class.java - override fun baseObjectJson() = "/json/2.0.0/model/channel/operation/operation with message.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/channel/operation/operation with message.json" - override fun extendedObjectJson() = "/json/2.0.0/model/channel/operation/operation with message - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/channel/operation/operation with message - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/channel/operation/operation with message - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/channel/operation/operation with message - wrongly extended.json" override fun build(): Operation { return Operation.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/operation/OperationTraitTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/operation/OperationTraitTest.kt index 01d0400f..39eee0b2 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/operation/OperationTraitTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/channel/operation/OperationTraitTest.kt @@ -30,11 +30,11 @@ class OperationTraitTest: SerDeTest() { override fun objectClass() = OperationTrait::class.java - override fun baseObjectJson() = "/json/2.0.0/model/channel/operation/operationTrait.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/channel/operation/operationTrait.json" - override fun extendedObjectJson() = "/json/2.0.0/model/channel/operation/operationTrait - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/channel/operation/operationTrait - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/channel/operation/operationTrait - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/channel/operation/operationTrait - wrongly extended.json" override fun build(): OperationTrait { return OperationTrait.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/component/ComponentsTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/component/ComponentsTest.kt index 3a3eb3c5..630ef078 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/component/ComponentsTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/component/ComponentsTest.kt @@ -26,11 +26,11 @@ class ComponentsTest: SerDeTest() { override fun objectClass() = Components::class.java - override fun baseObjectJson() = "/json/2.0.0/model/components/components.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/components/components.json" - override fun extendedObjectJson() = "/json/2.0.0/model/components/components - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/components/components - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/components/components - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/components/components - wrongly extended.json" override fun build(): Components { return Components.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/ContactTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/ContactTest.kt index 1bbe0338..8246489a 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/ContactTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/ContactTest.kt @@ -9,11 +9,11 @@ class ContactTest: SerDeTest() { override fun objectClass() = Contact::class.java - override fun baseObjectJson() = "/json/2.0.0/model/info/contact.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/info/contact.json" - override fun extendedObjectJson() = "/json/2.0.0/model/info/contact - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/info/contact - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/info/contact - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/info/contact - wrongly extended.json" override fun build(): Contact { return Contact( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/InfoTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/InfoTest.kt index 2dbb390d..54e284e1 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/InfoTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/InfoTest.kt @@ -9,11 +9,11 @@ class InfoTest: SerDeTest() { override fun objectClass() = Info::class.java - override fun baseObjectJson() = "/json/2.0.0/model/info/info.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/info/info.json" - override fun extendedObjectJson() = "/json/2.0.0/model/info/info - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/info/info - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/info/info - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/info/info - wrongly extended.json" override fun build(): Info { return Info( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/LicenseTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/LicenseTest.kt index c3267640..cbb6a3d5 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/LicenseTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/info/LicenseTest.kt @@ -9,11 +9,11 @@ class LicenseTest: SerDeTest() { override fun objectClass() = License::class.java - override fun baseObjectJson() = "/json/2.0.0/model/info/license.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/info/license.json" - override fun extendedObjectJson() = "/json/2.0.0/model/info/license - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/info/license - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/info/license - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/info/license - wrongly extended.json" override fun build(): License { return License( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/server/ServerTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/server/ServerTest.kt index 612bf7c0..a975182e 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/server/ServerTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/server/ServerTest.kt @@ -29,11 +29,11 @@ class ServerTest: SerDeTest() { override fun objectClass() = Server::class.java - override fun baseObjectJson() = "/json/2.0.0/model/server/server.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/server/server.json" - override fun extendedObjectJson() = "/json/2.0.0/model/server/server - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/server/server - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/server/server - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/server/server - wrongly extended.json" override fun build(): Server { return Server.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/server/ServerVariableTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/server/ServerVariableTest.kt index 2b3dbd5e..924a834f 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/server/ServerVariableTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_0_0/model/server/ServerVariableTest.kt @@ -10,11 +10,11 @@ class ServerVariableTest: SerDeTest() { override fun objectClass() = ServerVariable::class.java - override fun baseObjectJson() = "/json/2.0.0/model/server/serverVariable.json" + override fun baseObjectJson() = "/json/v2/2.0.0/model/server/serverVariable.json" - override fun extendedObjectJson() = "/json/2.0.0/model/server/serverVariable - extended.json" + override fun extendedObjectJson() = "/json/v2/2.0.0/model/server/serverVariable - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.0.0/model/server/serverVariable - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.0.0/model/server/serverVariable - wrongly extended.json" override fun build(): ServerVariable { return ServerVariable.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/AsyncAPITest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/AsyncAPITest.kt index 55e7e061..57300656 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/AsyncAPITest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/AsyncAPITest.kt @@ -14,11 +14,11 @@ class AsyncAPITest: SerDeTest() { override fun objectClass() = AsyncAPI::class.java - override fun baseObjectJson() = "/json/2.6.0/model/asyncapi.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/asyncapi.json" - override fun extendedObjectJson() = "/json/2.6.0/model/asyncapi - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/asyncapi - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/asyncapi - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/asyncapi - wrongly extended.json" override fun build(): AsyncAPI { return AsyncAPI( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/ExternalDocumentationTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/ExternalDocumentationTest.kt index e9a26c04..5b5bd86c 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/ExternalDocumentationTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/ExternalDocumentationTest.kt @@ -9,11 +9,11 @@ class ExternalDocumentationTest: SerDeTest() { override fun objectClass() = ExternalDocumentation::class.java - override fun baseObjectJson() = "/json/2.6.0/model/externalDocumentation.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/externalDocumentation.json" - override fun extendedObjectJson() = "/json/2.6.0/model/externalDocumentation - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/externalDocumentation - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/externalDocumentation - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/externalDocumentation - wrongly extended.json" override fun build(): ExternalDocumentation { return ExternalDocumentation( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/ReferenceTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/ReferenceTest.kt index 6d751297..aa1199db 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/ReferenceTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/ReferenceTest.kt @@ -14,7 +14,7 @@ class ReferenceTest { @Test @DisplayName("Compare hand crafted model with parsed json") fun compareModelWithParsedJson() { - val model = ClasspathUtils.readAsString("/json/2.6.0/model/reference.json") + val model = ClasspathUtils.readAsString("/json/v2/2.6.0/model/reference.json") Assertions.assertEquals( objectMapper.readValue(model, Reference::class.java), diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/TagTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/TagTest.kt index cebdea83..bd422301 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/TagTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/TagTest.kt @@ -9,11 +9,11 @@ class TagTest: SerDeTest() { override fun objectClass() = Tag::class.java - override fun baseObjectJson() = "/json/2.6.0/model/tag.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/tag.json" - override fun extendedObjectJson() = "/json/2.6.0/model/tag - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/tag - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/tag - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/tag - wrongly extended.json" override fun build(): Tag { return Tag( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/ChannelItemTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/ChannelItemTest.kt index d56dc689..887452a9 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/ChannelItemTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/ChannelItemTest.kt @@ -17,11 +17,11 @@ class ChannelItemTest: SerDeTest() { override fun objectClass() = ChannelItem::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/channelItem.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/channelItem.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/channelItem - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/channelItem - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/channelItem - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/channelItem - wrongly extended.json" override fun build(): ChannelItem { val subscribe = OperationWithOneOfMessageTest().build() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/ParameterTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/ParameterTest.kt index aa91ef16..2997d669 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/ParameterTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/ParameterTest.kt @@ -8,11 +8,11 @@ class ParameterWithReferenceToSchemaTest: SerDeTest() { override fun objectClass() = Parameter::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/parameter with reference to schema.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/parameter with reference to schema.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/parameter with reference to schema - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/parameter with reference to schema - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/parameter with reference to schema - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/parameter with reference to schema - wrongly extended.json" override fun build(): Parameter { return Parameter.builder() @@ -28,11 +28,11 @@ class ParameterWithSchemaTest: SerDeTest() { override fun objectClass() = Parameter::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/parameter with schema.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/parameter with schema.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/parameter with schema - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/parameter with schema - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/parameter with schema - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/parameter with schema - wrongly extended.json" override fun build(): Parameter { return Parameter.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/CorrelationIdTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/CorrelationIdTest.kt index 8189884d..bb3a2882 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/CorrelationIdTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/CorrelationIdTest.kt @@ -6,11 +6,11 @@ class CorrelationIdTest: SerDeTest() { override fun objectClass() = CorrelationId::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/message/correlationId.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/message/correlationId.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/message/correlationId - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/message/correlationId - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/message/correlationId - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/message/correlationId - wrongly extended.json" override fun build(): CorrelationId { return CorrelationId.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageExampleTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageExampleTest.kt index 63ececc8..c6776428 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageExampleTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageExampleTest.kt @@ -6,11 +6,11 @@ class MessageExampleTest: SerDeTest() { override fun objectClass() = MessageExample::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/message/messageExample.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/message/messageExample.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/message/messageExample - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/message/messageExample - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/message/messageExample - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/message/messageExample - wrongly extended.json" override fun build(): MessageExample { return MessageExample.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageTest.kt index eeeef6dd..61cb7557 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageTest.kt @@ -17,11 +17,11 @@ class MessageTest: SerDeTest() { override fun objectClass() = Message::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/message/message.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/message/message.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/message/message - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/message/message - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/message/message - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/message/message - wrongly extended.json" override fun build(): Message { return Message.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageTraitTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageTraitTest.kt index a3c6ce0e..2b5dce28 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageTraitTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/MessageTraitTest.kt @@ -17,11 +17,11 @@ class MessageTraitTest: SerDeTest() { override fun objectClass() = MessageTrait::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/message/messageTrait.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/message/messageTrait.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/message/messageTrait - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/message/messageTrait - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/message/messageTrait - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/message/messageTrait - wrongly extended.json" override fun build(): MessageTrait { return MessageTrait.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/OneOfMessagesTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/OneOfMessagesTest.kt index 03ee0086..40a4f6a6 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/OneOfMessagesTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/message/OneOfMessagesTest.kt @@ -14,7 +14,7 @@ class OneOfMessagesTest { @Test @DisplayName("Compare hand crafted model with parsed json") fun compareModelWithParsedJson() { - val model = ClasspathUtils.readAsString("/json/2.6.0/model/channel/message/oneOfMessages.json") + val model = ClasspathUtils.readAsString("/json/v2/2.6.0/model/channel/message/oneOfMessages.json") Assertions.assertEquals( objectMapper.readValue(model, OneOfMessages::class.java), diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/operation/OperationTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/operation/OperationTest.kt index 22e9a533..1b9ecb4f 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/operation/OperationTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/operation/OperationTest.kt @@ -17,11 +17,11 @@ class OperationWithReferenceToMessageTest: SerDeTest() { override fun objectClass() = Operation::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/operation/operation with reference to message.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/operation/operation with reference to message.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/operation/operation with reference to message - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/operation/operation with reference to message - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/operation/operation with reference to message - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/operation/operation with reference to message - wrongly extended.json" override fun build(): Operation { return Operation.builder() @@ -56,11 +56,11 @@ class OperationWithMessageTest: SerDeTest() { override fun objectClass() = Operation::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/operation/operation with message.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/operation/operation with message.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/operation/operation with message - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/operation/operation with message - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/operation/operation with message - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/operation/operation with message - wrongly extended.json" override fun build(): Operation { return Operation.builder() @@ -94,11 +94,11 @@ class OperationWithOneOfMessageTest: SerDeTest() { override fun objectClass() = Operation::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/operation/operation with oneOf message.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/operation/operation with oneOf message.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/operation/operation with oneOf message - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/operation/operation with oneOf message - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/operation/operation with oneOf message - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/operation/operation with oneOf message - wrongly extended.json" override fun build(): Operation { return Operation.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/operation/OperationTraitTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/operation/OperationTraitTest.kt index ca7f5304..5323cc73 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/operation/OperationTraitTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/channel/operation/OperationTraitTest.kt @@ -15,11 +15,11 @@ class OperationTraitTest: SerDeTest() { override fun objectClass() = OperationTrait::class.java - override fun baseObjectJson() = "/json/2.6.0/model/channel/operation/operationTrait.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/channel/operation/operationTrait.json" - override fun extendedObjectJson() = "/json/2.6.0/model/channel/operation/operationTrait - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/channel/operation/operationTrait - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/channel/operation/operationTrait - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/channel/operation/operationTrait - wrongly extended.json" override fun build(): OperationTrait { return OperationTrait.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/component/ComponentsTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/component/ComponentsTest.kt index 2bb3ec16..2135c2f3 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/component/ComponentsTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/component/ComponentsTest.kt @@ -29,11 +29,11 @@ class ComponentsTest: SerDeTest() { override fun objectClass() = Components::class.java - override fun baseObjectJson() = "/json/2.6.0/model/components/components.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/components/components.json" - override fun extendedObjectJson() = "/json/2.6.0/model/components/components - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/components/components - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/components/components - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/components/components - wrongly extended.json" override fun build(): Components { return Components.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/ContactTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/ContactTest.kt index a40bc460..f1e72822 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/ContactTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/ContactTest.kt @@ -9,11 +9,11 @@ class ContactTest: SerDeTest() { override fun objectClass() = Contact::class.java - override fun baseObjectJson() = "/json/2.6.0/model/info/contact.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/info/contact.json" - override fun extendedObjectJson() = "/json/2.6.0/model/info/contact - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/info/contact - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/info/contact - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/info/contact - wrongly extended.json" override fun build(): Contact { return Contact( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/InfoTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/InfoTest.kt index 069fc521..9175180f 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/InfoTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/InfoTest.kt @@ -9,11 +9,11 @@ class InfoTest: SerDeTest() { override fun objectClass() = Info::class.java - override fun baseObjectJson() = "/json/2.6.0/model/info/info.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/info/info.json" - override fun extendedObjectJson() = "/json/2.6.0/model/info/info - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/info/info - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/info/info - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/info/info - wrongly extended.json" override fun build(): Info { return Info( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/LicenseTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/LicenseTest.kt index 20beb268..7b84540c 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/LicenseTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/info/LicenseTest.kt @@ -9,11 +9,11 @@ class LicenseTest: SerDeTest() { override fun objectClass() = License::class.java - override fun baseObjectJson() = "/json/2.6.0/model/info/license.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/info/license.json" - override fun extendedObjectJson() = "/json/2.6.0/model/info/license - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/info/license - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/info/license - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/info/license - wrongly extended.json" override fun build(): License { return License( diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/server/ServerTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/server/ServerTest.kt index 2711875b..e742ad1f 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/server/ServerTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/server/ServerTest.kt @@ -31,11 +31,11 @@ class ServerTest: SerDeTest() { override fun objectClass() = Server::class.java - override fun baseObjectJson() = "/json/2.6.0/model/server/server.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/server/server.json" - override fun extendedObjectJson() = "/json/2.6.0/model/server/server - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/server/server - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/server/server - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/server/server - wrongly extended.json" override fun build(): Server { return Server.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/server/ServerVariableTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/server/ServerVariableTest.kt index aaf72c69..6f5b4da0 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/server/ServerVariableTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/_6_0/model/server/ServerVariableTest.kt @@ -10,11 +10,11 @@ class ServerVariableTest: SerDeTest() { override fun objectClass() = ServerVariable::class.java - override fun baseObjectJson() = "/json/2.6.0/model/server/serverVariable.json" + override fun baseObjectJson() = "/json/v2/2.6.0/model/server/serverVariable.json" - override fun extendedObjectJson() = "/json/2.6.0/model/server/serverVariable - extended.json" + override fun extendedObjectJson() = "/json/v2/2.6.0/model/server/serverVariable - extended.json" - override fun wronglyExtendedObjectJson() = "/json/2.6.0/model/server/serverVariable - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/2.6.0/model/server/serverVariable - wrongly extended.json" override fun build(): ServerVariable { return ServerVariable.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/amqp/AMQPChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/amqp/AMQPChannelBindingTest.kt index f89a520a..7ac5f187 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/amqp/AMQPChannelBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/amqp/AMQPChannelBindingTest.kt @@ -13,11 +13,11 @@ class AMQPChannelBindingTest: SerDeTest() { override fun objectClass() = AMQPChannelBinding::class.java - override fun baseObjectJson() = "/json/binding/channel/amqp/amqpChannelBinding.json" + override fun baseObjectJson() = "/json/v2/binding/channel/amqp/amqpChannelBinding.json" - override fun extendedObjectJson() = "/json/binding/channel/amqp/amqpChannelBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/channel/amqp/amqpChannelBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/channel/amqp/amqpChannelBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/channel/amqp/amqpChannelBinding - wrongly extended.json" override fun build(): AMQPChannelBinding { return AMQPChannelBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/anypointmq/AnypointMQChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/anypointmq/AnypointMQChannelBindingTest.kt index 96d93f92..57b0626c 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/anypointmq/AnypointMQChannelBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/anypointmq/AnypointMQChannelBindingTest.kt @@ -10,11 +10,11 @@ class AnypointMQChannelBindingTest: SerDeTest() { override fun objectClass() = AnypointMQChannelBinding::class.java - override fun baseObjectJson() = "/json/binding/channel/anypoint/anypointMQChannelBinding.json" + override fun baseObjectJson() = "/json/v2/binding/channel/anypoint/anypointMQChannelBinding.json" - override fun extendedObjectJson() = "/json/binding/channel/anypoint/anypointMQChannelBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/channel/anypoint/anypointMQChannelBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/channel/anypoint/anypointMQChannelBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/channel/anypoint/anypointMQChannelBinding - wrongly extended.json" override fun build(): AnypointMQChannelBinding { return AnypointMQChannelBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/googlepubsub/GooglePubSubChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/googlepubsub/GooglePubSubChannelBindingTest.kt index bde82173..3f3c180b 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/googlepubsub/GooglePubSubChannelBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/googlepubsub/GooglePubSubChannelBindingTest.kt @@ -6,11 +6,11 @@ class GooglePubSubChannelBindingTest: SerDeTest() { override fun objectClass() = GooglePubSubChannelBinding::class.java - override fun baseObjectJson() = "/json/binding/channel/googlepubsub/googlePubSubChannelBinding.json" + override fun baseObjectJson() = "/json/v2/binding/channel/googlepubsub/googlePubSubChannelBinding.json" - override fun extendedObjectJson() = "/json/binding/channel/googlepubsub/googlePubSubChannelBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/channel/googlepubsub/googlePubSubChannelBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/channel/googlepubsub/googlePubSubChannelBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/channel/googlepubsub/googlePubSubChannelBinding - wrongly extended.json" override fun build(): GooglePubSubChannelBinding { return GooglePubSubChannelBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/ibmmq/IBMMQChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/ibmmq/IBMMQChannelBindingTest.kt index 62e4a4a6..5d6a9f87 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/ibmmq/IBMMQChannelBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/ibmmq/IBMMQChannelBindingTest.kt @@ -6,11 +6,11 @@ class IBMMQChannelBindingTest: SerDeTest() { override fun objectClass() = IBMMQChannelBinding::class.java - override fun baseObjectJson() = "/json/binding/channel/ibmmq/ibmMQChannelBinding.json" + override fun baseObjectJson() = "/json/v2/binding/channel/ibmmq/ibmMQChannelBinding.json" - override fun extendedObjectJson() = "/json/binding/channel/ibmmq/ibmMQChannelBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/channel/ibmmq/ibmMQChannelBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/channel/ibmmq/ibmMQChannelBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/channel/ibmmq/ibmMQChannelBinding - wrongly extended.json" override fun build(): IBMMQChannelBinding { return IBMMQChannelBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/kafka/KafkaChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/kafka/KafkaChannelBindingTest.kt index b0ebffa0..98502a4f 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/kafka/KafkaChannelBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/kafka/KafkaChannelBindingTest.kt @@ -10,11 +10,11 @@ class KafkaChannelBindingTest: SerDeTest() { override fun objectClass() = KafkaChannelBinding::class.java - override fun baseObjectJson() = "/json/binding/channel/kafka/kafkaChannelBinding.json" + override fun baseObjectJson() = "/json/v2/binding/channel/kafka/kafkaChannelBinding.json" - override fun extendedObjectJson() = "/json/binding/channel/kafka/kafkaChannelBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/channel/kafka/kafkaChannelBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/channel/kafka/kafkaChannelBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/channel/kafka/kafkaChannelBinding - wrongly extended.json" override fun build(): KafkaChannelBinding { return KafkaChannelBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/pulsar/PulsarChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/pulsar/PulsarChannelBindingTest.kt index 9b502808..7d7f7b85 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/pulsar/PulsarChannelBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/pulsar/PulsarChannelBindingTest.kt @@ -6,11 +6,11 @@ class PulsarChannelBindingTest: SerDeTest() { override fun objectClass() = PulsarChannelBinding::class.java - override fun baseObjectJson() = "/json/binding/channel/pulsar/pulsarChannelBinding.json" + override fun baseObjectJson() = "/json/v2/binding/channel/pulsar/pulsarChannelBinding.json" - override fun extendedObjectJson() = "/json/binding/channel/pulsar/pulsarChannelBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/channel/pulsar/pulsarChannelBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/channel/pulsar/pulsarChannelBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/channel/pulsar/pulsarChannelBinding - wrongly extended.json" override fun build(): PulsarChannelBinding { return PulsarChannelBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/ws/WebSocketsChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/ws/WebSocketsChannelBindingTest.kt index 6588029c..252a01b9 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/ws/WebSocketsChannelBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/channel/ws/WebSocketsChannelBindingTest.kt @@ -12,11 +12,11 @@ class WebSocketsChannelBindingTest: SerDeTest() { override fun objectClass() = WebSocketsChannelBinding::class.java - override fun baseObjectJson() = "/json/binding/channel/ws/webSocketsChannelBinding.json" + override fun baseObjectJson() = "/json/v2/binding/channel/ws/webSocketsChannelBinding.json" - override fun extendedObjectJson() = "/json/binding/channel/ws/webSocketsChannelBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/channel/ws/webSocketsChannelBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/channel/ws/webSocketsChannelBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/channel/ws/webSocketsChannelBinding - wrongly extended.json" override fun build(): WebSocketsChannelBinding { return WebSocketsChannelBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/amqp/AMQPMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/amqp/AMQPMessageBindingTest.kt index 92562838..baa183c2 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/amqp/AMQPMessageBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/amqp/AMQPMessageBindingTest.kt @@ -6,11 +6,11 @@ class AMQPMessageBindingTest: SerDeTest() { override fun objectClass() = AMQPMessageBinding::class.java - override fun baseObjectJson() = "/json/binding/message/amqp/amqpMessageBinding.json" + override fun baseObjectJson() = "/json/v2/binding/message/amqp/amqpMessageBinding.json" - override fun extendedObjectJson() = "/json/binding/message/amqp/amqpMessageBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/message/amqp/amqpMessageBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/message/amqp/amqpMessageBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/message/amqp/amqpMessageBinding - wrongly extended.json" override fun build(): AMQPMessageBinding { return AMQPMessageBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/anypointmq/AnypointMQMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/anypointmq/AnypointMQMessageBindingTest.kt index 24f94596..83a254e9 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/anypointmq/AnypointMQMessageBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/anypointmq/AnypointMQMessageBindingTest.kt @@ -8,11 +8,11 @@ class AnypointMQMessageBindingTest: SerDeTest() { override fun objectClass() = AnypointMQMessageBinding::class.java - override fun baseObjectJson() = "/json/binding/message/anypointmq/anypointMQMessageBinding.json" + override fun baseObjectJson() = "/json/v2/binding/message/anypointmq/anypointMQMessageBinding.json" - override fun extendedObjectJson() = "/json/binding/message/anypointmq/anypointMQMessageBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/message/anypointmq/anypointMQMessageBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/message/anypointmq/anypointMQMessageBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/message/anypointmq/anypointMQMessageBinding - wrongly extended.json" override fun build(): AnypointMQMessageBinding { return AnypointMQMessageBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/googlepubsub/GooglePubSubMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/googlepubsub/GooglePubSubMessageBindingTest.kt index 99e10dcb..ca4354aa 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/googlepubsub/GooglePubSubMessageBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/googlepubsub/GooglePubSubMessageBindingTest.kt @@ -6,11 +6,11 @@ class GooglePubSubMessageBindingTest: SerDeTest() { override fun objectClass() = GooglePubSubMessageBinding::class.java - override fun baseObjectJson() = "/json/binding/message/googlepubsub/googlePubSubMessageBinding.json" + override fun baseObjectJson() = "/json/v2/binding/message/googlepubsub/googlePubSubMessageBinding.json" - override fun extendedObjectJson() = "/json/binding/message/googlepubsub/googlePubSubMessageBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/message/googlepubsub/googlePubSubMessageBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/message/googlepubsub/googlePubSubMessageBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/message/googlepubsub/googlePubSubMessageBinding - wrongly extended.json" override fun build(): GooglePubSubMessageBinding { return GooglePubSubMessageBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/http/HTTPMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/http/HTTPMessageBindingTest.kt index 3db85b16..8c616f2c 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/http/HTTPMessageBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/http/HTTPMessageBindingTest.kt @@ -8,11 +8,11 @@ class HTTPMessageBindingTest: SerDeTest() { override fun objectClass() = HTTPMessageBinding::class.java - override fun baseObjectJson() = "/json/binding/message/http/httpMessageBinding.json" + override fun baseObjectJson() = "/json/v2/binding/message/http/httpMessageBinding.json" - override fun extendedObjectJson() = "/json/binding/message/http/httpMessageBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/message/http/httpMessageBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/message/http/httpMessageBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/message/http/httpMessageBinding - wrongly extended.json" override fun build(): HTTPMessageBinding { return HTTPMessageBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/ibmmq/IBMMQMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/ibmmq/IBMMQMessageBindingTest.kt index 43661874..f190262f 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/ibmmq/IBMMQMessageBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/ibmmq/IBMMQMessageBindingTest.kt @@ -6,11 +6,11 @@ class IBMMQMessageBindingTest: SerDeTest() { override fun objectClass() = IBMMQMessageBinding::class.java - override fun baseObjectJson() = "/json/binding/message/ibmmq/ibmMQMessageBinding.json" + override fun baseObjectJson() = "/json/v2/binding/message/ibmmq/ibmMQMessageBinding.json" - override fun extendedObjectJson() = "/json/binding/message/ibmmq/ibmMQMessageBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/message/ibmmq/ibmMQMessageBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/message/ibmmq/ibmMQMessageBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/message/ibmmq/ibmMQMessageBinding - wrongly extended.json" override fun build(): IBMMQMessageBinding { return IBMMQMessageBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/kafka/KafkaMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/kafka/KafkaMessageBindingTest.kt index d54e8f3b..7180234b 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/kafka/KafkaMessageBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/kafka/KafkaMessageBindingTest.kt @@ -8,11 +8,11 @@ class KafkaMessageBindingTest: SerDeTest() { override fun objectClass() = KafkaMessageBinding::class.java - override fun baseObjectJson() = "/json/binding/message/kafka/kafkaMessageBinding.json" + override fun baseObjectJson() = "/json/v2/binding/message/kafka/kafkaMessageBinding.json" - override fun extendedObjectJson() = "/json/binding/message/kafka/kafkaMessageBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/message/kafka/kafkaMessageBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/message/kafka/kafkaMessageBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/message/kafka/kafkaMessageBinding - wrongly extended.json" override fun build(): KafkaMessageBinding { return KafkaMessageBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/mqtt/MQTTMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/mqtt/MQTTMessageBindingTest.kt index a565bb3d..43791dd2 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/mqtt/MQTTMessageBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/message/mqtt/MQTTMessageBindingTest.kt @@ -6,11 +6,11 @@ class MQTTMessageBindingTest: SerDeTest() { override fun objectClass() = MQTTMessageBinding::class.java - override fun baseObjectJson() = "/json/binding/message/mqtt/mqttMessageBinding.json" + override fun baseObjectJson() = "/json/v2/binding/message/mqtt/mqttMessageBinding.json" - override fun extendedObjectJson() = "/json/binding/message/mqtt/mqttMessageBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/message/mqtt/mqttMessageBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/message/mqtt/mqttMessageBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/message/mqtt/mqttMessageBinding - wrongly extended.json" override fun build(): MQTTMessageBinding { return MQTTMessageBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/amqp/AMQPOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/amqp/AMQPOperationBindingTest.kt index e395644f..b62375d4 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/amqp/AMQPOperationBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/amqp/AMQPOperationBindingTest.kt @@ -6,11 +6,11 @@ class AMQPOperationBindingTest: SerDeTest() { override fun objectClass() = AMQPOperationBinding::class.java - override fun baseObjectJson() = "/json/binding/operation/amqp/amqpOperationBinding.json" + override fun baseObjectJson() = "/json/v2/binding/operation/amqp/amqpOperationBinding.json" - override fun extendedObjectJson() = "/json/binding/operation/amqp/amqpOperationBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/operation/amqp/amqpOperationBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/operation/amqp/amqpOperationBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/operation/amqp/amqpOperationBinding - wrongly extended.json" override fun build(): AMQPOperationBinding { return AMQPOperationBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/http/HTTPOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/http/HTTPOperationBindingTest.kt index 0b568a12..afe6cedd 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/http/HTTPOperationBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/http/HTTPOperationBindingTest.kt @@ -9,11 +9,11 @@ class HTTPOperationBindingTest: SerDeTest() { override fun objectClass() = HTTPOperationBinding::class.java - override fun baseObjectJson() = "/json/binding/operation/http/httpOperationBinding.json" + override fun baseObjectJson() = "/json/v2/binding/operation/http/httpOperationBinding.json" - override fun extendedObjectJson() = "/json/binding/operation/http/httpOperationBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/operation/http/httpOperationBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/operation/http/httpOperationBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/operation/http/httpOperationBinding - wrongly extended.json" override fun build(): HTTPOperationBinding { return HTTPOperationBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/kafka/KafkaOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/kafka/KafkaOperationBindingTest.kt index b32ea5e0..3fc84ea6 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/kafka/KafkaOperationBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/kafka/KafkaOperationBindingTest.kt @@ -8,11 +8,11 @@ class KafkaOperationBindingTest: SerDeTest() { override fun objectClass() = KafkaOperationBinding::class.java - override fun baseObjectJson() = "/json/binding/operation/kafka/kafkaOperationBinding.json" + override fun baseObjectJson() = "/json/v2/binding/operation/kafka/kafkaOperationBinding.json" - override fun extendedObjectJson() = "/json/binding/operation/kafka/kafkaOperationBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/operation/kafka/kafkaOperationBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/operation/kafka/kafkaOperationBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/operation/kafka/kafkaOperationBinding - wrongly extended.json" override fun build(): KafkaOperationBinding { return KafkaOperationBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/mqtt/MQTTOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/mqtt/MQTTOperationBindingTest.kt index e0af0722..9bba70c1 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/mqtt/MQTTOperationBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/mqtt/MQTTOperationBindingTest.kt @@ -6,11 +6,11 @@ class MQTTOperationBindingTest: SerDeTest() { override fun objectClass() = MQTTOperationBinding::class.java - override fun baseObjectJson() = "/json/binding/operation/mqtt/mqttOperationBinding.json" + override fun baseObjectJson() = "/json/v2/binding/operation/mqtt/mqttOperationBinding.json" - override fun extendedObjectJson() = "/json/binding/operation/mqtt/mqttOperationBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/operation/mqtt/mqttOperationBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/operation/mqtt/mqttOperationBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/operation/mqtt/mqttOperationBinding - wrongly extended.json" override fun build(): MQTTOperationBinding { return MQTTOperationBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/nats/NATSOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/nats/NATSOperationBindingTest.kt index cae3cb10..9c2991a6 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/nats/NATSOperationBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/nats/NATSOperationBindingTest.kt @@ -6,11 +6,11 @@ class NATSOperationBindingTest: SerDeTest() { override fun objectClass() = NATSOperationBinding::class.java - override fun baseObjectJson() = "/json/binding/operation/nats/natsOperationBinding.json" + override fun baseObjectJson() = "/json/v2/binding/operation/nats/natsOperationBinding.json" - override fun extendedObjectJson() = "/json/binding/operation/nats/natsOperationBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/operation/nats/natsOperationBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/operation/nats/natsOperationBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/operation/nats/natsOperationBinding - wrongly extended.json" override fun build(): NATSOperationBinding { return NATSOperationBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/solace/SolaceOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/solace/SolaceOperationBindingTest.kt index f3afbf45..f62962ad 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/solace/SolaceOperationBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/operation/solace/SolaceOperationBindingTest.kt @@ -8,11 +8,11 @@ class SolaceOperationBindingTest: SerDeTest() { override fun objectClass() = SolaceOperationBinding::class.java - override fun baseObjectJson() = "/json/binding/operation/solace/solaceOperationBinding.json" + override fun baseObjectJson() = "/json/v2/binding/operation/solace/solaceOperationBinding.json" - override fun extendedObjectJson() = "/json/binding/operation/solace/solaceOperationBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/operation/solace/solaceOperationBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/operation/solace/solaceOperationBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/operation/solace/solaceOperationBinding - wrongly extended.json" override fun build(): SolaceOperationBinding { return SolaceOperationBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/ibmmq/IBMMQServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/ibmmq/IBMMQServerBindingTest.kt index 4f1aab9b..8c73a5ab 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/ibmmq/IBMMQServerBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/ibmmq/IBMMQServerBindingTest.kt @@ -10,11 +10,11 @@ class IBMMQServerBindingTest: SerDeTest() { override fun objectClass() = IBMMQServerBinding::class.java - override fun baseObjectJson() = "/json/binding/server/ibmmq/ibmmqServerBinding.json" + override fun baseObjectJson() = "/json/v2/binding/server/ibmmq/ibmmqServerBinding.json" - override fun extendedObjectJson() = "/json/binding/server/ibmmq/ibmmqServerBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/server/ibmmq/ibmmqServerBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/server/ibmmq/ibmmqServerBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/server/ibmmq/ibmmqServerBinding - wrongly extended.json" override fun build(): IBMMQServerBinding { return IBMMQServerBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/kafka/KafkaServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/kafka/KafkaServerBindingTest.kt index 56a324bd..0e9910ce 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/kafka/KafkaServerBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/kafka/KafkaServerBindingTest.kt @@ -10,11 +10,11 @@ class KafkaServerBindingTest: SerDeTest() { override fun objectClass() = KafkaServerBinding::class.java - override fun baseObjectJson() = "/json/binding/server/kafka/kafkaServerBinding.json" + override fun baseObjectJson() = "/json/v2/binding/server/kafka/kafkaServerBinding.json" - override fun extendedObjectJson() = "/json/binding/server/kafka/kafkaServerBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/server/kafka/kafkaServerBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/server/kafka/kafkaServerBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/server/kafka/kafkaServerBinding - wrongly extended.json" override fun build(): KafkaServerBinding { return KafkaServerBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/mqtt/MQTTServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/mqtt/MQTTServerBindingTest.kt index 4023b197..de06a9eb 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/mqtt/MQTTServerBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/mqtt/MQTTServerBindingTest.kt @@ -10,11 +10,11 @@ class MQTTServerBindingTest: SerDeTest() { override fun objectClass() = MQTTServerBinding::class.java - override fun baseObjectJson() = "/json/binding/server/mqtt/mqttServerBinding.json" + override fun baseObjectJson() = "/json/v2/binding/server/mqtt/mqttServerBinding.json" - override fun extendedObjectJson() = "/json/binding/server/mqtt/mqttServerBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/server/mqtt/mqttServerBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/server/mqtt/mqttServerBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/server/mqtt/mqttServerBinding - wrongly extended.json" override fun build(): MQTTServerBinding { return MQTTServerBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/mqtt5/MQTT5ServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/mqtt5/MQTT5ServerBindingTest.kt index 88145034..a80e4af4 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/mqtt5/MQTT5ServerBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/mqtt5/MQTT5ServerBindingTest.kt @@ -10,11 +10,11 @@ class MQTT5ServerBindingTest: SerDeTest() { override fun objectClass() = MQTT5ServerBinding::class.java - override fun baseObjectJson() = "/json/binding/server/mqtt5/mqtt5ServerBinding.json" + override fun baseObjectJson() = "/json/v2/binding/server/mqtt5/mqtt5ServerBinding.json" - override fun extendedObjectJson() = "/json/binding/server/mqtt5/mqtt5ServerBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/server/mqtt5/mqtt5ServerBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/server/mqtt5/mqtt5ServerBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/server/mqtt5/mqtt5ServerBinding - wrongly extended.json" override fun build(): MQTT5ServerBinding { return MQTT5ServerBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/pulsar/PulsarServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/pulsar/PulsarServerBindingTest.kt index d5ada220..869986ea 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/pulsar/PulsarServerBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/pulsar/PulsarServerBindingTest.kt @@ -10,11 +10,11 @@ class PulsarServerBindingTest: SerDeTest() { override fun objectClass() = PulsarServerBinding::class.java - override fun baseObjectJson() = "/json/binding/server/pulsar/pulsarServerBinding.json" + override fun baseObjectJson() = "/json/v2/binding/server/pulsar/pulsarServerBinding.json" - override fun extendedObjectJson() = "/json/binding/server/pulsar/pulsarServerBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/server/pulsar/pulsarServerBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/server/pulsar/pulsarServerBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/server/pulsar/pulsarServerBinding - wrongly extended.json" override fun build(): PulsarServerBinding { return PulsarServerBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/solace/SolaceServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/solace/SolaceServerBindingTest.kt index 4e4d1244..f02c7394 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/solace/SolaceServerBindingTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/binding/server/solace/SolaceServerBindingTest.kt @@ -10,11 +10,11 @@ class SolaceServerBindingTest: SerDeTest() { override fun objectClass() = SolaceServerBinding::class.java - override fun baseObjectJson() = "/json/binding/server/solace/solaceServerBinding.json" + override fun baseObjectJson() = "/json/v2/binding/server/solace/solaceServerBinding.json" - override fun extendedObjectJson() = "/json/binding/server/solace/solaceServerBinding - extended.json" + override fun extendedObjectJson() = "/json/v2/binding/server/solace/solaceServerBinding - extended.json" - override fun wronglyExtendedObjectJson() = "/json/binding/server/solace/solaceServerBinding - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/binding/server/solace/solaceServerBinding - wrongly extended.json" override fun build(): SolaceServerBinding { return SolaceServerBinding.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ApiKeySecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ApiKeySecuritySchemeTest.kt index fa6bdbeb..327f241a 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ApiKeySecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ApiKeySecuritySchemeTest.kt @@ -9,11 +9,11 @@ class ApiKeySecuritySchemeTest: SerDeTest() { override fun objectClass() = ApiKeySecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/apiKey.json" + override fun baseObjectJson() = "/json/v2/security_scheme/apiKey.json" - override fun extendedObjectJson() = "/json/security_scheme/apiKey - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/apiKey - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/apiKey - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/apiKey - wrongly extended.json" override fun build(): SecurityScheme { return ApiKeySecurityScheme.apiKeyBuilder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/AsymmetricEncryptionSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/AsymmetricEncryptionSecuritySchemeTest.kt index fd7958fb..4ed8707a 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/AsymmetricEncryptionSecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/AsymmetricEncryptionSecuritySchemeTest.kt @@ -9,11 +9,11 @@ class AsymmetricEncryptionSecuritySchemeTest: SerDeTest() { override fun objectClass() = SecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/asymmetricEncryption.json" + override fun baseObjectJson() = "/json/v2/security_scheme/asymmetricEncryption.json" - override fun extendedObjectJson() = "/json/security_scheme/asymmetricEncryption - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/asymmetricEncryption - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/asymmetricEncryption - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/asymmetricEncryption - wrongly extended.json" override fun build(): SecurityScheme { return SecurityScheme.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/GssapiSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/GssapiSecuritySchemeTest.kt index 172b11c8..5823f19b 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/GssapiSecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/GssapiSecuritySchemeTest.kt @@ -9,11 +9,11 @@ class GssapiSecuritySchemeTest: SerDeTest() { override fun objectClass() = SecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/gssapi.json" + override fun baseObjectJson() = "/json/v2/security_scheme/gssapi.json" - override fun extendedObjectJson() = "/json/security_scheme/gssapi - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/gssapi - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/gssapi - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/gssapi - wrongly extended.json" override fun build(): SecurityScheme { return SecurityScheme.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/OpenIdConnectSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/OpenIdConnectSecuritySchemeTest.kt index 97a08e96..6a9eb726 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/OpenIdConnectSecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/OpenIdConnectSecuritySchemeTest.kt @@ -9,11 +9,11 @@ class OpenIdConnectSecuritySchemeTest: SerDeTest() override fun objectClass() = OpenIdConnectSecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/openIdConnect.json" + override fun baseObjectJson() = "/json/v2/security_scheme/openIdConnect.json" - override fun extendedObjectJson() = "/json/security_scheme/openIdConnect - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/openIdConnect - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/openIdConnect - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/openIdConnect - wrongly extended.json" override fun build(): SecurityScheme { return OpenIdConnectSecurityScheme.openIdBuilder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/PlainSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/PlainSecuritySchemeTest.kt index 6cce170c..4adfd21a 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/PlainSecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/PlainSecuritySchemeTest.kt @@ -9,11 +9,11 @@ class PlainSecuritySchemeTest: SerDeTest() { override fun objectClass() = SecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/plain.json" + override fun baseObjectJson() = "/json/v2/security_scheme/plain.json" - override fun extendedObjectJson() = "/json/security_scheme/plain - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/plain - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/plain - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/plain - wrongly extended.json" override fun build(): SecurityScheme { return SecurityScheme.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ScramSha256SecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ScramSha256SecuritySchemeTest.kt index 24c1b5f7..d60c5a29 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ScramSha256SecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ScramSha256SecuritySchemeTest.kt @@ -9,11 +9,11 @@ class ScramSha256SecuritySchemeTest: SerDeTest() { override fun objectClass() = SecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/scramSha256.json" + override fun baseObjectJson() = "/json/v2/security_scheme/scramSha256.json" - override fun extendedObjectJson() = "/json/security_scheme/scramSha256 - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/scramSha256 - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/scramSha256 - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/scramSha256 - wrongly extended.json" override fun build(): SecurityScheme { return SecurityScheme.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ScramSha512SecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ScramSha512SecuritySchemeTest.kt index 6e44502f..de3ea488 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ScramSha512SecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/ScramSha512SecuritySchemeTest.kt @@ -9,11 +9,11 @@ class ScramSha512SecuritySchemeTest: SerDeTest() { override fun objectClass() = SecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/scramSha512.json" + override fun baseObjectJson() = "/json/v2/security_scheme/scramSha512.json" - override fun extendedObjectJson() = "/json/security_scheme/scramSha512 - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/scramSha512 - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/scramSha512 - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/scramSha512 - wrongly extended.json" override fun build(): SecurityScheme { return SecurityScheme.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/SymmetricEncryptionSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/SymmetricEncryptionSecuritySchemeTest.kt index 90adcbda..479a88c5 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/SymmetricEncryptionSecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/SymmetricEncryptionSecuritySchemeTest.kt @@ -9,11 +9,11 @@ class SymmetricEncryptionSecuritySchemeTest: SerDeTest() { override fun objectClass() = SecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/symmetricEncryption.json" + override fun baseObjectJson() = "/json/v2/security_scheme/symmetricEncryption.json" - override fun extendedObjectJson() = "/json/security_scheme/symmetricEncryption - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/symmetricEncryption - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/symmetricEncryption - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/symmetricEncryption - wrongly extended.json" override fun build(): SecurityScheme { return SecurityScheme.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/UserPasswordSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/UserPasswordSecuritySchemeTest.kt index a2eaea5f..59f9ecef 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/UserPasswordSecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/UserPasswordSecuritySchemeTest.kt @@ -9,11 +9,11 @@ class UserPasswordSecuritySchemeTest: SerDeTest() { override fun objectClass() = SecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/userPassword.json" + override fun baseObjectJson() = "/json/v2/security_scheme/userPassword.json" - override fun extendedObjectJson() = "/json/security_scheme/userPassword - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/userPassword - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/userPassword - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/userPassword - wrongly extended.json" override fun build(): SecurityScheme { return SecurityScheme.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/X509SecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/X509SecuritySchemeTest.kt index 4bf34b00..3a18ab74 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/X509SecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/X509SecuritySchemeTest.kt @@ -9,11 +9,11 @@ class X509SecuritySchemeTest: SerDeTest() { override fun objectClass() = SecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/X509.json" + override fun baseObjectJson() = "/json/v2/security_scheme/X509.json" - override fun extendedObjectJson() = "/json/security_scheme/X509 - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/X509 - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/X509 - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/X509 - wrongly extended.json" override fun build(): SecurityScheme { return SecurityScheme.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/http/HttpApiKeySecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/http/HttpApiKeySecuritySchemeTest.kt index acc8ccc1..9b0a782d 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/http/HttpApiKeySecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/http/HttpApiKeySecuritySchemeTest.kt @@ -6,11 +6,11 @@ class HttpApiKeySecuritySchemeTest: SerDeTest() { override fun objectClass() = HttpApiKeySecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/http/httpApiKey.json" + override fun baseObjectJson() = "/json/v2/security_scheme/http/httpApiKey.json" - override fun extendedObjectJson() = "/json/security_scheme/http/httpApiKey - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/http/httpApiKey - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/http/httpApiKey - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/http/httpApiKey - wrongly extended.json" override fun build(): HttpApiKeySecurityScheme { return HttpApiKeySecurityScheme.httpApiKeyBuilder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/http/HttpSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/http/HttpSecuritySchemeTest.kt index da721d92..672d53ab 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/http/HttpSecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/http/HttpSecuritySchemeTest.kt @@ -6,11 +6,11 @@ class HttpSecuritySchemeBasicTest: SerDeTest() { override fun objectClass() = HttpSecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/http/httpBasic.json" + override fun baseObjectJson() = "/json/v2/security_scheme/http/httpBasic.json" - override fun extendedObjectJson() = "/json/security_scheme/http/httpBasic - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/http/httpBasic - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/http/httpBasic - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/http/httpBasic - wrongly extended.json" override fun build(): HttpSecurityScheme { return HttpSecurityScheme.httpBuilder() @@ -25,11 +25,11 @@ class HttpSecuritySchemeBearerTest: SerDeTest() { override fun objectClass() = HttpSecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/http/httpBearer.json" + override fun baseObjectJson() = "/json/v2/security_scheme/http/httpBearer.json" - override fun extendedObjectJson() = "/json/security_scheme/http/httpBearer - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/http/httpBearer - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/http/httpBearer - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/http/httpBearer - wrongly extended.json" override fun build(): HttpSecurityScheme { return HttpSecurityScheme.httpBuilder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/OAuth2SecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/OAuth2SecuritySchemeTest.kt index 92a572a1..00c2d19d 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/OAuth2SecuritySchemeTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/OAuth2SecuritySchemeTest.kt @@ -10,11 +10,11 @@ class OAuth2SecuritySchemeTest: SerDeTest() { override fun objectClass() = OAuth2SecurityScheme::class.java - override fun baseObjectJson() = "/json/security_scheme/oauth2/oauth2.json" + override fun baseObjectJson() = "/json/v2/security_scheme/oauth2/oauth2.json" - override fun extendedObjectJson() = "/json/security_scheme/oauth2/oauth2 - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/oauth2/oauth2 - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/oauth2/oauth2 - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/oauth2/oauth2 - wrongly extended.json" override fun build(): SecurityScheme { return OAuth2SecurityScheme.oauth2Builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/OAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/OAuthFlowTest.kt index 3d7037fa..1841a203 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/OAuthFlowTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/OAuthFlowTest.kt @@ -10,11 +10,11 @@ class OAuthFlowTest: SerDeTest() { override fun objectClass() = OAuthFlows::class.java - override fun baseObjectJson() = "/json/security_scheme/oauth2/oauthFlows.json" + override fun baseObjectJson() = "/json/v2/security_scheme/oauth2/oauthFlows.json" - override fun extendedObjectJson() = "/json/security_scheme/oauth2/oauthFlows - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/oauth2/oauthFlows - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/oauth2/oauthFlows - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/oauth2/oauthFlows - wrongly extended.json" override fun build(): OAuthFlows { return OAuthFlows.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/AuthorizationCodeOAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/AuthorizationCodeOAuthFlowTest.kt index ba33e07f..c71ae840 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/AuthorizationCodeOAuthFlowTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/AuthorizationCodeOAuthFlowTest.kt @@ -6,11 +6,11 @@ class AuthorizationCodeOAuthFlowTest: SerDeTest() { override fun objectClass() = AuthorizationCodeOAuthFlow::class.java - override fun baseObjectJson() = "/json/security_scheme/oauth2/flow/authorizationCodeOAuthFlow.json" + override fun baseObjectJson() = "/json/v2/security_scheme/oauth2/flow/authorizationCodeOAuthFlow.json" - override fun extendedObjectJson() = "/json/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - wrongly extended.json" override fun build(): AuthorizationCodeOAuthFlow { return AuthorizationCodeOAuthFlow.authorizationCodeBuilder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/ClientCredentialsOAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/ClientCredentialsOAuthFlowTest.kt index 68664468..cca55c8a 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/ClientCredentialsOAuthFlowTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/ClientCredentialsOAuthFlowTest.kt @@ -6,11 +6,11 @@ class ClientCredentialsOAuthFlowTest: SerDeTest() { override fun objectClass() = ClientCredentialsOAuthFlow::class.java - override fun baseObjectJson() = "/json/security_scheme/oauth2/flow/clientCredentialsOAuthFlow.json" + override fun baseObjectJson() = "/json/v2/security_scheme/oauth2/flow/clientCredentialsOAuthFlow.json" - override fun extendedObjectJson() = "/json/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - wrongly extended.json" override fun build(): ClientCredentialsOAuthFlow { return ClientCredentialsOAuthFlow.clientCredentialsBuilder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/ImplicitOAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/ImplicitOAuthFlowTest.kt index a63a4b9a..452606d0 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/ImplicitOAuthFlowTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/ImplicitOAuthFlowTest.kt @@ -6,11 +6,11 @@ class ImplicitOAuthFlowTest: SerDeTest() { override fun objectClass() = ImplicitOAuthFlow::class.java - override fun baseObjectJson() = "/json/security_scheme/oauth2/flow/implicitOAuthFlow.json" + override fun baseObjectJson() = "/json/v2/security_scheme/oauth2/flow/implicitOAuthFlow.json" - override fun extendedObjectJson() = "/json/security_scheme/oauth2/flow/implicitOAuthFlow - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/oauth2/flow/implicitOAuthFlow - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/oauth2/flow/implicitOAuthFlow - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/oauth2/flow/implicitOAuthFlow - wrongly extended.json" override fun build(): ImplicitOAuthFlow { return ImplicitOAuthFlow.implicitBuilder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/OAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/OAuthFlowTest.kt index 33849f93..b2dde97b 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/OAuthFlowTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/OAuthFlowTest.kt @@ -6,11 +6,11 @@ class OAuthFlowTest: SerDeTest() { override fun objectClass() = OAuthFlow::class.java - override fun baseObjectJson() = "/json/security_scheme/oauth2/flow/oauthFlow.json" + override fun baseObjectJson() = "/json/v2/security_scheme/oauth2/flow/oauthFlow.json" - override fun extendedObjectJson() = "/json/security_scheme/oauth2/flow/oauthFlow - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/oauth2/flow/oauthFlow - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/oauth2/flow/oauthFlow - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/oauth2/flow/oauthFlow - wrongly extended.json" override fun build(): OAuthFlow { return OAuthFlow.builder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/PasswordOAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/PasswordOAuthFlowTest.kt index 6fee6747..db1013cb 100644 --- a/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/PasswordOAuthFlowTest.kt +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v2/security_scheme/oauth2/flow/PasswordOAuthFlowTest.kt @@ -6,11 +6,11 @@ class PasswordOAuthFlowTest: SerDeTest() { override fun objectClass() = PasswordOAuthFlow::class.java - override fun baseObjectJson() = "/json/security_scheme/oauth2/flow/passwordOAuthFlow.json" + override fun baseObjectJson() = "/json/v2/security_scheme/oauth2/flow/passwordOAuthFlow.json" - override fun extendedObjectJson() = "/json/security_scheme/oauth2/flow/passwordOAuthFlow - extended.json" + override fun extendedObjectJson() = "/json/v2/security_scheme/oauth2/flow/passwordOAuthFlow - extended.json" - override fun wronglyExtendedObjectJson() = "/json/security_scheme/oauth2/flow/passwordOAuthFlow - wrongly extended.json" + override fun wronglyExtendedObjectJson() = "/json/v2/security_scheme/oauth2/flow/passwordOAuthFlow - wrongly extended.json" override fun build(): PasswordOAuthFlow { return PasswordOAuthFlow.passwordBuilder() diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/ClasspathUtils.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/ClasspathUtils.kt new file mode 100644 index 00000000..aef776a1 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/ClasspathUtils.kt @@ -0,0 +1,14 @@ +package com.asyncapi.v3 + +/** + * @author Pavel Bodiachevskii + */ +object ClasspathUtils { + + fun readAsString(resourceName: String): String { + return ClasspathUtils::class.java + .getResource(resourceName) + .readText(charset = Charsets.UTF_8) + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/SerDeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/SerDeTest.kt new file mode 100644 index 00000000..45ccc185 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/SerDeTest.kt @@ -0,0 +1,85 @@ +package com.asyncapi.v3 + +import com.fasterxml.jackson.annotation.JsonInclude +import com.fasterxml.jackson.databind.JsonMappingException +import com.fasterxml.jackson.databind.ObjectMapper +import org.junit.jupiter.api.Assertions +import org.junit.jupiter.api.DisplayName +import org.junit.jupiter.api.Test + +abstract class SerDeTest { + + protected val objectMapper = ObjectMapper().setSerializationInclusion(JsonInclude.Include.NON_NULL) + + protected abstract fun objectClass(): Class + + protected abstract fun baseObjectJson(): String + + protected abstract fun extendedObjectJson(): String + + protected abstract fun wronglyExtendedObjectJson(): String + + @Test + @DisplayName("Compare hand crafted object with parsed json") + fun compareObjectWithParsedJson() { + val model = ClasspathUtils.readAsString(baseObjectJson()) + + Assertions.assertEquals( + objectMapper.readValue(model, objectClass()), + build() + ) + } + + @Test + @DisplayName("Compare hand crafted extended object with parsed json") + fun compareExtendedObjectWithParsedJson() { + val model = objectMapper.readValue(ClasspathUtils.readAsString(extendedObjectJson()), objectClass()) + + Assertions.assertEquals(0, (model as ExtendableObject).extensionFields!!["x-number"]) + Assertions.assertEquals("", (model as ExtendableObject).extensionFields!!["x-string"]) + Assertions.assertEquals( + mapOf(Pair("property", emptyMap())), + (model as ExtendableObject).extensionFields!!["x-object"] + ) + Assertions.assertEquals(model, buildExtended()) + } + + @Test + @DisplayName("Compare hand crafted extended object with json") + fun compareExtendedObjectWithJson() { + val model = ClasspathUtils.readAsString(extendedObjectJson()) + + Assertions.assertEquals( + model, + objectMapper.writerWithDefaultPrettyPrinter().writeValueAsString(buildExtended()) + ) + } + + @Test + @DisplayName("Read wrongly extended object") + fun readWronglyExtendedObject() { + val model = ClasspathUtils.readAsString(wronglyExtendedObjectJson()) + + val exception = Assertions.assertThrows(JsonMappingException::class.java) { + objectMapper.readValue(model, objectClass()) + } + Assertions.assertEquals( + "\"ext-number\" is not valid extension property (through reference chain: ${objectClass().name}[\"ext-number\"])", + exception.message + ) + } + + abstract fun build(): ExtendableObject + + fun buildExtended(): ExtendableObject { + val `object` = build() + `object`.extensionFields = mapOf( + Pair("x-number", 0), + Pair("x-string", ""), + Pair("x-object", mapOf(Pair("property", emptyMap()))), + ) + + return `object` + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/AsyncAPITest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/AsyncAPITest.kt new file mode 100644 index 00000000..080fbb0d --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/AsyncAPITest.kt @@ -0,0 +1,52 @@ +package com.asyncapi.v3._0_0.model + +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3._0_0.model.channel.ChannelTest +import com.asyncapi.v3._0_0.model.channel.ChannelTestWithReference +import com.asyncapi.v3._0_0.model.component.ComponentsTest +import com.asyncapi.v3._0_0.model.info.InfoTest +import com.asyncapi.v3._0_0.model.operation.OperationTest +import com.asyncapi.v3._0_0.model.operation.OperationTestWithReference +import com.asyncapi.v3._0_0.model.server.ServerTest +import com.asyncapi.v3._0_0.model.server.ServerTestWithReference + +/** + * @author Pavel Bodiachevskii + */ +class AsyncAPITest: SerDeTest() { + + override fun objectClass() = AsyncAPI::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/asyncapi.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/asyncapi - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/asyncapi - wrongly extended.json" + + override fun build(): AsyncAPI { + return AsyncAPI( + "3.0.0", + "https://www.asyncapi.com", + "application/json", + InfoTest().build(), + mapOf( + Pair("server 1", ServerTest().build()), + Pair("server 2", ServerTestWithReference().build()), + Pair("server 3", Reference("#/components/servers/server")) + ), + mapOf( + Pair("channel 1", ChannelTest().build()), + Pair("channel 2", ChannelTestWithReference().build()), + Pair("channel 3", Reference("#/components/channels/channel")) + ), + mapOf( + Pair("operation 1", OperationTest().build()), + Pair("operation 2", OperationTestWithReference().build()), + Pair("operation 3", Reference("#/components/operations/operation")) + ), + ComponentsTest().build() + ) + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/ExternalDocumentationTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/ExternalDocumentationTest.kt new file mode 100644 index 00000000..2df6be6f --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/ExternalDocumentationTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3._0_0.model + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class ExternalDocumentationTest: SerDeTest() { + + override fun objectClass() = ExternalDocumentation::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/externalDocumentation.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/externalDocumentation - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/externalDocumentation - wrongly extended.json" + + override fun build(): ExternalDocumentation { + return ExternalDocumentation( + "Find more info here", + "https://example.com" + ) + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/ReferenceTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/ReferenceTest.kt new file mode 100644 index 00000000..9ebf9892 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/ReferenceTest.kt @@ -0,0 +1,29 @@ +package com.asyncapi.v3._0_0.model + +import com.asyncapi.v3.ClasspathUtils +import com.asyncapi.v3.Reference +import com.fasterxml.jackson.databind.ObjectMapper +import org.junit.jupiter.api.Assertions +import org.junit.jupiter.api.DisplayName +import org.junit.jupiter.api.Test + +class ReferenceTest { + + private val objectMapper = ObjectMapper() + + @Test + @DisplayName("Compare hand crafted model with parsed json") + fun compareModelWithParsedJson() { + val model = ClasspathUtils.readAsString("/json/v3/3.0.0/model/reference.json") + + Assertions.assertEquals( + objectMapper.readValue(model, Reference::class.java), + build() + ) + } + + fun build(): Reference { + return Reference("#/components/schemas/user") + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/TagTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/TagTest.kt new file mode 100644 index 00000000..e18a3ca9 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/TagTest.kt @@ -0,0 +1,50 @@ +package com.asyncapi.v3._0_0.model + +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class TagTestWithReferenceToExternalDocs: SerDeTest() { + + override fun objectClass() = Tag::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/tag with reference to externalDocs.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/tag with reference to externalDocs - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/tag with reference to externalDocs - wrongly extended.json" + + override fun build(): Tag { + return Tag( + "user", + "User-related messages", + Reference("#/components/external-doc") + ) + } + +} + +/** + * @author Pavel Bodiachevskii + */ +class TagTest: SerDeTest() { + + override fun objectClass() = Tag::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/tag.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/tag - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/tag - wrongly extended.json" + + override fun build(): Tag { + return Tag( + "user", + "User-related messages", + ExternalDocumentationTest().build() + ) + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/ChannelTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/ChannelTest.kt new file mode 100644 index 00000000..e48f456b --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/ChannelTest.kt @@ -0,0 +1,155 @@ +package com.asyncapi.v3._0_0.model.channel + +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3._0_0.model.ExternalDocumentationTest +import com.asyncapi.v3._0_0.model.TagTest +import com.asyncapi.v3._0_0.model.TagTestWithReferenceToExternalDocs +import com.asyncapi.v3._0_0.model.channel.message.MessageTestWithMultiFormatSchema +import com.asyncapi.v3._0_0.model.channel.message.MessageTestWithReference +import com.asyncapi.v3._0_0.model.channel.message.MessageTestWithSchema +import com.asyncapi.v3.binding.channel.amqp.AMQPChannelBindingTest +import com.asyncapi.v3.binding.channel.anypointmq.AnypointMQChannelBindingTest +import com.asyncapi.v3.binding.channel.googlepubsub.GooglePubSubChannelBindingTest +import com.asyncapi.v3.binding.channel.ibmmq.IBMMQChannelBindingTest +import com.asyncapi.v3.binding.channel.kafka.KafkaChannelBindingTest +import com.asyncapi.v3.binding.channel.pulsar.PulsarChannelBindingTest +import com.asyncapi.v3.binding.channel.ws.WebSocketsChannelBindingTest + +class ChannelTest: SerDeTest() { + + override fun objectClass() = Channel::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/channel.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/channel - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/channel - wrongly extended.json" + + override fun build(): Channel { + return Channel.builder() + .address("users.{userId}") + .title("Users channel") + .summary("messages about user events.") + .description("This channel is used to exchange messages about users signing up") + .servers(listOf( + Reference("#/components/servers/1"), + Reference("#/components/servers/2"), + Reference("#/components/servers/3") + )) + .parameters(mapOf( + Pair("userId", ParameterTest().build()), + Pair("userStatus", Reference("#/components/parameters/user-status")) + )) + .messages(mapOf( + Pair("changeStatus", Reference("#/components/parameters/user-status")), + Pair("message", MessageTestWithSchema().build()), + Pair("message 2", MessageTestWithMultiFormatSchema().build()), + Pair("message with reference", MessageTestWithReference().build()), + )) + .bindings(bindings()) + .tags(listOf( + TagTest().build(), + TagTestWithReferenceToExternalDocs().build(), + Reference("#/components/tag") + )) + .externalDocs(ExternalDocumentationTest().build()) + .build() + } + + companion object { + fun bindings(): Map { + return mapOf( + Pair("amqp", AMQPChannelBindingTest().build()), + Pair("amqp1", Reference("#/components/channelBindings/amqp1")), + Pair("anypointmq", AnypointMQChannelBindingTest().build()), + Pair("googlepubsub", GooglePubSubChannelBindingTest().build()), + Pair("http", Reference("#/components/channelBindings/http")), + Pair("ibmmq", IBMMQChannelBindingTest().build()), + Pair("jms", Reference("#/components/channelBindings/jms")), + Pair("kafka", KafkaChannelBindingTest().build()), + Pair("mercure", Reference("#/components/channelBindings/mercure")), + Pair("mqtt", Reference("#/components/channelBindings/mqtt")), + Pair("mqtt5", Reference("#/components/channelBindings/mqtt5")), + Pair("nats", Reference("#/components/channelBindings/nats")), + Pair("pulsar", PulsarChannelBindingTest().build()), + Pair("redis", Reference("#/components/channelBindings/redis")), + Pair("sns", Reference("#/components/channelBindings/sns")), + Pair("solace", Reference("#/components/channelBindings/solace")), + Pair("sqs", Reference("#/components/channelBindings/sqs")), + Pair("stomp", Reference("#/components/channelBindings/stomp")), + Pair("ws", WebSocketsChannelBindingTest().build()) + ) + } + } + +} + +class ChannelTestWithReference: SerDeTest() { + + override fun objectClass() = Channel::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/channel with reference.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/channel with reference - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/channel with reference - wrongly extended.json" + + override fun build(): Channel { + return Channel.builder() + .address("users.{userId}") + .title("Users channel") + .summary("messages about user events.") + .description("This channel is used to exchange messages about users signing up") + .servers(listOf( + Reference("#/components/servers/1"), + Reference("#/components/servers/2"), + Reference("#/components/servers/3") + )) + .parameters(mapOf( + Pair("userId", ParameterTest().build()), + Pair("userStatus", Reference("#/components/parameters/user-status")) + )) + .messages(mapOf( + Pair("changeStatus", Reference("#/components/parameters/user-status")), + Pair("message", MessageTestWithSchema().build()), + Pair("message 2", MessageTestWithMultiFormatSchema().build()), + Pair("message with reference", MessageTestWithReference().build()), + )) + .bindings(bindings()) + .tags(listOf( + TagTest().build(), + TagTestWithReferenceToExternalDocs().build(), + Reference("#/components/tag") + )) + .externalDocs(Reference("#/components/external-doc")) + .build() + } + + companion object { + fun bindings(): Map { + return mapOf( + Pair("amqp", AMQPChannelBindingTest().build()), + Pair("amqp1", Reference("#/components/channelBindings/amqp1")), + Pair("anypointmq", AnypointMQChannelBindingTest().build()), + Pair("googlepubsub", GooglePubSubChannelBindingTest().build()), + Pair("http", Reference("#/components/channelBindings/http")), + Pair("ibmmq", IBMMQChannelBindingTest().build()), + Pair("jms", Reference("#/components/channelBindings/jms")), + Pair("kafka", KafkaChannelBindingTest().build()), + Pair("mercure", Reference("#/components/channelBindings/mercure")), + Pair("mqtt", Reference("#/components/channelBindings/mqtt")), + Pair("mqtt5", Reference("#/components/channelBindings/mqtt5")), + Pair("nats", Reference("#/components/channelBindings/nats")), + Pair("pulsar", PulsarChannelBindingTest().build()), + Pair("redis", Reference("#/components/channelBindings/redis")), + Pair("sns", Reference("#/components/channelBindings/sns")), + Pair("solace", Reference("#/components/channelBindings/solace")), + Pair("sqs", Reference("#/components/channelBindings/sqs")), + Pair("stomp", Reference("#/components/channelBindings/stomp")), + Pair("ws", WebSocketsChannelBindingTest().build()) + ) + } + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/ParameterTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/ParameterTest.kt new file mode 100644 index 00000000..b96bb44f --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/ParameterTest.kt @@ -0,0 +1,29 @@ +package com.asyncapi.v3._0_0.model.channel + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class ParameterTest: SerDeTest() { + + override fun objectClass() = Parameter::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/parameter.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/parameter - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/parameter - wrongly extended.json" + + override fun build(): Parameter { + return Parameter.builder() + .description("Id of the user.") + .defaultValue("0e822ca6-5311-4d4c-b409-993a1820e689") + .enumValues(listOf("0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0")) + .examples(listOf("0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0")) + .location("\$message.payload#/user/id") + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/CorrelationIdTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/CorrelationIdTest.kt new file mode 100644 index 00000000..c4903647 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/CorrelationIdTest.kt @@ -0,0 +1,22 @@ +package com.asyncapi.v3._0_0.model.channel.message + +import com.asyncapi.v3.SerDeTest + +class CorrelationIdTest: SerDeTest() { + + override fun objectClass() = CorrelationId::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/message/correlationId.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/message/correlationId - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/message/correlationId - wrongly extended.json" + + override fun build(): CorrelationId { + return CorrelationId.builder() + .description("Default Correlation ID") + .location("\$message.header#/correlationId") + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/MessageExampleTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/MessageExampleTest.kt new file mode 100644 index 00000000..3537b2c7 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/MessageExampleTest.kt @@ -0,0 +1,34 @@ +package com.asyncapi.v3._0_0.model.channel.message + +import com.asyncapi.v3.SerDeTest + +class MessageExampleTest: SerDeTest() { + + override fun objectClass() = MessageExample::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/message/messageExample.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/message/messageExample - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/message/messageExample - wrongly extended.json" + + override fun build(): MessageExample { + return MessageExample.builder() + .name("SimpleSignup") + .summary("A simple UserSignup example message") + .headers(mapOf( + Pair("correlationId", "my-correlation-id"), + Pair("applicationInstanceId", "myInstanceId") + )) + .payload(mapOf( + Pair("user", mapOf( + Pair("someUserKey", "someUserValue") + )), + Pair("signup", mapOf( + Pair("someSignupKey", "someSignupValue") + )) + )) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/MessageTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/MessageTest.kt new file mode 100644 index 00000000..f89217b3 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/MessageTest.kt @@ -0,0 +1,266 @@ +package com.asyncapi.v3._0_0.model.channel.message + +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3._0_0.model.ExternalDocumentation +import com.asyncapi.v3._0_0.model.Tag +import com.asyncapi.v3.schema.Schema +import com.asyncapi.v3.schema.MultiFormatSchema +import com.asyncapi.v3.binding.message.amqp.AMQPMessageBindingTest +import com.asyncapi.v3.binding.message.anypointmq.AnypointMQMessageBindingTest +import com.asyncapi.v3.binding.message.googlepubsub.GooglePubSubMessageBindingTest +import com.asyncapi.v3.binding.message.http.HTTPMessageBindingTest +import com.asyncapi.v3.binding.message.ibmmq.IBMMQMessageBindingTest +import com.asyncapi.v3.binding.message.kafka.KafkaMessageBindingTest +import com.asyncapi.v3.binding.message.mqtt.MQTTMessageBindingTest + +class MessageTestWithSchema: SerDeTest() { + + override fun objectClass() = Message::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/message/message.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/message/message - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/message/message - wrongly extended.json" + + override fun build(): Message { + return Message.builder() + .messageId("userSignup") + .headers(Schema.builder() + .type("object") + .properties(mapOf( + Pair( + "correlationId", + Schema.builder() + .description("Correlation ID set by application") + .type("string") + .build() + ), + Pair( + "applicationInstanceId", + Schema.builder() + .description("Unique identifier for a given instance of the publishing application") + .type("string") + .build() + ) + )) + .build() + ) + .payload(Schema.builder() + .type("object") + .properties(mapOf( + Pair( + "metric", + Schema.builder() + .description("Metric set by application") + .type("string") + .build() + ) + )) + .build() + ) + .correlationId(CorrelationId("Default Correlation ID", "\$message.header#/correlationId")) + .contentType("application/json") + .name("UserSignup") + .title("User signup") + .summary("Action to sign a user up.") + .description("A longer description") + .tags(listOf( + Tag("user", null, null), + Tag("signup", null, null), + Tag("register", null, null), + )) + .externalDocs(ExternalDocumentation("User sign up rules", "messages/sign-up-rules")) + .bindings(bindings()) + .examples(listOf(MessageExampleTest().build())) + .traits(listOf( + MessageTraitTestWithSchema().build(), + MessageTraitTestWithReference().build(), + MessageTraitTestWithMultiFormatSchema().build() + )) + .build() + } + + companion object { + fun bindings(): Map { + return mapOf( + Pair("amqp", AMQPMessageBindingTest().build()), + Pair("amqp1", Reference("#/components/messageBindings/amqp1")), + Pair("anypointmq", AnypointMQMessageBindingTest().build()), + Pair("googlepubsub", GooglePubSubMessageBindingTest().build()), + Pair("http", HTTPMessageBindingTest().build()), + Pair("ibmmq", IBMMQMessageBindingTest().build()), + Pair("jms", Reference("#/components/messageBindings/jms")), + Pair("kafka", KafkaMessageBindingTest().build()), + Pair("mercure", Reference("#/components/messageBindings/mercure")), + Pair("mqtt", MQTTMessageBindingTest().build()), + Pair("mqtt5", Reference("#/components/messageBindings/mqtt5")), + Pair("nats", Reference("#/components/messageBindings/nats")), + Pair("pulsar", Reference("#/components/messageBindings/pulsar")), + Pair("redis", Reference("#/components/messageBindings/redis")), + Pair("sns", Reference("#/components/messageBindings/sns")), + Pair("solace", Reference("#/components/messageBindings/solace")), + Pair("sqs", Reference("#/components/messageBindings/sqs")), + Pair("stomp", Reference("#/components/messageBindings/stomp")), + Pair("ws", Reference("#/components/messageBindings/ws")) + ) + } + } + +} + +class MessageTestWithReference: SerDeTest() { + + override fun objectClass() = Message::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/message/message with reference.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/message/message with reference - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/message/message with reference - wrongly extended.json" + + override fun build(): Message { + return Message.builder() + .messageId("userSignup") + .headers(Reference("#/components/messages/message-header")) + .payload(Reference("#/components/messages/message-payload")) + .correlationId(Reference("#/components/messages/message-correlation-id")) + .contentType("application/json") + .name("UserSignup") + .title("User signup") + .summary("Action to sign a user up.") + .description("A longer description") + .tags(listOf( + Tag("user", null, null), + Tag("signup", null, null), + Tag("register", null, null), + Reference("#/components/tags/tag") + )) + .externalDocs(Reference("#/components/externalDocs/external-doc")) + .bindings(mapOf( + Pair("amqp", AMQPMessageBindingTest().build()), + Pair("amqp1", Reference("#/components/messageBindings/amqp1")), + Pair("anypointmq", AnypointMQMessageBindingTest().build()), + Pair("googlepubsub", GooglePubSubMessageBindingTest().build()), + Pair("http", HTTPMessageBindingTest().build()), + Pair("ibmmq", IBMMQMessageBindingTest().build()), + Pair("jms", Reference("#/components/messageBindings/jms")), + Pair("kafka", KafkaMessageBindingTest().build()), + Pair("mercure", Reference("#/components/messageBindings/mercure")), + Pair("mqtt", MQTTMessageBindingTest().build()), + Pair("mqtt5", Reference("#/components/messageBindings/mqtt5")), + Pair("nats", Reference("#/components/messageBindings/nats")), + Pair("pulsar", Reference("#/components/messageBindings/pulsar")), + Pair("redis", Reference("#/components/messageBindings/redis")), + Pair("sns", Reference("#/components/messageBindings/sns")), + Pair("solace", Reference("#/components/messageBindings/solace")), + Pair("sqs", Reference("#/components/messageBindings/sqs")), + Pair("stomp", Reference("#/components/messageBindings/stomp")), + Pair("ws", Reference("#/components/messageBindings/ws")) + )) + .examples(listOf(MessageExampleTest().build())) + .traits(listOf( + MessageTraitTestWithSchema().build(), + MessageTraitTestWithReference().build(), + MessageTraitTestWithMultiFormatSchema().build() + )) + .build() + } + +} + +class MessageTestWithMultiFormatSchema: SerDeTest() { + + override fun objectClass() = Message::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/message/message 2.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/message/message 2 - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/message/message 2 - wrongly extended.json" + + override fun build(): Message { + return Message.builder() + .messageId("userSignup") + .headers(MultiFormatSchema.builder() + .schemaFormat("application/vnd.aai.asyncapi+json;version=3.0.0") + .schema(linkedMapOf( + Pair("type", "object"), + Pair("properties", mapOf( + Pair( + "correlationId", + mapOf( + Pair("description", "Correlation ID set by application"), + Pair("type", "string") + ) + ), + Pair( + "applicationInstanceId", + mapOf( + Pair("description", "Unique identifier for a given instance of the publishing application"), + Pair("type", "string") + ) + ) + )) + )).build() + ) + .payload(MultiFormatSchema.builder() + .schemaFormat("application/vnd.aai.asyncapi+json;version=3.0.0") + .schema(linkedMapOf( + Pair("type", "object"), + Pair("properties", mapOf( + Pair( + "metric", + mapOf( + Pair("description", "Metric set by application"), + Pair("type", "string") + ) + ) + )) + )).build() + ) + .correlationId(Reference("#/components/messages/message-correlation-id")) + .contentType("application/json") + .name("UserSignup") + .title("User signup") + .summary("Action to sign a user up.") + .description("A longer description") + .tags(listOf( + Tag("user", null, null), + Tag("signup", null, null), + Tag("register", null, null), + Reference("#/components/tags/tag") + )) + .externalDocs(Reference("#/components/externalDocs/external-doc")) + .bindings(mapOf( + Pair("amqp", AMQPMessageBindingTest().build()), + Pair("amqp1", Reference("#/components/messageBindings/amqp1")), + Pair("anypointmq", AnypointMQMessageBindingTest().build()), + Pair("googlepubsub", GooglePubSubMessageBindingTest().build()), + Pair("http", HTTPMessageBindingTest().build()), + Pair("ibmmq", IBMMQMessageBindingTest().build()), + Pair("jms", Reference("#/components/messageBindings/jms")), + Pair("kafka", KafkaMessageBindingTest().build()), + Pair("mercure", Reference("#/components/messageBindings/mercure")), + Pair("mqtt", MQTTMessageBindingTest().build()), + Pair("mqtt5", Reference("#/components/messageBindings/mqtt5")), + Pair("nats", Reference("#/components/messageBindings/nats")), + Pair("pulsar", Reference("#/components/messageBindings/pulsar")), + Pair("redis", Reference("#/components/messageBindings/redis")), + Pair("sns", Reference("#/components/messageBindings/sns")), + Pair("solace", Reference("#/components/messageBindings/solace")), + Pair("sqs", Reference("#/components/messageBindings/sqs")), + Pair("stomp", Reference("#/components/messageBindings/stomp")), + Pair("ws", Reference("#/components/messageBindings/ws")) + )) + .examples(listOf(MessageExampleTest().build())) + .traits(listOf( + MessageTraitTestWithSchema().build(), + MessageTraitTestWithReference().build(), + MessageTraitTestWithMultiFormatSchema().build() + )) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/MessageTraitTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/MessageTraitTest.kt new file mode 100644 index 00000000..afaf90a2 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/channel/message/MessageTraitTest.kt @@ -0,0 +1,216 @@ +package com.asyncapi.v3._0_0.model.channel.message + +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3._0_0.model.ExternalDocumentation +import com.asyncapi.v3._0_0.model.Tag +import com.asyncapi.v3.schema.Schema +import com.asyncapi.v3.schema.MultiFormatSchema +import com.asyncapi.v3.binding.message.amqp.AMQPMessageBindingTest +import com.asyncapi.v3.binding.message.anypointmq.AnypointMQMessageBindingTest +import com.asyncapi.v3.binding.message.googlepubsub.GooglePubSubMessageBindingTest +import com.asyncapi.v3.binding.message.http.HTTPMessageBindingTest +import com.asyncapi.v3.binding.message.ibmmq.IBMMQMessageBindingTest +import com.asyncapi.v3.binding.message.kafka.KafkaMessageBindingTest +import com.asyncapi.v3.binding.message.mqtt.MQTTMessageBindingTest + +class MessageTraitTestWithSchema: SerDeTest() { + + override fun objectClass() = MessageTrait::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/message/messageTrait.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/message/messageTrait - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/message/messageTrait - wrongly extended.json" + + override fun build(): MessageTrait { + return MessageTrait.builder() + .messageId("userSignup") + .headers(Schema.builder() + .type("object") + .properties(mapOf( + Pair( + "correlationId", + Schema.builder() + .description("Correlation ID set by application") + .type("string") + .build() + ), + Pair( + "applicationInstanceId", + Schema.builder() + .description("Unique identifier for a given instance of the publishing application") + .type("string") + .build() + ) + )) + .build() + ) + .correlationId(CorrelationId("Default Correlation ID", "\$message.header#/correlationId")) + .contentType("application/json") + .name("UserSignup") + .title("User signup") + .summary("Action to sign a user up.") + .description("A longer description") + .tags(listOf( + Tag("user", null, null), + Tag("signup", null, null), + Tag("register", null, null), + )) + .externalDocs(ExternalDocumentation("User sign up rules", "messages/sign-up-rules")) + .bindings(mapOf( + Pair("amqp", AMQPMessageBindingTest().build()), + Pair("amqp1", Reference("#/components/messageBindings/amqp1")), + Pair("anypointmq", AnypointMQMessageBindingTest().build()), + Pair("googlepubsub", GooglePubSubMessageBindingTest().build()), + Pair("http", HTTPMessageBindingTest().build()), + Pair("ibmmq", IBMMQMessageBindingTest().build()), + Pair("jms", Reference("#/components/messageBindings/jms")), + Pair("kafka", KafkaMessageBindingTest().build()), + Pair("mercure", Reference("#/components/messageBindings/mercure")), + Pair("mqtt", MQTTMessageBindingTest().build()), + Pair("mqtt5", Reference("#/components/messageBindings/mqtt5")), + Pair("nats", Reference("#/components/messageBindings/nats")), + Pair("pulsar", Reference("#/components/messageBindings/pulsar")), + Pair("redis", Reference("#/components/messageBindings/redis")), + Pair("sns", Reference("#/components/messageBindings/sns")), + Pair("solace", Reference("#/components/messageBindings/solace")), + Pair("sqs", Reference("#/components/messageBindings/sqs")), + Pair("stomp", Reference("#/components/messageBindings/stomp")), + Pair("ws", Reference("#/components/messageBindings/ws")) + )) + .examples(listOf(MessageExampleTest().build())) + .build() + } + +} + +class MessageTraitTestWithReference: SerDeTest() { + + override fun objectClass() = MessageTrait::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/message/messageTrait with reference.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/message/messageTrait with reference - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/message/messageTrait with reference - wrongly extended.json" + + override fun build(): MessageTrait { + return MessageTrait.builder() + .messageId("userSignup") + .headers(Reference("#/components/messages/message-header")) + .correlationId(Reference("#/components/messages/message-correlation-id")) + .contentType("application/json") + .name("UserSignup") + .title("User signup") + .summary("Action to sign a user up.") + .description("A longer description") + .tags(listOf( + Tag("user", null, null), + Tag("signup", null, null), + Tag("register", null, null), + Reference("#/components/tags/tag") + )) + .externalDocs(Reference("#/components/externalDocs/external-doc")) + .bindings(mapOf( + Pair("amqp", AMQPMessageBindingTest().build()), + Pair("amqp1", Reference("#/components/messageBindings/amqp1")), + Pair("anypointmq", AnypointMQMessageBindingTest().build()), + Pair("googlepubsub", GooglePubSubMessageBindingTest().build()), + Pair("http", HTTPMessageBindingTest().build()), + Pair("ibmmq", IBMMQMessageBindingTest().build()), + Pair("jms", Reference("#/components/messageBindings/jms")), + Pair("kafka", KafkaMessageBindingTest().build()), + Pair("mercure", Reference("#/components/messageBindings/mercure")), + Pair("mqtt", MQTTMessageBindingTest().build()), + Pair("mqtt5", Reference("#/components/messageBindings/mqtt5")), + Pair("nats", Reference("#/components/messageBindings/nats")), + Pair("pulsar", Reference("#/components/messageBindings/pulsar")), + Pair("redis", Reference("#/components/messageBindings/redis")), + Pair("sns", Reference("#/components/messageBindings/sns")), + Pair("solace", Reference("#/components/messageBindings/solace")), + Pair("sqs", Reference("#/components/messageBindings/sqs")), + Pair("stomp", Reference("#/components/messageBindings/stomp")), + Pair("ws", Reference("#/components/messageBindings/ws")) + )) + .examples(listOf(MessageExampleTest().build())) + .build() + } + +} + +class MessageTraitTestWithMultiFormatSchema: SerDeTest() { + + override fun objectClass() = MessageTrait::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/channel/message/messageTrait 2.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/channel/message/messageTrait 2 - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/channel/message/messageTrait 2 - wrongly extended.json" + + override fun build(): MessageTrait { + return MessageTrait.builder() + .messageId("userSignup") + .headers(MultiFormatSchema.builder() + .schemaFormat("application/vnd.aai.asyncapi+json;version=3.0.0") + .schema(linkedMapOf( + Pair("type", "object"), + Pair("properties", mapOf( + Pair( + "correlationId", + mapOf( + Pair("description", "Correlation ID set by application"), + Pair("type", "string") + ) + ), + Pair( + "applicationInstanceId", + mapOf( + Pair("description", "Unique identifier for a given instance of the publishing application"), + Pair("type", "string") + ) + ) + )) + )).build() + ) + .correlationId(Reference("#/components/messages/message-correlation-id")) + .contentType("application/json") + .name("UserSignup") + .title("User signup") + .summary("Action to sign a user up.") + .description("A longer description") + .tags(listOf( + Tag("user", null, null), + Tag("signup", null, null), + Tag("register", null, null), + Reference("#/components/tags/tag") + )) + .externalDocs(Reference("#/components/externalDocs/external-doc")) + .bindings(mapOf( + Pair("amqp", AMQPMessageBindingTest().build()), + Pair("amqp1", Reference("#/components/messageBindings/amqp1")), + Pair("anypointmq", AnypointMQMessageBindingTest().build()), + Pair("googlepubsub", GooglePubSubMessageBindingTest().build()), + Pair("http", HTTPMessageBindingTest().build()), + Pair("ibmmq", IBMMQMessageBindingTest().build()), + Pair("jms", Reference("#/components/messageBindings/jms")), + Pair("kafka", KafkaMessageBindingTest().build()), + Pair("mercure", Reference("#/components/messageBindings/mercure")), + Pair("mqtt", MQTTMessageBindingTest().build()), + Pair("mqtt5", Reference("#/components/messageBindings/mqtt5")), + Pair("nats", Reference("#/components/messageBindings/nats")), + Pair("pulsar", Reference("#/components/messageBindings/pulsar")), + Pair("redis", Reference("#/components/messageBindings/redis")), + Pair("sns", Reference("#/components/messageBindings/sns")), + Pair("solace", Reference("#/components/messageBindings/solace")), + Pair("sqs", Reference("#/components/messageBindings/sqs")), + Pair("stomp", Reference("#/components/messageBindings/stomp")), + Pair("ws", Reference("#/components/messageBindings/ws")) + )) + .examples(listOf(MessageExampleTest().build())) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/component/ComponentsTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/component/ComponentsTest.kt new file mode 100644 index 00000000..2c42c289 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/component/ComponentsTest.kt @@ -0,0 +1,164 @@ +package com.asyncapi.v3._0_0.model.component + +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3._0_0.model.ExternalDocumentationTest +import com.asyncapi.v3._0_0.model.TagTest +import com.asyncapi.v3._0_0.model.TagTestWithReferenceToExternalDocs +import com.asyncapi.v3._0_0.model.channel.ChannelTest +import com.asyncapi.v3._0_0.model.channel.ChannelTestWithReference +import com.asyncapi.v3._0_0.model.channel.ParameterTest +import com.asyncapi.v3._0_0.model.channel.message.* +import com.asyncapi.v3._0_0.model.operation.OperationTest +import com.asyncapi.v3._0_0.model.operation.OperationTestWithReference +import com.asyncapi.v3._0_0.model.operation.OperationTraitTest +import com.asyncapi.v3._0_0.model.operation.OperationTraitTestWithReference +import com.asyncapi.v3._0_0.model.operation.reply.OperationReplyAddressTest +import com.asyncapi.v3._0_0.model.operation.reply.OperationReplyTest +import com.asyncapi.v3._0_0.model.operation.reply.OperationReplyTestWithReference +import com.asyncapi.v3._0_0.model.server.ServerTest +import com.asyncapi.v3._0_0.model.server.ServerVariableTest +import com.asyncapi.v3.schema.MultiFormatSchema +import com.asyncapi.v3.schema.Schema +import com.asyncapi.v3.schema.Type +import com.asyncapi.v3.security_scheme.ApiKeySecuritySchemeTest +import com.asyncapi.v3.security_scheme.OpenIdConnectSecuritySchemeTest +import com.asyncapi.v3.security_scheme.http.HttpApiKeySecuritySchemeTest +import com.asyncapi.v3.security_scheme.http.HttpSecuritySchemeBasicTest +import com.asyncapi.v3.security_scheme.http.HttpSecuritySchemeBearerTest +import com.asyncapi.v3.security_scheme.oauth2.OAuth2SecuritySchemeTest + +/** + * @version 3.0-.0 + * @author Pavel Bodiachevskii + */ +class ComponentsTest: SerDeTest() { + + override fun objectClass() = Components::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/components/components.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/components/components - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/components/components - wrongly extended.json" + + override fun build(): Components { + /* + oauth2 // scopes + openIdConnect // scopes + */ + return Components.builder() + .schemas(mapOf( + Pair("Category", Schema.builder() + .type(Type.OBJECT) + .properties(mapOf( + Pair("id", Schema.builder().type(Type.INTEGER).format("int64").build()), + Pair("name", Schema.builder().type(Type.STRING).build()) + )) + .build() + ), + Pair( + "Tag", + MultiFormatSchema.builder() + .schemaFormat("application/json") + .schema(mapOf( + Pair("type", "object"), + Pair("properties", mapOf( + Pair("id", mapOf( + Pair("type", "integer"), + Pair("format", "int64") + )), + Pair("name", mapOf( + Pair("type", "string") + )) + )) + )) + .build() + ), + Pair("User", Reference("#/components/schemas/user")) + )) + .servers(mapOf( + Pair("mqtt-test", ServerTest().build()), + Pair("mqtt-stage", Reference("#/components/servers/mqtt-stage")) + )) + .serverVariables(mapOf( + Pair("port", ServerVariableTest().build()), + Pair("basePath", Reference("#/components/serverVariables/basePath")) + )) + .channels(mapOf( + Pair("channel 1", ChannelTest().build()), + Pair("channel 2", ChannelTestWithReference().build()), + Pair("channel 3", Reference("#/components/channels/channel")), + )) + .operations(mapOf( + Pair("operation 1", OperationTest().build()), + Pair("operation 2", OperationTestWithReference().build()), + Pair("operation 3", Reference("#/components/operations/operation")) + )) + .replies(mapOf( + Pair("reply 1", OperationReplyTest().build()), + Pair("reply 2", OperationReplyTestWithReference().build()), + Pair("reply 3", Reference("#/components/replies/reply")) + )) + .replyAddresses(mapOf( + Pair("reply addresses 1", OperationReplyAddressTest().build()), + Pair("reply addresses 2", Reference("#/components/replyAddresses/replyAddress")) + )) + .messages(mapOf( + Pair("message 1", MessageTestWithSchema().build()), + Pair("message 2", MessageTestWithMultiFormatSchema().build()), + Pair("message 3", MessageTestWithReference().build()), + Pair("message 4", Reference("#/components/messages/message")) + )) + .securitySchemes(mapOf( + Pair("apiKey", ApiKeySecuritySchemeTest().build()), + Pair("asymmetricEncryption", Reference("#/components/securitySchemes/asymmetricEncryption")), + Pair("gssapi", Reference("#/components/securitySchemes/gssapi")), + Pair("oauth2", OAuth2SecuritySchemeTest().build()), + Pair("openIdConnect", OpenIdConnectSecuritySchemeTest().build()), + Pair("httpApiKey", HttpApiKeySecuritySchemeTest().build()), + Pair("httpBasic", HttpSecuritySchemeBasicTest().build()), + Pair("httpBearer", HttpSecuritySchemeBearerTest().build()), + Pair("plain", Reference("#/components/securitySchemes/plain")), + Pair("scramSha256", Reference("#/components/securitySchemes/scramSha256")), + Pair("scramSha512", Reference("#/components/securitySchemes/scramSha512")), + Pair("symmetricEncryption", Reference("#/components/securitySchemes/symmetricEncryption")), + Pair("userPassword", Reference("#/components/securitySchemes/userPassword")), + Pair("X509", Reference("#/components/securitySchemes/X509")), + )) + .parameters(mapOf( + Pair("parameter 1", ParameterTest().build()), + Pair("parameter 2", Reference("#/components/parameters/parameter")) + )) + .correlationIds(mapOf( + Pair("correlationId 1", CorrelationIdTest().build()), + Pair("correlationId 2", Reference("#/correlationIds/parameters/correlationId")) + )) + .operationTraits(mapOf( + Pair("operationTrait 1", OperationTraitTest().build()), + Pair("operationTrait 2", OperationTraitTestWithReference().build()), + Pair("operationTrait 3", Reference("#/components/operationTraits/operationTrait")) + )) + .messageTraits(mapOf( + Pair("messageTrait 1", MessageTraitTestWithSchema().build()), + Pair("messageTrait 2", MessageTraitTestWithMultiFormatSchema().build()), + Pair("messageTrait 3", MessageTraitTestWithReference().build()), + Pair("messageTrait 4", Reference("#/components/messageTraits/messageTrait")) + )) + .serverBindings(ServerTest.bindings()) + .channelBindings(ChannelTest.bindings()) + .operationBindings(OperationTest.bindings()) + .messageBindings(MessageTestWithSchema.bindings()) + .externalDocs(mapOf( + Pair("externalDoc 1", ExternalDocumentationTest().build()), + Pair("externalDoc 2", Reference("#/components/externalDocs/externalDoc")), + )) + .tags(mapOf( + Pair("tag 1", TagTest().build()), + Pair("tag 2", TagTestWithReferenceToExternalDocs().build()), + Pair("tag 3", Reference("#/components/tags/tag")), + )) + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/info/ContactTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/info/ContactTest.kt new file mode 100644 index 00000000..d9d9b017 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/info/ContactTest.kt @@ -0,0 +1,26 @@ +package com.asyncapi.v3._0_0.model.info + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class ContactTest: SerDeTest() { + + override fun objectClass() = Contact::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/info/contact.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/info/contact - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/info/contact - wrongly extended.json" + + override fun build(): Contact { + return Contact( + "AsyncApi", + "https://www.asyncapi.com", + "java@asyncapi.com" + ) + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/info/InfoTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/info/InfoTest.kt new file mode 100644 index 00000000..9c2ccfbc --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/info/InfoTest.kt @@ -0,0 +1,59 @@ +package com.asyncapi.v3._0_0.model.info + +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3._0_0.model.ExternalDocumentationTest +import com.asyncapi.v3._0_0.model.TagTest + +/** + * @author Pavel Bodiachevskii + */ +class InfoTest: SerDeTest() { + + override fun objectClass() = Info::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/info/info.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/info/info - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/info/info - wrongly extended.json" + + override fun build(): Info { + return Info( + "AsyncApi sample", + "2.0", + "short description", + "https://www.asyncapi.com/about/", + ContactTest().build(), + LicenseTest().build(), + listOf(TagTest().build()), + ExternalDocumentationTest().build(), + ) + } + +} + +class InfoTestWithReferences: SerDeTest() { + + override fun objectClass() = Info::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/info/info with reference.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/info/info with reference - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/info/info with reference - wrongly extended.json" + + override fun build(): Info { + return Info( + "AsyncApi sample", + "2.0", + "short description", + "https://www.asyncapi.com/about/", + ContactTest().build(), + LicenseTest().build(), + listOf(Reference("#/components/schemas/tag")), + Reference("#/components/schemas/externalDoc"), + ) + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/info/LicenseTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/info/LicenseTest.kt new file mode 100644 index 00000000..a7a9537b --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/info/LicenseTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3._0_0.model.info + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class LicenseTest: SerDeTest() { + + override fun objectClass() = License::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/info/license.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/info/license - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/info/license - wrongly extended.json" + + override fun build(): License { + return License( + "Apache License 2.0", + "http://www.apache.org/licenses/" + ) + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/OperationTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/OperationTest.kt new file mode 100644 index 00000000..295ef12b --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/OperationTest.kt @@ -0,0 +1,154 @@ +package com.asyncapi.v3._0_0.model.operation + +import com.asyncapi.v3.binding.operation.amqp.AMQPOperationBindingTest +import com.asyncapi.v3.binding.operation.http.HTTPOperationBindingTest +import com.asyncapi.v3.binding.operation.kafka.KafkaOperationBindingTest +import com.asyncapi.v3.binding.operation.mqtt.MQTTOperationBindingTest +import com.asyncapi.v3.binding.operation.nats.NATSOperationBindingTest +import com.asyncapi.v3.binding.operation.solace.SolaceOperationBindingTest +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3._0_0.model.ExternalDocumentation +import com.asyncapi.v3._0_0.model.Tag +import com.asyncapi.v3._0_0.model.operation.reply.OperationReplyTest +import com.asyncapi.v3.security_scheme.ApiKeySecuritySchemeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class OperationTest: SerDeTest() { + + override fun objectClass() = Operation::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/operation/operation.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/operation/operation - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/operation/operation - wrongly extended.json" + + override fun build(): Operation { + return Operation.builder() + .action(OperationAction.SEND) + .channel(Reference("#/components/channels/channel")) + .title("Send message operation") + .summary("Send message") + .description("Send message to remote server") + .security(listOf( + ApiKeySecuritySchemeTest().build(), + Reference("#/components/security/plain") + )) + .tags(listOf( + Tag("messages", "operations with messages", ExternalDocumentation( + "Messages validation rules", "messages/validation-rules" + )), + Reference("#/components/tags/tag") + )) + .externalDocs(ExternalDocumentation("Messages validation rules", "messages/validation-rules")) + .bindings(bindings()) + .traits(listOf( + OperationTraitTest().build(), + OperationTraitTestWithReference().build(), + Reference("#/components/operations/trait") + )) + .messages(listOf( + Reference("#/components/messages/message 1"), + Reference("#/components/messages/message 2"), + Reference("#/components/messages/message 3"), + )) + .reply(OperationReplyTest().build()) + .build() + } + + companion object { + fun bindings(): Map { + return mapOf( + Pair("amqp", AMQPOperationBindingTest().build()), + Pair("amqp1", Reference("#/components/operationBindings/amqp1")), + Pair("anypointmq", Reference("#/components/operationBindings/anypointmq")), + Pair("googlepubsub", Reference("#/components/operationBindings/googlepubsub")), + Pair("http", HTTPOperationBindingTest().build()), + Pair("ibmmq", Reference("#/components/operationBindings/ibmmq")), + Pair("jms", Reference("#/components/operationBindings/jms")), + Pair("kafka", KafkaOperationBindingTest().build()), + Pair("mercure", Reference("#/components/operationBindings/mercure")), + Pair("mqtt", MQTTOperationBindingTest().build()), + Pair("mqtt5", Reference("#/components/operationBindings/mqtt5")), + Pair("nats", NATSOperationBindingTest().build()), + Pair("pulsar", Reference("#/components/operationBindings/pulsar")), + Pair("redis", Reference("#/components/operationBindings/redis")), + Pair("sns", Reference("#/components/operationBindings/sns")), + Pair("solace", SolaceOperationBindingTest().build()), + Pair("sqs", Reference("#/components/operationBindings/sqs")), + Pair("stomp", Reference("#/components/operationBindings/stomp")), + Pair("ws", Reference("#/components/operationBindings/ws")) + ) + } + } + +} + +class OperationTestWithReference: SerDeTest() { + + override fun objectClass() = Operation::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/operation/operation with reference.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/operation/operation with reference - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/operation/operation with reference - wrongly extended.json" + + override fun build(): Operation { + return Operation.builder() + .action(OperationAction.RECEIVE) + .channel(Reference("#/components/channels/channel")) + .title("Send message operation") + .summary("Send message") + .description("Send message to remote server") + .security(listOf( + ApiKeySecuritySchemeTest().build(), + Reference("#/components/security/plain") + )) + .tags(listOf( + Tag("messages", "operations with messages", ExternalDocumentation( + "Messages validation rules", "messages/validation-rules" + )), + Reference("#/components/tags/tag") + )) + .externalDocs(Reference("#/components/externalDocs/external-doc")) + .bindings(mapOf( + Pair("amqp", AMQPOperationBindingTest().build()), + Pair("amqp1", Reference("#/components/operationBindings/amqp1")), + Pair("anypointmq", Reference("#/components/operationBindings/anypointmq")), + Pair("googlepubsub", Reference("#/components/operationBindings/googlepubsub")), + Pair("http", HTTPOperationBindingTest().build()), + Pair("ibmmq", Reference("#/components/operationBindings/ibmmq")), + Pair("jms", Reference("#/components/operationBindings/jms")), + Pair("kafka", KafkaOperationBindingTest().build()), + Pair("mercure", Reference("#/components/operationBindings/mercure")), + Pair("mqtt", MQTTOperationBindingTest().build()), + Pair("mqtt5", Reference("#/components/operationBindings/mqtt5")), + Pair("nats", NATSOperationBindingTest().build()), + Pair("pulsar", Reference("#/components/operationBindings/pulsar")), + Pair("redis", Reference("#/components/operationBindings/redis")), + Pair("sns", Reference("#/components/operationBindings/sns")), + Pair("solace", SolaceOperationBindingTest().build()), + Pair("sqs", Reference("#/components/operationBindings/sqs")), + Pair("stomp", Reference("#/components/operationBindings/stomp")), + Pair("ws", Reference("#/components/operationBindings/ws")) + )) + .traits(listOf( + OperationTraitTest().build(), + OperationTraitTestWithReference().build(), + Reference("#/components/operations/trait") + )) + .messages(listOf( + Reference("#/components/messages/message 1"), + Reference("#/components/messages/message 2"), + Reference("#/components/messages/message 3"), + )) + .reply(Reference("#/components/replies/reply")) + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/OperationTraitTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/OperationTraitTest.kt new file mode 100644 index 00000000..38c081a8 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/OperationTraitTest.kt @@ -0,0 +1,134 @@ +package com.asyncapi.v3._0_0.model.operation + +import com.asyncapi.v3.binding.operation.amqp.AMQPOperationBindingTest +import com.asyncapi.v3.binding.operation.http.HTTPOperationBindingTest +import com.asyncapi.v3.binding.operation.kafka.KafkaOperationBindingTest +import com.asyncapi.v3.binding.operation.mqtt.MQTTOperationBindingTest +import com.asyncapi.v3.binding.operation.nats.NATSOperationBindingTest +import com.asyncapi.v3.binding.operation.solace.SolaceOperationBindingTest +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3._0_0.model.ExternalDocumentation +import com.asyncapi.v3._0_0.model.Tag +import com.asyncapi.v3._0_0.model.operation.reply.OperationReplyTest +import com.asyncapi.v3.security_scheme.ApiKeySecuritySchemeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class OperationTraitTest: SerDeTest() { + + override fun objectClass() = OperationTrait::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/operation/operationTrait.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/operation/operationTrait - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/operation/operationTrait - wrongly extended.json" + + override fun build(): OperationTrait { + return OperationTrait.builder() + .title("Send message operation") + .summary("Send message") + .description("Send message to remote server") + .security(listOf( + ApiKeySecuritySchemeTest().build(), + Reference("#/components/security/plain") + )) + .tags(listOf( + Tag("messages", "operations with messages", ExternalDocumentation( + "Messages validation rules", "messages/validation-rules" + )), + Reference("#/components/tags/tag") + )) + .externalDocs(ExternalDocumentation("Messages validation rules", "messages/validation-rules")) + .bindings(mapOf( + Pair("amqp", AMQPOperationBindingTest().build()), + Pair("amqp1", Reference("#/components/operationBindings/amqp1")), + Pair("anypointmq", Reference("#/components/operationBindings/anypointmq")), + Pair("googlepubsub", Reference("#/components/operationBindings/googlepubsub")), + Pair("http", HTTPOperationBindingTest().build()), + Pair("ibmmq", Reference("#/components/operationBindings/ibmmq")), + Pair("jms", Reference("#/components/operationBindings/jms")), + Pair("kafka", KafkaOperationBindingTest().build()), + Pair("mercure", Reference("#/components/operationBindings/mercure")), + Pair("mqtt", MQTTOperationBindingTest().build()), + Pair("mqtt5", Reference("#/components/operationBindings/mqtt5")), + Pair("nats", NATSOperationBindingTest().build()), + Pair("pulsar", Reference("#/components/operationBindings/pulsar")), + Pair("redis", Reference("#/components/operationBindings/redis")), + Pair("sns", Reference("#/components/operationBindings/sns")), + Pair("solace", SolaceOperationBindingTest().build()), + Pair("sqs", Reference("#/components/operationBindings/sqs")), + Pair("stomp", Reference("#/components/operationBindings/stomp")), + Pair("ws", Reference("#/components/operationBindings/ws")) + )) + .messages(listOf( + Reference("#/components/messages/message 1"), + Reference("#/components/messages/message 2"), + Reference("#/components/messages/message 3"), + )) + .reply(OperationReplyTest().build()) + .build() + } + +} + +class OperationTraitTestWithReference: SerDeTest() { + + override fun objectClass() = OperationTrait::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/operation/operationTrait with reference.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/operation/operationTrait with reference - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/operation/operationTrait with reference - wrongly extended.json" + + override fun build(): OperationTrait { + return OperationTrait.builder() + .title("Send message operation") + .summary("Send message") + .description("Send message to remote server") + .security(listOf( + ApiKeySecuritySchemeTest().build(), + Reference("#/components/security/plain") + )) + .tags(listOf( + Tag("messages", "operations with messages", ExternalDocumentation( + "Messages validation rules", "messages/validation-rules" + )), + Reference("#/components/tags/tag") + )) + .externalDocs(Reference("#/components/externalDocs/external-doc")) + .bindings(mapOf( + Pair("amqp", AMQPOperationBindingTest().build()), + Pair("amqp1", Reference("#/components/operationBindings/amqp1")), + Pair("anypointmq", Reference("#/components/operationBindings/anypointmq")), + Pair("googlepubsub", Reference("#/components/operationBindings/googlepubsub")), + Pair("http", HTTPOperationBindingTest().build()), + Pair("ibmmq", Reference("#/components/operationBindings/ibmmq")), + Pair("jms", Reference("#/components/operationBindings/jms")), + Pair("kafka", KafkaOperationBindingTest().build()), + Pair("mercure", Reference("#/components/operationBindings/mercure")), + Pair("mqtt", MQTTOperationBindingTest().build()), + Pair("mqtt5", Reference("#/components/operationBindings/mqtt5")), + Pair("nats", NATSOperationBindingTest().build()), + Pair("pulsar", Reference("#/components/operationBindings/pulsar")), + Pair("redis", Reference("#/components/operationBindings/redis")), + Pair("sns", Reference("#/components/operationBindings/sns")), + Pair("solace", SolaceOperationBindingTest().build()), + Pair("sqs", Reference("#/components/operationBindings/sqs")), + Pair("stomp", Reference("#/components/operationBindings/stomp")), + Pair("ws", Reference("#/components/operationBindings/ws")) + )) + .messages(listOf( + Reference("#/components/messages/message 1"), + Reference("#/components/messages/message 2"), + Reference("#/components/messages/message 3"), + )) + .reply(Reference("#/components/replies/reply")) + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/reply/OperationReplyAddressTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/reply/OperationReplyAddressTest.kt new file mode 100644 index 00000000..d4060116 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/reply/OperationReplyAddressTest.kt @@ -0,0 +1,26 @@ +package com.asyncapi.v3._0_0.model.operation.reply + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class OperationReplyAddressTest: SerDeTest() { + + override fun objectClass() = OperationReplyAddress::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/operation/reply/operationReplyAddress.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/operation/reply/operationReplyAddress - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/operation/reply/operationReplyAddress - wrongly extended.json" + + override fun build(): OperationReplyAddress { + return OperationReplyAddress.builder() + .description("Consumer inbox") + .location("\$message.header#/replyTo") + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/reply/OperationReplyTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/reply/OperationReplyTest.kt new file mode 100644 index 00000000..74af36c6 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/operation/reply/OperationReplyTest.kt @@ -0,0 +1,56 @@ +package com.asyncapi.v3._0_0.model.operation.reply + +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class OperationReplyTest: SerDeTest() { + + override fun objectClass() = OperationReply::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/operation/reply/operationReply.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/operation/reply/operationReply - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/operation/reply/operationReply - wrongly extended.json" + + override fun build(): OperationReply { + return OperationReply.builder() + .address(OperationReplyAddressTest().build()) + .channel(Reference("#/components/channels/channel")) + .messages(listOf( + Reference("#/components/messages/message 1"), + Reference("#/components/messages/message 2"), + Reference("#/components/messages/message 3"), + )) + .build() + } + +} + +class OperationReplyTestWithReference: SerDeTest() { + + override fun objectClass() = OperationReply::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/operation/reply/operationReply with reference.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/operation/reply/operationReply with reference - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/operation/reply/operationReply with reference - wrongly extended.json" + + override fun build(): OperationReply { + return OperationReply.builder() + .address(Reference("#/components/addresses/address")) + .channel(Reference("#/components/channels/channel")) + .messages(listOf( + Reference("#/components/messages/message 1"), + Reference("#/components/messages/message 2"), + Reference("#/components/messages/message 3"), + )) + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/server/ServerTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/server/ServerTest.kt new file mode 100644 index 00000000..cee89d7a --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/server/ServerTest.kt @@ -0,0 +1,255 @@ +package com.asyncapi.v3._0_0.model.server + +import com.asyncapi.v3.Reference +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3._0_0.model.ExternalDocumentationTest +import com.asyncapi.v3._0_0.model.Tag +import com.asyncapi.v3.binding.server.amqp1.AMQP1ServerBinding +import com.asyncapi.v3.binding.server.anypointmq.AnypointMQServerBinding +import com.asyncapi.v3.binding.server.googlepubsub.GooglePubSubServerBinding +import com.asyncapi.v3.binding.server.http.HTTPServerBinding +import com.asyncapi.v3.binding.server.ibmmq.IBMMQServerBinding +import com.asyncapi.v3.binding.server.jms.JMSServerBinding +import com.asyncapi.v3.binding.server.kafka.KafkaServerBinding +import com.asyncapi.v3.binding.server.mercure.MercureServerBinding +import com.asyncapi.v3.binding.server.mqtt.MQTTServerBinding +import com.asyncapi.v3.binding.server.mqtt.MQTTServerLastWillConfiguration +import com.asyncapi.v3.binding.server.mqtt5.MQTT5ServerBinding +import com.asyncapi.v3.binding.server.nats.NATSServerBinding +import com.asyncapi.v3.binding.server.pulsar.PulsarServerBinding +import com.asyncapi.v3.binding.server.redis.RedisServerBinding +import com.asyncapi.v3.binding.server.sns.SNSServerBinding +import com.asyncapi.v3.binding.server.solace.SolaceServerBinding +import com.asyncapi.v3.binding.server.sqs.SQSServerBinding +import com.asyncapi.v3.binding.server.stomp.STOMPServerBinding +import com.asyncapi.v3.binding.server.ws.WebSocketsServerBinding +import com.asyncapi.v3.security_scheme.ApiKeySecuritySchemeTest +import com.asyncapi.v3.security_scheme.http.HttpSecuritySchemeBearerTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class ServerTest: SerDeTest() { + + override fun objectClass() = Server::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/server/server.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/server/server - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/server/server - wrongly extended.json" + + override fun build(): Server { + return Server.builder() + .host("{username}.gigantic-server.com:{port}/{basePath}") + .protocol("secure-mqtt") + .protocolVersion("5") + .pathname("/messages") + .description("The production API server") + .title("secure-mqtt API server") + .summary("API server") + .variables(mapOf( + Pair("username", ServerVariable.builder() + .defaultValue("demo") + .description("This value is assigned by the service provider, in this example `gigantic-server.com`") + .build()), + Pair("port", ServerVariable.builder() + .enumValues(listOf("8883", "8884")) + .defaultValue("8883") + .build()), + Pair("basePath", Reference("#/components/serverVariables/basePath")) + )) + .security(listOf( + ApiKeySecuritySchemeTest().build(), + HttpSecuritySchemeBearerTest().build() + )) + .tags(listOf( + Tag("env:staging", "This environment is a replica of the production environment", null) + )) + .externalDocs(ExternalDocumentationTest().build()) + .bindings(bindings()) + .build() + } + + companion object { + @JvmStatic + fun bindings(): Map { + return mapOf( + Pair("amqp", Reference("#/components/serverBindings/amqp")), + Pair("amqp1", AMQP1ServerBinding()), + Pair("anypointmq", AnypointMQServerBinding()), + Pair("googlepubsub", GooglePubSubServerBinding()), + Pair("http", HTTPServerBinding()), + Pair( + "ibmmq", + IBMMQServerBinding.builder() + .groupId("PRODCLSTR1") + .cipherSpec("ANY_TLS12_OR_HIGHER") + .build() + ), + Pair("jms", JMSServerBinding()), + Pair( + "kafka", + KafkaServerBinding.builder() + .schemaRegistryUrl("https://my-schema-registry.com") + .schemaRegistryVendor("confluent") + .build() + ), + Pair("mercure", MercureServerBinding()), + Pair( + "mqtt", + MQTTServerBinding.builder() + .clientId("guest") + .cleanSession(true) + .lastWill(MQTTServerLastWillConfiguration( + "/last-wills", + 2, + "Guest gone offline.", + false + )) + .keepAlive(60) + .build() + ), + Pair( + "mqtt5", + MQTT5ServerBinding.builder() + .sessionExpiryInterval(60) + .build() + ), + Pair("nats", NATSServerBinding()), + Pair( + "pulsar", + PulsarServerBinding.builder() + .tenant("contoso") + .build() + ), + Pair("redis", RedisServerBinding()), + Pair("sns", SNSServerBinding()), + Pair( + "solace", + SolaceServerBinding.builder() + .msgVpn("solace.private.net") + .build() + ), + Pair("sqs", SQSServerBinding()), + Pair("stomp", STOMPServerBinding()), + Pair("ws", WebSocketsServerBinding()), + ) + } + } + +} + +class ServerTestWithReference: SerDeTest() { + + override fun objectClass() = Server::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/server/server with reference.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/server/server with reference - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/server/server with reference - wrongly extended.json" + + override fun build(): Server { + return Server.builder() + .host("{username}.gigantic-server.com:{port}/{basePath}") + .protocol("secure-mqtt") + .protocolVersion("5") + .pathname("/messages") + .description("The production API server") + .title("secure-mqtt API server") + .summary("API server") + .variables(mapOf( + Pair("username", ServerVariable.builder() + .defaultValue("demo") + .description("This value is assigned by the service provider, in this example `gigantic-server.com`") + .build()), + Pair("port", ServerVariable.builder() + .enumValues(listOf("8883", "8884")) + .defaultValue("8883") + .build()), + Pair("basePath", Reference("#/components/serverVariables/basePath")) + )) + .security(listOf( + ApiKeySecuritySchemeTest().build(), + HttpSecuritySchemeBearerTest().build(), + Reference("#/components/securitySchemes/openId") + )) + .tags(listOf( + Tag("env:staging", "This environment is a replica of the production environment", null), + Reference("#/components/tags/tag_name") + )) + .externalDocs(Reference("#/components/externalDocs/externalDoc")) + .bindings(bindings()) + .build() + } + + companion object { + @JvmStatic + fun bindings(): Map { + return mapOf( + Pair("amqp", Reference("#/components/serverBindings/amqp")), + Pair("amqp1", AMQP1ServerBinding()), + Pair("anypointmq", AnypointMQServerBinding()), + Pair("googlepubsub", GooglePubSubServerBinding()), + Pair("http", HTTPServerBinding()), + Pair( + "ibmmq", + IBMMQServerBinding.builder() + .groupId("PRODCLSTR1") + .cipherSpec("ANY_TLS12_OR_HIGHER") + .build() + ), + Pair("jms", JMSServerBinding()), + Pair( + "kafka", + KafkaServerBinding.builder() + .schemaRegistryUrl("https://my-schema-registry.com") + .schemaRegistryVendor("confluent") + .build() + ), + Pair("mercure", MercureServerBinding()), + Pair( + "mqtt", + MQTTServerBinding.builder() + .clientId("guest") + .cleanSession(true) + .lastWill(MQTTServerLastWillConfiguration( + "/last-wills", + 2, + "Guest gone offline.", + false + )) + .keepAlive(60) + .build() + ), + Pair( + "mqtt5", + MQTT5ServerBinding.builder() + .sessionExpiryInterval(60) + .build() + ), + Pair("nats", NATSServerBinding()), + Pair( + "pulsar", + PulsarServerBinding.builder() + .tenant("contoso") + .build() + ), + Pair("redis", RedisServerBinding()), + Pair("sns", SNSServerBinding()), + Pair( + "solace", + SolaceServerBinding.builder() + .msgVpn("solace.private.net") + .build() + ), + Pair("sqs", SQSServerBinding()), + Pair("stomp", STOMPServerBinding()), + Pair("ws", WebSocketsServerBinding()), + ) + } + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/server/ServerVariableTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/server/ServerVariableTest.kt new file mode 100644 index 00000000..9107078e --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/_0_0/model/server/ServerVariableTest.kt @@ -0,0 +1,28 @@ +package com.asyncapi.v3._0_0.model.server + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class ServerVariableTest: SerDeTest() { + + override fun objectClass() = ServerVariable::class.java + + override fun baseObjectJson() = "/json/v3/3.0.0/model/server/serverVariable.json" + + override fun extendedObjectJson() = "/json/v3/3.0.0/model/server/serverVariable - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/3.0.0/model/server/serverVariable - wrongly extended.json" + + override fun build(): ServerVariable { + return ServerVariable.builder() + .enumValues(listOf("8883", "8884")) + .description("To which port connect") + .defaultValue("8883") + .examples(listOf("8883", "8884")) + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/amqp/AMQPChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/amqp/AMQPChannelBindingTest.kt new file mode 100644 index 00000000..f45456ca --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/amqp/AMQPChannelBindingTest.kt @@ -0,0 +1,42 @@ +package com.asyncapi.v3.binding.channel.amqp + +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3.binding.channel.amqp.exchange.AMQPChannelExchangeProperties +import com.asyncapi.v3.binding.channel.amqp.exchange.AMQPChannelExchangeType +import com.asyncapi.v3.binding.channel.amqp.queue.AMQPChannelQueueProperties + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class AMQPChannelBindingTest: SerDeTest() { + + override fun objectClass() = AMQPChannelBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/channel/amqp/amqpChannelBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/channel/amqp/amqpChannelBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/channel/amqp/amqpChannelBinding - wrongly extended.json" + + override fun build(): AMQPChannelBinding { + return AMQPChannelBinding.builder() + .`is`(AMQPChannelType.ROUTING_KEY) + .queue(AMQPChannelQueueProperties.builder() + .name("my-queue-name") + .durable(true) + .exclusive(true) + .autoDelete(false) + .build() + ) + .exchange(AMQPChannelExchangeProperties.builder() + .name("myExchange") + .type(AMQPChannelExchangeType.TOPIC) + .durable(true) + .autoDelete(false) + .build() + ) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/anypointmq/AnypointMQChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/anypointmq/AnypointMQChannelBindingTest.kt new file mode 100644 index 00000000..a345ee89 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/anypointmq/AnypointMQChannelBindingTest.kt @@ -0,0 +1,26 @@ +package com.asyncapi.v3.binding.channel.anypointmq + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class AnypointMQChannelBindingTest: SerDeTest() { + + override fun objectClass() = AnypointMQChannelBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/channel/anypoint/anypointMQChannelBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/channel/anypoint/anypointMQChannelBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/channel/anypoint/anypointMQChannelBinding - wrongly extended.json" + + override fun build(): AnypointMQChannelBinding { + return AnypointMQChannelBinding.builder() + .destination("user-signup-exchg") + .destinationType(AnypointMQChannelDestinationType.EXCHANGE) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelBindingTest.kt new file mode 100644 index 00000000..e4e85536 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/googlepubsub/GooglePubSubChannelBindingTest.kt @@ -0,0 +1,42 @@ +package com.asyncapi.v3.binding.channel.googlepubsub + +import com.asyncapi.v3.SerDeTest + +class GooglePubSubChannelBindingTest: SerDeTest() { + + override fun objectClass() = GooglePubSubChannelBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding - wrongly extended.json" + + override fun build(): GooglePubSubChannelBinding { + return GooglePubSubChannelBinding.builder() + .topic("projects/your-project/topics/topic-proto-schema") + .messageRetentionDuration("86400s") + .messageStoragePolicy(GooglePubSubChannelMessageStoragePolicy( + listOf( + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ) + )) + .schemaSettings(GooglePubSubChannelSchemaSettings.builder() + .encoding("binary") + .name("projects/your-project/schemas/message-proto") + .build() + ) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelBindingTest.kt new file mode 100644 index 00000000..44b62126 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/ibmmq/IBMMQChannelBindingTest.kt @@ -0,0 +1,35 @@ +package com.asyncapi.v3.binding.channel.ibmmq + +import com.asyncapi.v3.SerDeTest + +class IBMMQChannelBindingTest: SerDeTest() { + + override fun objectClass() = IBMMQChannelBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/channel/ibmmq/ibmMQChannelBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/channel/ibmmq/ibmMQChannelBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/channel/ibmmq/ibmMQChannelBinding - wrongly extended.json" + + override fun build(): IBMMQChannelBinding { + return IBMMQChannelBinding.builder() + .destinationType(IBMMQChannelDestinationType.TOPIC) + .queue(IBMMQChannelQueueProperties.builder() + .objectName("message") + .isPartitioned(false) + .exclusive(true) + .build() + ) + .topic(IBMMQChannelTopicProperties.builder() + .string("messages") + .objectName("message") + .durablePermitted(true) + .lastMsgRetained(true) + .build() + ) + .maxMsgLength(1024) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/kafka/KafkaChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/kafka/KafkaChannelBindingTest.kt new file mode 100644 index 00000000..6b53ef17 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/kafka/KafkaChannelBindingTest.kt @@ -0,0 +1,38 @@ +package com.asyncapi.v3.binding.channel.kafka + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class KafkaChannelBindingTest: SerDeTest() { + + override fun objectClass() = KafkaChannelBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/channel/kafka/kafkaChannelBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/channel/kafka/kafkaChannelBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/channel/kafka/kafkaChannelBinding - wrongly extended.json" + + override fun build(): KafkaChannelBinding { + return KafkaChannelBinding.builder() + .topic("my-specific-topic-name") + .partitions(20) + .replicas(3) + .topicConfiguration(KafkaChannelTopicConfiguration.builder() + .cleanupPolicy(listOf( + KafkaChannelTopicCleanupPolicy.DELETE, + KafkaChannelTopicCleanupPolicy.COMPACT + )) + .retentionMs(604_800_000) + .retentionBytes(1_000_000_000) + .deleteRetentionMs(86_400_000) + .maxMessageBytes(1_048_588) + .build() + ) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelBindingTest.kt new file mode 100644 index 00000000..2c2d6da8 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/pulsar/PulsarChannelBindingTest.kt @@ -0,0 +1,31 @@ +package com.asyncapi.v3.binding.channel.pulsar + +import com.asyncapi.v3.SerDeTest + +class PulsarChannelBindingTest: SerDeTest() { + + override fun objectClass() = PulsarChannelBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/channel/pulsar/pulsarChannelBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/channel/pulsar/pulsarChannelBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/channel/pulsar/pulsarChannelBinding - wrongly extended.json" + + override fun build(): PulsarChannelBinding { + return PulsarChannelBinding.builder() + .namespace("staging") + .persistence(PulsarChannelPersistence.PERSISTENT) + .compaction(1000) + .geoReplication(listOf("us-east1", "us-west1")) + .retention(PulsarChannelRetentionDefinition.builder() + .time(7) + .size(1000) + .build() + ) + .ttl(360) + .deduplication(false) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/ws/WebSocketsChannelBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/ws/WebSocketsChannelBindingTest.kt new file mode 100644 index 00000000..8182aec6 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/channel/ws/WebSocketsChannelBindingTest.kt @@ -0,0 +1,53 @@ +package com.asyncapi.v3.binding.channel.ws + +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3.schema.Schema +import com.asyncapi.v3.schema.Type + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class WebSocketsChannelBindingTest: SerDeTest() { + + override fun objectClass() = WebSocketsChannelBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/channel/ws/webSocketsChannelBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/channel/ws/webSocketsChannelBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/channel/ws/webSocketsChannelBinding - wrongly extended.json" + + override fun build(): WebSocketsChannelBinding { + return WebSocketsChannelBinding.builder() + .method(WebSocketsChannelMethod.GET) + .query(Schema.builder() + .type(Type.OBJECT) + .properties(mapOf( + Pair( + "ref", + Schema.builder() + .type(Type.STRING) + .description("Referral.") + .build() + ) + )) + .build() + ) + .headers(Schema.builder() + .type(Type.OBJECT) + .properties(mapOf( + Pair( + "Authentication", + Schema.builder() + .type(Type.STRING) + .description("Authentication token") + .build() + ) + )) + .build() + ) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/amqp/AMQPMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/amqp/AMQPMessageBindingTest.kt new file mode 100644 index 00000000..46ce1df5 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/amqp/AMQPMessageBindingTest.kt @@ -0,0 +1,22 @@ +package com.asyncapi.v3.binding.message.amqp + +import com.asyncapi.v3.SerDeTest + +class AMQPMessageBindingTest: SerDeTest() { + + override fun objectClass() = AMQPMessageBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/message/amqp/amqpMessageBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/message/amqp/amqpMessageBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/message/amqp/amqpMessageBinding - wrongly extended.json" + + override fun build(): AMQPMessageBinding { + return AMQPMessageBinding.builder() + .contentEncoding("gzip") + .messageType("user.signup") + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/anypointmq/AnypointMQMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/anypointmq/AnypointMQMessageBindingTest.kt new file mode 100644 index 00000000..610b2f74 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/anypointmq/AnypointMQMessageBindingTest.kt @@ -0,0 +1,34 @@ +package com.asyncapi.v3.binding.message.anypointmq + +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3.schema.Schema +import com.asyncapi.v3.schema.Type + +class AnypointMQMessageBindingTest: SerDeTest() { + + override fun objectClass() = AnypointMQMessageBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/message/anypointmq/anypointMQMessageBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/message/anypointmq/anypointMQMessageBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/message/anypointmq/anypointMQMessageBinding - wrongly extended.json" + + override fun build(): AnypointMQMessageBinding { + return AnypointMQMessageBinding.builder() + .headers(Schema.builder() + .type(Type.OBJECT) + .properties(mapOf( + Pair( + "correlationId", + Schema.builder() + .type(Type.STRING) + .description("Correlation ID set by application") + .build() + ) + )) + .build()) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageBindingTest.kt new file mode 100644 index 00000000..201aa44e --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/googlepubsub/GooglePubSubMessageBindingTest.kt @@ -0,0 +1,24 @@ +package com.asyncapi.v3.binding.message.googlepubsub + +import com.asyncapi.v3.SerDeTest + +class GooglePubSubMessageBindingTest: SerDeTest() { + + override fun objectClass() = GooglePubSubMessageBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding - wrongly extended.json" + + override fun build(): GooglePubSubMessageBinding { + return GooglePubSubMessageBinding.builder() + .schema(GooglePubSubMessageSchemaDefinition( + "projects/your-project/schemas/message-avro", + GooglePubSubMessageSchemaDefinitionType.AVRO + )) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/http/HTTPMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/http/HTTPMessageBindingTest.kt new file mode 100644 index 00000000..2b52abc2 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/http/HTTPMessageBindingTest.kt @@ -0,0 +1,34 @@ +package com.asyncapi.v3.binding.message.http + +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3.schema.Schema +import com.asyncapi.v3.schema.Type + +class HTTPMessageBindingTest: SerDeTest() { + + override fun objectClass() = HTTPMessageBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/message/http/httpMessageBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/message/http/httpMessageBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/message/http/httpMessageBinding - wrongly extended.json" + + override fun build(): HTTPMessageBinding { + return HTTPMessageBinding.builder() + .headers(Schema.builder() + .type(Type.OBJECT) + .properties(mapOf( + Pair( + "Content-Type", + Schema.builder() + .type(Type.STRING) + .enumValue(listOf("application/json")) + .build() + ) + )) + .build()) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/ibmmq/IBMMQMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/ibmmq/IBMMQMessageBindingTest.kt new file mode 100644 index 00000000..4924a3e5 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/ibmmq/IBMMQMessageBindingTest.kt @@ -0,0 +1,24 @@ +package com.asyncapi.v3.binding.message.ibmmq + +import com.asyncapi.v3.SerDeTest + +class IBMMQMessageBindingTest: SerDeTest() { + + override fun objectClass() = IBMMQMessageBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/message/ibmmq/ibmMQMessageBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/message/ibmmq/ibmMQMessageBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/message/ibmmq/ibmMQMessageBinding - wrongly extended.json" + + override fun build(): IBMMQMessageBinding { + return IBMMQMessageBinding.builder() + .type(IBMMQMessageType.JMS) + .description("JMS stream message") + .headers("Content-Type: application/json") + .expiry(0) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/kafka/KafkaMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/kafka/KafkaMessageBindingTest.kt new file mode 100644 index 00000000..4331ecde --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/kafka/KafkaMessageBindingTest.kt @@ -0,0 +1,29 @@ +package com.asyncapi.v3.binding.message.kafka + +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3.schema.Schema +import com.asyncapi.v3.schema.Type + +class KafkaMessageBindingTest: SerDeTest() { + + override fun objectClass() = KafkaMessageBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/message/kafka/kafkaMessageBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/message/kafka/kafkaMessageBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/message/kafka/kafkaMessageBinding - wrongly extended.json" + + override fun build(): KafkaMessageBinding { + return KafkaMessageBinding.builder() + .key(Schema.builder() + .type(Type.STRING) + .enumValue(listOf("myKey")) + .build()) + .schemaIdLocation(KafkaMessageSchemaIdLocation.PAYLOAD) + .schemaIdPayloadEncoding("apicurio-new") + .schemaLookupStrategy("TopicIdStrategy") + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/mqtt/MQTTMessageBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/mqtt/MQTTMessageBindingTest.kt new file mode 100644 index 00000000..d327ec4e --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/message/mqtt/MQTTMessageBindingTest.kt @@ -0,0 +1,20 @@ +package com.asyncapi.v3.binding.message.mqtt + +import com.asyncapi.v3.SerDeTest + +class MQTTMessageBindingTest: SerDeTest() { + + override fun objectClass() = MQTTMessageBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/message/mqtt/mqttMessageBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/message/mqtt/mqttMessageBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/message/mqtt/mqttMessageBinding - wrongly extended.json" + + override fun build(): MQTTMessageBinding { + return MQTTMessageBinding.builder() + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/amqp/AMQPOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/amqp/AMQPOperationBindingTest.kt new file mode 100644 index 00000000..0fc26178 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/amqp/AMQPOperationBindingTest.kt @@ -0,0 +1,30 @@ +package com.asyncapi.v3.binding.operation.amqp + +import com.asyncapi.v3.SerDeTest + +class AMQPOperationBindingTest: SerDeTest() { + + override fun objectClass() = AMQPOperationBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/operation/amqp/amqpOperationBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/operation/amqp/amqpOperationBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/operation/amqp/amqpOperationBinding - wrongly extended.json" + + override fun build(): AMQPOperationBinding { + return AMQPOperationBinding.builder() + .expiration(100_000) + .userId("guest") + .cc(listOf("user.logs")) + .priority(10) + .deliveryMode(2) + .mandatory(false) + .bcc(listOf("external.audit")) + .replyTo("user.signedup") + .timestamp(true) + .ack(false) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/http/HTTPOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/http/HTTPOperationBindingTest.kt new file mode 100644 index 00000000..9a101826 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/http/HTTPOperationBindingTest.kt @@ -0,0 +1,41 @@ +package com.asyncapi.v3.binding.operation.http + +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3.schema.Schema +import com.asyncapi.v3.schema.Type +import java.math.BigDecimal + +class HTTPOperationBindingTest: SerDeTest() { + + override fun objectClass() = HTTPOperationBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/operation/http/httpOperationBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/operation/http/httpOperationBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/operation/http/httpOperationBinding - wrongly extended.json" + + override fun build(): HTTPOperationBinding { + return HTTPOperationBinding.builder() + .type(HTTPOperationType.REQUEST) + .method(HTTPOperationMethod.GET) + .query(Schema.builder() + .type(Type.OBJECT) + .required(listOf("companyId")) + .properties(mapOf( + Pair( + "companyId", + Schema.builder() + .type(Type.NUMBER) + .minimum(BigDecimal.ONE) + .description("The Id of the company.") + .build() + ) + )) + .additionalProperties(false) + .build() + ) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/kafka/KafkaOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/kafka/KafkaOperationBindingTest.kt new file mode 100644 index 00000000..e42eb7bf --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/kafka/KafkaOperationBindingTest.kt @@ -0,0 +1,30 @@ +package com.asyncapi.v3.binding.operation.kafka + +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3.schema.Schema +import com.asyncapi.v3.schema.Type + +class KafkaOperationBindingTest: SerDeTest() { + + override fun objectClass() = KafkaOperationBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/operation/kafka/kafkaOperationBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/operation/kafka/kafkaOperationBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/operation/kafka/kafkaOperationBinding - wrongly extended.json" + + override fun build(): KafkaOperationBinding { + return KafkaOperationBinding.builder() + .groupId(Schema.builder() + .type(Type.STRING) + .enumValue(listOf("myGroupId")) + .build()) + .clientId(Schema.builder() + .type(Type.STRING) + .enumValue(listOf("myClientId")) + .build()) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/mqtt/MQTTOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/mqtt/MQTTOperationBindingTest.kt new file mode 100644 index 00000000..e199cf50 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/mqtt/MQTTOperationBindingTest.kt @@ -0,0 +1,22 @@ +package com.asyncapi.v3.binding.operation.mqtt + +import com.asyncapi.v3.SerDeTest + +class MQTTOperationBindingTest: SerDeTest() { + + override fun objectClass() = MQTTOperationBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/operation/mqtt/mqttOperationBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/operation/mqtt/mqttOperationBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/operation/mqtt/mqttOperationBinding - wrongly extended.json" + + override fun build(): MQTTOperationBinding { + return MQTTOperationBinding.builder() + .qos(2) + .retain(true) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/nats/NATSOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/nats/NATSOperationBindingTest.kt new file mode 100644 index 00000000..60f0ef6c --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/nats/NATSOperationBindingTest.kt @@ -0,0 +1,21 @@ +package com.asyncapi.v3.binding.operation.nats + +import com.asyncapi.v3.SerDeTest + +class NATSOperationBindingTest: SerDeTest() { + + override fun objectClass() = NATSOperationBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/operation/nats/natsOperationBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/operation/nats/natsOperationBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/operation/nats/natsOperationBinding - wrongly extended.json" + + override fun build(): NATSOperationBinding { + return NATSOperationBinding.builder() + .queue("messages") + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/solace/SolaceOperationBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/solace/SolaceOperationBindingTest.kt new file mode 100644 index 00000000..cae516f2 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/operation/solace/SolaceOperationBindingTest.kt @@ -0,0 +1,47 @@ +package com.asyncapi.v3.binding.operation.solace + +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3.binding.operation.solace.queue.SolaceOperationQueue +import com.asyncapi.v3.binding.operation.solace.topic.SolaceOperationTopic + +class SolaceOperationBindingTest: SerDeTest() { + + override fun objectClass() = SolaceOperationBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/operation/solace/solaceOperationBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/operation/solace/solaceOperationBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/operation/solace/solaceOperationBinding - wrongly extended.json" + + override fun build(): SolaceOperationBinding { + return SolaceOperationBinding.builder() + .destinations(listOf( + SolaceOperationDestination.builder() + .destinationType(SolaceOperationDestination.Type.QUEUE) + .queue(SolaceOperationQueue.builder() + .name("CreatedHREvents") + .topicSubscriptions(listOf("person/*/created")) + .accessType(SolaceOperationQueue.AccessType.EXCLUSIVE) + .maxMsgSpoolSize("1,500") + .maxTtl("60") + .build() + ) + .build(), + SolaceOperationDestination.builder() + .destinationType(SolaceOperationDestination.Type.QUEUE) + .queue(SolaceOperationQueue.builder() + .name("UpdatedHREvents") + .topicSubscriptions(listOf("person/*/updated")) + .build() + ) + .topic(SolaceOperationTopic.builder() + .topicSubscriptions(listOf("person/*/updated")) + .build() + ) + .build() + )) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/ibmmq/IBMMQServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/ibmmq/IBMMQServerBindingTest.kt new file mode 100644 index 00000000..67670a7b --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/ibmmq/IBMMQServerBindingTest.kt @@ -0,0 +1,26 @@ +package com.asyncapi.v3.binding.server.ibmmq + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class IBMMQServerBindingTest: SerDeTest() { + + override fun objectClass() = IBMMQServerBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/server/ibmmq/ibmmqServerBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/server/ibmmq/ibmmqServerBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/server/ibmmq/ibmmqServerBinding - wrongly extended.json" + + override fun build(): IBMMQServerBinding { + return IBMMQServerBinding.builder() + .groupId("PRODCLSTR1") + .cipherSpec("ANY_TLS12_OR_HIGHER") + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/kafka/KafkaServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/kafka/KafkaServerBindingTest.kt new file mode 100644 index 00000000..dea2146f --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/kafka/KafkaServerBindingTest.kt @@ -0,0 +1,26 @@ +package com.asyncapi.v3.binding.server.kafka + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class KafkaServerBindingTest: SerDeTest() { + + override fun objectClass() = KafkaServerBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/server/kafka/kafkaServerBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/server/kafka/kafkaServerBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/server/kafka/kafkaServerBinding - wrongly extended.json" + + override fun build(): KafkaServerBinding { + return KafkaServerBinding.builder() + .schemaRegistryUrl("https://my-schema-registry.com") + .schemaRegistryVendor("confluent") + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/mqtt/MQTTServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/mqtt/MQTTServerBindingTest.kt new file mode 100644 index 00000000..9dccffeb --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/mqtt/MQTTServerBindingTest.kt @@ -0,0 +1,33 @@ +package com.asyncapi.v3.binding.server.mqtt + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class MQTTServerBindingTest: SerDeTest() { + + override fun objectClass() = MQTTServerBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/server/mqtt/mqttServerBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/server/mqtt/mqttServerBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/server/mqtt/mqttServerBinding - wrongly extended.json" + + override fun build(): MQTTServerBinding { + return MQTTServerBinding.builder() + .clientId("guest") + .cleanSession(true) + .lastWill(MQTTServerLastWillConfiguration( + "/last-wills", + 2, + "Guest gone offline.", + false + )) + .keepAlive(60) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/mqtt5/MQTT5ServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/mqtt5/MQTT5ServerBindingTest.kt new file mode 100644 index 00000000..23cd7f3d --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/mqtt5/MQTT5ServerBindingTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.binding.server.mqtt5 + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class MQTT5ServerBindingTest: SerDeTest() { + + override fun objectClass() = MQTT5ServerBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/server/mqtt5/mqtt5ServerBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/server/mqtt5/mqtt5ServerBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/server/mqtt5/mqtt5ServerBinding - wrongly extended.json" + + override fun build(): MQTT5ServerBinding { + return MQTT5ServerBinding.builder() + .sessionExpiryInterval(60) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/pulsar/PulsarServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/pulsar/PulsarServerBindingTest.kt new file mode 100644 index 00000000..1daee16b --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/pulsar/PulsarServerBindingTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.binding.server.pulsar + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class PulsarServerBindingTest: SerDeTest() { + + override fun objectClass() = PulsarServerBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/server/pulsar/pulsarServerBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/server/pulsar/pulsarServerBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/server/pulsar/pulsarServerBinding - wrongly extended.json" + + override fun build(): PulsarServerBinding { + return PulsarServerBinding.builder() + .tenant("contoso") + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/solace/SolaceServerBindingTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/solace/SolaceServerBindingTest.kt new file mode 100644 index 00000000..a95a49d4 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/binding/server/solace/SolaceServerBindingTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.binding.server.solace + +import com.asyncapi.v3.SerDeTest + +/** + * @version 3.0.0 + * @author Pavel Bodiachevskii + */ +class SolaceServerBindingTest: SerDeTest() { + + override fun objectClass() = SolaceServerBinding::class.java + + override fun baseObjectJson() = "/json/v3/binding/server/solace/solaceServerBinding.json" + + override fun extendedObjectJson() = "/json/v3/binding/server/solace/solaceServerBinding - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/binding/server/solace/solaceServerBinding - wrongly extended.json" + + override fun build(): SolaceServerBinding { + return SolaceServerBinding.builder() + .msgVpn("solace.private.net") + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/ApiKeySecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/ApiKeySecuritySchemeTest.kt new file mode 100644 index 00000000..fc7aa22d --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/ApiKeySecuritySchemeTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.security_scheme + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class ApiKeySecuritySchemeTest: SerDeTest() { + + override fun objectClass() = ApiKeySecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/apiKey.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/apiKey - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/apiKey - wrongly extended.json" + + override fun build(): SecurityScheme { + return ApiKeySecurityScheme.apiKeyBuilder() + .description("apiKey") + .`in`(ApiKeySecurityScheme.ApiKeyLocation.USER) + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/AsymmetricEncryptionSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/AsymmetricEncryptionSecuritySchemeTest.kt new file mode 100644 index 00000000..ff6e6cd1 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/AsymmetricEncryptionSecuritySchemeTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.security_scheme + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class AsymmetricEncryptionSecuritySchemeTest: SerDeTest() { + + override fun objectClass() = SecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/asymmetricEncryption.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/asymmetricEncryption - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/asymmetricEncryption - wrongly extended.json" + + override fun build(): SecurityScheme { + return SecurityScheme.builder() + .type(SecurityScheme.Type.ASYMMETRIC_ENCRYPTION) + .description("asymmetricEncryption") + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/GssapiSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/GssapiSecuritySchemeTest.kt new file mode 100644 index 00000000..f0f20f3c --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/GssapiSecuritySchemeTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.security_scheme + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class GssapiSecuritySchemeTest: SerDeTest() { + + override fun objectClass() = SecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/gssapi.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/gssapi - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/gssapi - wrongly extended.json" + + override fun build(): SecurityScheme { + return SecurityScheme.builder() + .type(SecurityScheme.Type.GSSAPI) + .description("gssapi") + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/OpenIdConnectSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/OpenIdConnectSecuritySchemeTest.kt new file mode 100644 index 00000000..baf2ff56 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/OpenIdConnectSecuritySchemeTest.kt @@ -0,0 +1,26 @@ +package com.asyncapi.v3.security_scheme + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class OpenIdConnectSecuritySchemeTest: SerDeTest() { + + override fun objectClass() = OpenIdConnectSecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/openIdConnect.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/openIdConnect - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/openIdConnect - wrongly extended.json" + + override fun build(): SecurityScheme { + return OpenIdConnectSecurityScheme.openIdBuilder() + .description("openIdConnect") + .openIdConnectUrl("https://server.com/.well-known/openid-configuration") + .scopes(listOf("write:pets", "read:pets")) + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/PlainSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/PlainSecuritySchemeTest.kt new file mode 100644 index 00000000..9eca4fd4 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/PlainSecuritySchemeTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.security_scheme + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class PlainSecuritySchemeTest: SerDeTest() { + + override fun objectClass() = SecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/plain.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/plain - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/plain - wrongly extended.json" + + override fun build(): SecurityScheme { + return SecurityScheme.builder() + .type(SecurityScheme.Type.PLAIN) + .description("plain") + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/ScramSha256SecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/ScramSha256SecuritySchemeTest.kt new file mode 100644 index 00000000..501f23f3 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/ScramSha256SecuritySchemeTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.security_scheme + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class ScramSha256SecuritySchemeTest: SerDeTest() { + + override fun objectClass() = SecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/scramSha256.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/scramSha256 - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/scramSha256 - wrongly extended.json" + + override fun build(): SecurityScheme { + return SecurityScheme.builder() + .type(SecurityScheme.Type.SCRAM_SHA256) + .description("scramSha256") + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/ScramSha512SecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/ScramSha512SecuritySchemeTest.kt new file mode 100644 index 00000000..1e26e677 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/ScramSha512SecuritySchemeTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.security_scheme + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class ScramSha512SecuritySchemeTest: SerDeTest() { + + override fun objectClass() = SecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/scramSha512.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/scramSha512 - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/scramSha512 - wrongly extended.json" + + override fun build(): SecurityScheme { + return SecurityScheme.builder() + .type(SecurityScheme.Type.SCRAM_SHA512) + .description("scramSha512") + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/SymmetricEncryptionSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/SymmetricEncryptionSecuritySchemeTest.kt new file mode 100644 index 00000000..4f6057da --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/SymmetricEncryptionSecuritySchemeTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.security_scheme + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class SymmetricEncryptionSecuritySchemeTest: SerDeTest() { + + override fun objectClass() = SecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/symmetricEncryption.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/symmetricEncryption - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/symmetricEncryption - wrongly extended.json" + + override fun build(): SecurityScheme { + return SecurityScheme.builder() + .type(SecurityScheme.Type.SYMMETRIC_ENCRYPTION) + .description("symmetricEncryption") + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/UserPasswordSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/UserPasswordSecuritySchemeTest.kt new file mode 100644 index 00000000..c7aa3980 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/UserPasswordSecuritySchemeTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.security_scheme + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class UserPasswordSecuritySchemeTest: SerDeTest() { + + override fun objectClass() = SecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/userPassword.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/userPassword - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/userPassword - wrongly extended.json" + + override fun build(): SecurityScheme { + return SecurityScheme.builder() + .type(SecurityScheme.Type.USER_PASSWORD) + .description("userPassword") + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/X509SecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/X509SecuritySchemeTest.kt new file mode 100644 index 00000000..849ce42a --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/X509SecuritySchemeTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.security_scheme + +import com.asyncapi.v3.SerDeTest + +/** + * @author Pavel Bodiachevskii + */ +class X509SecuritySchemeTest: SerDeTest() { + + override fun objectClass() = SecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/X509.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/X509 - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/X509 - wrongly extended.json" + + override fun build(): SecurityScheme { + return SecurityScheme.builder() + .type(SecurityScheme.Type.X509) + .description("X509") + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/http/HttpApiKeySecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/http/HttpApiKeySecuritySchemeTest.kt new file mode 100644 index 00000000..df47744d --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/http/HttpApiKeySecuritySchemeTest.kt @@ -0,0 +1,23 @@ +package com.asyncapi.v3.security_scheme.http + +import com.asyncapi.v3.SerDeTest + +class HttpApiKeySecuritySchemeTest: SerDeTest() { + + override fun objectClass() = HttpApiKeySecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/http/httpApiKey.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/http/httpApiKey - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/http/httpApiKey - wrongly extended.json" + + override fun build(): HttpApiKeySecurityScheme { + return HttpApiKeySecurityScheme.httpApiKeyBuilder() + .description("httpApiKey") + .name("api_key") + .`in`(HttpApiKeySecurityScheme.ApiKeyLocation.HEADER) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/http/HttpSecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/http/HttpSecuritySchemeTest.kt new file mode 100644 index 00000000..c06ad616 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/http/HttpSecuritySchemeTest.kt @@ -0,0 +1,42 @@ +package com.asyncapi.v3.security_scheme.http + +import com.asyncapi.v3.SerDeTest + +class HttpSecuritySchemeBasicTest: SerDeTest() { + + override fun objectClass() = HttpSecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/http/httpBasic.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/http/httpBasic - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/http/httpBasic - wrongly extended.json" + + override fun build(): HttpSecurityScheme { + return HttpSecurityScheme.httpBuilder() + .description("http") + .scheme("basic") + .build() + } + +} + +class HttpSecuritySchemeBearerTest: SerDeTest() { + + override fun objectClass() = HttpSecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/http/httpBearer.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/http/httpBearer - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/http/httpBearer - wrongly extended.json" + + override fun build(): HttpSecurityScheme { + return HttpSecurityScheme.httpBuilder() + .description("http") + .scheme("bearer") + .bearerFormat("JWT") + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/OAuth2SecuritySchemeTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/OAuth2SecuritySchemeTest.kt new file mode 100644 index 00000000..19d6840c --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/OAuth2SecuritySchemeTest.kt @@ -0,0 +1,27 @@ +package com.asyncapi.v3.security_scheme.oauth2 + +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3.security_scheme.SecurityScheme + +/** + * @author Pavel Bodiachevskii + */ +class OAuth2SecuritySchemeTest: SerDeTest() { + + override fun objectClass() = OAuth2SecurityScheme::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/oauth2/oauth2.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/oauth2/oauth2 - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/oauth2/oauth2 - wrongly extended.json" + + override fun build(): SecurityScheme { + return OAuth2SecurityScheme.oauth2Builder() + .description("oauth2") + .flows(OAuthFlowTest().build()) + .scopes(listOf("write:pets", "read:pets")) + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/OAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/OAuthFlowTest.kt new file mode 100644 index 00000000..1a943fa8 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/OAuthFlowTest.kt @@ -0,0 +1,28 @@ +package com.asyncapi.v3.security_scheme.oauth2 + +import com.asyncapi.v3.SerDeTest +import com.asyncapi.v3.security_scheme.oauth2.flow.* + +/** + * @author Pavel Bodiachevskii + */ +class OAuthFlowTest: SerDeTest() { + + override fun objectClass() = OAuthFlows::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/oauth2/oauthFlows.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/oauth2/oauthFlows - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/oauth2/oauthFlows - wrongly extended.json" + + override fun build(): OAuthFlows { + return OAuthFlows.builder() + .authorizationCode(AuthorizationCodeOAuthFlowTest().build()) + .clientCredentials(ClientCredentialsOAuthFlowTest().build()) + .implicit(ImplicitOAuthFlowTest().build()) + .password(PasswordOAuthFlowTest().build()) + .build() + } + +} diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/AuthorizationCodeOAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/AuthorizationCodeOAuthFlowTest.kt new file mode 100644 index 00000000..01f543e3 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/AuthorizationCodeOAuthFlowTest.kt @@ -0,0 +1,27 @@ +package com.asyncapi.v3.security_scheme.oauth2.flow + +import com.asyncapi.v3.SerDeTest + +class AuthorizationCodeOAuthFlowTest: SerDeTest() { + + override fun objectClass() = AuthorizationCodeOAuthFlow::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - wrongly extended.json" + + override fun build(): AuthorizationCodeOAuthFlow { + return AuthorizationCodeOAuthFlow.authorizationCodeBuilder() + .authorizationUrl("https://example.com/api/oauth/dialog") + .tokenUrl("https://example.com/api/oauth/token") + .refreshUrl("https://example.com/api/oauth/refresh") + .scopes(mapOf( + Pair("write:pets", "modify pets in your account"), + Pair("read:pets", "read your pets") + )) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/ClientCredentialsOAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/ClientCredentialsOAuthFlowTest.kt new file mode 100644 index 00000000..ff2f0d93 --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/ClientCredentialsOAuthFlowTest.kt @@ -0,0 +1,26 @@ +package com.asyncapi.v3.security_scheme.oauth2.flow + +import com.asyncapi.v3.SerDeTest + +class ClientCredentialsOAuthFlowTest: SerDeTest() { + + override fun objectClass() = ClientCredentialsOAuthFlow::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - wrongly extended.json" + + override fun build(): ClientCredentialsOAuthFlow { + return ClientCredentialsOAuthFlow.clientCredentialsBuilder() + .tokenUrl("https://example.com/api/oauth/token") + .refreshUrl("https://example.com/api/oauth/refresh") + .scopes(mapOf( + Pair("write:pets", "modify pets in your account"), + Pair("read:pets", "read your pets") + )) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/ImplicitOAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/ImplicitOAuthFlowTest.kt new file mode 100644 index 00000000..12cdc5df --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/ImplicitOAuthFlowTest.kt @@ -0,0 +1,26 @@ +package com.asyncapi.v3.security_scheme.oauth2.flow + +import com.asyncapi.v3.SerDeTest + +class ImplicitOAuthFlowTest: SerDeTest() { + + override fun objectClass() = ImplicitOAuthFlow::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow - wrongly extended.json" + + override fun build(): ImplicitOAuthFlow { + return ImplicitOAuthFlow.implicitBuilder() + .authorizationUrl("https://example.com/api/oauth/dialog") + .refreshUrl("https://example.com/api/oauth/refresh") + .scopes(mapOf( + Pair("write:pets", "modify pets in your account"), + Pair("read:pets", "read your pets") + )) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/OAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/OAuthFlowTest.kt new file mode 100644 index 00000000..b40c1eea --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/OAuthFlowTest.kt @@ -0,0 +1,25 @@ +package com.asyncapi.v3.security_scheme.oauth2.flow + +import com.asyncapi.v3.SerDeTest + +class OAuthFlowTest: SerDeTest() { + + override fun objectClass() = OAuthFlow::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/oauth2/flow/oauthFlow.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/oauth2/flow/oauthFlow - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/oauth2/flow/oauthFlow - wrongly extended.json" + + override fun build(): OAuthFlow { + return OAuthFlow.builder() + .refreshUrl("https://example.com/api/oauth/refresh") + .scopes(mapOf( + Pair("write:pets", "modify pets in your account"), + Pair("read:pets", "read your pets") + )) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/PasswordOAuthFlowTest.kt b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/PasswordOAuthFlowTest.kt new file mode 100644 index 00000000..531e97ad --- /dev/null +++ b/asyncapi-core/src/test/kotlin/com/asyncapi/v3/security_scheme/oauth2/flow/PasswordOAuthFlowTest.kt @@ -0,0 +1,26 @@ +package com.asyncapi.v3.security_scheme.oauth2.flow + +import com.asyncapi.v3.SerDeTest + +class PasswordOAuthFlowTest: SerDeTest() { + + override fun objectClass() = PasswordOAuthFlow::class.java + + override fun baseObjectJson() = "/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow.json" + + override fun extendedObjectJson() = "/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow - extended.json" + + override fun wronglyExtendedObjectJson() = "/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow - wrongly extended.json" + + override fun build(): PasswordOAuthFlow { + return PasswordOAuthFlow.passwordBuilder() + .tokenUrl("https://example.com/api/oauth/token") + .refreshUrl("https://example.com/api/oauth/refresh") + .scopes(mapOf( + Pair("write:pets", "modify pets in your account"), + Pair("read:pets", "read your pets") + )) + .build() + } + +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/asyncapi - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/asyncapi - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/asyncapi - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/asyncapi - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/asyncapi - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/asyncapi - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/asyncapi - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/asyncapi - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/asyncapi.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/asyncapi.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/asyncapi.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/asyncapi.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/channel.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/channel.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/channel.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/channel.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/channelItem - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/channelItem - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/channelItem - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/channelItem - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/channelItem - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/channelItem - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/channelItem - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/channelItem - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/channelItem.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/channelItem.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/channelItem.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/channelItem.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/correlationId - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/correlationId - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/correlationId - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/correlationId - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/correlationId - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/correlationId - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/correlationId - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/correlationId - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/correlationId.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/correlationId.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/correlationId.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/correlationId.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/message - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/message - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/message - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/message - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/message - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/message - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/message - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/message - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/message.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/message.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/message.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/message.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/messageTrait - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/messageTrait - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/messageTrait - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/messageTrait - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/messageTrait - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/messageTrait - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/messageTrait - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/messageTrait - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/messageTrait.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/messageTrait.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/message/messageTrait.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/message/messageTrait.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with message - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with message - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with message - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with message - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with message - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with message - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with message - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with message - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with message.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with message.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with message.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with message.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with reference to message - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with reference to message - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with reference to message - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with reference to message - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with reference to message - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with reference to message - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with reference to message - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with reference to message - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with reference to message.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with reference to message.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operation with reference to message.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operation with reference to message.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operationTrait - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operationTrait - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operationTrait - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operationTrait - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operationTrait - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operationTrait - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operationTrait - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operationTrait - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operationTrait.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operationTrait.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/operation/operationTrait.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/operation/operationTrait.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/parameter - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/parameter - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/parameter - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/parameter - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/parameter - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/parameter - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/parameter - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/parameter - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/channel/parameter.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/parameter.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/channel/parameter.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/channel/parameter.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/components/components - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/components/components - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/components/components - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/components/components - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/components/components - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/components/components - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/components/components - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/components/components - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/components/components.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/components/components.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/components/components.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/components/components.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/externalDocumentation - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/externalDocumentation - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/externalDocumentation - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/externalDocumentation - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/externalDocumentation - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/externalDocumentation - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/externalDocumentation - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/externalDocumentation - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/externalDocumentation.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/externalDocumentation.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/externalDocumentation.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/externalDocumentation.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/info/contact - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/contact - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/info/contact - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/contact - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/info/contact - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/contact - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/info/contact - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/contact - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/info/contact.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/contact.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/info/contact.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/contact.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/info/info - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/info - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/info/info - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/info - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/info/info - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/info - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/info/info - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/info - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/info/info.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/info.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/info/info.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/info.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/info/license - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/license - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/info/license - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/license - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/info/license - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/license - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/info/license - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/license - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/info/license.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/license.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/info/license.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/info/license.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/reference.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/reference.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/reference.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/reference.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/server/server - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/server - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/server/server - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/server - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/server/server - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/server - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/server/server - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/server - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/server/server.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/server.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/server/server.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/server.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/server/serverVariable - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/serverVariable - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/server/serverVariable - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/serverVariable - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/server/serverVariable - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/serverVariable - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/server/serverVariable - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/serverVariable - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/server/serverVariable.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/serverVariable.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/server/serverVariable.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/server/serverVariable.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/tag - extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/tag - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/tag - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/tag - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/tag - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/tag - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/tag - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/tag - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.0.0/model/tag.json b/asyncapi-core/src/test/resources/json/v2/2.0.0/model/tag.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.0.0/model/tag.json rename to asyncapi-core/src/test/resources/json/v2/2.0.0/model/tag.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/asyncapi - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/asyncapi - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/asyncapi - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/asyncapi - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/asyncapi - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/asyncapi - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/asyncapi - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/asyncapi - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/asyncapi.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/asyncapi.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/asyncapi.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/asyncapi.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/channelItem - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/channelItem - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/channelItem - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/channelItem - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/channelItem - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/channelItem - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/channelItem - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/channelItem - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/channelItem.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/channelItem.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/channelItem.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/channelItem.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/correlationId - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/correlationId - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/correlationId - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/correlationId - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/correlationId - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/correlationId - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/correlationId - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/correlationId - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/correlationId.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/correlationId.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/correlationId.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/correlationId.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/message - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/message - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/message - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/message - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/message - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/message - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/message - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/message - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/message.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/message.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/message.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/message.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageExample - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageExample - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageExample - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageExample - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageExample - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageExample - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageExample - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageExample - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageExample.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageExample.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageExample.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageExample.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageTrait - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageTrait - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageTrait - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageTrait - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageTrait - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageTrait - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageTrait - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageTrait - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageTrait.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageTrait.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/messageTrait.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/messageTrait.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/oneOfMessages.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/oneOfMessages.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/message/oneOfMessages.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/message/oneOfMessages.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with message - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with message - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with message - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with message - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with message - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with message - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with message - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with message - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with message.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with message.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with message.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with message.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with oneOf message - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with oneOf message - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with oneOf message - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with oneOf message - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with oneOf message - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with oneOf message - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with oneOf message - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with oneOf message - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with oneOf message.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with oneOf message.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with oneOf message.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with oneOf message.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with reference to message - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with reference to message - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with reference to message - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with reference to message - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with reference to message - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with reference to message - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with reference to message - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with reference to message - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with reference to message.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with reference to message.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operation with reference to message.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operation with reference to message.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operationTrait - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operationTrait - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operationTrait - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operationTrait - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operationTrait - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operationTrait - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operationTrait - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operationTrait - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operationTrait.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operationTrait.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/operation/operationTrait.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/operation/operationTrait.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with reference to schema - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with reference to schema - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with reference to schema - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with reference to schema - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with reference to schema - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with reference to schema - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with reference to schema - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with reference to schema - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with reference to schema.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with reference to schema.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with reference to schema.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with reference to schema.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with schema - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with schema - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with schema - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with schema - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with schema - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with schema - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with schema - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with schema - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with schema.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with schema.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/channel/parameter with schema.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/channel/parameter with schema.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/components/components - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/components/components - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/components/components - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/components/components - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/components/components - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/components/components - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/components/components - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/components/components - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/components/components.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/components/components.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/components/components.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/components/components.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/externalDocumentation - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/externalDocumentation - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/externalDocumentation - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/externalDocumentation - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/externalDocumentation - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/externalDocumentation - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/externalDocumentation - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/externalDocumentation - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/externalDocumentation.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/externalDocumentation.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/externalDocumentation.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/externalDocumentation.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/info/contact - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/contact - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/info/contact - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/contact - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/info/contact - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/contact - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/info/contact - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/contact - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/info/contact.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/contact.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/info/contact.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/contact.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/info/info - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/info - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/info/info - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/info - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/info/info - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/info - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/info/info - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/info - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/info/info.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/info.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/info/info.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/info.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/info/license - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/license - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/info/license - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/license - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/info/license - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/license - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/info/license - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/license - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/info/license.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/license.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/info/license.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/info/license.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/reference.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/reference.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/reference.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/reference.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/server/server - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/server - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/server/server - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/server - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/server/server - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/server - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/server/server - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/server - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/server/server.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/server.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/server/server.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/server.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/server/serverVariable - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/serverVariable - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/server/serverVariable - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/serverVariable - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/server/serverVariable - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/serverVariable - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/server/serverVariable - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/serverVariable - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/server/serverVariable.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/serverVariable.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/server/serverVariable.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/server/serverVariable.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/tag - extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/tag - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/tag - extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/tag - extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/tag - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/tag - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/tag - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/tag - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/2.6.0/model/tag.json b/asyncapi-core/src/test/resources/json/v2/2.6.0/model/tag.json similarity index 100% rename from asyncapi-core/src/test/resources/json/2.6.0/model/tag.json rename to asyncapi-core/src/test/resources/json/v2/2.6.0/model/tag.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/amqp/amqpChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/amqp/amqpChannelBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/amqp/amqpChannelBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/amqp/amqpChannelBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/amqp/amqpChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/amqp/amqpChannelBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/amqp/amqpChannelBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/amqp/amqpChannelBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/amqp/amqpChannelBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/amqp/amqpChannelBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/amqp/amqpChannelBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/amqp/amqpChannelBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/anypoint/anypointMQChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/anypoint/anypointMQChannelBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/anypoint/anypointMQChannelBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/anypoint/anypointMQChannelBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/anypoint/anypointMQChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/anypoint/anypointMQChannelBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/anypoint/anypointMQChannelBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/anypoint/anypointMQChannelBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/anypoint/anypointMQChannelBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/anypoint/anypointMQChannelBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/anypoint/anypointMQChannelBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/anypoint/anypointMQChannelBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/googlepubsub/googlePubSubChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/googlepubsub/googlePubSubChannelBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/googlepubsub/googlePubSubChannelBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/googlepubsub/googlePubSubChannelBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/googlepubsub/googlePubSubChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/googlepubsub/googlePubSubChannelBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/googlepubsub/googlePubSubChannelBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/googlepubsub/googlePubSubChannelBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/googlepubsub/googlePubSubChannelBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/googlepubsub/googlePubSubChannelBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/googlepubsub/googlePubSubChannelBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/googlepubsub/googlePubSubChannelBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/ibmmq/ibmMQChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/ibmmq/ibmMQChannelBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/ibmmq/ibmMQChannelBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/ibmmq/ibmMQChannelBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/ibmmq/ibmMQChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/ibmmq/ibmMQChannelBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/ibmmq/ibmMQChannelBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/ibmmq/ibmMQChannelBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/ibmmq/ibmMQChannelBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/ibmmq/ibmMQChannelBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/ibmmq/ibmMQChannelBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/ibmmq/ibmMQChannelBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/kafka/kafkaChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/kafka/kafkaChannelBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/kafka/kafkaChannelBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/kafka/kafkaChannelBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/kafka/kafkaChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/kafka/kafkaChannelBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/kafka/kafkaChannelBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/kafka/kafkaChannelBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/kafka/kafkaChannelBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/kafka/kafkaChannelBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/kafka/kafkaChannelBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/kafka/kafkaChannelBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/pulsar/pulsarChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/pulsar/pulsarChannelBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/pulsar/pulsarChannelBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/pulsar/pulsarChannelBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/pulsar/pulsarChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/pulsar/pulsarChannelBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/pulsar/pulsarChannelBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/pulsar/pulsarChannelBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/pulsar/pulsarChannelBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/pulsar/pulsarChannelBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/pulsar/pulsarChannelBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/pulsar/pulsarChannelBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/ws/webSocketsChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/ws/webSocketsChannelBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/ws/webSocketsChannelBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/ws/webSocketsChannelBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/ws/webSocketsChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/ws/webSocketsChannelBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/ws/webSocketsChannelBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/ws/webSocketsChannelBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/channel/ws/webSocketsChannelBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/channel/ws/webSocketsChannelBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/channel/ws/webSocketsChannelBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/channel/ws/webSocketsChannelBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/amqp/amqpMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/amqp/amqpMessageBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/amqp/amqpMessageBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/amqp/amqpMessageBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/amqp/amqpMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/amqp/amqpMessageBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/amqp/amqpMessageBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/amqp/amqpMessageBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/amqp/amqpMessageBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/message/amqp/amqpMessageBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/amqp/amqpMessageBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/amqp/amqpMessageBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/anypointmq/anypointMQMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/anypointmq/anypointMQMessageBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/anypointmq/anypointMQMessageBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/anypointmq/anypointMQMessageBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/anypointmq/anypointMQMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/anypointmq/anypointMQMessageBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/anypointmq/anypointMQMessageBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/anypointmq/anypointMQMessageBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/anypointmq/anypointMQMessageBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/message/anypointmq/anypointMQMessageBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/anypointmq/anypointMQMessageBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/anypointmq/anypointMQMessageBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/googlepubsub/googlePubSubMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/googlepubsub/googlePubSubMessageBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/googlepubsub/googlePubSubMessageBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/googlepubsub/googlePubSubMessageBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/googlepubsub/googlePubSubMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/googlepubsub/googlePubSubMessageBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/googlepubsub/googlePubSubMessageBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/googlepubsub/googlePubSubMessageBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/googlepubsub/googlePubSubMessageBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/message/googlepubsub/googlePubSubMessageBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/googlepubsub/googlePubSubMessageBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/googlepubsub/googlePubSubMessageBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/http/httpMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/http/httpMessageBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/http/httpMessageBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/http/httpMessageBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/http/httpMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/http/httpMessageBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/http/httpMessageBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/http/httpMessageBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/http/httpMessageBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/message/http/httpMessageBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/http/httpMessageBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/http/httpMessageBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/ibmmq/ibmMQMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/ibmmq/ibmMQMessageBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/ibmmq/ibmMQMessageBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/ibmmq/ibmMQMessageBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/ibmmq/ibmMQMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/ibmmq/ibmMQMessageBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/ibmmq/ibmMQMessageBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/ibmmq/ibmMQMessageBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/ibmmq/ibmMQMessageBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/message/ibmmq/ibmMQMessageBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/ibmmq/ibmMQMessageBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/ibmmq/ibmMQMessageBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/kafka/kafkaMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/kafka/kafkaMessageBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/kafka/kafkaMessageBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/kafka/kafkaMessageBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/kafka/kafkaMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/kafka/kafkaMessageBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/kafka/kafkaMessageBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/kafka/kafkaMessageBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/kafka/kafkaMessageBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/message/kafka/kafkaMessageBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/kafka/kafkaMessageBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/kafka/kafkaMessageBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/mqtt/mqttMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/mqtt/mqttMessageBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/mqtt/mqttMessageBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/mqtt/mqttMessageBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/mqtt/mqttMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/message/mqtt/mqttMessageBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/mqtt/mqttMessageBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/mqtt/mqttMessageBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/message/mqtt/mqttMessageBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/message/mqtt/mqttMessageBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/message/mqtt/mqttMessageBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/message/mqtt/mqttMessageBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/amqp/amqpOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/amqp/amqpOperationBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/amqp/amqpOperationBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/amqp/amqpOperationBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/amqp/amqpOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/amqp/amqpOperationBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/amqp/amqpOperationBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/amqp/amqpOperationBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/amqp/amqpOperationBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/amqp/amqpOperationBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/amqp/amqpOperationBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/amqp/amqpOperationBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/http/httpOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/http/httpOperationBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/http/httpOperationBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/http/httpOperationBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/http/httpOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/http/httpOperationBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/http/httpOperationBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/http/httpOperationBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/http/httpOperationBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/http/httpOperationBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/http/httpOperationBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/http/httpOperationBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/kafka/kafkaOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/kafka/kafkaOperationBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/kafka/kafkaOperationBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/kafka/kafkaOperationBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/kafka/kafkaOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/kafka/kafkaOperationBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/kafka/kafkaOperationBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/kafka/kafkaOperationBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/kafka/kafkaOperationBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/kafka/kafkaOperationBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/kafka/kafkaOperationBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/kafka/kafkaOperationBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/mqtt/mqttOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/mqtt/mqttOperationBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/mqtt/mqttOperationBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/mqtt/mqttOperationBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/mqtt/mqttOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/mqtt/mqttOperationBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/mqtt/mqttOperationBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/mqtt/mqttOperationBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/mqtt/mqttOperationBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/mqtt/mqttOperationBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/mqtt/mqttOperationBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/mqtt/mqttOperationBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/nats/natsOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/nats/natsOperationBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/nats/natsOperationBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/nats/natsOperationBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/nats/natsOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/nats/natsOperationBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/nats/natsOperationBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/nats/natsOperationBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/nats/natsOperationBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/nats/natsOperationBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/nats/natsOperationBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/nats/natsOperationBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/solace/solaceOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/solace/solaceOperationBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/solace/solaceOperationBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/solace/solaceOperationBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/solace/solaceOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/solace/solaceOperationBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/solace/solaceOperationBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/solace/solaceOperationBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/operation/solace/solaceOperationBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/operation/solace/solaceOperationBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/operation/solace/solaceOperationBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/operation/solace/solaceOperationBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/ibmmq/ibmmqServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/ibmmq/ibmmqServerBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/ibmmq/ibmmqServerBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/ibmmq/ibmmqServerBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/ibmmq/ibmmqServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/ibmmq/ibmmqServerBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/ibmmq/ibmmqServerBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/ibmmq/ibmmqServerBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/ibmmq/ibmmqServerBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/server/ibmmq/ibmmqServerBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/ibmmq/ibmmqServerBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/ibmmq/ibmmqServerBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/kafka/kafkaServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/kafka/kafkaServerBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/kafka/kafkaServerBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/kafka/kafkaServerBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/kafka/kafkaServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/kafka/kafkaServerBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/kafka/kafkaServerBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/kafka/kafkaServerBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/kafka/kafkaServerBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/server/kafka/kafkaServerBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/kafka/kafkaServerBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/kafka/kafkaServerBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/mqtt/mqttServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/mqtt/mqttServerBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/mqtt/mqttServerBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/mqtt/mqttServerBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/mqtt/mqttServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/mqtt/mqttServerBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/mqtt/mqttServerBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/mqtt/mqttServerBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/mqtt/mqttServerBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/server/mqtt/mqttServerBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/mqtt/mqttServerBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/mqtt/mqttServerBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/mqtt5/mqtt5ServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/mqtt5/mqtt5ServerBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/mqtt5/mqtt5ServerBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/mqtt5/mqtt5ServerBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/mqtt5/mqtt5ServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/mqtt5/mqtt5ServerBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/mqtt5/mqtt5ServerBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/mqtt5/mqtt5ServerBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/mqtt5/mqtt5ServerBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/server/mqtt5/mqtt5ServerBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/mqtt5/mqtt5ServerBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/mqtt5/mqtt5ServerBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/pulsar/pulsarServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/pulsar/pulsarServerBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/pulsar/pulsarServerBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/pulsar/pulsarServerBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/pulsar/pulsarServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/pulsar/pulsarServerBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/pulsar/pulsarServerBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/pulsar/pulsarServerBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/pulsar/pulsarServerBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/server/pulsar/pulsarServerBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/pulsar/pulsarServerBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/pulsar/pulsarServerBinding.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/solace/solaceServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/solace/solaceServerBinding - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/solace/solaceServerBinding - extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/solace/solaceServerBinding - extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/solace/solaceServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/binding/server/solace/solaceServerBinding - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/solace/solaceServerBinding - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/solace/solaceServerBinding - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/binding/server/solace/solaceServerBinding.json b/asyncapi-core/src/test/resources/json/v2/binding/server/solace/solaceServerBinding.json similarity index 100% rename from asyncapi-core/src/test/resources/json/binding/server/solace/solaceServerBinding.json rename to asyncapi-core/src/test/resources/json/v2/binding/server/solace/solaceServerBinding.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/X509 - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/X509 - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/X509 - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/X509 - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/X509 - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/X509 - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/X509 - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/X509 - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/X509.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/X509.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/X509.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/X509.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/apiKey - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/apiKey - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/apiKey - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/apiKey - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/apiKey - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/apiKey - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/apiKey - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/apiKey - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/apiKey.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/apiKey.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/apiKey.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/apiKey.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/asymmetricEncryption - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/asymmetricEncryption - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/asymmetricEncryption - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/asymmetricEncryption - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/asymmetricEncryption - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/asymmetricEncryption - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/asymmetricEncryption - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/asymmetricEncryption - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/asymmetricEncryption.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/asymmetricEncryption.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/asymmetricEncryption.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/asymmetricEncryption.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/gssapi - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/gssapi - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/gssapi - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/gssapi - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/gssapi - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/gssapi - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/gssapi - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/gssapi - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/gssapi.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/gssapi.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/gssapi.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/gssapi.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/http/httpApiKey - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpApiKey - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/http/httpApiKey - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpApiKey - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/http/httpApiKey - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpApiKey - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/http/httpApiKey - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpApiKey - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/http/httpApiKey.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpApiKey.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/http/httpApiKey.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpApiKey.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/http/httpBasic - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBasic - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/http/httpBasic - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBasic - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/http/httpBasic - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBasic - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/http/httpBasic - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBasic - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/http/httpBasic.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBasic.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/http/httpBasic.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBasic.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/http/httpBearer - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBearer - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/http/httpBearer - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBearer - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/http/httpBearer - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBearer - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/http/httpBearer - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBearer - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/http/httpBearer.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBearer.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/http/httpBearer.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/http/httpBearer.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/authorizationCodeOAuthFlow.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/authorizationCodeOAuthFlow.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/authorizationCodeOAuthFlow.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/authorizationCodeOAuthFlow.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/clientCredentialsOAuthFlow.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/clientCredentialsOAuthFlow.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/clientCredentialsOAuthFlow.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/clientCredentialsOAuthFlow.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/implicitOAuthFlow - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/implicitOAuthFlow - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/implicitOAuthFlow - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/implicitOAuthFlow - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/implicitOAuthFlow - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/implicitOAuthFlow - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/implicitOAuthFlow - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/implicitOAuthFlow - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/implicitOAuthFlow.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/implicitOAuthFlow.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/implicitOAuthFlow.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/implicitOAuthFlow.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/oauthFlow - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/oauthFlow - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/oauthFlow - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/oauthFlow - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/oauthFlow - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/oauthFlow - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/oauthFlow - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/oauthFlow - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/oauthFlow.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/oauthFlow.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/oauthFlow.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/oauthFlow.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/passwordOAuthFlow - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/passwordOAuthFlow - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/passwordOAuthFlow - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/passwordOAuthFlow - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/passwordOAuthFlow - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/passwordOAuthFlow - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/passwordOAuthFlow - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/passwordOAuthFlow - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/passwordOAuthFlow.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/passwordOAuthFlow.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/flow/passwordOAuthFlow.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/flow/passwordOAuthFlow.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauth2 - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauth2 - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauth2 - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauth2 - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauth2 - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauth2 - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauth2 - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauth2 - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauth2.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauth2.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauth2.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauth2.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauthFlows - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauthFlows - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauthFlows - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauthFlows - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauthFlows - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauthFlows - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauthFlows - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauthFlows - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauthFlows.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauthFlows.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/oauth2/oauthFlows.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/oauth2/oauthFlows.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/openIdConnect - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/openIdConnect - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/openIdConnect - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/openIdConnect - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/openIdConnect - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/openIdConnect - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/openIdConnect - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/openIdConnect - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/openIdConnect.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/openIdConnect.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/openIdConnect.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/openIdConnect.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/plain - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/plain - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/plain - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/plain - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/plain - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/plain - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/plain - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/plain - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/plain.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/plain.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/plain.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/plain.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/scramSha256 - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha256 - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/scramSha256 - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha256 - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/scramSha256 - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha256 - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/scramSha256 - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha256 - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/scramSha256.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha256.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/scramSha256.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha256.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/scramSha512 - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha512 - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/scramSha512 - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha512 - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/scramSha512 - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha512 - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/scramSha512 - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha512 - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/scramSha512.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha512.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/scramSha512.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/scramSha512.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/symmetricEncryption - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/symmetricEncryption - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/symmetricEncryption - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/symmetricEncryption - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/symmetricEncryption - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/symmetricEncryption - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/symmetricEncryption - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/symmetricEncryption - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/symmetricEncryption.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/symmetricEncryption.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/symmetricEncryption.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/symmetricEncryption.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/userPassword - extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/userPassword - extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/userPassword - extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/userPassword - extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/userPassword - wrongly extended.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/userPassword - wrongly extended.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/userPassword - wrongly extended.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/userPassword - wrongly extended.json diff --git a/asyncapi-core/src/test/resources/json/security_scheme/userPassword.json b/asyncapi-core/src/test/resources/json/v2/security_scheme/userPassword.json similarity index 100% rename from asyncapi-core/src/test/resources/json/security_scheme/userPassword.json rename to asyncapi-core/src/test/resources/json/v2/security_scheme/userPassword.json diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/asyncapi - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/asyncapi - extended.json new file mode 100644 index 00000000..f984dcc6 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/asyncapi - extended.json @@ -0,0 +1,13106 @@ +{ + "asyncapi" : "3.0.0", + "id" : "https://www.asyncapi.com", + "defaultContentType" : "application/json", + "info" : { + "title" : "AsyncApi sample", + "version" : "2.0", + "description" : "short description", + "termsOfService" : "https://www.asyncapi.com/about/", + "contact" : { + "name" : "AsyncApi", + "url" : "https://www.asyncapi.com", + "email" : "java@asyncapi.com" + }, + "license" : { + "name" : "Apache License 2.0", + "url" : "http://www.apache.org/licenses/" + }, + "tags" : [ { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "servers" : { + "server 1" : { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "default" : "demo" + }, + "port" : { + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment" + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "server 2" : { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "default" : "demo" + }, + "port" : { + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + }, { + "$ref" : "#/components/securitySchemes/openId" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment" + }, { + "$ref" : "#/components/tags/tag_name" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/externalDoc" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "server 3" : { + "$ref" : "#/components/servers/server" + } + }, + "channels" : { + "channel 1" : { + "address" : "users.{userId}", + "title" : "Users channel", + "summary" : "messages about user events.", + "description" : "This channel is used to exchange messages about users signing up", + "servers" : [ { + "$ref" : "#/components/servers/1" + }, { + "$ref" : "#/components/servers/2" + }, { + "$ref" : "#/components/servers/3" + } ], + "parameters" : { + "userId" : { + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ] + }, + "userStatus" : { + "$ref" : "#/components/parameters/user-status" + } + }, + "messages" : { + "changeStatus" : { + "$ref" : "#/components/parameters/user-status" + }, + "message" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "message 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message with reference" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } + }, + "bindings" : { + "amqp" : { + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/channelBindings/amqp1" + }, + "anypointmq" : { + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "$ref" : "#/components/channelBindings/http" + }, + "ibmmq" : { + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/channelBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + } + }, + "mercure" : { + "$ref" : "#/components/channelBindings/mercure" + }, + "mqtt" : { + "$ref" : "#/components/channelBindings/mqtt" + }, + "mqtt5" : { + "$ref" : "#/components/channelBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/channelBindings/nats" + }, + "pulsar" : { + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0" + }, + "redis" : { + "$ref" : "#/components/channelBindings/redis" + }, + "sns" : { + "$ref" : "#/components/channelBindings/sns" + }, + "solace" : { + "$ref" : "#/components/channelBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/channelBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/channelBindings/stomp" + }, + "ws" : { + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0" + } + }, + "tags" : [ { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, { + "$ref" : "#/components/tag" + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "channel 2" : { + "address" : "users.{userId}", + "title" : "Users channel", + "summary" : "messages about user events.", + "description" : "This channel is used to exchange messages about users signing up", + "servers" : [ { + "$ref" : "#/components/servers/1" + }, { + "$ref" : "#/components/servers/2" + }, { + "$ref" : "#/components/servers/3" + } ], + "parameters" : { + "userId" : { + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ] + }, + "userStatus" : { + "$ref" : "#/components/parameters/user-status" + } + }, + "messages" : { + "changeStatus" : { + "$ref" : "#/components/parameters/user-status" + }, + "message" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "message 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message with reference" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } + }, + "bindings" : { + "amqp" : { + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/channelBindings/amqp1" + }, + "anypointmq" : { + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "$ref" : "#/components/channelBindings/http" + }, + "ibmmq" : { + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/channelBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + } + }, + "mercure" : { + "$ref" : "#/components/channelBindings/mercure" + }, + "mqtt" : { + "$ref" : "#/components/channelBindings/mqtt" + }, + "mqtt5" : { + "$ref" : "#/components/channelBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/channelBindings/nats" + }, + "pulsar" : { + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0" + }, + "redis" : { + "$ref" : "#/components/channelBindings/redis" + }, + "sns" : { + "$ref" : "#/components/channelBindings/sns" + }, + "solace" : { + "$ref" : "#/components/channelBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/channelBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/channelBindings/stomp" + }, + "ws" : { + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0" + } + }, + "tags" : [ { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, { + "$ref" : "#/components/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "channel 3" : { + "$ref" : "#/components/channels/channel" + } + }, + "operations" : { + "operation 1" : { + "action" : "send", + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "traits" : [ { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, { + "$ref" : "#/components/operations/trait" + } ], + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, + "operation 2" : { + "action" : "receive", + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "traits" : [ { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, { + "$ref" : "#/components/operations/trait" + } ], + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, + "operation 3" : { + "$ref" : "#/components/operations/operation" + } + }, + "components" : { + "schemas" : { + "Category" : { + "type" : "object", + "properties" : { + "id" : { + "type" : "integer", + "format" : "int64" + }, + "name" : { + "type" : "string" + } + } + }, + "Tag" : { + "schemaFormat" : "application/json", + "schema" : { + "type" : "object", + "properties" : { + "id" : { + "type" : "integer", + "format" : "int64" + }, + "name" : { + "type" : "string" + } + } + } + }, + "User" : { + "$ref" : "#/components/schemas/user" + } + }, + "servers" : { + "mqtt-test" : { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "default" : "demo" + }, + "port" : { + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment" + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "mqtt-stage" : { + "$ref" : "#/components/servers/mqtt-stage" + } + }, + "serverVariables" : { + "port" : { + "description" : "To which port connect", + "examples" : [ "8883", "8884" ], + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "channels" : { + "channel 1" : { + "address" : "users.{userId}", + "title" : "Users channel", + "summary" : "messages about user events.", + "description" : "This channel is used to exchange messages about users signing up", + "servers" : [ { + "$ref" : "#/components/servers/1" + }, { + "$ref" : "#/components/servers/2" + }, { + "$ref" : "#/components/servers/3" + } ], + "parameters" : { + "userId" : { + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ] + }, + "userStatus" : { + "$ref" : "#/components/parameters/user-status" + } + }, + "messages" : { + "changeStatus" : { + "$ref" : "#/components/parameters/user-status" + }, + "message" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "message 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message with reference" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } + }, + "bindings" : { + "amqp" : { + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/channelBindings/amqp1" + }, + "anypointmq" : { + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "$ref" : "#/components/channelBindings/http" + }, + "ibmmq" : { + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/channelBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + } + }, + "mercure" : { + "$ref" : "#/components/channelBindings/mercure" + }, + "mqtt" : { + "$ref" : "#/components/channelBindings/mqtt" + }, + "mqtt5" : { + "$ref" : "#/components/channelBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/channelBindings/nats" + }, + "pulsar" : { + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0" + }, + "redis" : { + "$ref" : "#/components/channelBindings/redis" + }, + "sns" : { + "$ref" : "#/components/channelBindings/sns" + }, + "solace" : { + "$ref" : "#/components/channelBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/channelBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/channelBindings/stomp" + }, + "ws" : { + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0" + } + }, + "tags" : [ { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, { + "$ref" : "#/components/tag" + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "channel 2" : { + "address" : "users.{userId}", + "title" : "Users channel", + "summary" : "messages about user events.", + "description" : "This channel is used to exchange messages about users signing up", + "servers" : [ { + "$ref" : "#/components/servers/1" + }, { + "$ref" : "#/components/servers/2" + }, { + "$ref" : "#/components/servers/3" + } ], + "parameters" : { + "userId" : { + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ] + }, + "userStatus" : { + "$ref" : "#/components/parameters/user-status" + } + }, + "messages" : { + "changeStatus" : { + "$ref" : "#/components/parameters/user-status" + }, + "message" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "message 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message with reference" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } + }, + "bindings" : { + "amqp" : { + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/channelBindings/amqp1" + }, + "anypointmq" : { + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "$ref" : "#/components/channelBindings/http" + }, + "ibmmq" : { + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/channelBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + } + }, + "mercure" : { + "$ref" : "#/components/channelBindings/mercure" + }, + "mqtt" : { + "$ref" : "#/components/channelBindings/mqtt" + }, + "mqtt5" : { + "$ref" : "#/components/channelBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/channelBindings/nats" + }, + "pulsar" : { + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0" + }, + "redis" : { + "$ref" : "#/components/channelBindings/redis" + }, + "sns" : { + "$ref" : "#/components/channelBindings/sns" + }, + "solace" : { + "$ref" : "#/components/channelBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/channelBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/channelBindings/stomp" + }, + "ws" : { + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0" + } + }, + "tags" : [ { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, { + "$ref" : "#/components/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "channel 3" : { + "$ref" : "#/components/channels/channel" + } + }, + "operations" : { + "operation 1" : { + "action" : "send", + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "traits" : [ { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, { + "$ref" : "#/components/operations/trait" + } ], + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, + "operation 2" : { + "action" : "receive", + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "traits" : [ { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, { + "$ref" : "#/components/operations/trait" + } ], + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, + "operation 3" : { + "$ref" : "#/components/operations/operation" + } + }, + "replies" : { + "reply 1" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + }, + "reply 2" : { + "address" : { + "$ref" : "#/components/addresses/address" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + }, + "reply 3" : { + "$ref" : "#/components/replies/reply" + } + }, + "replyAddresses" : { + "reply addresses 1" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "reply addresses 2" : { + "$ref" : "#/components/replyAddresses/replyAddress" + } + }, + "messages" : { + "message 1" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "message 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message 3" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message 4" : { + "$ref" : "#/components/messages/message" + } + }, + "securitySchemes" : { + "apiKey" : { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, + "asymmetricEncryption" : { + "$ref" : "#/components/securitySchemes/asymmetricEncryption" + }, + "gssapi" : { + "$ref" : "#/components/securitySchemes/gssapi" + }, + "oauth2" : { + "type" : "oauth2", + "description" : "oauth2", + "flows" : { + "implicit" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "authorizationUrl" : "https://example.com/api/oauth/dialog" + }, + "password" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "tokenUrl" : "https://example.com/api/oauth/token" + }, + "clientCredentials" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "tokenUrl" : "https://example.com/api/oauth/token" + }, + "authorizationCode" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "authorizationUrl" : "https://example.com/api/oauth/dialog", + "tokenUrl" : "https://example.com/api/oauth/token" + } + }, + "scopes" : [ "write:pets", "read:pets" ] + }, + "openIdConnect" : { + "type" : "openIdConnect", + "description" : "openIdConnect", + "openIdConnectUrl" : "https://server.com/.well-known/openid-configuration", + "scopes" : [ "write:pets", "read:pets" ] + }, + "httpApiKey" : { + "type" : "httpApiKey", + "description" : "httpApiKey", + "name" : "api_key", + "in" : "header" + }, + "httpBasic" : { + "type" : "http", + "description" : "http", + "scheme" : "basic" + }, + "httpBearer" : { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + }, + "plain" : { + "$ref" : "#/components/securitySchemes/plain" + }, + "scramSha256" : { + "$ref" : "#/components/securitySchemes/scramSha256" + }, + "scramSha512" : { + "$ref" : "#/components/securitySchemes/scramSha512" + }, + "symmetricEncryption" : { + "$ref" : "#/components/securitySchemes/symmetricEncryption" + }, + "userPassword" : { + "$ref" : "#/components/securitySchemes/userPassword" + }, + "X509" : { + "$ref" : "#/components/securitySchemes/X509" + } + }, + "parameters" : { + "parameter 1" : { + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ] + }, + "parameter 2" : { + "$ref" : "#/components/parameters/parameter" + } + }, + "correlationIds" : { + "correlationId 1" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "correlationId 2" : { + "$ref" : "#/correlationIds/parameters/correlationId" + } + }, + "operationTraits" : { + "operationTrait 1" : { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, + "operationTrait 2" : { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, + "operationTrait 3" : { + "$ref" : "#/components/operationTraits/operationTrait" + } + }, + "messageTraits" : { + "messageTrait 1" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "messageTrait 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "messageTrait 3" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "messageTrait 4" : { + "$ref" : "#/components/messageTraits/messageTrait" + } + }, + "serverBindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + }, + "channelBindings" : { + "amqp" : { + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/channelBindings/amqp1" + }, + "anypointmq" : { + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "$ref" : "#/components/channelBindings/http" + }, + "ibmmq" : { + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/channelBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + } + }, + "mercure" : { + "$ref" : "#/components/channelBindings/mercure" + }, + "mqtt" : { + "$ref" : "#/components/channelBindings/mqtt" + }, + "mqtt5" : { + "$ref" : "#/components/channelBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/channelBindings/nats" + }, + "pulsar" : { + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0" + }, + "redis" : { + "$ref" : "#/components/channelBindings/redis" + }, + "sns" : { + "$ref" : "#/components/channelBindings/sns" + }, + "solace" : { + "$ref" : "#/components/channelBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/channelBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/channelBindings/stomp" + }, + "ws" : { + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0" + } + }, + "operationBindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messageBindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "externalDocs" : { + "externalDoc 1" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "externalDoc 2" : { + "$ref" : "#/components/externalDocs/externalDoc" + } + }, + "tags" : { + "tag 1" : { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "tag 2" : { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "tag 3" : { + "$ref" : "#/components/tags/tag" + } + } + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/asyncapi - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/asyncapi - wrongly extended.json new file mode 100644 index 00000000..e094a307 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/asyncapi - wrongly extended.json @@ -0,0 +1,13973 @@ +{ + "asyncapi": "3.0.0", + "id": "https://www.asyncapi.com", + "defaultContentType": "application/json", + "info": { + "title": "AsyncApi sample", + "version": "2.0", + "description": "short description", + "termsOfService": "https://www.asyncapi.com/about/", + "contact": { + "name": "AsyncApi", + "url": "https://www.asyncapi.com", + "email": "java@asyncapi.com" + }, + "license": { + "name": "Apache License 2.0", + "url": "http://www.apache.org/licenses/" + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + } + ], + "externalDocs": { + "description": "Find more info here", + "url": "https://example.com" + } + }, + "servers": { + "server 1": { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "server 2": { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + }, { + "$ref" : "#/components/securitySchemes/openId" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + }, { + "$ref" : "#/components/tags/tag_name" + }], + "externalDocs" : { + "$ref" : "#/components/externalDocs/externalDoc" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "server 3": { + "$ref": "#/components/servers/server" + } + }, + "channels": { + "channel 1": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "channel 2": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "channel 3": { + "$ref": "#/components/channels/channel" + } + }, + "operations": { + "operation 1": { + "action": "send", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + "operation 2": { + "action": "receive", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + "operation 3": { + "$ref": "#/components/operations/operation" + } + }, + "components": { + "schemas": { + "Category": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int64" + }, + "name": { + "type": "string" + } + } + }, + "Tag": { + "schemaFormat": "application/json", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int64" + }, + "name": { + "type": "string" + } + } + } + }, + "User": { + "$ref": "#/components/schemas/user" + } + }, + "servers": { + "mqtt-test": { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "mqtt-stage": { + "$ref": "#/components/servers/mqtt-stage" + } + }, + "serverVariables": { + "port": { + "enum": [ + "8883", + "8884" + ], + "default": "8883", + "description": "To which port connect", + "examples": [ + "8883", + "8884" + ] + }, + "basePath": { + "$ref": "#/components/serverVariables/basePath" + } + }, + "channels": { + "channel 1": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "channel 2": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "channel 3": { + "$ref": "#/components/channels/channel" + } + }, + "operations": { + "operation 1": { + "action": "send", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + "operation 2": { + "action": "receive", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + "operation 3": { + "$ref": "#/components/operations/operation" + } + }, + "replies": { + "reply 1": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + }, + "reply 2": { + "address": { + "$ref": "#/components/addresses/address" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + }, + "reply 3": { + "$ref": "#/components/replies/reply" + } + }, + "replyAddresses": { + "reply addresses 1": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "reply addresses 2": { + "$ref": "#/components/replyAddresses/replyAddress" + } + }, + "messages": { + "message 1": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 3": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 4": { + "$ref": "#/components/messages/message" + } + }, + "securitySchemes": { + "apiKey": { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + "asymmetricEncryption": { + "$ref": "#/components/securitySchemes/asymmetricEncryption" + }, + "gssapi": { + "$ref": "#/components/securitySchemes/gssapi" + }, + "oauth2": { + "type": "oauth2", + "description": "oauth2", + "flows": { + "authorizationCode": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "clientCredentials": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "implicit": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "password": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + } + }, + "scopes": [ "write:pets", "read:pets" ] + }, + "openIdConnect": { + "type": "openIdConnect", + "description": "openIdConnect", + "openIdConnectUrl": "https://server.com/.well-known/openid-configuration", + "scopes": [ + "write:pets", + "read:pets" + ] + }, + "httpApiKey": { + "type": "httpApiKey", + "description": "httpApiKey", + "name": "api_key", + "in": "header" + }, + "httpBasic": { + "type": "http", + "description": "http", + "scheme": "basic" + }, + "httpBearer": { + "type": "http", + "description": "http", + "scheme": "bearer", + "bearerFormat": "JWT" + }, + "plain": { + "$ref": "#/components/securitySchemes/plain" + }, + "scramSha256": { + "$ref": "#/components/securitySchemes/scramSha256" + }, + "scramSha512": { + "$ref": "#/components/securitySchemes/scramSha512" + }, + "symmetricEncryption": { + "$ref": "#/components/securitySchemes/symmetricEncryption" + }, + "userPassword": { + "$ref": "#/components/securitySchemes/userPassword" + }, + "X509": { + "$ref": "#/components/securitySchemes/X509" + } + }, + "parameters": { + "parameter 1": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "parameter 2": { + "$ref": "#/components/parameters/parameter" + } + }, + "correlationIds": { + "correlationId 1": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "correlationId 2": { + "$ref": "#/correlationIds/parameters/correlationId" + } + }, + "operationTraits": { + "operationTrait 1": { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + "operationTrait 2": { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + "operationTrait 3": { + "$ref": "#/components/operationTraits/operationTrait" + } + }, + "messageTraits": { + "messageTrait 1": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 3": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 4": { + "$ref": "#/components/messageTraits/messageTrait" + } + }, + "serverBindings": { + "amqp": { + "$ref": "#/components/serverBindings/amqp" + }, + "amqp1": {}, + "anypointmq": {}, + "googlepubsub": {}, + "http": {}, + "ibmmq": { + "groupId": "PRODCLSTR1", + "ccdtQueueManagerName": "*", + "multiEndpointServer": false, + "heartBeatInterval": 300, + "cipherSpec": "ANY_TLS12_OR_HIGHER", + "bindingVersion": "0.1.0" + }, + "jms": {}, + "kafka": { + "schemaRegistryUrl": "https://my-schema-registry.com", + "schemaRegistryVendor": "confluent", + "bindingVersion": "0.4.0" + }, + "mercure": {}, + "mqtt": { + "clientId": "guest", + "cleanSession": true, + "lastWill": { + "topic": "/last-wills", + "qos": 2, + "message": "Guest gone offline.", + "retain": false + }, + "keepAlive": 60, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "sessionExpiryInterval": 60, + "bindingVersion": "0.2.0" + }, + "nats": {}, + "pulsar": { + "tenant": "contoso", + "bindingVersion": "0.1.0" + }, + "redis": {}, + "sns": {}, + "solace": { + "msgVpn": "solace.private.net", + "bindingVersion": "0.3.0" + }, + "sqs": {}, + "stomp": {}, + "ws": {} + }, + "channelBindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "operationBindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messageBindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "externalDocs": { + "externalDoc 1": { + "description": "Find more info here", + "url": "https://example.com" + }, + "externalDoc 2": { + "$ref": "#/components/externalDocs/externalDoc" + } + }, + "tags": { + "tag 1": { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "tag 2": { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + "tag 3": { + "$ref": "#/components/tags/tag" + } + } + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/asyncapi.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/asyncapi.json new file mode 100644 index 00000000..ee0257c0 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/asyncapi.json @@ -0,0 +1,13967 @@ +{ + "asyncapi": "3.0.0", + "id": "https://www.asyncapi.com", + "defaultContentType": "application/json", + "info": { + "title": "AsyncApi sample", + "version": "2.0", + "description": "short description", + "termsOfService": "https://www.asyncapi.com/about/", + "contact": { + "name": "AsyncApi", + "url": "https://www.asyncapi.com", + "email": "java@asyncapi.com" + }, + "license": { + "name": "Apache License 2.0", + "url": "http://www.apache.org/licenses/" + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + } + ], + "externalDocs": { + "description": "Find more info here", + "url": "https://example.com" + } + }, + "servers": { + "server 1": { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "server 2": { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + }, { + "$ref" : "#/components/securitySchemes/openId" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + }, { + "$ref" : "#/components/tags/tag_name" + }], + "externalDocs" : { + "$ref" : "#/components/externalDocs/externalDoc" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "server 3": { + "$ref": "#/components/servers/server" + } + }, + "channels": { + "channel 1": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "channel 2": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "channel 3": { + "$ref": "#/components/channels/channel" + } + }, + "operations": { + "operation 1": { + "action": "send", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + "operation 2": { + "action": "receive", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + "operation 3": { + "$ref": "#/components/operations/operation" + } + }, + "components": { + "schemas": { + "Category": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int64" + }, + "name": { + "type": "string" + } + } + }, + "Tag": { + "schemaFormat": "application/json", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int64" + }, + "name": { + "type": "string" + } + } + } + }, + "User": { + "$ref": "#/components/schemas/user" + } + }, + "servers": { + "mqtt-test": { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "mqtt-stage": { + "$ref": "#/components/servers/mqtt-stage" + } + }, + "serverVariables": { + "port": { + "enum": [ + "8883", + "8884" + ], + "default": "8883", + "description": "To which port connect", + "examples": [ + "8883", + "8884" + ] + }, + "basePath": { + "$ref": "#/components/serverVariables/basePath" + } + }, + "channels": { + "channel 1": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "channel 2": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "channel 3": { + "$ref": "#/components/channels/channel" + } + }, + "operations": { + "operation 1": { + "action": "send", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + "operation 2": { + "action": "receive", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + "operation 3": { + "$ref": "#/components/operations/operation" + } + }, + "replies": { + "reply 1": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + }, + "reply 2": { + "address": { + "$ref": "#/components/addresses/address" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + }, + "reply 3": { + "$ref": "#/components/replies/reply" + } + }, + "replyAddresses": { + "reply addresses 1": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "reply addresses 2": { + "$ref": "#/components/replyAddresses/replyAddress" + } + }, + "messages": { + "message 1": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 3": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 4": { + "$ref": "#/components/messages/message" + } + }, + "securitySchemes": { + "apiKey": { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + "asymmetricEncryption": { + "$ref": "#/components/securitySchemes/asymmetricEncryption" + }, + "gssapi": { + "$ref": "#/components/securitySchemes/gssapi" + }, + "oauth2": { + "type": "oauth2", + "description": "oauth2", + "flows": { + "authorizationCode": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "clientCredentials": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "implicit": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "password": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + } + }, + "scopes": [ "write:pets", "read:pets" ] + }, + "openIdConnect": { + "type": "openIdConnect", + "description": "openIdConnect", + "openIdConnectUrl": "https://server.com/.well-known/openid-configuration", + "scopes": [ + "write:pets", + "read:pets" + ] + }, + "httpApiKey": { + "type": "httpApiKey", + "description": "httpApiKey", + "name": "api_key", + "in": "header" + }, + "httpBasic": { + "type": "http", + "description": "http", + "scheme": "basic" + }, + "httpBearer": { + "type": "http", + "description": "http", + "scheme": "bearer", + "bearerFormat": "JWT" + }, + "plain": { + "$ref": "#/components/securitySchemes/plain" + }, + "scramSha256": { + "$ref": "#/components/securitySchemes/scramSha256" + }, + "scramSha512": { + "$ref": "#/components/securitySchemes/scramSha512" + }, + "symmetricEncryption": { + "$ref": "#/components/securitySchemes/symmetricEncryption" + }, + "userPassword": { + "$ref": "#/components/securitySchemes/userPassword" + }, + "X509": { + "$ref": "#/components/securitySchemes/X509" + } + }, + "parameters": { + "parameter 1": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "parameter 2": { + "$ref": "#/components/parameters/parameter" + } + }, + "correlationIds": { + "correlationId 1": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "correlationId 2": { + "$ref": "#/correlationIds/parameters/correlationId" + } + }, + "operationTraits": { + "operationTrait 1": { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + "operationTrait 2": { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + "operationTrait 3": { + "$ref": "#/components/operationTraits/operationTrait" + } + }, + "messageTraits": { + "messageTrait 1": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 3": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 4": { + "$ref": "#/components/messageTraits/messageTrait" + } + }, + "serverBindings": { + "amqp": { + "$ref": "#/components/serverBindings/amqp" + }, + "amqp1": {}, + "anypointmq": {}, + "googlepubsub": {}, + "http": {}, + "ibmmq": { + "groupId": "PRODCLSTR1", + "ccdtQueueManagerName": "*", + "multiEndpointServer": false, + "heartBeatInterval": 300, + "cipherSpec": "ANY_TLS12_OR_HIGHER", + "bindingVersion": "0.1.0" + }, + "jms": {}, + "kafka": { + "schemaRegistryUrl": "https://my-schema-registry.com", + "schemaRegistryVendor": "confluent", + "bindingVersion": "0.4.0" + }, + "mercure": {}, + "mqtt": { + "clientId": "guest", + "cleanSession": true, + "lastWill": { + "topic": "/last-wills", + "qos": 2, + "message": "Guest gone offline.", + "retain": false + }, + "keepAlive": 60, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "sessionExpiryInterval": 60, + "bindingVersion": "0.2.0" + }, + "nats": {}, + "pulsar": { + "tenant": "contoso", + "bindingVersion": "0.1.0" + }, + "redis": {}, + "sns": {}, + "solace": { + "msgVpn": "solace.private.net", + "bindingVersion": "0.3.0" + }, + "sqs": {}, + "stomp": {}, + "ws": {} + }, + "channelBindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "operationBindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messageBindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "externalDocs": { + "externalDoc 1": { + "description": "Find more info here", + "url": "https://example.com" + }, + "externalDoc 2": { + "$ref": "#/components/externalDocs/externalDoc" + } + }, + "tags": { + "tag 1": { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "tag 2": { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + "tag 3": { + "$ref": "#/components/tags/tag" + } + } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel - extended.json new file mode 100644 index 00000000..72243656 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel - extended.json @@ -0,0 +1,1934 @@ +{ + "address" : "users.{userId}", + "title" : "Users channel", + "summary" : "messages about user events.", + "description" : "This channel is used to exchange messages about users signing up", + "servers" : [ { + "$ref" : "#/components/servers/1" + }, { + "$ref" : "#/components/servers/2" + }, { + "$ref" : "#/components/servers/3" + } ], + "parameters" : { + "userId" : { + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ] + }, + "userStatus" : { + "$ref" : "#/components/parameters/user-status" + } + }, + "messages" : { + "changeStatus" : { + "$ref" : "#/components/parameters/user-status" + }, + "message" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "message 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message with reference" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } + }, + "bindings" : { + "amqp" : { + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/channelBindings/amqp1" + }, + "anypointmq" : { + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "$ref" : "#/components/channelBindings/http" + }, + "ibmmq" : { + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/channelBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + } + }, + "mercure" : { + "$ref" : "#/components/channelBindings/mercure" + }, + "mqtt" : { + "$ref" : "#/components/channelBindings/mqtt" + }, + "mqtt5" : { + "$ref" : "#/components/channelBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/channelBindings/nats" + }, + "pulsar" : { + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0" + }, + "redis" : { + "$ref" : "#/components/channelBindings/redis" + }, + "sns" : { + "$ref" : "#/components/channelBindings/sns" + }, + "solace" : { + "$ref" : "#/components/channelBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/channelBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/channelBindings/stomp" + }, + "ws" : { + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0" + } + }, + "tags" : [ { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, { + "$ref" : "#/components/tag" + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel - wrongly extended.json new file mode 100644 index 00000000..97175680 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel - wrongly extended.json @@ -0,0 +1,2012 @@ +{ + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel with reference - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel with reference - extended.json new file mode 100644 index 00000000..dcc4605f --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel with reference - extended.json @@ -0,0 +1,1933 @@ +{ + "address" : "users.{userId}", + "title" : "Users channel", + "summary" : "messages about user events.", + "description" : "This channel is used to exchange messages about users signing up", + "servers" : [ { + "$ref" : "#/components/servers/1" + }, { + "$ref" : "#/components/servers/2" + }, { + "$ref" : "#/components/servers/3" + } ], + "parameters" : { + "userId" : { + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ] + }, + "userStatus" : { + "$ref" : "#/components/parameters/user-status" + } + }, + "messages" : { + "changeStatus" : { + "$ref" : "#/components/parameters/user-status" + }, + "message" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "message 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message with reference" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } + }, + "bindings" : { + "amqp" : { + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/channelBindings/amqp1" + }, + "anypointmq" : { + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "$ref" : "#/components/channelBindings/http" + }, + "ibmmq" : { + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/channelBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + } + }, + "mercure" : { + "$ref" : "#/components/channelBindings/mercure" + }, + "mqtt" : { + "$ref" : "#/components/channelBindings/mqtt" + }, + "mqtt5" : { + "$ref" : "#/components/channelBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/channelBindings/nats" + }, + "pulsar" : { + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0" + }, + "redis" : { + "$ref" : "#/components/channelBindings/redis" + }, + "sns" : { + "$ref" : "#/components/channelBindings/sns" + }, + "solace" : { + "$ref" : "#/components/channelBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/channelBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/channelBindings/stomp" + }, + "ws" : { + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0" + } + }, + "tags" : [ { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, { + "$ref" : "#/components/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel with reference - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel with reference - wrongly extended.json new file mode 100644 index 00000000..9efbe3a8 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel with reference - wrongly extended.json @@ -0,0 +1,2011 @@ +{ + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs": { + "$ref": "#/components/external-doc" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel with reference.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel with reference.json new file mode 100644 index 00000000..d60772f8 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel with reference.json @@ -0,0 +1,2005 @@ +{ + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel.json new file mode 100644 index 00000000..35db9993 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/channel.json @@ -0,0 +1,2006 @@ +{ + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/correlationId - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/correlationId - extended.json new file mode 100644 index 00000000..47474f2f --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/correlationId - extended.json @@ -0,0 +1,9 @@ +{ + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/correlationId - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/correlationId - wrongly extended.json new file mode 100644 index 00000000..199ca7a9 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/correlationId - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "description": "Default Correlation ID", + "location": "$message.header#/correlationId", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/correlationId.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/correlationId.json new file mode 100644 index 00000000..2e50f550 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/correlationId.json @@ -0,0 +1,4 @@ +{ + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message - extended.json new file mode 100644 index 00000000..18ef0098 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message - extended.json @@ -0,0 +1,589 @@ +{ + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message - wrongly extended.json new file mode 100644 index 00000000..5a27b02c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message - wrongly extended.json @@ -0,0 +1,608 @@ +{ + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ], + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message 2 - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message 2 - extended.json new file mode 100644 index 00000000..d671c764 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message 2 - extended.json @@ -0,0 +1,595 @@ +{ + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message 2 - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message 2 - wrongly extended.json new file mode 100644 index 00000000..f80d7fc1 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message 2 - wrongly extended.json @@ -0,0 +1,613 @@ +{ + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ], + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message 2.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message 2.json new file mode 100644 index 00000000..af63777e --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message 2.json @@ -0,0 +1,607 @@ +{ + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message with reference - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message with reference - extended.json new file mode 100644 index 00000000..b5b5f5fc --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message with reference - extended.json @@ -0,0 +1,573 @@ +{ + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message with reference - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message with reference - wrongly extended.json new file mode 100644 index 00000000..c9fab724 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message with reference - wrongly extended.json @@ -0,0 +1,591 @@ +{ + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ], + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message with reference.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message with reference.json new file mode 100644 index 00000000..75614fd8 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message with reference.json @@ -0,0 +1,585 @@ +{ + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message.json new file mode 100644 index 00000000..4b6fcdbf --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/message.json @@ -0,0 +1,602 @@ +{ + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageExample - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageExample - extended.json new file mode 100644 index 00000000..4eb8dfc9 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageExample - extended.json @@ -0,0 +1,21 @@ +{ + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageExample - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageExample - wrongly extended.json new file mode 100644 index 00000000..876390ff --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageExample - wrongly extended.json @@ -0,0 +1,22 @@ +{ + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageExample.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageExample.json new file mode 100644 index 00000000..cec8a4ae --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageExample.json @@ -0,0 +1,16 @@ +{ + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait - extended.json new file mode 100644 index 00000000..02ac4644 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait - extended.json @@ -0,0 +1,151 @@ +{ + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait - wrongly extended.json new file mode 100644 index 00000000..b780fa7c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait - wrongly extended.json @@ -0,0 +1,156 @@ +{ + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait 2 - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait 2 - extended.json new file mode 100644 index 00000000..6a154c25 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait 2 - extended.json @@ -0,0 +1,154 @@ +{ + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait 2 - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait 2 - wrongly extended.json new file mode 100644 index 00000000..45defcb4 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait 2 - wrongly extended.json @@ -0,0 +1,378 @@ +{ + "messageId" : "userSignup", + "headers": { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "title" : null, + "description" : null, + "readOnly" : null, + "writeOnly" : null, + "examples" : null, + "contentEncoding" : null, + "contentMediaType" : null, + "type" : "object", + "multipleOf" : null, + "maximum" : null, + "exclusiveMaximum" : null, + "minimum" : null, + "exclusiveMinimum" : null, + "maxLength" : null, + "minLength" : null, + "pattern" : null, + "items" : null, + "additionalItems" : null, + "maxItems" : null, + "minItems" : null, + "uniqueItems" : null, + "contains" : null, + "maxProperties" : null, + "minProperties" : null, + "required" : null, + "properties" : { + "correlationId" : { + "title" : null, + "description" : "Correlation ID set by application", + "readOnly" : null, + "writeOnly" : null, + "examples" : null, + "contentEncoding" : null, + "contentMediaType" : null, + "type" : "string", + "multipleOf" : null, + "maximum" : null, + "exclusiveMaximum" : null, + "minimum" : null, + "exclusiveMinimum" : null, + "maxLength" : null, + "minLength" : null, + "pattern" : null, + "items" : null, + "additionalItems" : null, + "maxItems" : null, + "minItems" : null, + "uniqueItems" : null, + "contains" : null, + "maxProperties" : null, + "minProperties" : null, + "required" : null, + "properties" : null, + "patternProperties" : null, + "additionalProperties" : null, + "dependencies" : null, + "propertyNames" : null, + "allOf" : null, + "anyOf" : null, + "oneOf" : null, + "not" : null, + "format" : null, + "discriminator" : null, + "externalDocs" : null, + "deprecated" : null, + "default" : null, + "$ref" : null, + "enum" : null, + "const" : null, + "if" : null, + "then" : null, + "else" : null + } + }, + "patternProperties" : null, + "additionalProperties" : null, + "dependencies" : null, + "propertyNames" : null, + "allOf" : null, + "anyOf" : null, + "oneOf" : null, + "not" : null, + "format" : null, + "discriminator" : null, + "externalDocs" : null, + "deprecated" : null, + "default" : null, + "$ref" : null, + "enum" : null, + "const" : null, + "if" : null, + "then" : null, + "else" : null + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "orderingKey" : null, + "attributes" : null, + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "title" : null, + "description" : null, + "readOnly" : null, + "writeOnly" : null, + "examples" : null, + "contentEncoding" : null, + "contentMediaType" : null, + "type" : "object", + "multipleOf" : null, + "maximum" : null, + "exclusiveMaximum" : null, + "minimum" : null, + "exclusiveMinimum" : null, + "maxLength" : null, + "minLength" : null, + "pattern" : null, + "items" : null, + "additionalItems" : null, + "maxItems" : null, + "minItems" : null, + "uniqueItems" : null, + "contains" : null, + "maxProperties" : null, + "minProperties" : null, + "required" : null, + "properties" : { + "Content-Type" : { + "title" : null, + "description" : null, + "readOnly" : null, + "writeOnly" : null, + "examples" : null, + "contentEncoding" : null, + "contentMediaType" : null, + "type" : "string", + "multipleOf" : null, + "maximum" : null, + "exclusiveMaximum" : null, + "minimum" : null, + "exclusiveMinimum" : null, + "maxLength" : null, + "minLength" : null, + "pattern" : null, + "items" : null, + "additionalItems" : null, + "maxItems" : null, + "minItems" : null, + "uniqueItems" : null, + "contains" : null, + "maxProperties" : null, + "minProperties" : null, + "required" : null, + "properties" : null, + "patternProperties" : null, + "additionalProperties" : null, + "dependencies" : null, + "propertyNames" : null, + "allOf" : null, + "anyOf" : null, + "oneOf" : null, + "not" : null, + "format" : null, + "discriminator" : null, + "externalDocs" : null, + "deprecated" : null, + "default" : null, + "$ref" : null, + "enum" : [ "application/json" ], + "const" : null, + "if" : null, + "then" : null, + "else" : null + } + }, + "patternProperties" : null, + "additionalProperties" : null, + "dependencies" : null, + "propertyNames" : null, + "allOf" : null, + "anyOf" : null, + "oneOf" : null, + "not" : null, + "format" : null, + "discriminator" : null, + "externalDocs" : null, + "deprecated" : null, + "default" : null, + "$ref" : null, + "enum" : null, + "const" : null, + "if" : null, + "then" : null, + "else" : null + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "title" : null, + "description" : null, + "readOnly" : null, + "writeOnly" : null, + "examples" : null, + "contentEncoding" : null, + "contentMediaType" : null, + "type" : "string", + "multipleOf" : null, + "maximum" : null, + "exclusiveMaximum" : null, + "minimum" : null, + "exclusiveMinimum" : null, + "maxLength" : null, + "minLength" : null, + "pattern" : null, + "items" : null, + "additionalItems" : null, + "maxItems" : null, + "minItems" : null, + "uniqueItems" : null, + "contains" : null, + "maxProperties" : null, + "minProperties" : null, + "required" : null, + "properties" : null, + "patternProperties" : null, + "additionalProperties" : null, + "dependencies" : null, + "propertyNames" : null, + "allOf" : null, + "anyOf" : null, + "oneOf" : null, + "not" : null, + "format" : null, + "discriminator" : null, + "externalDocs" : null, + "deprecated" : null, + "default" : null, + "$ref" : null, + "enum" : [ "myKey" ], + "const" : null, + "if" : null, + "then" : null, + "else" : null + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user", + "description" : null, + "externalDocs" : null + }, { + "name" : "signup", + "description" : null, + "externalDocs" : null + }, { + "name" : "register", + "description" : null, + "externalDocs" : null + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property": {} + }, + "ext-number" : 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait 2.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait 2.json new file mode 100644 index 00000000..77c98c8b --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait 2.json @@ -0,0 +1,152 @@ +{ + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait with reference - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait with reference - extended.json new file mode 100644 index 00000000..388e54f6 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait with reference - extended.json @@ -0,0 +1,141 @@ +{ + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait with reference - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait with reference - wrongly extended.json new file mode 100644 index 00000000..659f5936 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait with reference - wrongly extended.json @@ -0,0 +1,145 @@ +{ + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property": {} + }, + "ext-number" : 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait with reference.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait with reference.json new file mode 100644 index 00000000..cdc5730a --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait with reference.json @@ -0,0 +1,139 @@ +{ + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait.json new file mode 100644 index 00000000..1d7388c1 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/message/messageTrait.json @@ -0,0 +1,150 @@ +{ + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/parameter - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/parameter - extended.json new file mode 100644 index 00000000..21886304 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/parameter - extended.json @@ -0,0 +1,12 @@ +{ + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/parameter - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/parameter - wrongly extended.json new file mode 100644 index 00000000..e51b19cc --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/parameter - wrongly extended.json @@ -0,0 +1,23 @@ +{ + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/parameter.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/parameter.json new file mode 100644 index 00000000..da2f7860 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/channel/parameter.json @@ -0,0 +1,17 @@ +{ + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/components/components - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/components/components - extended.json new file mode 100644 index 00000000..16d5e98c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/components/components - extended.json @@ -0,0 +1,8059 @@ +{ + "schemas" : { + "Category" : { + "type" : "object", + "properties" : { + "id" : { + "type" : "integer", + "format" : "int64" + }, + "name" : { + "type" : "string" + } + } + }, + "Tag" : { + "schemaFormat" : "application/json", + "schema" : { + "type" : "object", + "properties" : { + "id" : { + "type" : "integer", + "format" : "int64" + }, + "name" : { + "type" : "string" + } + } + } + }, + "User" : { + "$ref" : "#/components/schemas/user" + } + }, + "servers" : { + "mqtt-test" : { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "default" : "demo" + }, + "port" : { + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment" + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "mqtt-stage" : { + "$ref" : "#/components/servers/mqtt-stage" + } + }, + "serverVariables" : { + "port" : { + "description" : "To which port connect", + "examples" : [ "8883", "8884" ], + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "channels" : { + "channel 1" : { + "address" : "users.{userId}", + "title" : "Users channel", + "summary" : "messages about user events.", + "description" : "This channel is used to exchange messages about users signing up", + "servers" : [ { + "$ref" : "#/components/servers/1" + }, { + "$ref" : "#/components/servers/2" + }, { + "$ref" : "#/components/servers/3" + } ], + "parameters" : { + "userId" : { + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ] + }, + "userStatus" : { + "$ref" : "#/components/parameters/user-status" + } + }, + "messages" : { + "changeStatus" : { + "$ref" : "#/components/parameters/user-status" + }, + "message" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "message 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message with reference" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } + }, + "bindings" : { + "amqp" : { + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/channelBindings/amqp1" + }, + "anypointmq" : { + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "$ref" : "#/components/channelBindings/http" + }, + "ibmmq" : { + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/channelBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + } + }, + "mercure" : { + "$ref" : "#/components/channelBindings/mercure" + }, + "mqtt" : { + "$ref" : "#/components/channelBindings/mqtt" + }, + "mqtt5" : { + "$ref" : "#/components/channelBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/channelBindings/nats" + }, + "pulsar" : { + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0" + }, + "redis" : { + "$ref" : "#/components/channelBindings/redis" + }, + "sns" : { + "$ref" : "#/components/channelBindings/sns" + }, + "solace" : { + "$ref" : "#/components/channelBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/channelBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/channelBindings/stomp" + }, + "ws" : { + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0" + } + }, + "tags" : [ { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, { + "$ref" : "#/components/tag" + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "channel 2" : { + "address" : "users.{userId}", + "title" : "Users channel", + "summary" : "messages about user events.", + "description" : "This channel is used to exchange messages about users signing up", + "servers" : [ { + "$ref" : "#/components/servers/1" + }, { + "$ref" : "#/components/servers/2" + }, { + "$ref" : "#/components/servers/3" + } ], + "parameters" : { + "userId" : { + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ] + }, + "userStatus" : { + "$ref" : "#/components/parameters/user-status" + } + }, + "messages" : { + "changeStatus" : { + "$ref" : "#/components/parameters/user-status" + }, + "message" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "message 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message with reference" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } + }, + "bindings" : { + "amqp" : { + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/channelBindings/amqp1" + }, + "anypointmq" : { + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "$ref" : "#/components/channelBindings/http" + }, + "ibmmq" : { + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/channelBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + } + }, + "mercure" : { + "$ref" : "#/components/channelBindings/mercure" + }, + "mqtt" : { + "$ref" : "#/components/channelBindings/mqtt" + }, + "mqtt5" : { + "$ref" : "#/components/channelBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/channelBindings/nats" + }, + "pulsar" : { + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0" + }, + "redis" : { + "$ref" : "#/components/channelBindings/redis" + }, + "sns" : { + "$ref" : "#/components/channelBindings/sns" + }, + "solace" : { + "$ref" : "#/components/channelBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/channelBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/channelBindings/stomp" + }, + "ws" : { + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0" + } + }, + "tags" : [ { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, { + "$ref" : "#/components/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "channel 3" : { + "$ref" : "#/components/channels/channel" + } + }, + "operations" : { + "operation 1" : { + "action" : "send", + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "traits" : [ { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, { + "$ref" : "#/components/operations/trait" + } ], + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, + "operation 2" : { + "action" : "receive", + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "traits" : [ { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, { + "$ref" : "#/components/operations/trait" + } ], + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, + "operation 3" : { + "$ref" : "#/components/operations/operation" + } + }, + "replies" : { + "reply 1" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + }, + "reply 2" : { + "address" : { + "$ref" : "#/components/addresses/address" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + }, + "reply 3" : { + "$ref" : "#/components/replies/reply" + } + }, + "replyAddresses" : { + "reply addresses 1" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "reply addresses 2" : { + "$ref" : "#/components/replyAddresses/replyAddress" + } + }, + "messages" : { + "message 1" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "payload" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "message 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "payload" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "metric" : { + "description" : "Metric set by application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message 3" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "payload" : { + "$ref" : "#/components/messages/message-payload" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "traits" : [ { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "message 4" : { + "$ref" : "#/components/messages/message" + } + }, + "securitySchemes" : { + "apiKey" : { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, + "asymmetricEncryption" : { + "$ref" : "#/components/securitySchemes/asymmetricEncryption" + }, + "gssapi" : { + "$ref" : "#/components/securitySchemes/gssapi" + }, + "oauth2" : { + "type" : "oauth2", + "description" : "oauth2", + "flows" : { + "implicit" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "authorizationUrl" : "https://example.com/api/oauth/dialog" + }, + "password" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "tokenUrl" : "https://example.com/api/oauth/token" + }, + "clientCredentials" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "tokenUrl" : "https://example.com/api/oauth/token" + }, + "authorizationCode" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "authorizationUrl" : "https://example.com/api/oauth/dialog", + "tokenUrl" : "https://example.com/api/oauth/token" + } + }, + "scopes" : [ "write:pets", "read:pets" ] + }, + "openIdConnect" : { + "type" : "openIdConnect", + "description" : "openIdConnect", + "openIdConnectUrl" : "https://server.com/.well-known/openid-configuration", + "scopes" : [ "write:pets", "read:pets" ] + }, + "httpApiKey" : { + "type" : "httpApiKey", + "description" : "httpApiKey", + "name" : "api_key", + "in" : "header" + }, + "httpBasic" : { + "type" : "http", + "description" : "http", + "scheme" : "basic" + }, + "httpBearer" : { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + }, + "plain" : { + "$ref" : "#/components/securitySchemes/plain" + }, + "scramSha256" : { + "$ref" : "#/components/securitySchemes/scramSha256" + }, + "scramSha512" : { + "$ref" : "#/components/securitySchemes/scramSha512" + }, + "symmetricEncryption" : { + "$ref" : "#/components/securitySchemes/symmetricEncryption" + }, + "userPassword" : { + "$ref" : "#/components/securitySchemes/userPassword" + }, + "X509" : { + "$ref" : "#/components/securitySchemes/X509" + } + }, + "parameters" : { + "parameter 1" : { + "description" : "Id of the user.", + "examples" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ], + "location" : "$message.payload#/user/id", + "default" : "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum" : [ "0e822ca6-5311-4d4c-b409-993a1820e689", "381f5ddc-75c6-4c21-9ec1-3919ed345be9", "70559d88-31a5-4ef2-8c34-7fbd04057ed5", "c6dc0047-a90d-4efa-95e3-a272282934e0" ] + }, + "parameter 2" : { + "$ref" : "#/components/parameters/parameter" + } + }, + "correlationIds" : { + "correlationId 1" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "correlationId 2" : { + "$ref" : "#/correlationIds/parameters/correlationId" + } + }, + "operationTraits" : { + "operationTrait 1" : { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, + "operationTrait 2" : { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, + "operationTrait 3" : { + "$ref" : "#/components/operationTraits/operationTrait" + } + }, + "messageTraits" : { + "messageTrait 1" : { + "messageId" : "userSignup", + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + }, + "correlationId" : { + "description" : "Default Correlation ID", + "location" : "$message.header#/correlationId" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + } ], + "externalDocs" : { + "description" : "User sign up rules", + "url" : "messages/sign-up-rules" + } + }, + "messageTrait 2" : { + "messageId" : "userSignup", + "headers" : { + "schemaFormat" : "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + }, + "applicationInstanceId" : { + "description" : "Unique identifier for a given instance of the publishing application", + "type" : "string" + } + } + } + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "messageTrait 3" : { + "messageId" : "userSignup", + "headers" : { + "$ref" : "#/components/messages/message-header" + }, + "correlationId" : { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType" : "application/json", + "name" : "UserSignup", + "title" : "User signup", + "summary" : "Action to sign a user up.", + "description" : "A longer description", + "bindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "examples" : [ { + "headers" : { + "correlationId" : "my-correlation-id", + "applicationInstanceId" : "myInstanceId" + }, + "payload" : { + "user" : { + "someUserKey" : "someUserValue" + }, + "signup" : { + "someSignupKey" : "someSignupValue" + } + }, + "name" : "SimpleSignup", + "summary" : "A simple UserSignup example message" + } ], + "tags" : [ { + "name" : "user" + }, { + "name" : "signup" + }, { + "name" : "register" + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + } + }, + "messageTrait 4" : { + "$ref" : "#/components/messageTraits/messageTrait" + } + }, + "serverBindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + }, + "channelBindings" : { + "amqp" : { + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/channelBindings/amqp1" + }, + "anypointmq" : { + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "$ref" : "#/components/channelBindings/http" + }, + "ibmmq" : { + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/channelBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + } + }, + "mercure" : { + "$ref" : "#/components/channelBindings/mercure" + }, + "mqtt" : { + "$ref" : "#/components/channelBindings/mqtt" + }, + "mqtt5" : { + "$ref" : "#/components/channelBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/channelBindings/nats" + }, + "pulsar" : { + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0" + }, + "redis" : { + "$ref" : "#/components/channelBindings/redis" + }, + "sns" : { + "$ref" : "#/components/channelBindings/sns" + }, + "solace" : { + "$ref" : "#/components/channelBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/channelBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/channelBindings/stomp" + }, + "ws" : { + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0" + } + }, + "operationBindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messageBindings" : { + "amqp" : { + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/messageBindings/amqp1" + }, + "anypointmq" : { + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1" + }, + "googlepubsub" : { + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0" + }, + "http" : { + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0" + }, + "jms" : { + "$ref" : "#/components/messageBindings/jms" + }, + "kafka" : { + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0" + }, + "mercure" : { + "$ref" : "#/components/messageBindings/mercure" + }, + "mqtt" : { + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/messageBindings/mqtt5" + }, + "nats" : { + "$ref" : "#/components/messageBindings/nats" + }, + "pulsar" : { + "$ref" : "#/components/messageBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/messageBindings/redis" + }, + "sns" : { + "$ref" : "#/components/messageBindings/sns" + }, + "solace" : { + "$ref" : "#/components/messageBindings/solace" + }, + "sqs" : { + "$ref" : "#/components/messageBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/messageBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/messageBindings/ws" + } + }, + "externalDocs" : { + "externalDoc 1" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "externalDoc 2" : { + "$ref" : "#/components/externalDocs/externalDoc" + } + }, + "tags" : { + "tag 1" : { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "tag 2" : { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "tag 3" : { + "$ref" : "#/components/tags/tag" + } + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/components/components - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/components/components - wrongly extended.json new file mode 100644 index 00000000..3ed77cdd --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/components/components - wrongly extended.json @@ -0,0 +1,8582 @@ +{ + "schemas": { + "Category": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int64" + }, + "name": { + "type": "string" + } + } + }, + "Tag": { + "schemaFormat": "application/json", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int64" + }, + "name": { + "type": "string" + } + } + } + }, + "User": { + "$ref": "#/components/schemas/user" + } + }, + "servers": { + "mqtt-test": { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "mqtt-stage": { + "$ref": "#/components/servers/mqtt-stage" + } + }, + "serverVariables": { + "port": { + "enum": [ + "8883", + "8884" + ], + "default": "8883", + "description": "To which port connect", + "examples": [ + "8883", + "8884" + ] + }, + "basePath": { + "$ref": "#/components/serverVariables/basePath" + } + }, + "channels": { + "channel 1": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "channel 2": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "channel 3": { + "$ref": "#/components/channels/channel" + } + }, + "operations": { + "operation 1": { + "action": "send", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + "operation 2": { + "action": "receive", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + "operation 3": { + "$ref": "#/components/operations/operation" + } + }, + "replies": { + "reply 1": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + }, + "reply 2": { + "address": { + "$ref": "#/components/addresses/address" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + }, + "reply 3": { + "$ref": "#/components/replies/reply" + } + }, + "replyAddresses": { + "reply addresses 1": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "reply addresses 2": { + "$ref": "#/components/replyAddresses/replyAddress" + } + }, + "messages": { + "message 1": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 3": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 4": { + "$ref": "#/components/messages/message" + } + }, + "securitySchemes": { + "apiKey": { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + "asymmetricEncryption": { + "$ref": "#/components/securitySchemes/asymmetricEncryption" + }, + "gssapi": { + "$ref": "#/components/securitySchemes/gssapi" + }, + "oauth2": { + "type": "oauth2", + "description": "oauth2", + "flows": { + "authorizationCode": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "clientCredentials": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "implicit": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "password": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + } + }, + "scopes": [ "write:pets", "read:pets" ] + }, + "openIdConnect": { + "type": "openIdConnect", + "description": "openIdConnect", + "openIdConnectUrl": "https://server.com/.well-known/openid-configuration", + "scopes": [ + "write:pets", + "read:pets" + ] + }, + "httpApiKey": { + "type": "httpApiKey", + "description": "httpApiKey", + "name": "api_key", + "in": "header" + }, + "httpBasic": { + "type": "http", + "description": "http", + "scheme": "basic" + }, + "httpBearer": { + "type": "http", + "description": "http", + "scheme": "bearer", + "bearerFormat": "JWT" + }, + "plain": { + "$ref": "#/components/securitySchemes/plain" + }, + "scramSha256": { + "$ref": "#/components/securitySchemes/scramSha256" + }, + "scramSha512": { + "$ref": "#/components/securitySchemes/scramSha512" + }, + "symmetricEncryption": { + "$ref": "#/components/securitySchemes/symmetricEncryption" + }, + "userPassword": { + "$ref": "#/components/securitySchemes/userPassword" + }, + "X509": { + "$ref": "#/components/securitySchemes/X509" + } + }, + "parameters": { + "parameter 1": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "parameter 2": { + "$ref": "#/components/parameters/parameter" + } + }, + "correlationIds": { + "correlationId 1": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "correlationId 2": { + "$ref": "#/correlationIds/parameters/correlationId" + } + }, + "operationTraits": { + "operationTrait 1": { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + "operationTrait 2": { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + "operationTrait 3": { + "$ref": "#/components/operationTraits/operationTrait" + } + }, + "messageTraits": { + "messageTrait 1": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 3": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 4": { + "$ref": "#/components/messageTraits/messageTrait" + } + }, + "serverBindings": { + "amqp": { + "$ref": "#/components/serverBindings/amqp" + }, + "amqp1": {}, + "anypointmq": {}, + "googlepubsub": {}, + "http": {}, + "ibmmq": { + "groupId": "PRODCLSTR1", + "ccdtQueueManagerName": "*", + "multiEndpointServer": false, + "heartBeatInterval": 300, + "cipherSpec": "ANY_TLS12_OR_HIGHER", + "bindingVersion": "0.1.0" + }, + "jms": {}, + "kafka": { + "schemaRegistryUrl": "https://my-schema-registry.com", + "schemaRegistryVendor": "confluent", + "bindingVersion": "0.4.0" + }, + "mercure": {}, + "mqtt": { + "clientId": "guest", + "cleanSession": true, + "lastWill": { + "topic": "/last-wills", + "qos": 2, + "message": "Guest gone offline.", + "retain": false + }, + "keepAlive": 60, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "sessionExpiryInterval": 60, + "bindingVersion": "0.2.0" + }, + "nats": {}, + "pulsar": { + "tenant": "contoso", + "bindingVersion": "0.1.0" + }, + "redis": {}, + "sns": {}, + "solace": { + "msgVpn": "solace.private.net", + "bindingVersion": "0.3.0" + }, + "sqs": {}, + "stomp": {}, + "ws": {} + }, + "channelBindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "operationBindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messageBindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "externalDocs": { + "externalDoc 1": { + "description": "Find more info here", + "url": "https://example.com" + }, + "externalDoc 2": { + "$ref": "#/components/externalDocs/externalDoc" + } + }, + "tags": { + "tag 1": { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "tag 2": { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + "tag 3": { + "$ref": "#/components/tags/tag" + } + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/components/components.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/components/components.json new file mode 100644 index 00000000..ddd25dc1 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/components/components.json @@ -0,0 +1,8576 @@ +{ + "schemas": { + "Category": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int64" + }, + "name": { + "type": "string" + } + } + }, + "Tag": { + "schemaFormat": "application/json", + "schema": { + "type": "object", + "properties": { + "id": { + "type": "integer", + "format": "int64" + }, + "name": { + "type": "string" + } + } + } + }, + "User": { + "$ref": "#/components/schemas/user" + } + }, + "servers": { + "mqtt-test": { + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } + }, + "mqtt-stage": { + "$ref": "#/components/servers/mqtt-stage" + } + }, + "serverVariables": { + "port": { + "enum": [ + "8883", + "8884" + ], + "default": "8883", + "description": "To which port connect", + "examples": [ + "8883", + "8884" + ] + }, + "basePath": { + "$ref": "#/components/serverVariables/basePath" + } + }, + "channels": { + "channel 1": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "channel 2": { + "address": "users.{userId}", + "title": "Users channel", + "summary": "messages about user events.", + "description": "This channel is used to exchange messages about users signing up", + "servers": [ + { "$ref": "#/components/servers/1"}, + { "$ref": "#/components/servers/2"}, + { "$ref": "#/components/servers/3"} + ], + "parameters": { + "userId": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "userStatus": { "$ref": "#/components/parameters/user-status"} + }, + "messages": { + "changeStatus": { "$ref": "#/components/parameters/user-status"}, + "message": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message with reference": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + } + }, + "bindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + { + "$ref": "#/components/tag" + } + ], + "externalDocs" : { + "$ref" : "#/components/external-doc" + } + }, + "channel 3": { + "$ref": "#/components/channels/channel" + } + }, + "operations": { + "operation 1": { + "action": "send", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + "operation 2": { + "action": "receive", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + "operation 3": { + "$ref": "#/components/operations/operation" + } + }, + "replies": { + "reply 1": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + }, + "reply 2": { + "address": { + "$ref": "#/components/addresses/address" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + }, + "reply 3": { + "$ref": "#/components/replies/reply" + } + }, + "replyAddresses": { + "reply addresses 1": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "reply addresses 2": { + "$ref": "#/components/replyAddresses/replyAddress" + } + }, + "messages": { + "message 1": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "payload": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "payload": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "metric": { + "description": "Metric set by application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref" : "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 3": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "payload": { + "$ref": "#/components/messages/message-payload" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ], + "traits": [ + { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + } + ] + }, + "message 4": { + "$ref": "#/components/messages/message" + } + }, + "securitySchemes": { + "apiKey": { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + "asymmetricEncryption": { + "$ref": "#/components/securitySchemes/asymmetricEncryption" + }, + "gssapi": { + "$ref": "#/components/securitySchemes/gssapi" + }, + "oauth2": { + "type": "oauth2", + "description": "oauth2", + "flows": { + "authorizationCode": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "clientCredentials": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "implicit": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "password": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + } + }, + "scopes": [ "write:pets", "read:pets" ] + }, + "openIdConnect": { + "type": "openIdConnect", + "description": "openIdConnect", + "openIdConnectUrl": "https://server.com/.well-known/openid-configuration", + "scopes": [ + "write:pets", + "read:pets" + ] + }, + "httpApiKey": { + "type": "httpApiKey", + "description": "httpApiKey", + "name": "api_key", + "in": "header" + }, + "httpBasic": { + "type": "http", + "description": "http", + "scheme": "basic" + }, + "httpBearer": { + "type": "http", + "description": "http", + "scheme": "bearer", + "bearerFormat": "JWT" + }, + "plain": { + "$ref": "#/components/securitySchemes/plain" + }, + "scramSha256": { + "$ref": "#/components/securitySchemes/scramSha256" + }, + "scramSha512": { + "$ref": "#/components/securitySchemes/scramSha512" + }, + "symmetricEncryption": { + "$ref": "#/components/securitySchemes/symmetricEncryption" + }, + "userPassword": { + "$ref": "#/components/securitySchemes/userPassword" + }, + "X509": { + "$ref": "#/components/securitySchemes/X509" + } + }, + "parameters": { + "parameter 1": { + "description": "Id of the user.", + "default": "0e822ca6-5311-4d4c-b409-993a1820e689", + "enum": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "examples": [ + "0e822ca6-5311-4d4c-b409-993a1820e689", + "381f5ddc-75c6-4c21-9ec1-3919ed345be9", + "70559d88-31a5-4ef2-8c34-7fbd04057ed5", + "c6dc0047-a90d-4efa-95e3-a272282934e0" + ], + "location": "$message.payload#/user/id" + }, + "parameter 2": { + "$ref": "#/components/parameters/parameter" + } + }, + "correlationIds": { + "correlationId 1": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "correlationId 2": { + "$ref": "#/correlationIds/parameters/correlationId" + } + }, + "operationTraits": { + "operationTrait 1": { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + "operationTrait 2": { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + "operationTrait 3": { + "$ref": "#/components/operationTraits/operationTrait" + } + }, + "messageTraits": { + "messageTrait 1": { + "messageId": "userSignup", + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + }, + "correlationId": { + "description": "Default Correlation ID", + "location": "$message.header#/correlationId" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" } + ], + "externalDocs": { + "description": "User sign up rules", + "url": "messages/sign-up-rules" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 2": { + "messageId": "userSignup", + "headers": { + "schemaFormat": "application/vnd.aai.asyncapi+json;version=3.0.0", + "schema": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + }, + "applicationInstanceId": { + "description": "Unique identifier for a given instance of the publishing application", + "type": "string" + } + } + } + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 3": { + "messageId": "userSignup", + "headers": { + "$ref": "#/components/messages/message-header" + }, + "correlationId": { + "$ref": "#/components/messages/message-correlation-id" + }, + "contentType": "application/json", + "name": "UserSignup", + "title": "User signup", + "summary": "Action to sign a user up.", + "description": "A longer description", + "tags": [ + { "name": "user" }, + { "name": "signup" }, + { "name": "register" }, + { "$ref": "#/components/tags/tag" } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "examples": [ + { + "name": "SimpleSignup", + "summary": "A simple UserSignup example message", + "headers": { + "correlationId": "my-correlation-id", + "applicationInstanceId": "myInstanceId" + }, + "payload": { + "user": { + "someUserKey": "someUserValue" + }, + "signup": { + "someSignupKey": "someSignupValue" + } + } + } + ] + }, + "messageTrait 4": { + "$ref": "#/components/messageTraits/messageTrait" + } + }, + "serverBindings": { + "amqp": { + "$ref": "#/components/serverBindings/amqp" + }, + "amqp1": {}, + "anypointmq": {}, + "googlepubsub": {}, + "http": {}, + "ibmmq": { + "groupId": "PRODCLSTR1", + "ccdtQueueManagerName": "*", + "multiEndpointServer": false, + "heartBeatInterval": 300, + "cipherSpec": "ANY_TLS12_OR_HIGHER", + "bindingVersion": "0.1.0" + }, + "jms": {}, + "kafka": { + "schemaRegistryUrl": "https://my-schema-registry.com", + "schemaRegistryVendor": "confluent", + "bindingVersion": "0.4.0" + }, + "mercure": {}, + "mqtt": { + "clientId": "guest", + "cleanSession": true, + "lastWill": { + "topic": "/last-wills", + "qos": 2, + "message": "Guest gone offline.", + "retain": false + }, + "keepAlive": 60, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "sessionExpiryInterval": 60, + "bindingVersion": "0.2.0" + }, + "nats": {}, + "pulsar": { + "tenant": "contoso", + "bindingVersion": "0.1.0" + }, + "redis": {}, + "sns": {}, + "solace": { + "msgVpn": "solace.private.net", + "bindingVersion": "0.3.0" + }, + "sqs": {}, + "stomp": {}, + "ws": {} + }, + "channelBindings": { + "amqp": { + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/channelBindings/amqp1" + }, + "anypointmq": { + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "$ref": "#/components/channelBindings/http" + }, + "ibmmq": { + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/channelBindings/jms" + }, + "kafka": { + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/channelBindings/mercure" + }, + "mqtt": { + "$ref": "#/components/channelBindings/mqtt" + }, + "mqtt5": { + "$ref": "#/components/channelBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/channelBindings/nats" + }, + "pulsar": { + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" + }, + "redis": { + "$ref": "#/components/channelBindings/redis" + }, + "sns": { + "$ref": "#/components/channelBindings/sns" + }, + "solace": { + "$ref": "#/components/channelBindings/solace" + }, + "sqs": { + "$ref": "#/components/channelBindings/sqs" + }, + "stomp": { + "$ref": "#/components/channelBindings/stomp" + }, + "ws": { + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } + } + }, + "operationBindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messageBindings": { + "amqp": { + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/messageBindings/amqp1" + }, + "anypointmq": { + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" + }, + "googlepubsub": { + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" + }, + "http": { + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" + }, + "jms": { + "$ref": "#/components/messageBindings/jms" + }, + "kafka": { + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/messageBindings/mercure" + }, + "mqtt": { + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/messageBindings/mqtt5" + }, + "nats": { + "$ref": "#/components/messageBindings/nats" + }, + "pulsar": { + "$ref": "#/components/messageBindings/pulsar" + }, + "redis": { + "$ref": "#/components/messageBindings/redis" + }, + "sns": { + "$ref": "#/components/messageBindings/sns" + }, + "solace": { + "$ref": "#/components/messageBindings/solace" + }, + "sqs": { + "$ref": "#/components/messageBindings/sqs" + }, + "stomp": { + "$ref": "#/components/messageBindings/stomp" + }, + "ws": { + "$ref": "#/components/messageBindings/ws" + } + }, + "externalDocs": { + "externalDoc 1": { + "description": "Find more info here", + "url": "https://example.com" + }, + "externalDoc 2": { + "$ref": "#/components/externalDocs/externalDoc" + } + }, + "tags": { + "tag 1": { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + }, + "tag 2": { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } + }, + "tag 3": { + "$ref": "#/components/tags/tag" + } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/externalDocumentation - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/externalDocumentation - extended.json new file mode 100644 index 00000000..0183a85a --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/externalDocumentation - extended.json @@ -0,0 +1,9 @@ +{ + "description" : "Find more info here", + "url" : "https://example.com", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/externalDocumentation - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/externalDocumentation - wrongly extended.json new file mode 100644 index 00000000..48a7ffed --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/externalDocumentation - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "description": "Find more info here", + "url": "https://example.com", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/externalDocumentation.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/externalDocumentation.json new file mode 100644 index 00000000..d41602e3 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/externalDocumentation.json @@ -0,0 +1,4 @@ +{ + "description": "Find more info here", + "url": "https://example.com" +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/contact - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/contact - extended.json new file mode 100644 index 00000000..74154899 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/contact - extended.json @@ -0,0 +1,10 @@ +{ + "name" : "AsyncApi", + "url" : "https://www.asyncapi.com", + "email" : "java@asyncapi.com", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/contact - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/contact - wrongly extended.json new file mode 100644 index 00000000..bf8dcedb --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/contact - wrongly extended.json @@ -0,0 +1,11 @@ +{ + "name": "AsyncApi", + "url": "https://www.asyncapi.com", + "email": "java@asyncapi.com", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/contact.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/contact.json new file mode 100644 index 00000000..31cd246a --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/contact.json @@ -0,0 +1,5 @@ +{ + "name": "AsyncApi", + "url": "https://www.asyncapi.com", + "email": "java@asyncapi.com" +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info - extended.json new file mode 100644 index 00000000..c430f171 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info - extended.json @@ -0,0 +1,32 @@ +{ + "title" : "AsyncApi sample", + "version" : "2.0", + "description" : "short description", + "termsOfService" : "https://www.asyncapi.com/about/", + "contact" : { + "name" : "AsyncApi", + "url" : "https://www.asyncapi.com", + "email" : "java@asyncapi.com" + }, + "license" : { + "name" : "Apache License 2.0", + "url" : "http://www.apache.org/licenses/" + }, + "tags" : [ { + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + } + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info - wrongly extended.json new file mode 100644 index 00000000..b6dbd60b --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info - wrongly extended.json @@ -0,0 +1,21 @@ +{ + "title": "AsyncApi sample", + "version": "2.0", + "description": "short description", + "termsOfService": "https://www.asyncapi.com/about/", + "contact": { + "name": "AsyncApi", + "url": "https://www.asyncapi.com", + "email": "java@asyncapi.com" + }, + "license": { + "name": "Apache License 2.0", + "url": "http://www.apache.org/licenses/" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info with reference - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info with reference - extended.json new file mode 100644 index 00000000..64ee7183 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info with reference - extended.json @@ -0,0 +1,26 @@ +{ + "title" : "AsyncApi sample", + "version" : "2.0", + "description" : "short description", + "termsOfService" : "https://www.asyncapi.com/about/", + "contact" : { + "name" : "AsyncApi", + "url" : "https://www.asyncapi.com", + "email" : "java@asyncapi.com" + }, + "license" : { + "name" : "Apache License 2.0", + "url" : "http://www.apache.org/licenses/" + }, + "tags" : [ { + "$ref" : "#/components/schemas/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/schemas/externalDoc" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info with reference - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info with reference - wrongly extended.json new file mode 100644 index 00000000..0ac2a117 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info with reference - wrongly extended.json @@ -0,0 +1,29 @@ +{ + "title": "AsyncApi sample", + "version": "2.0", + "description": "short description", + "termsOfService": "https://www.asyncapi.com/about/", + "contact": { + "name": "AsyncApi", + "url": "https://www.asyncapi.com", + "email": "java@asyncapi.com" + }, + "license": { + "name": "Apache License 2.0", + "url": "http://www.apache.org/licenses/" + }, + "tags": [ + { + "$ref": "#/components/schemas/tag" + } + ], + "externalDocs": { + "$ref": "#/components/schemas/externalDoc" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info with reference.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info with reference.json new file mode 100644 index 00000000..253ea5b8 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info with reference.json @@ -0,0 +1,23 @@ +{ + "title": "AsyncApi sample", + "version": "2.0", + "description": "short description", + "termsOfService": "https://www.asyncapi.com/about/", + "contact": { + "name": "AsyncApi", + "url": "https://www.asyncapi.com", + "email": "java@asyncapi.com" + }, + "license": { + "name": "Apache License 2.0", + "url": "http://www.apache.org/licenses/" + }, + "tags": [ + { + "$ref": "#/components/schemas/tag" + } + ], + "externalDocs": { + "$ref": "#/components/schemas/externalDoc" + } +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info.json new file mode 100644 index 00000000..8231edb9 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/info.json @@ -0,0 +1,29 @@ +{ + "title": "AsyncApi sample", + "version": "2.0", + "description": "short description", + "termsOfService": "https://www.asyncapi.com/about/", + "contact": { + "name": "AsyncApi", + "url": "https://www.asyncapi.com", + "email": "java@asyncapi.com" + }, + "license": { + "name": "Apache License 2.0", + "url": "http://www.apache.org/licenses/" + }, + "tags": [ + { + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } + } + ], + "externalDocs": { + "description": "Find more info here", + "url": "https://example.com" + } +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/license - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/license - extended.json new file mode 100644 index 00000000..95d3cd1e --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/license - extended.json @@ -0,0 +1,9 @@ +{ + "name" : "Apache License 2.0", + "url" : "http://www.apache.org/licenses/", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/license - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/license - wrongly extended.json new file mode 100644 index 00000000..a52ea20d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/license - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "name": "Apache License 2.0", + "url": "http://www.apache.org/licenses/", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/license.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/license.json new file mode 100644 index 00000000..61436164 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/info/license.json @@ -0,0 +1,4 @@ +{ + "name": "Apache License 2.0", + "url": "http://www.apache.org/licenses/" +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation - extended.json new file mode 100644 index 00000000..e4b609b1 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation - extended.json @@ -0,0 +1,488 @@ +{ + "action" : "send", + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "traits" : [ { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, { + "$ref" : "#/components/operations/trait" + } ], + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation - wrongly extended.json new file mode 100644 index 00000000..533f605c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation - wrongly extended.json @@ -0,0 +1,580 @@ +{ + "action": "send", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation with reference - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation with reference - extended.json new file mode 100644 index 00000000..f5914284 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation with reference - extended.json @@ -0,0 +1,474 @@ +{ + "action" : "receive", + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "traits" : [ { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + } + }, { + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + } + }, { + "$ref" : "#/components/operations/trait" + } ], + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation with reference - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation with reference - wrongly extended.json new file mode 100644 index 00000000..20e049dc --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation with reference - wrongly extended.json @@ -0,0 +1,562 @@ +{ + "action": "receive", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation with reference.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation with reference.json new file mode 100644 index 00000000..f6bfb55d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation with reference.json @@ -0,0 +1,556 @@ +{ + "action": "receive", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation.json new file mode 100644 index 00000000..5e32db03 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operation.json @@ -0,0 +1,574 @@ +{ + "action": "send", + "channel": "#/components/channels/channel", + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "traits": [ + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } + }, + { + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } + }, + { + "$ref": "#/components/operations/trait" + } + ], + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait - extended.json new file mode 100644 index 00000000..5984c9c4 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait - extended.json @@ -0,0 +1,169 @@ +{ + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ] + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait - wrongly extended.json new file mode 100644 index 00000000..6b932104 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait - wrongly extended.json @@ -0,0 +1,201 @@ +{ + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait with reference - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait with reference - extended.json new file mode 100644 index 00000000..abb0d7a6 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait with reference - extended.json @@ -0,0 +1,155 @@ +{ + "title" : "Send message operation", + "summary" : "Send message", + "description" : "Send message to remote server", + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "$ref" : "#/components/security/plain" + } ], + "tags" : [ { + "name" : "messages", + "description" : "operations with messages", + "externalDocs" : { + "description" : "Messages validation rules", + "url" : "messages/validation-rules" + } + }, { + "$ref" : "#/components/tags/tag" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/external-doc" + }, + "bindings" : { + "amqp" : { + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0" + }, + "amqp1" : { + "$ref" : "#/components/operationBindings/amqp1" + }, + "anypointmq" : { + "$ref" : "#/components/operationBindings/anypointmq" + }, + "googlepubsub" : { + "$ref" : "#/components/operationBindings/googlepubsub" + }, + "http" : { + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0" + }, + "ibmmq" : { + "$ref" : "#/components/operationBindings/ibmmq" + }, + "jms" : { + "$ref" : "#/components/operationBindings/jms" + }, + "kafka" : { + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + } + }, + "mercure" : { + "$ref" : "#/components/operationBindings/mercure" + }, + "mqtt" : { + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "$ref" : "#/components/operationBindings/mqtt5" + }, + "nats" : { + "queue" : "messages", + "bindingVersion" : "0.1.0" + }, + "pulsar" : { + "$ref" : "#/components/operationBindings/pulsar" + }, + "redis" : { + "$ref" : "#/components/operationBindings/redis" + }, + "sns" : { + "$ref" : "#/components/operationBindings/sns" + }, + "solace" : { + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0" + }, + "sqs" : { + "$ref" : "#/components/operationBindings/sqs" + }, + "stomp" : { + "$ref" : "#/components/operationBindings/stomp" + }, + "ws" : { + "$ref" : "#/components/operationBindings/ws" + } + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "reply" : { + "$ref" : "#/components/replies/reply" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait with reference - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait with reference - wrongly extended.json new file mode 100644 index 00000000..bb25657b --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait with reference - wrongly extended.json @@ -0,0 +1,183 @@ +{ + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait with reference.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait with reference.json new file mode 100644 index 00000000..515a29c9 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait with reference.json @@ -0,0 +1,177 @@ +{ + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "$ref": "#/components/externalDocs/external-doc" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "$ref": "#/components/replies/reply" + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait.json new file mode 100644 index 00000000..ac447907 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/operationTrait.json @@ -0,0 +1,195 @@ +{ + "title": "Send message operation", + "summary": "Send message", + "description": "Send message to remote server", + "security": [ + { + "type": "apiKey", + "description": "apiKey", + "in": "user" + }, + { + "$ref": "#/components/security/plain" + } + ], + "tags": [ + { + "name": "messages", + "description": "operations with messages", + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + } + }, + { + "$ref": "#/components/tags/tag" + } + ], + "externalDocs": { + "description": "Messages validation rules", + "url": "messages/validation-rules" + }, + "bindings": { + "amqp": { + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" + }, + "amqp1": { + "$ref": "#/components/operationBindings/amqp1" + }, + "anypointmq": { + "$ref": "#/components/operationBindings/anypointmq" + }, + "googlepubsub": { + "$ref": "#/components/operationBindings/googlepubsub" + }, + "http": { + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" + }, + "ibmmq": { + "$ref": "#/components/operationBindings/ibmmq" + }, + "jms": { + "$ref": "#/components/operationBindings/jms" + }, + "kafka": { + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" + }, + "mercure": { + "$ref": "#/components/operationBindings/mercure" + }, + "mqtt": { + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "$ref": "#/components/operationBindings/mqtt5" + }, + "nats": { + "queue": "messages", + "bindingVersion": "0.1.0" + }, + "pulsar": { + "$ref": "#/components/operationBindings/pulsar" + }, + "redis": { + "$ref": "#/components/operationBindings/redis" + }, + "sns": { + "$ref": "#/components/operationBindings/sns" + }, + "solace": { + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" + }, + "sqs": { + "$ref": "#/components/operationBindings/sqs" + }, + "stomp": { + "$ref": "#/components/operationBindings/stomp" + }, + "ws": { + "$ref": "#/components/operationBindings/ws" + } + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "reply": { + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply - extended.json new file mode 100644 index 00000000..83c51aca --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply - extended.json @@ -0,0 +1,21 @@ +{ + "address" : { + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply - wrongly extended.json new file mode 100644 index 00000000..2aeadcde --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply - wrongly extended.json @@ -0,0 +1,26 @@ +{ + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply with reference - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply with reference - extended.json new file mode 100644 index 00000000..b844af0d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply with reference - extended.json @@ -0,0 +1,20 @@ +{ + "address" : { + "$ref" : "#/components/addresses/address" + }, + "channel" : { + "$ref" : "#/components/channels/channel" + }, + "messages" : [ { + "$ref" : "#/components/messages/message 1" + }, { + "$ref" : "#/components/messages/message 2" + }, { + "$ref" : "#/components/messages/message 3" + } ], + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply with reference - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply with reference - wrongly extended.json new file mode 100644 index 00000000..9bf87ab7 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply with reference - wrongly extended.json @@ -0,0 +1,25 @@ +{ + "address": { + "$ref" : "#/components/addresses/address" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ], + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply with reference.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply with reference.json new file mode 100644 index 00000000..b4a84b9b --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply with reference.json @@ -0,0 +1,19 @@ +{ + "address": { + "$ref": "#/components/addresses/address" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply.json new file mode 100644 index 00000000..59809bdb --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReply.json @@ -0,0 +1,20 @@ +{ + "address": { + "description": "Consumer inbox", + "location": "$message.header#/replyTo" + }, + "channel": { + "$ref": "#/components/channels/channel" + }, + "messages": [ + { + "$ref": "#/components/messages/message 1" + }, + { + "$ref": "#/components/messages/message 2" + }, + { + "$ref": "#/components/messages/message 3" + } + ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReplyAddress - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReplyAddress - extended.json new file mode 100644 index 00000000..b29e8c8c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReplyAddress - extended.json @@ -0,0 +1,9 @@ +{ + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReplyAddress - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReplyAddress - wrongly extended.json new file mode 100644 index 00000000..570fd1fd --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReplyAddress - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "description" : "Consumer inbox", + "location" : "$message.header#/replyTo", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReplyAddress.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReplyAddress.json new file mode 100644 index 00000000..90fa3ab1 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/operation/reply/operationReplyAddress.json @@ -0,0 +1,4 @@ +{ + "description": "Consumer inbox", + "location": "$message.header#/replyTo" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/reference.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/reference.json new file mode 100644 index 00000000..cca746ac --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/reference.json @@ -0,0 +1,3 @@ +{ + "$ref": "#/components/schemas/user" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server - extended.json new file mode 100644 index 00000000..8345f9cf --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server - extended.json @@ -0,0 +1,99 @@ +{ + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "default" : "demo" + }, + "port" : { + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment" + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server - wrongly extended.json new file mode 100644 index 00000000..7abed521 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server - wrongly extended.json @@ -0,0 +1,109 @@ +{ + "host": "{username}.gigantic-server.com:{port}/{basePath}", + "protocol": "secure-mqtt", + "protocolVersion": "5", + "pathname": "/messages", + "description": "The production API server", + "title": "secure-mqtt API server", + "summary": "API server", + "variables": { + "username": { + "default": "demo", + "description": "This value is assigned by the service provider, in this example `gigantic-server.com`" + }, + "port": { + "enum": [ + "8883", + "8884" + ], + "default": "8883" + }, + "basePath": { + "$ref": "#/components/serverVariables/basePath" + } + }, + "security": [ + { + "type": "httpApiKey", + "description": "httpApiKey", + "name": "api_key", + "in": "header" + }, + { + "type": "http", + "description": "http", + "scheme": "bearer", + "bearerFormat": "JWT" + } + ], + "tags": [ + { + "name": "env:staging", + "description": "This environment is a replica of the production environment" + } + ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings": { + "amqp": { + "$ref": "#/components/serverBindings/amqp" + }, + "amqp1": {}, + "anypointmq": {}, + "googlepubsub": {}, + "http": {}, + "ibmmq": { + "groupId": "PRODCLSTR1", + "ccdtQueueManagerName": "*", + "multiEndpointServer": false, + "heartBeatInterval": 300, + "cipherSpec": "ANY_TLS12_OR_HIGHER", + "bindingVersion": "0.1.0" + }, + "jms": {}, + "kafka": { + "schemaRegistryUrl": "https://my-schema-registry.com", + "schemaRegistryVendor": "confluent", + "bindingVersion": "0.4.0" + }, + "mercure": {}, + "mqtt": { + "clientId": "guest", + "cleanSession": true, + "lastWill": { + "topic": "/last-wills", + "qos": 2, + "message": "Guest gone offline.", + "retain": false + }, + "keepAlive": 60, + "bindingVersion": "0.1.0" + }, + "mqtt5": { + "sessionExpiryInterval": 60, + "bindingVersion": "0.2.0" + }, + "nats": {}, + "pulsar": { + "tenant": "contoso", + "bindingVersion": "0.1.0" + }, + "redis": {}, + "sns": {}, + "solace": { + "msgVpn": "solace.private.net", + "bindingVersion": "0.3.0" + }, + "sqs": {}, + "stomp": {}, + "ws": {} + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server with reference - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server with reference - extended.json new file mode 100644 index 00000000..544037d4 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server with reference - extended.json @@ -0,0 +1,102 @@ +{ + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "default" : "demo" + }, + "port" : { + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + }, { + "$ref" : "#/components/securitySchemes/openId" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment" + }, { + "$ref" : "#/components/tags/tag_name" + } ], + "externalDocs" : { + "$ref" : "#/components/externalDocs/externalDoc" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server with reference - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server with reference - wrongly extended.json new file mode 100644 index 00000000..e0e49b6d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server with reference - wrongly extended.json @@ -0,0 +1,108 @@ +{ + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + }, { + "$ref" : "#/components/securitySchemes/openId" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + }, { + "$ref" : "#/components/tags/tag_name" + }], + "externalDocs" : { + "$ref" : "#/components/externalDocs/externalDoc" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server with reference.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server with reference.json new file mode 100644 index 00000000..3dffe38d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server with reference.json @@ -0,0 +1,102 @@ +{ + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + }, { + "$ref" : "#/components/securitySchemes/openId" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + }, { + "$ref" : "#/components/tags/tag_name" + }], + "externalDocs" : { + "$ref" : "#/components/externalDocs/externalDoc" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server.json new file mode 100644 index 00000000..387253d0 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/server.json @@ -0,0 +1,99 @@ +{ + "host" : "{username}.gigantic-server.com:{port}/{basePath}", + "protocol" : "secure-mqtt", + "protocolVersion" : "5", + "pathname" : "/messages", + "description" : "The production API server", + "title" : "secure-mqtt API server", + "summary" : "API server", + "variables" : { + "username" : { + "description" : "This value is assigned by the service provider, in this example `gigantic-server.com`", + "examples" : null, + "enum" : null, + "default" : "demo" + }, + "port" : { + "description" : null, + "examples" : null, + "enum" : [ "8883", "8884" ], + "default" : "8883" + }, + "basePath" : { + "$ref" : "#/components/serverVariables/basePath" + } + }, + "security" : [ { + "type" : "apiKey", + "description" : "apiKey", + "in" : "user" + }, { + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT" + } ], + "tags" : [ { + "name" : "env:staging", + "description" : "This environment is a replica of the production environment", + "externalDocs" : null + } ], + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "bindings" : { + "amqp" : { + "$ref" : "#/components/serverBindings/amqp" + }, + "amqp1" : { }, + "anypointmq" : { }, + "googlepubsub" : { }, + "http" : { }, + "ibmmq" : { + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0" + }, + "jms" : { }, + "kafka" : { + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0" + }, + "mercure" : { }, + "mqtt" : { + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0" + }, + "mqtt5" : { + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0" + }, + "nats" : { }, + "pulsar" : { + "tenant" : "contoso", + "bindingVersion" : "0.1.0" + }, + "redis" : { }, + "sns" : { }, + "solace" : { + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0" + }, + "sqs" : { }, + "stomp" : { }, + "ws" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/serverVariable - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/serverVariable - extended.json new file mode 100644 index 00000000..93416d9d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/serverVariable - extended.json @@ -0,0 +1,11 @@ +{ + "description" : "To which port connect", + "examples" : [ "8883", "8884" ], + "enum" : [ "8883", "8884" ], + "default" : "8883", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/serverVariable - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/serverVariable - wrongly extended.json new file mode 100644 index 00000000..16e70dab --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/serverVariable - wrongly extended.json @@ -0,0 +1,18 @@ +{ + "enum": [ + "8883", + "8884" + ], + "default": "8883", + "description": "To which port connect", + "examples": [ + "8883", + "8884" + ], + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/serverVariable.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/serverVariable.json new file mode 100644 index 00000000..84405441 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/server/serverVariable.json @@ -0,0 +1,12 @@ +{ + "enum": [ + "8883", + "8884" + ], + "default": "8883", + "description": "To which port connect", + "examples": [ + "8883", + "8884" + ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag - extended.json new file mode 100644 index 00000000..d41b395e --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag - extended.json @@ -0,0 +1,13 @@ +{ + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag - wrongly extended.json new file mode 100644 index 00000000..7a65e27e --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag - wrongly extended.json @@ -0,0 +1,14 @@ +{ + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag with reference to externalDocs - extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag with reference to externalDocs - extended.json new file mode 100644 index 00000000..1d10e2f8 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag with reference to externalDocs - extended.json @@ -0,0 +1,12 @@ +{ + "name" : "user", + "description" : "User-related messages", + "externalDocs" : { + "$ref" : "#/components/external-doc" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag with reference to externalDocs - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag with reference to externalDocs - wrongly extended.json new file mode 100644 index 00000000..79e4f263 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag with reference to externalDocs - wrongly extended.json @@ -0,0 +1,13 @@ +{ + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag with reference to externalDocs.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag with reference to externalDocs.json new file mode 100644 index 00000000..f9ad85f8 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag with reference to externalDocs.json @@ -0,0 +1,7 @@ +{ + "name": "user", + "description": "User-related messages", + "externalDocs": { + "$ref": "#/components/external-doc" + } +} diff --git a/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag.json b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag.json new file mode 100644 index 00000000..aa06e030 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/3.0.0/model/tag.json @@ -0,0 +1,8 @@ +{ + "name": "user", + "description": "User-related messages", + "externalDocs": { + "description" : "Find more info here", + "url" : "https://example.com" + } +} diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/amqp/amqpChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/amqp/amqpChannelBinding - extended.json new file mode 100644 index 00000000..61ef0ad3 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/amqp/amqpChannelBinding - extended.json @@ -0,0 +1,23 @@ +{ + "is" : "routingKey", + "exchange" : { + "name" : "myExchange", + "type" : "topic", + "durable" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "queue" : { + "name" : "my-queue-name", + "durable" : true, + "exclusive" : true, + "autoDelete" : false, + "vhost" : "/" + }, + "bindingVersion" : "0.2.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/amqp/amqpChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/amqp/amqpChannelBinding - wrongly extended.json new file mode 100644 index 00000000..a6433eb4 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/amqp/amqpChannelBinding - wrongly extended.json @@ -0,0 +1,24 @@ +{ + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/amqp/amqpChannelBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/amqp/amqpChannelBinding.json new file mode 100644 index 00000000..e91cacb2 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/amqp/amqpChannelBinding.json @@ -0,0 +1,18 @@ +{ + "is": "routingKey", + "queue": { + "name": "my-queue-name", + "durable": true, + "exclusive": true, + "autoDelete": false, + "vhost": "/" + }, + "exchange": { + "name": "myExchange", + "type": "topic", + "durable": true, + "autoDelete": false, + "vhost": "/" + }, + "bindingVersion": "0.2.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/anypoint/anypointMQChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/anypoint/anypointMQChannelBinding - extended.json new file mode 100644 index 00000000..4a27096c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/anypoint/anypointMQChannelBinding - extended.json @@ -0,0 +1,10 @@ +{ + "destination" : "user-signup-exchg", + "destinationType" : "exchange", + "bindingVersion" : "0.0.1", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/anypoint/anypointMQChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/anypoint/anypointMQChannelBinding - wrongly extended.json new file mode 100644 index 00000000..2b92a333 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/anypoint/anypointMQChannelBinding - wrongly extended.json @@ -0,0 +1,11 @@ +{ + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/anypoint/anypointMQChannelBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/anypoint/anypointMQChannelBinding.json new file mode 100644 index 00000000..c5d7598b --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/anypoint/anypointMQChannelBinding.json @@ -0,0 +1,5 @@ +{ + "destination": "user-signup-exchg", + "destinationType": "exchange", + "bindingVersion": "0.0.1" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding - extended.json new file mode 100644 index 00000000..2d00b527 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding - extended.json @@ -0,0 +1,17 @@ +{ + "topic" : "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration" : "86400s", + "messageStoragePolicy" : { + "allowedPersistenceRegions" : [ "us-central1", "us-central2", "us-east1", "us-east4", "us-east5", "us-east7", "us-south1", "us-west1", "us-west2", "us-west3", "us-west4" ] + }, + "schemaSettings" : { + "encoding" : "binary", + "name" : "projects/your-project/schemas/message-proto" + }, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding - wrongly extended.json new file mode 100644 index 00000000..374dbd31 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding - wrongly extended.json @@ -0,0 +1,30 @@ +{ + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding.json new file mode 100644 index 00000000..fb9b3d3e --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/googlepubsub/googlePubSubChannelBinding.json @@ -0,0 +1,24 @@ +{ + "topic": "projects/your-project/topics/topic-proto-schema", + "messageRetentionDuration": "86400s", + "messageStoragePolicy": { + "allowedPersistenceRegions": [ + "us-central1", + "us-central2", + "us-east1", + "us-east4", + "us-east5", + "us-east7", + "us-south1", + "us-west1", + "us-west2", + "us-west3", + "us-west4" + ] + }, + "schemaSettings": { + "encoding": "binary", + "name": "projects/your-project/schemas/message-proto" + }, + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/ibmmq/ibmMQChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/ibmmq/ibmMQChannelBinding - extended.json new file mode 100644 index 00000000..a0f4e987 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/ibmmq/ibmMQChannelBinding - extended.json @@ -0,0 +1,21 @@ +{ + "destinationType" : "topic", + "queue" : { + "objectName" : "message", + "isPartitioned" : false, + "exclusive" : true + }, + "topic" : { + "string" : "messages", + "objectName" : "message", + "durablePermitted" : true, + "lastMsgRetained" : true + }, + "maxMsgLength" : 1024, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/ibmmq/ibmMQChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/ibmmq/ibmMQChannelBinding - wrongly extended.json new file mode 100644 index 00000000..deff6b3f --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/ibmmq/ibmMQChannelBinding - wrongly extended.json @@ -0,0 +1,22 @@ +{ + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/ibmmq/ibmMQChannelBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/ibmmq/ibmMQChannelBinding.json new file mode 100644 index 00000000..7ebdae40 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/ibmmq/ibmMQChannelBinding.json @@ -0,0 +1,16 @@ +{ + "destinationType": "topic", + "queue": { + "objectName": "message", + "isPartitioned": false, + "exclusive": true + }, + "topic": { + "string": "messages", + "objectName": "message", + "durablePermitted": true, + "lastMsgRetained": true + }, + "maxMsgLength": 1024, + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/kafka/kafkaChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/kafka/kafkaChannelBinding - extended.json new file mode 100644 index 00000000..1b79a719 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/kafka/kafkaChannelBinding - extended.json @@ -0,0 +1,18 @@ +{ + "bindingVersion" : "0.4.0", + "topic" : "my-specific-topic-name", + "partitions" : 20, + "replicas" : 3, + "topicConfiguration" : { + "cleanup.policy" : [ "delete", "compact" ], + "retention.ms" : 604800000, + "retention.bytes" : 1000000000, + "delete.retention.ms" : 86400000, + "max.message.bytes" : 1048588 + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/kafka/kafkaChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/kafka/kafkaChannelBinding - wrongly extended.json new file mode 100644 index 00000000..8373d9c4 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/kafka/kafkaChannelBinding - wrongly extended.json @@ -0,0 +1,22 @@ +{ + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/kafka/kafkaChannelBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/kafka/kafkaChannelBinding.json new file mode 100644 index 00000000..c937ae56 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/kafka/kafkaChannelBinding.json @@ -0,0 +1,16 @@ +{ + "topic": "my-specific-topic-name", + "partitions": 20, + "replicas": 3, + "topicConfiguration": { + "cleanup.policy": [ + "delete", + "compact" + ], + "retention.ms": 604800000, + "retention.bytes": 1000000000, + "delete.retention.ms": 86400000, + "max.message.bytes": 1048588 + }, + "bindingVersion": "0.4.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/pulsar/pulsarChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/pulsar/pulsarChannelBinding - extended.json new file mode 100644 index 00000000..17b32f84 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/pulsar/pulsarChannelBinding - extended.json @@ -0,0 +1,18 @@ +{ + "namespace" : "staging", + "persistence" : "persistent", + "compaction" : 1000, + "geo-replication" : [ "us-east1", "us-west1" ], + "retention" : { + "time" : 7, + "size" : 1000 + }, + "ttl" : 360, + "deduplication" : false, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/pulsar/pulsarChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/pulsar/pulsarChannelBinding - wrongly extended.json new file mode 100644 index 00000000..eb0e8d65 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/pulsar/pulsarChannelBinding - wrongly extended.json @@ -0,0 +1,22 @@ +{ + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/pulsar/pulsarChannelBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/pulsar/pulsarChannelBinding.json new file mode 100644 index 00000000..21af1c35 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/pulsar/pulsarChannelBinding.json @@ -0,0 +1,16 @@ +{ + "namespace": "staging", + "persistence": "persistent", + "compaction": 1000, + "geo-replication": [ + "us-east1", + "us-west1" + ], + "retention": { + "time": 7, + "size": 1000 + }, + "ttl": 360, + "deduplication": false, + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/ws/webSocketsChannelBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/ws/webSocketsChannelBinding - extended.json new file mode 100644 index 00000000..f0c5c5dc --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/ws/webSocketsChannelBinding - extended.json @@ -0,0 +1,27 @@ +{ + "method" : "GET", + "query" : { + "type" : "object", + "properties" : { + "ref" : { + "description" : "Referral.", + "type" : "string" + } + } + }, + "headers" : { + "type" : "object", + "properties" : { + "Authentication" : { + "description" : "Authentication token", + "type" : "string" + } + } + }, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/ws/webSocketsChannelBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/ws/webSocketsChannelBinding - wrongly extended.json new file mode 100644 index 00000000..535cd4bc --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/ws/webSocketsChannelBinding - wrongly extended.json @@ -0,0 +1,27 @@ +{ + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/channel/ws/webSocketsChannelBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/channel/ws/webSocketsChannelBinding.json new file mode 100644 index 00000000..f30d9581 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/channel/ws/webSocketsChannelBinding.json @@ -0,0 +1,21 @@ +{ + "method": "GET", + "query": { + "type": "object", + "properties": { + "ref": { + "type": "string", + "description": "Referral." + } + } + }, + "headers": { + "type": "object", + "properties": { + "Authentication": { + "type": "string", + "description": "Authentication token" + } + } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/amqp/amqpMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/amqp/amqpMessageBinding - extended.json new file mode 100644 index 00000000..98d5ef64 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/amqp/amqpMessageBinding - extended.json @@ -0,0 +1,10 @@ +{ + "contentEncoding" : "gzip", + "messageType" : "user.signup", + "bindingVersion" : "0.2.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/amqp/amqpMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/amqp/amqpMessageBinding - wrongly extended.json new file mode 100644 index 00000000..b3d1d1f1 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/amqp/amqpMessageBinding - wrongly extended.json @@ -0,0 +1,11 @@ +{ + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/amqp/amqpMessageBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/message/amqp/amqpMessageBinding.json new file mode 100644 index 00000000..3a56f03e --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/amqp/amqpMessageBinding.json @@ -0,0 +1,5 @@ +{ + "contentEncoding": "gzip", + "messageType": "user.signup", + "bindingVersion": "0.2.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/anypointmq/anypointMQMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/anypointmq/anypointMQMessageBinding - extended.json new file mode 100644 index 00000000..35dee45d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/anypointmq/anypointMQMessageBinding - extended.json @@ -0,0 +1,17 @@ +{ + "headers" : { + "type" : "object", + "properties" : { + "correlationId" : { + "description" : "Correlation ID set by application", + "type" : "string" + } + } + }, + "bindingVersion" : "0.0.1", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/anypointmq/anypointMQMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/anypointmq/anypointMQMessageBinding - wrongly extended.json new file mode 100644 index 00000000..bbc0329e --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/anypointmq/anypointMQMessageBinding - wrongly extended.json @@ -0,0 +1,18 @@ +{ + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/anypointmq/anypointMQMessageBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/message/anypointmq/anypointMQMessageBinding.json new file mode 100644 index 00000000..04509bbf --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/anypointmq/anypointMQMessageBinding.json @@ -0,0 +1,12 @@ +{ + "headers": { + "type": "object", + "properties": { + "correlationId": { + "description": "Correlation ID set by application", + "type": "string" + } + } + }, + "bindingVersion": "0.0.1" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding - extended.json new file mode 100644 index 00000000..e0d383d4 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding - extended.json @@ -0,0 +1,12 @@ +{ + "schema" : { + "name" : "projects/your-project/schemas/message-avro", + "type" : "avro" + }, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding - wrongly extended.json new file mode 100644 index 00000000..2219970c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding - wrongly extended.json @@ -0,0 +1,13 @@ +{ + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding.json new file mode 100644 index 00000000..511854ad --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/googlepubsub/googlePubSubMessageBinding.json @@ -0,0 +1,7 @@ +{ + "schema": { + "name": "projects/your-project/schemas/message-avro", + "type": "avro" + }, + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/http/httpMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/http/httpMessageBinding - extended.json new file mode 100644 index 00000000..436e5391 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/http/httpMessageBinding - extended.json @@ -0,0 +1,17 @@ +{ + "headers" : { + "type" : "object", + "properties" : { + "Content-Type" : { + "type" : "string", + "enum" : [ "application/json" ] + } + } + }, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/http/httpMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/http/httpMessageBinding - wrongly extended.json new file mode 100644 index 00000000..b4b71d4e --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/http/httpMessageBinding - wrongly extended.json @@ -0,0 +1,20 @@ +{ + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/http/httpMessageBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/message/http/httpMessageBinding.json new file mode 100644 index 00000000..5f7f5672 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/http/httpMessageBinding.json @@ -0,0 +1,14 @@ +{ + "headers": { + "type": "object", + "properties": { + "Content-Type": { + "type": "string", + "enum": [ + "application/json" + ] + } + } + }, + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/ibmmq/ibmMQMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/ibmmq/ibmMQMessageBinding - extended.json new file mode 100644 index 00000000..bf14dfb0 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/ibmmq/ibmMQMessageBinding - extended.json @@ -0,0 +1,12 @@ +{ + "type" : "jms", + "headers" : "Content-Type: application/json", + "description" : "JMS stream message", + "expiry" : 0, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/ibmmq/ibmMQMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/ibmmq/ibmMQMessageBinding - wrongly extended.json new file mode 100644 index 00000000..175d30fb --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/ibmmq/ibmMQMessageBinding - wrongly extended.json @@ -0,0 +1,13 @@ +{ + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/ibmmq/ibmMQMessageBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/message/ibmmq/ibmMQMessageBinding.json new file mode 100644 index 00000000..49697805 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/ibmmq/ibmMQMessageBinding.json @@ -0,0 +1,7 @@ +{ + "type": "jms", + "description": "JMS stream message", + "headers": "Content-Type: application/json", + "expiry": 0, + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/kafka/kafkaMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/kafka/kafkaMessageBinding - extended.json new file mode 100644 index 00000000..380a3d0c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/kafka/kafkaMessageBinding - extended.json @@ -0,0 +1,15 @@ +{ + "key" : { + "type" : "string", + "enum" : [ "myKey" ] + }, + "schemaIdLocation" : "payload", + "schemaIdPayloadEncoding" : "apicurio-new", + "schemaLookupStrategy" : "TopicIdStrategy", + "bindingVersion" : "0.4.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/kafka/kafkaMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/kafka/kafkaMessageBinding - wrongly extended.json new file mode 100644 index 00000000..37105e30 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/kafka/kafkaMessageBinding - wrongly extended.json @@ -0,0 +1,18 @@ +{ + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/kafka/kafkaMessageBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/message/kafka/kafkaMessageBinding.json new file mode 100644 index 00000000..42340266 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/kafka/kafkaMessageBinding.json @@ -0,0 +1,12 @@ +{ + "key": { + "type": "string", + "enum": [ + "myKey" + ] + }, + "schemaIdLocation": "payload", + "schemaIdPayloadEncoding": "apicurio-new", + "schemaLookupStrategy": "TopicIdStrategy", + "bindingVersion": "0.4.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/mqtt/mqttMessageBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/mqtt/mqttMessageBinding - extended.json new file mode 100644 index 00000000..32459b79 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/mqtt/mqttMessageBinding - extended.json @@ -0,0 +1,8 @@ +{ + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/mqtt/mqttMessageBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/message/mqtt/mqttMessageBinding - wrongly extended.json new file mode 100644 index 00000000..a1ecfd51 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/mqtt/mqttMessageBinding - wrongly extended.json @@ -0,0 +1,9 @@ +{ + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/message/mqtt/mqttMessageBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/message/mqtt/mqttMessageBinding.json new file mode 100644 index 00000000..04dbf945 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/message/mqtt/mqttMessageBinding.json @@ -0,0 +1,3 @@ +{ + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/amqp/amqpOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/amqp/amqpOperationBinding - extended.json new file mode 100644 index 00000000..a19a9822 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/amqp/amqpOperationBinding - extended.json @@ -0,0 +1,18 @@ +{ + "expiration" : 100000, + "userId" : "guest", + "cc" : [ "user.logs" ], + "priority" : 10, + "deliveryMode" : 2, + "mandatory" : false, + "bcc" : [ "external.audit" ], + "replyTo" : "user.signedup", + "timestamp" : true, + "ack" : false, + "bindingVersion" : "0.2.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/amqp/amqpOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/amqp/amqpOperationBinding - wrongly extended.json new file mode 100644 index 00000000..10ba23cd --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/amqp/amqpOperationBinding - wrongly extended.json @@ -0,0 +1,23 @@ +{ + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/amqp/amqpOperationBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/amqp/amqpOperationBinding.json new file mode 100644 index 00000000..3bfeef70 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/amqp/amqpOperationBinding.json @@ -0,0 +1,17 @@ +{ + "expiration": 100000, + "userId": "guest", + "cc": [ + "user.logs" + ], + "priority": 10, + "deliveryMode": 2, + "mandatory": false, + "bcc": [ + "external.audit" + ], + "replyTo": "user.signedup", + "timestamp": true, + "ack": false, + "bindingVersion": "0.2.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/http/httpOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/http/httpOperationBinding - extended.json new file mode 100644 index 00000000..70152613 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/http/httpOperationBinding - extended.json @@ -0,0 +1,22 @@ +{ + "type" : "request", + "method" : "GET", + "query" : { + "type" : "object", + "required" : [ "companyId" ], + "properties" : { + "companyId" : { + "description" : "The Id of the company.", + "type" : "number", + "minimum" : 1 + } + }, + "additionalProperties" : false + }, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/http/httpOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/http/httpOperationBinding - wrongly extended.json new file mode 100644 index 00000000..278fb5ae --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/http/httpOperationBinding - wrongly extended.json @@ -0,0 +1,25 @@ +{ + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/http/httpOperationBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/http/httpOperationBinding.json new file mode 100644 index 00000000..d832076d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/http/httpOperationBinding.json @@ -0,0 +1,19 @@ +{ + "type": "request", + "method": "GET", + "query": { + "type": "object", + "required": [ + "companyId" + ], + "properties": { + "companyId": { + "type": "number", + "minimum": 1, + "description": "The Id of the company." + } + }, + "additionalProperties": false + }, + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/kafka/kafkaOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/kafka/kafkaOperationBinding - extended.json new file mode 100644 index 00000000..c86580a4 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/kafka/kafkaOperationBinding - extended.json @@ -0,0 +1,16 @@ +{ + "bindingVersion" : "0.4.0", + "groupId" : { + "type" : "string", + "enum" : [ "myGroupId" ] + }, + "clientId" : { + "type" : "string", + "enum" : [ "myClientId" ] + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/kafka/kafkaOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/kafka/kafkaOperationBinding - wrongly extended.json new file mode 100644 index 00000000..a36503dd --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/kafka/kafkaOperationBinding - wrongly extended.json @@ -0,0 +1,21 @@ +{ + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/kafka/kafkaOperationBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/kafka/kafkaOperationBinding.json new file mode 100644 index 00000000..542d1fe2 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/kafka/kafkaOperationBinding.json @@ -0,0 +1,15 @@ +{ + "groupId": { + "type": "string", + "enum": [ + "myGroupId" + ] + }, + "clientId": { + "type": "string", + "enum": [ + "myClientId" + ] + }, + "bindingVersion": "0.4.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/mqtt/mqttOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/mqtt/mqttOperationBinding - extended.json new file mode 100644 index 00000000..987a9860 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/mqtt/mqttOperationBinding - extended.json @@ -0,0 +1,10 @@ +{ + "qos" : 2, + "retain" : true, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/mqtt/mqttOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/mqtt/mqttOperationBinding - wrongly extended.json new file mode 100644 index 00000000..6a0014f5 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/mqtt/mqttOperationBinding - wrongly extended.json @@ -0,0 +1,11 @@ +{ + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/mqtt/mqttOperationBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/mqtt/mqttOperationBinding.json new file mode 100644 index 00000000..7500db5c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/mqtt/mqttOperationBinding.json @@ -0,0 +1,5 @@ +{ + "qos": 2, + "retain": true, + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/nats/natsOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/nats/natsOperationBinding - extended.json new file mode 100644 index 00000000..2a77c3b3 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/nats/natsOperationBinding - extended.json @@ -0,0 +1,9 @@ +{ + "queue" : "messages", + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/nats/natsOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/nats/natsOperationBinding - wrongly extended.json new file mode 100644 index 00000000..1c6e0e8e --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/nats/natsOperationBinding - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "queue": "messages", + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/nats/natsOperationBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/nats/natsOperationBinding.json new file mode 100644 index 00000000..53d874bb --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/nats/natsOperationBinding.json @@ -0,0 +1,4 @@ +{ + "queue": "messages", + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/solace/solaceOperationBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/solace/solaceOperationBinding - extended.json new file mode 100644 index 00000000..97da1987 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/solace/solaceOperationBinding - extended.json @@ -0,0 +1,29 @@ +{ + "destinations" : [ { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "CreatedHREvents", + "topicSubscriptions" : [ "person/*/created" ], + "accessType" : "exclusive", + "maxMsgSpoolSize" : "1,500", + "maxTtl" : "60" + } + }, { + "destinationType" : "queue", + "deliveryMode" : "persistent", + "queue" : { + "name" : "UpdatedHREvents", + "topicSubscriptions" : [ "person/*/updated" ] + }, + "topic" : { + "topicSubscriptions" : [ "person/*/updated" ] + } + } ], + "bindingVersion" : "0.3.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/solace/solaceOperationBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/solace/solaceOperationBinding - wrongly extended.json new file mode 100644 index 00000000..ef371f24 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/solace/solaceOperationBinding - wrongly extended.json @@ -0,0 +1,37 @@ +{ + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/operation/solace/solaceOperationBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/operation/solace/solaceOperationBinding.json new file mode 100644 index 00000000..e5b10158 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/operation/solace/solaceOperationBinding.json @@ -0,0 +1,31 @@ +{ + "destinations": [ + { + "destinationType": "queue", + "queue": { + "name": "CreatedHREvents", + "topicSubscriptions": [ + "person/*/created" + ], + "accessType": "exclusive", + "maxMsgSpoolSize": "1,500", + "maxTtl": "60" + } + }, + { + "destinationType": "queue", + "queue": { + "name": "UpdatedHREvents", + "topicSubscriptions": [ + "person/*/updated" + ] + }, + "topic": { + "topicSubscriptions": [ + "person/*/updated" + ] + } + } + ], + "bindingVersion": "0.3.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/ibmmq/ibmmqServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/ibmmq/ibmmqServerBinding - extended.json new file mode 100644 index 00000000..53447913 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/ibmmq/ibmmqServerBinding - extended.json @@ -0,0 +1,13 @@ +{ + "groupId" : "PRODCLSTR1", + "ccdtQueueManagerName" : "*", + "cipherSpec" : "ANY_TLS12_OR_HIGHER", + "multiEndpointServer" : false, + "heartBeatInterval" : 300, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/ibmmq/ibmmqServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/ibmmq/ibmmqServerBinding - wrongly extended.json new file mode 100644 index 00000000..81ed7a44 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/ibmmq/ibmmqServerBinding - wrongly extended.json @@ -0,0 +1,14 @@ +{ + "groupId": "PRODCLSTR1", + "ccdtQueueManagerName": "*", + "multiEndpointServer": false, + "heartBeatInterval": 300, + "cipherSpec": "ANY_TLS12_OR_HIGHER", + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/ibmmq/ibmmqServerBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/server/ibmmq/ibmmqServerBinding.json new file mode 100644 index 00000000..cde4b02d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/ibmmq/ibmmqServerBinding.json @@ -0,0 +1,8 @@ +{ + "groupId": "PRODCLSTR1", + "ccdtQueueManagerName": "*", + "multiEndpointServer": false, + "heartBeatInterval": 300, + "cipherSpec": "ANY_TLS12_OR_HIGHER", + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/kafka/kafkaServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/kafka/kafkaServerBinding - extended.json new file mode 100644 index 00000000..a0349c5c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/kafka/kafkaServerBinding - extended.json @@ -0,0 +1,10 @@ +{ + "schemaRegistryUrl" : "https://my-schema-registry.com", + "schemaRegistryVendor" : "confluent", + "bindingVersion" : "0.4.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/kafka/kafkaServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/kafka/kafkaServerBinding - wrongly extended.json new file mode 100644 index 00000000..00eee56a --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/kafka/kafkaServerBinding - wrongly extended.json @@ -0,0 +1,11 @@ +{ + "schemaRegistryUrl": "https://my-schema-registry.com", + "schemaRegistryVendor": "confluent", + "bindingVersion": "0.4.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/kafka/kafkaServerBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/server/kafka/kafkaServerBinding.json new file mode 100644 index 00000000..cc2f24e8 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/kafka/kafkaServerBinding.json @@ -0,0 +1,5 @@ +{ + "schemaRegistryUrl": "https://my-schema-registry.com", + "schemaRegistryVendor": "confluent", + "bindingVersion": "0.4.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt/mqttServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt/mqttServerBinding - extended.json new file mode 100644 index 00000000..304ed881 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt/mqttServerBinding - extended.json @@ -0,0 +1,17 @@ +{ + "clientId" : "guest", + "cleanSession" : true, + "lastWill" : { + "topic" : "/last-wills", + "qos" : 2, + "message" : "Guest gone offline.", + "retain" : false + }, + "keepAlive" : 60, + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt/mqttServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt/mqttServerBinding - wrongly extended.json new file mode 100644 index 00000000..e3c8e972 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt/mqttServerBinding - wrongly extended.json @@ -0,0 +1,18 @@ +{ + "clientId": "guest", + "cleanSession": true, + "lastWill": { + "topic": "/last-wills", + "qos": 2, + "message": "Guest gone offline.", + "retain": false + }, + "keepAlive": 60, + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt/mqttServerBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt/mqttServerBinding.json new file mode 100644 index 00000000..e5073c57 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt/mqttServerBinding.json @@ -0,0 +1,12 @@ +{ + "clientId": "guest", + "cleanSession": true, + "lastWill": { + "topic": "/last-wills", + "qos": 2, + "message": "Guest gone offline.", + "retain": false + }, + "keepAlive": 60, + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt5/mqtt5ServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt5/mqtt5ServerBinding - extended.json new file mode 100644 index 00000000..1104cd11 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt5/mqtt5ServerBinding - extended.json @@ -0,0 +1,9 @@ +{ + "sessionExpiryInterval" : 60, + "bindingVersion" : "0.2.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt5/mqtt5ServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt5/mqtt5ServerBinding - wrongly extended.json new file mode 100644 index 00000000..ce682d11 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt5/mqtt5ServerBinding - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "sessionExpiryInterval": 60, + "bindingVersion": "0.2.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt5/mqtt5ServerBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt5/mqtt5ServerBinding.json new file mode 100644 index 00000000..1c422293 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/mqtt5/mqtt5ServerBinding.json @@ -0,0 +1,4 @@ +{ + "sessionExpiryInterval": 60, + "bindingVersion": "0.2.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/pulsar/pulsarServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/pulsar/pulsarServerBinding - extended.json new file mode 100644 index 00000000..de267c67 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/pulsar/pulsarServerBinding - extended.json @@ -0,0 +1,9 @@ +{ + "tenant" : "contoso", + "bindingVersion" : "0.1.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/pulsar/pulsarServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/pulsar/pulsarServerBinding - wrongly extended.json new file mode 100644 index 00000000..380c5cb2 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/pulsar/pulsarServerBinding - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "tenant": "contoso", + "bindingVersion": "0.1.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/pulsar/pulsarServerBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/server/pulsar/pulsarServerBinding.json new file mode 100644 index 00000000..bc86f5c2 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/pulsar/pulsarServerBinding.json @@ -0,0 +1,4 @@ +{ + "tenant": "contoso", + "bindingVersion": "0.1.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/solace/solaceServerBinding - extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/solace/solaceServerBinding - extended.json new file mode 100644 index 00000000..4e9101f6 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/solace/solaceServerBinding - extended.json @@ -0,0 +1,9 @@ +{ + "msgVpn" : "solace.private.net", + "bindingVersion" : "0.3.0", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/solace/solaceServerBinding - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/binding/server/solace/solaceServerBinding - wrongly extended.json new file mode 100644 index 00000000..f6e4672f --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/solace/solaceServerBinding - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "msgVpn": "solace.private.net", + "bindingVersion": "0.3.0", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/binding/server/solace/solaceServerBinding.json b/asyncapi-core/src/test/resources/json/v3/binding/server/solace/solaceServerBinding.json new file mode 100644 index 00000000..1e86ad5a --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/binding/server/solace/solaceServerBinding.json @@ -0,0 +1,4 @@ +{ + "msgVpn": "solace.private.net", + "bindingVersion": "0.3.0" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/X509 - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/X509 - extended.json new file mode 100644 index 00000000..46699754 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/X509 - extended.json @@ -0,0 +1,9 @@ +{ + "type" : "X509", + "description" : "X509", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/X509 - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/X509 - wrongly extended.json new file mode 100644 index 00000000..42acde6f --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/X509 - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "type": "X509", + "description": "X509", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/X509.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/X509.json new file mode 100644 index 00000000..a2355018 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/X509.json @@ -0,0 +1,4 @@ +{ + "type": "X509", + "description": "X509" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/apiKey - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/apiKey - extended.json new file mode 100644 index 00000000..a50ce65d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/apiKey - extended.json @@ -0,0 +1,10 @@ +{ + "type" : "apiKey", + "description" : "apiKey", + "in" : "user", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/apiKey - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/apiKey - wrongly extended.json new file mode 100644 index 00000000..4833f8a5 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/apiKey - wrongly extended.json @@ -0,0 +1,11 @@ +{ + "type": "apiKey", + "description": "apiKey", + "in": "user", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/apiKey.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/apiKey.json new file mode 100644 index 00000000..b5f91e04 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/apiKey.json @@ -0,0 +1,5 @@ +{ + "type": "apiKey", + "description": "apiKey", + "in": "user" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/asymmetricEncryption - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/asymmetricEncryption - extended.json new file mode 100644 index 00000000..8c6b124c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/asymmetricEncryption - extended.json @@ -0,0 +1,9 @@ +{ + "type" : "asymmetricEncryption", + "description" : "asymmetricEncryption", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/asymmetricEncryption - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/asymmetricEncryption - wrongly extended.json new file mode 100644 index 00000000..fdf5491f --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/asymmetricEncryption - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "type": "asymmetricEncryption", + "description": "asymmetricEncryption", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/asymmetricEncryption.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/asymmetricEncryption.json new file mode 100644 index 00000000..db927521 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/asymmetricEncryption.json @@ -0,0 +1,4 @@ +{ + "type": "asymmetricEncryption", + "description": "asymmetricEncryption" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/gssapi - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/gssapi - extended.json new file mode 100644 index 00000000..636a9ddc --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/gssapi - extended.json @@ -0,0 +1,9 @@ +{ + "type" : "gssapi", + "description" : "gssapi", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/gssapi - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/gssapi - wrongly extended.json new file mode 100644 index 00000000..7307abaf --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/gssapi - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "type": "gssapi", + "description": "gssapi", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/gssapi.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/gssapi.json new file mode 100644 index 00000000..b45a1317 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/gssapi.json @@ -0,0 +1,4 @@ +{ + "type": "gssapi", + "description": "gssapi" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpApiKey - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpApiKey - extended.json new file mode 100644 index 00000000..5ab385b3 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpApiKey - extended.json @@ -0,0 +1,11 @@ +{ + "type" : "httpApiKey", + "description" : "httpApiKey", + "name" : "api_key", + "in" : "header", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpApiKey - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpApiKey - wrongly extended.json new file mode 100644 index 00000000..767730b1 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpApiKey - wrongly extended.json @@ -0,0 +1,12 @@ +{ + "type": "httpApiKey", + "description": "httpApiKey", + "name": "api_key", + "in": "header", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpApiKey.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpApiKey.json new file mode 100644 index 00000000..467469f5 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpApiKey.json @@ -0,0 +1,6 @@ +{ + "type": "httpApiKey", + "description": "httpApiKey", + "name": "api_key", + "in": "header" +} diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBasic - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBasic - extended.json new file mode 100644 index 00000000..5477e747 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBasic - extended.json @@ -0,0 +1,10 @@ +{ + "type" : "http", + "description" : "http", + "scheme" : "basic", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBasic - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBasic - wrongly extended.json new file mode 100644 index 00000000..5c4e3887 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBasic - wrongly extended.json @@ -0,0 +1,11 @@ +{ + "type": "http", + "description": "http", + "scheme": "basic", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBasic.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBasic.json new file mode 100644 index 00000000..38f712e1 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBasic.json @@ -0,0 +1,5 @@ +{ + "type": "http", + "description": "http", + "scheme": "basic" +} diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBearer - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBearer - extended.json new file mode 100644 index 00000000..1a371df6 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBearer - extended.json @@ -0,0 +1,11 @@ +{ + "type" : "http", + "description" : "http", + "scheme" : "bearer", + "bearerFormat" : "JWT", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBearer - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBearer - wrongly extended.json new file mode 100644 index 00000000..cfdc83f2 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBearer - wrongly extended.json @@ -0,0 +1,12 @@ +{ + "type": "http", + "description": "http", + "scheme": "bearer", + "bearerFormat": "JWT", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBearer.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBearer.json new file mode 100644 index 00000000..68da22ef --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/http/httpBearer.json @@ -0,0 +1,6 @@ +{ + "type": "http", + "description": "http", + "scheme": "bearer", + "bearerFormat": "JWT" +} diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - extended.json new file mode 100644 index 00000000..46d99302 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - extended.json @@ -0,0 +1,14 @@ +{ + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "authorizationUrl" : "https://example.com/api/oauth/dialog", + "tokenUrl" : "https://example.com/api/oauth/token", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - wrongly extended.json new file mode 100644 index 00000000..19240f8f --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow - wrongly extended.json @@ -0,0 +1,15 @@ +{ + "authorizationUrl": "https://example.com/api/oauth/dialog", + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow.json new file mode 100644 index 00000000..74711855 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/authorizationCodeOAuthFlow.json @@ -0,0 +1,9 @@ +{ + "authorizationUrl": "https://example.com/api/oauth/dialog", + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - extended.json new file mode 100644 index 00000000..c211a2d9 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - extended.json @@ -0,0 +1,13 @@ +{ + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "tokenUrl" : "https://example.com/api/oauth/token", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - wrongly extended.json new file mode 100644 index 00000000..b5d31e51 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow - wrongly extended.json @@ -0,0 +1,14 @@ +{ + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow.json new file mode 100644 index 00000000..0c1ea575 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/clientCredentialsOAuthFlow.json @@ -0,0 +1,8 @@ +{ + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow - extended.json new file mode 100644 index 00000000..43c50d71 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow - extended.json @@ -0,0 +1,13 @@ +{ + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "authorizationUrl" : "https://example.com/api/oauth/dialog", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow - wrongly extended.json new file mode 100644 index 00000000..215f12ae --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow - wrongly extended.json @@ -0,0 +1,14 @@ +{ + "authorizationUrl": "https://example.com/api/oauth/dialog", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow.json new file mode 100644 index 00000000..d0c0526a --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/implicitOAuthFlow.json @@ -0,0 +1,8 @@ +{ + "authorizationUrl": "https://example.com/api/oauth/dialog", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/oauthFlow - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/oauthFlow - extended.json new file mode 100644 index 00000000..cb45fb58 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/oauthFlow - extended.json @@ -0,0 +1,12 @@ +{ + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/oauthFlow - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/oauthFlow - wrongly extended.json new file mode 100644 index 00000000..511f29d1 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/oauthFlow - wrongly extended.json @@ -0,0 +1,13 @@ +{ + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/oauthFlow.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/oauthFlow.json new file mode 100644 index 00000000..9b766a37 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/oauthFlow.json @@ -0,0 +1,7 @@ +{ + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow - extended.json new file mode 100644 index 00000000..c211a2d9 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow - extended.json @@ -0,0 +1,13 @@ +{ + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "tokenUrl" : "https://example.com/api/oauth/token", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow - wrongly extended.json new file mode 100644 index 00000000..b5d31e51 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow - wrongly extended.json @@ -0,0 +1,14 @@ +{ + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow.json new file mode 100644 index 00000000..0c1ea575 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/flow/passwordOAuthFlow.json @@ -0,0 +1,8 @@ +{ + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauth2 - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauth2 - extended.json new file mode 100644 index 00000000..3e2171a7 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauth2 - extended.json @@ -0,0 +1,45 @@ +{ + "type" : "oauth2", + "description" : "oauth2", + "flows" : { + "implicit" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "authorizationUrl" : "https://example.com/api/oauth/dialog" + }, + "password" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "tokenUrl" : "https://example.com/api/oauth/token" + }, + "clientCredentials" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "tokenUrl" : "https://example.com/api/oauth/token" + }, + "authorizationCode" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "authorizationUrl" : "https://example.com/api/oauth/dialog", + "tokenUrl" : "https://example.com/api/oauth/token" + } + }, + "scopes" : [ "write:pets", "read:pets" ], + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauth2 - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauth2 - wrongly extended.json new file mode 100644 index 00000000..2b4b9899 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauth2 - wrongly extended.json @@ -0,0 +1,46 @@ +{ + "type": "oauth2", + "description": "oauth2", + "flows": { + "authorizationCode": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "clientCredentials": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "implicit": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "password": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + } + }, + "scopes": [ "write:pets", "read:pets" ], + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauth2.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauth2.json new file mode 100644 index 00000000..2adf3db5 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauth2.json @@ -0,0 +1,40 @@ +{ + "type": "oauth2", + "description": "oauth2", + "flows": { + "authorizationCode": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "clientCredentials": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "implicit": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "password": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + } + }, + "scopes": [ "write:pets", "read:pets" ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauthFlows - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauthFlows - extended.json new file mode 100644 index 00000000..6ed27910 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauthFlows - extended.json @@ -0,0 +1,40 @@ +{ + "implicit" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "authorizationUrl" : "https://example.com/api/oauth/dialog" + }, + "password" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "tokenUrl" : "https://example.com/api/oauth/token" + }, + "clientCredentials" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "tokenUrl" : "https://example.com/api/oauth/token" + }, + "authorizationCode" : { + "refreshUrl" : "https://example.com/api/oauth/refresh", + "scopes" : { + "write:pets" : "modify pets in your account", + "read:pets" : "read your pets" + }, + "authorizationUrl" : "https://example.com/api/oauth/dialog", + "tokenUrl" : "https://example.com/api/oauth/token" + }, + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauthFlows - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauthFlows - wrongly extended.json new file mode 100644 index 00000000..8bc0ba04 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauthFlows - wrongly extended.json @@ -0,0 +1,41 @@ +{ + "authorizationCode": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "clientCredentials": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "implicit": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "password": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauthFlows.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauthFlows.json new file mode 100644 index 00000000..11671049 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/oauth2/oauthFlows.json @@ -0,0 +1,35 @@ +{ + "authorizationCode": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "clientCredentials": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "implicit": { + "authorizationUrl": "https://example.com/api/oauth/dialog", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + }, + "password": { + "tokenUrl": "https://example.com/api/oauth/token", + "refreshUrl": "https://example.com/api/oauth/refresh", + "scopes": { + "write:pets": "modify pets in your account", + "read:pets": "read your pets" + } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/openIdConnect - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/openIdConnect - extended.json new file mode 100644 index 00000000..cfd5a756 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/openIdConnect - extended.json @@ -0,0 +1,11 @@ +{ + "type" : "openIdConnect", + "description" : "openIdConnect", + "openIdConnectUrl" : "https://server.com/.well-known/openid-configuration", + "scopes" : [ "write:pets", "read:pets" ], + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/openIdConnect - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/openIdConnect - wrongly extended.json new file mode 100644 index 00000000..66338a6d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/openIdConnect - wrongly extended.json @@ -0,0 +1,15 @@ +{ + "type": "openIdConnect", + "description": "openIdConnect", + "openIdConnectUrl": "https://server.com/.well-known/openid-configuration", + "scopes": [ + "write:pets", + "read:pets" + ], + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/openIdConnect.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/openIdConnect.json new file mode 100644 index 00000000..49747b8c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/openIdConnect.json @@ -0,0 +1,9 @@ +{ + "type": "openIdConnect", + "description": "openIdConnect", + "openIdConnectUrl": "https://server.com/.well-known/openid-configuration", + "scopes": [ + "write:pets", + "read:pets" + ] +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/plain - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/plain - extended.json new file mode 100644 index 00000000..135a087a --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/plain - extended.json @@ -0,0 +1,9 @@ +{ + "type" : "plain", + "description" : "plain", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/plain - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/plain - wrongly extended.json new file mode 100644 index 00000000..7cdcc873 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/plain - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "type": "plain", + "description": "plain", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/plain.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/plain.json new file mode 100644 index 00000000..9bda0b46 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/plain.json @@ -0,0 +1,4 @@ +{ + "type": "plain", + "description": "plain" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha256 - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha256 - extended.json new file mode 100644 index 00000000..c338b045 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha256 - extended.json @@ -0,0 +1,9 @@ +{ + "type" : "scramSha256", + "description" : "scramSha256", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha256 - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha256 - wrongly extended.json new file mode 100644 index 00000000..7042bea1 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha256 - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "type": "scramSha256", + "description": "scramSha256", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha256.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha256.json new file mode 100644 index 00000000..b6f35d52 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha256.json @@ -0,0 +1,4 @@ +{ + "type": "scramSha256", + "description": "scramSha256" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha512 - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha512 - extended.json new file mode 100644 index 00000000..17a21d8d --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha512 - extended.json @@ -0,0 +1,9 @@ +{ + "type" : "scramSha512", + "description" : "scramSha512", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha512 - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha512 - wrongly extended.json new file mode 100644 index 00000000..50109d93 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha512 - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "type": "scramSha512", + "description": "scramSha512", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha512.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha512.json new file mode 100644 index 00000000..52481a68 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/scramSha512.json @@ -0,0 +1,4 @@ +{ + "type": "scramSha512", + "description": "scramSha512" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/symmetricEncryption - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/symmetricEncryption - extended.json new file mode 100644 index 00000000..d4915691 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/symmetricEncryption - extended.json @@ -0,0 +1,9 @@ +{ + "type" : "symmetricEncryption", + "description" : "symmetricEncryption", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/symmetricEncryption - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/symmetricEncryption - wrongly extended.json new file mode 100644 index 00000000..81bb0e1c --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/symmetricEncryption - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "type": "symmetricEncryption", + "description": "symmetricEncryption", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/symmetricEncryption.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/symmetricEncryption.json new file mode 100644 index 00000000..58aa4d19 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/symmetricEncryption.json @@ -0,0 +1,4 @@ +{ + "type": "symmetricEncryption", + "description": "symmetricEncryption" +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/userPassword - extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/userPassword - extended.json new file mode 100644 index 00000000..721e5559 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/userPassword - extended.json @@ -0,0 +1,9 @@ +{ + "type" : "userPassword", + "description" : "userPassword", + "x-number" : 0, + "x-string" : "", + "x-object" : { + "property" : { } + } +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/userPassword - wrongly extended.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/userPassword - wrongly extended.json new file mode 100644 index 00000000..e0d85aa5 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/userPassword - wrongly extended.json @@ -0,0 +1,10 @@ +{ + "type": "userPassword", + "description": "userPassword", + "x-number": 0, + "x-string": "", + "x-object": { + "property": {} + }, + "ext-number": 1 +} \ No newline at end of file diff --git a/asyncapi-core/src/test/resources/json/v3/security_scheme/userPassword.json b/asyncapi-core/src/test/resources/json/v3/security_scheme/userPassword.json new file mode 100644 index 00000000..4d9a3cc3 --- /dev/null +++ b/asyncapi-core/src/test/resources/json/v3/security_scheme/userPassword.json @@ -0,0 +1,4 @@ +{ + "type": "userPassword", + "description": "userPassword" +} \ No newline at end of file