#%RAML 0.8 title: Stream version: 1 baseUri: https://api.us1.covisint.com/stream/v1 schemas: - resourceReference: | { "id" : "http://api.covisint.com/schema/resourceReference", "$schema" : "http://json-schema.org/draft-04/schema", "description" : "Schema representing links", "type" : "object", "properties" : { "id" : { "type" : "string", "description" : "The unique identifier for the resource.", "required": true }, "type" : { "type" : "string", "description" : "The type of the resource." }, "realm" : { "type" : "string", "description" : "The realm of the resource." } } } - namedResourceReference: "{\n \"id\" : \"http://api.covisint.com/schema/namedScopedResource\",\n \ \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"type\" : \"object\",\n \ \"description\" : \"Expands on the basic resource reference and adds internationalized name and description.\",\n \"extends\" : {\n \"$ref\" : \"http://api.covisint.com/schema/resourceReference#\"\n \ },\n \"properties\" : {\n \"name\" : { \n \"description\": \"Internationalized resource name.\",\n \"$ref\" : \"http://api.covisint.com/idm/schema/internationalString#\"\n \ },\n \"description\" : { \n \"description\": \"Internationalized resource description.\",\n \"$ref\" : \"http://api.covisint.com/idm/schema/internationalString#\"\n \ }\n }\n}\n" - resource: | { "id" : "http://api.covisint.com/schema/resource", "$schema" : "http://json-schema.org/draft-04/schema", "description" : "Core schema", "definitions" : { "resource" : { "id" : "resource", "type" : "object", "description" : "A basic resource.", "properties" : { "id" : { "type" : "string", "maxLength" : 64, "description" : "The unique identifier for this resource.", "required": true }, "version": { "type" : "number", "minimum" : 0, "maximum" : 9223372036854775807, "description" : "The current version for this resource. Exists once the resource has been saved. This is mandatory for PUT requests, but should not be supplied for POST requests.", "required": false }, "creator" : { "type" : "string", "maxLength" : 64, "description" : "The creator of this resource. This read-only field is ignored by the server, and is overlayed with the value supplied in the x-requestor header.", "required": true, "readonly": true }, "creatorAppId" : { "type" : "string", "maxLength" : 64, "description" : "The id of the application used to create this resource. This read-only field is ignored by the server, and is overlayed with the value supplied in the x-requestor-app header.", "required": true, "readonly": true }, "creation" : { "type" : "number", "minimum" : 0, "maximum" : 9223372036854775807, "description" : "This read only property is ignored by the server and the system will overlay with the time, in milliseconds since the epoch, when this resource was created.", "required": true, "readonly": true } } } } } - resourceV2: "{\n \"id\" : \"http://api.covisint.com/schema/resourceV2\",\n \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"description\" : \"Core schema\",\n \ \"definitions\" : {\n \"resource\" : {\n \"id\" : \"resourceV2\",\n \ \"type\" : \"object\",\n \"description\" : \"A basic resource (version V2).\",\n \"properties\" : {\n \"id\" : {\n \"type\" : \"string\",\n \ \"maxLength\" : 64,\n \"description\" : \"The unique identifier for this resource.\",\n \"required\": true\n },\n \"version\": {\n \"type\" : \"string\",\n \"description\" : \"The current version for this resource. Exists once the resource has been saved. This is mandatory for PUT requests, but should not be supplied for POST requests.\",\n \"required\": false\n },\n \"creator\" : {\n \"type\" : \"string\",\n \ \"maxLength\" : 64,\n \"description\" : \"The creator of this resource. This read-only field is ignored by the server, and is overlayed with the value supplied in the x-requestor header.\",\n \"required\": true,\n \ \"readonly\": true\n },\n \"creatorAppId\" : {\n \"type\" : \"string\",\n \"maxLength\" : 64,\n \"description\" : \"The id of the application used to create this resource. This read-only field is ignored by the server, and is overlayed with the value supplied in the x-requestor-app header.\",\n \"required\": true,\n \"readonly\": true\n },\n \ \"creation\" : {\n \"type\" : \"number\",\n \"minimum\" : 0,\n \"maximum\" : 9223372036854775807,\n \"description\" : \"This read only property is ignored by the server and the system will overlay with the time, in milliseconds since the epoch, when this resource was created.\",\n \ \"required\": true,\n \"readonly\": true\n }\n }\n \ }\n } \n}\n" - realmScopedResource: "{\n \"id\" : \"http://api.covisint.com/schema/realmScopedResource\",\n \ \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"type\" : \"object\",\n \ \"description\" : \"Expands on the base resource and adds a realm attribute.\",\n \ \"extends\" : {\n \"$ref\" : \"http://api.covisint.com/schema/resource#\"\n \ },\n \"properties\" : {\n \"realm\" : {\n \"type\" : \"string\",\n \ \"maxLength\" : 25,\n \"pattern\" : \"^[A-Za-z0-9]{2,25}$\",\n \"description\" : \"The realm in which this resource is being created. This read-only field is ignored by the server, and is overlayed with the value supplied in the x-realm header.\",\n \"required\": true,\n \"readonly\": true \n \ }\n }\n}\n" - realmScopedResourceV2: "{\n \"id\" : \"http://api.covisint.com/schema/realmScopedResourceV2\",\n \ \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"type\" : \"object\",\n \ \"description\" : \"A realm scoped resource (version V2). Expands on the base resource (version V2) and adds a realm attribute.\",\n \"extends\" : {\n \"$ref\" : \"http://api.covisint.com/schema/resourceV2#\"\n },\n \"properties\" : {\n \ \"realm\" : {\n \"type\" : \"string\",\n \"maxLength\" : 25,\n \"pattern\" : \"^[A-Za-z0-9]{2,25}$\",\n \"description\" : \"The realm in which this resource is being created. This read-only field is ignored by the server, and is overlayed with the value supplied in the x-realm header.\",\n \"required\": true,\n \"readonly\": true \n }\n }\n} \n" - errorResponseSchema: "{\n \"id\" : \"http://api.covisint.com/schema/errorResponseSchema\",\n \ \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"type\" : \"object\",\n \ \"description\" : \"Representation of an HTTP 4xx/5xx error response.\",\n \"properties\" : {\n \"status\" : { \n \"type\" : \"number\",\n \"minimum\" : 400,\n \ \"maximum\" : 599,\n \"description\" : \"The HTTP status code.\",\n \ \"required\": true\n },\n \"apiMessage\" : { \n \"type\" : \"string\",\n \ \"description\" : \"A helpful, human-readable description of the error, useful for basic diagnostics.\" \n },\n \"apiStatusCode\" : {\n \"type\" : \"string\",\n \"description\" : \"The API-specific status code.\"\n }\n \ }\n}\n" - serviceCode: "{\n \"id\" : \"http://api.covisint.com/schema/serviceCodes\",\n \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"type\": \"object\",\n \"description\": \"The site/service/location codes granted along with a service.\",\n \"properties\": {\n \"code\": { \"type\": \"string\", \"required\": true, \"maxLength\": 200, \"description\": \"The code value.\" },\n \"codeKind\": { \"type\": \"string\", \"required\": true, \"maxLength\": 36, \"description\": \"The associated business unit.\" }\n }\n} \n" - serviceCodes: | { "type" : "array", "description" : "The site/service/location codes granted along with the service, if any.", "items" : { "$ref" : "http://api.covisint.com/schema/serviceCode#"}, "required": false } - address: | { "id" : "http://api.covisint.com/idm/schema/address", "$schema" : "http://json-schema.org/draft-04/schema", "type" : "object", "description" : "A container for the subject's address elements.", "properties" : { "streets" : { "type" : "array", "description" : "An array of address streets (i.e. address line 1, 2, 3).", "minItems" : 0, "items" : { "type" : "string", "maxLength" : 255 } }, "city" : { "type" : "string", "maxLength" : 60, "description" : "The city name." }, "state" : { "type" : "string", "maxLength" : 60, "description" : "The state/province name or code." }, "postal" : { "type" : "string", "maxLength" : 10, "description" : "The postal or zip code." }, "country" : { "type" : "string", "minLength" : 2, "maxLength" : 3, "description" : "The ISO country code. http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2"} } } - phone: "{\n \"id\" : \"http://api.covisint.com/idm/schema/phone\",\n \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"type\" : \"object\",\n \"description\" : \"A container for phone number details.\",\n \"properties\" : {\n \"number\" : { \"type\" : \"string\",\"maxLength\" : 100, \"description\" : \"The phone number.\" },\n \"type\" : { \"enum\" : [ \"main\", \"mobile\", \"fax\" ], \"description\" : \"The phone number type.\" }\n },\n \"required\" : [ \"type\" ]\n} \n" - internationalString: | { "id": "http://api.covisint.com/idm/schema/internationalString", "$schema": "http://json-schema.org/draft-04/schema", "type": "array", "description" : "An internationalized string value, supporting one or more language translations.", "minItems": 1, "items": { "type": "object", "properties": { "lang": { "type": "string", "maxLength": 10, "description": "The language or locale in which the text is written." }, "text": { "type": "string", "maxLength": 2000, "description": "The internationalized text value." } } } } - tags: | { "id": "http://api.covisint.com/idm/schema/tag", "$schema": "http://json-schema.org/draft-04/schema", "type": "array", "description" : "The tags associated with a resource. This array is read-only, and may be modified on the resource endpoint with the appropriate tagging APIs.", "minItems": 1, "items": { "type": "object", "properties": { "tagName": { "type": "string", "description": "The tag associated with a resource." } } } } - baseDefinitionResource: "{\n \"id\" : \"http://api.covisint.com/schema/baseDefinitionResource\",\n \ \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"type\" : \"object\",\n \ \"description\" : \"A base rule definition(version V1). Expands on the base resource (version V2) and adds a realm attribute.\",\n \"extends\": {\n \"$ref\" : \"http://api.covisint.com/schema/realmScopedResourceV2#\"\n },\n \"properties\": {\n \"name\": {\n \"description\": \"The application name (internationalized).\",\n \ \"required\": true,\n \"$ref\": \"http://api.covisint.com/schema/internationalString#\"\n \ },\n \"description\": {\n \"required\": false,\n \"description\": \"The application description (internationalized).\",\n \"$ref\" : \"http://api.covisint.com/idm/schema/internationalString#\"\n \ }, \n \"properties\":{\n \"type\":\"array\",\n \"description\":\"Properties used by the implementation.\",\n \"required\":false,\n \"minItems\":0,\n \ \"items\":[ \n { \n \"anyOf\": [\n {\n \ \"type\": \"string\",\n \"description\": \"The name of the property.\",\n \"required\": true\n },\n \ {\n \"type\": \"string\",\n \"description\": \"The value of the property.\",\n \"required\": true\n }\n \ ]\n }\n ]\n }\n }\n}\n" - baseActionDefinitionResource: | { "id" : "http://api.covisint.com/schema/baseActionDefinitionResource", "$schema" : "http://json-schema.org/draft-04/schema", "type" : "object", "description" : "A base action action definition. Expands on the base definition resource ", "extends": { "$ref" : "http://api.covisint.com/schema/baseDefinitionResource#" }, "properties": { "type": { "description": "Type of action definition.", "enum": [ "SEND_APPLICATION_NOTIFICATION", "SEND_COMMAND", "SEND_NOTIFICATION" ], "required": true } } } - baseTriggerDefinitionResource: | { "id" : "http://api.covisint.com/schema/baseTriggerDefinitionResource", "$schema" : "http://json-schema.org/draft-04/schema", "type" : "object", "description" : "A base action trigger definition. Expands on the base definition resource ", "extends": { "$ref" : "http://api.covisint.com/schema/baseDefinitionResource#" }, "properties": { "type": { "description": "Type of trigger definition.", "enum": [ "DEVICE_SEND_EVENT", "DEVICE_LIFECYCLE_STATE_CHANGE", "DEVICE_OPERATIONAL_STATE_CHANGE" ], "required": true } } } - dataType: "{\n \"id\" : \"http://api.covisint.com/schema/dataType\",\n \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"description\" : \"Data type enum.\",\n \"enum\":[ \n \"string\",\n \"integer\",\n \"bool\",\n \ \"decimal\"\n ]\n}\n" - attribute: "{\n \"id\" : \"http://api.covisint.com/schema/attribute\",\n \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"type\" : \"object\",\n \"description\" : \"An attribute.\",\n \"properties\" : {\n \"oneOf\" : [\n {\n \"attributeTypeId\" : {\n \"type\" : \"string\",\n \"description\" : \"The attribute type id.\",\n \"required\" : true\n }\n },\n { \n \"attributeType\" : {\n \"description\" : \"The full attribute type definition.\",\n \"$ref\" : \"http://api.covisint.com/schema/attributeType#\" \n }\n }\n ],\n \ \"value\" : {\n \"type\" : \"any\",\n \"description\" : \"The attribute value.\",\n \"required\" : false\n }\n }\n}\n" - attributes: "{\n \"id\" : \"http://api.covisint.com/schema/attributes\",\n \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"type\" : \"array\",\n \"description\" : \"Collection of attributes.\",\n \"items\" : { \n \"$ref\" : \"http://api.covisint.com/schema/attribute#\"\n \ }\n}\n" - expression: "{\n \"id\" : \"http://api.covisint.com/schema/expression#\",\n \"$schema\" : \"http://json-schema.org/draft-04/schema\",\n \"description\" : \"The DSL for defining conditional expressions.\",\n \"oneOf\" : [\n {\n \"type\" : \"object\",\n \"properties\" : {\n \"any\" : {\n \"type\" : \"array\",\n \"description\" : \"An aggregate expression representing an 'any' condition.\",\n \"items\" : {\n \"$ref\" : \"http://api.covisint.com/schema/expression#\"\n }\n }\n \ }\n },\n {\n \"type\" : \"object\",\n \"properties\" : {\n \"all\" : {\n \"type\" : \"array\",\n \"description\" : \"An aggregate expression representing an 'all' condition.\",\n \"items\" : {\n \"$ref\" : \"http://api.covisint.com/schema/expression#\"\n \ }\n }\n }\n },\n {\n \"type\" : \"object\",\n \"description\" : \"A simple leaf-node expression. The format of this expression is: '(f:, v:())'. The supported expressions are: equal, notEqual, startsWith, endsWith, matches, greaterThan, greaterThanOrEqual, lessThan, lessThanOrEqual. The field name can be a simple field name i.e. 'id' or hierarchical field name using dot-notation like 'resource.id' / 'resource.tag[0]' . The value corresponding to the field name provided should always be a simple data type and cannot be an array or an object.\",\n \"properties\" : {\n \"expr\" : {\n \"type\" : \"string\",\n \"required\" : \"true\"\n }\n }\n }\n ]\n}\n \n" - streams: | { "id": "http://api.covisint.com/schema/streams", "$schema": "http://json-schema.org/draft-04/schema", "description": "Collection of stream definitions.", "type": "array", "items": { "$ref": "http://api.covisint.com/schema/stream#" } } - stream: | { "$schema": "http://json-schema.org/draft-04/schema#", "id": "http://api.covisint.com/schema/stream", "type": "object", "description": "Schema representing a datahub stream.", "extends": { "$ref": "http://api.covisint.com/schema/realmScopedResourceV2#" }, "properties": { "name": { "description": "The application name (internationalized).", "required": true, "$ref": "http://api.covisint.com/schema/internationalString#" }, "description" : { "required": false, "description": "The application description (internationalized).", "$ref" : "http://api.covisint.com/idm/schema/internationalString#" }, "streamType": { "description": "Source that creates the stream.", "enum": [ "DEVICE", "APPLICATION", "MESSAGING", "SYNC" ], "required": true }, "protocolType": { "enum": [ "MQTT", "HTTPS", "JMS", "STOMP", "AMQP", "WSS", "CAPS", "KAFKA", "FTP", "BATCH" ], "required": true, "description": "The communication protocol MQTT/JMS/HTTPS/AMQP/STOMP/WSS supported by the stream." }, "protocolSecurityType": { "enum": [ "NONE", "BASIC", "X_509_JWT", "CUSTOM", "OAUTH2" ], "required": true, "description": "The protocol security types NONE/BASIC supported by the stream." }, "payloadSecurityType": { "enum": [ "NONE", "ENCRYPTED", "CUSTOM" ], "required": true, "description": "The payload security types NONE/ENCRYPTED supported by the stream." }, "ownerId": { "type": "string", "minLength": 1, "maxLength": 60, "required": true, "description": "The id of the owner for which this stream is being defined." }, "consumerTopic": { "type": "string", "required": false, "minLength": 1, "maxLength": 200, "description": "The name of the consumer topic for the stream.", "readOnly": true }, "producerTopic": { "type": "string", "required": false, "minLength": 1, "maxLength": 200, "description": "The name of the producer topic for the stream.", "readOnly": true }, "alertConsumerTopic": { "type": "string", "required": false, "minLength": 1, "maxLength": 200, "description": "The name of the alert Consumer topic for the stream.", "readOnly": true }, "messageProcessorPartitionId": { "type": "string", "required": false, "minLength": 1, "maxLength": 5, "description": "The partition ID for the inbound processing topic.", "readOnly": true }, "streamConfiguration": { "type": "object", "required" : false, "description": "The stream configuration to be employed.", "properties": { "logMode": { "enum": [ "ON", "OFF", "INFO", "DEBUG" ], "required": true, "description": "The log mode of the stream configuration.", "readOnly": true }, "pullingThreads": { "type": "integer", "required": true, "minimum": 1, "maximum": 10, "description": "The number of threads that will pull." }, "sleepTime": { "type": "integer", "required": true, "minimum": 100, "maximum": 10000, "description": "The amount of time between fetches, in milliseconds." }, "quota": { "type": "integer", "required": true, "minimum": 100, "maximum": 10000, "description": "The amount of time between fetches, in milliseconds." } } }, "protocolSecurityAttributes":{ "required": false, "type":"array", "description":"The list of attribute protocol security attributes associated to the stream.", "minItems":1, "items":[ { "anyOf": [ { "type": "string", "description": "The name of the protocol attribute. userName,password, serviceurl, and etc.", "required": true }, { "type": "string", "description": "The value of the protocol attribute. userName,password, serviceurl, and etc.", "required": true } ] } ] }, "payloadSecurityAttributes":{ "required": false, "type":"array", "description":"The list of attribute payload security attributes associated to the stream.", "minItems":1, "items":[ { "anyOf": [ { "type": "string", "description": "The name of the payload security attributes. consumerPrivateKey,producerPublicKey etc.", "required": true }, { "type": "string", "description": "The value of the payload security attributes. producerPrivateKey,consumerPublicKey etc.", "required": true } ] } ] }, "streamState": { "enum": [ "ACTIVE", "INACTIVE" ], "description": "The present state types ACTIVE/INACTIVE of stream." }, "encryptionAlgorithmAttributes": { "required": true, "type":"array", "description":"The list of encryption algorithm attributes associated to the stream.", "minItems":1, "items":[ { "anyOf": [ { "type": "string", "description": "The name of the encryption algorithm attributes. securityStandards, algorithmName, algorithmKeySize etc.", "required": true }, { "type": "string", "description": "The value of the encryption algorithm attributes. securityStandards, algorithmName, algorithmKeySize etc.", "required": true } ] } ] }, "encryptionKey": { "type": "string", "required": false, "description": "The encryption key to be used for the stream." }, "ackTimeout": { "type": "number", "required": false, "description": "The value in milliseconds that this stream will send back an acknowledgment of a command." }, "customProtocolType": { "type": "string", "required": false, "description": "Custom protocol name e.g. CALAMP, COVAP, VPN, SSH, SSL etc., mandatory if caps or ftp is selected as protocol type." }, "direction": { "enum": [ "ACTIVE_SENDING", "ACTIVE_RECEIVING", "PASSIVE_SENDING", "PASSIVE_RECEIVING", "BOTH" ], "description": "The direction state types ACTIVE_SENDING/ACTIVE_RECEIVING/BOTH of stream." }, "deliveryConfig": { "type": "object", "required" : false, "description": "The delivery configuration to be employed.", "properties": { "commandRollbackAttempts": { "type": "integer", "required": true, "description": "The number of times, rollback a command before dropped it from the queue." }, "ackWaitTimeoutLimit": { "type": "integer", "required": true, "description": "The length of time, wait until, the ACK didn’t come in." }, "retryInterval": { "type": "integer", "required": true, "description": "The length of time, wait between retries." }, "retryNumber": { "type": "integer", "required": true, "description": "The number of times try to send out a message, during a send of a command/event." }, "retryTimeOut": { "type": "long", "required": true, "description": "The length of time in millisecond in a single transmission before enter into a retry loop." }, "deliverySchedule": { "type": "string", "required": false, "description": "The scheduler script expression for command delivery." }, "deliveryScript": { "type": "string", "required": false, "description": "The delivery script for command delivery." }, "deliveryEnabled": { "type": "boolean", "required": false, "description": "The command delivery scheduler activation status." }, "destinationURI": { "type": "string", "required": false, "description": "The command destination URI." }, "messagesPerThread": { "type": "string", "required": false, "description": "The number of messages a single thread can handle." }, "deliveryThreads": { "type": "string", "required": false, "description": "The number of delivery threads per stream." } } }, "documentRecognition": { "type": "object", "required" : false, "description": "The document recognition to be employed.", "properties": { "description": { "type": "string", "required": true, "description": "The description of the custom document recognition script." }, "classScript": { "type": "string", "required": true, "description": "The base64 custom document recognition script." }, "type": { "enum": [ "JAVA", "JAVASCRIPT" ], "required": true, "description": "The type of script e.g. JAVA,JAVASCRIPT." } } }, "customScripts": { "type" : "object", "required" : false, "description" : "The custom scripts to be employed.", "properties" : { "preHookScript" : { "type" : "string", "required" : false, "description" : "The custom script to run before file transfer." }, "postHookScript" : { "type" : "string", "required" : false, "description" : "The custom script to run after file transfer." }, "communicationScript" : { "type" : "string", "required" : false, "description" : "The custom execution script to be applied on ftp message." } } }, "batchConfig": { "type": "object", "required" : false, "description": "The batch configuration.", "properties": { "schedule": { "type": "string", "required": true, "description": "A quartz cron expression that controls how often the batch job is triggered. See http://www.quartz-scheduler.org/api/2.2.1/org/quartz/CronExpression.html." }, "handler": { "type": "string", "required": true, "description": "The fully qualified class name for the batch handler." }, "handlerAttributes": { "type": "object", "required": false, "description": "Custom attributes that are passed to the batch handler for processing." }, "maxBytes": { "type": "integer", "required": false, "minimum": 2, "description": "The maximum size in bytes of the batched message payload." }, "maxMessages": { "type": "integer", "required": false, "minimum": 2, "description": "The maximum number of messages the can exist in a single batched message." }, "compression": { "enum": [ "NONE" ], "required": false, "description": "The type of compression to use for the payload." } } } } } - streamDevices: | { "id": "http://api.covisint.com/schema/streamDevice", "$schema": "http://json-schema.org/draft-04/schema", "description": "Collection of stream definitions.", "type": "array", "items": { "$ref": "http://api.covisint.com/schema/streamDevice#" } } - streamDevice: | { "$schema": "http://json-schema.org/draft-04/schema#", "id": "http://api.covisint.com/schema/streamDevice", "type": "object", "properties": { "streamId": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The gateway stream id on which devices will be added." }, "deviceId": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The id of the device for which this stream is being defined (only applicable for streamType == device)." } } } - streamDocumentInfos: | { "id": "http://api.covisint.com/schema/streamDocumentInfo", "$schema": "http://json-schema.org/draft-04/schema", "description": "Collection of stream documentInfos.", "type": "array", "items": { "$ref": "http://api.covisint.com/schema/streamDocumentInfo#" } } - streamDocumentInfo: | { "$schema": "http://json-schema.org/draft-04/schema#", "id": "http://api.covisint.com/schema/streamDocumentInfo", "type": "object", "properties": { "streamId": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The gateway stream id on which documentInfo will be added." }, "documentInfoId": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The id of the documentInfo for which this stream is being defined." }, "senderCodeId": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The senderCodeId of trading partner for which this stream is being defined." }, "receiverCodeId": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The receiverCodeId of trading partner for which this stream is being defined." }, "mapKey": { "description": "The mapKey of the stream, which could be either EXTENDED_KEY or DOCUMENT_RECOGNITION.", "enum": [ "EXTENDED_KEY", "DOCUMENT_RECOGNITION" ] }, "mapAttributeName":{ "required": false, "type":"array", "description":"The list of map attribute name associated to the stream.", "minItems":1, "items":[ { "anyOf": [ { "type": "string", "description": "The name of the map attribute name. temperature, speed and etc.", "required": true }, { "type": "string", "description": "The value of the map attribute name. temperature, speed and etc.", "required": true } ] } ] },"responseMapping": { "type": "object", "required" : false, "description": "The response mapping to be employed.", "properties": { "senderCodeId": { "type": "string", "required": false, "description": "The sender code id of response mapping." }, "receiverCodeId": { "type": "string", "required": false, "description": "The receiver code id of response mapping." }, "documentInfoId": { "type": "string", "required": false, "description": "The document info id of response mapping." } } } } } - streamActivityState: | { "$schema": "http://json-schema.org/draft-04/schema#", "id": "http://api.covisint.com/schema/streamActivityState", "type": "object", "properties": { "streamId": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The stream id." }, "activityState": { "description": "The state of the stream, which could be either STANDBY, ONLINE or OFFLINE.", "enum": [ "STANDBY", "ONLINE", "OFFLINE" ] }, "lastCheckinTime": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The last checkin time of activity stream." }, "sourceIP": { "type": "string", "minLength": "1", "maxLength": 15, "description": "The source IP used in this stream." }, "sourcePort": { "type": "string", "minLength": "1", "maxLength": 10, "description": "The source IP used in this stream." }, "capsInstanceId": { "type": "string", "minLength": "1", "maxLength": 10, "description": "The caps instance id associated with the passed stream." } } } - streamControlState: | { "$schema": "http://json-schema.org/draft-04/schema#", "id": "http://api.covisint.com/schema/streamControlState", "type": "object", "properties": { "streamId": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The stream id." }, "deviceCounter": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The device counter used in this stream." }, "platformCounter": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The platform counter used in this stream." } } } - streamLockState: | { "$schema": "http://json-schema.org/draft-04/schema#", "id": "http://api.covisint.com/schema/streamLockState", "type": "object", "properties": { "streamId": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The stream id." }, "lockState": { "description": "The state of the stream, which could be either LOCKED or UNLOCKED.", "enum": [ "LOCKED", "UNLOCKED" ] }, "dateTime": { "type": "string", "minLength": "1", "maxLength": 60, "description": "The current date and time for passed stream." }, "capsInstanceId": { "type": "string", "minLength": "1", "maxLength": 10, "description": "The caps instance id associated with the passed stream." } } } traits: - secured: usage: Apply this to any method that needs to be secured. Requests with this trait require authentication using a bearer token. headers: Authorization: description: Access token that is obtained from the /token endpoint of the OAuth API. pattern: "^Bearer .*$" example: Bearer ZCtYUGpYRXpET0JvVE1rZzlWV3I1Yk required: true responses: 401: &6 description: Unauthenticated request. This is returned if the access token is missing, invalid, or expired. Access tokens are obtained through the /token endpoint of the Oauth API. body: application/vnd.com.covisint.error.v1+json: schema: errorResponseSchema 403: &7 description: Unauthorized request. The requestor is not authorized to perform the requested operation. body: application/vnd.com.covisint.error.v1+json: schema: errorResponseSchema - unsecured: usage: Apply this to any method that needs to be unsecured. Requests with this trait do not require any authentication. headers: SolutionInstanceId: description: The solution instance id. example: abcd123e-0109-441c-8a20-123a456b789c required: true responses: 400: description: Bad request. Please provide the valid solution instance id. body: application/vnd.com.covisint.error.v1+json: schema: errorResponseSchema - getResponse: responses: 404: &3 description: | The URI requested is invalid or the resource requested does not exist. ___ Substatus codes and error messages are mentioned below: + (If a resource id is a URI parameter) framework:resource:missing - A resource with the following ID was not found: {resourceId} + No message for an invalid URI body: application/vnd.com.covisint.error.v1+json: schema: errorResponseSchema 406: &1 description: | Unable to produce content of specified 'Accept' media type ___ Substatus codes and error messages are mentioned below: + framework:request:unsupported:mediatype - The server is unable to produce content of type {acceptMediaType} body: application/vnd.com.covisint.error.v1+json: schema: errorResponseSchema 500: &2 description: | An unknown server error occurred ___ Substatus codes and error messages are mentioned below: + framework:unknown body: application/vnd.com.covisint.error.v1+json: schema: errorResponseSchema - getSearchResponse: responses: 406: *1 500: *2 - postResponse: responses: 406: *1 415: &4 description: | Unable to consume content of specified 'Content-Type' media type ___ Substatus codes and error messages are mentioned below: + framework:request:unsupported:mediatype - The server is unable to consume content of type {contentMediaType} body: application/vnd.com.covisint.error.v1+json: schema: errorResponseSchema 500: *2 - deleteResponse: responses: 500: *2 - putResponse: responses: 404: *3 406: *1 409: &5 description: | There is a conflict in identifying the resource being acted on. There are two categories. (1) The unique identifier in the URL and in the body are different. (2) The current version of the resource being updated and the version sent in the body of the request. This may be an indication that the resource has changed since the client loaded it. The conflict should be resolved and the update resubmitted with the current version of the resource. + framework:resource:conflict + framework:resource:conflict:id - The ID of the resource in the request, {requestedId}, does not match the ID of the given resource, {resourceId} + framework:resource:conflict:version - The version of the provided resource, {requestVersion}, does not match the current version of the resource, {latestVersion} body: application/vnd.com.covisint.error.v1+json: schema: errorResponseSchema 415: *4 500: *2 - putResponseV2: responses: 404: *3 406: *1 409: description: | There is a conflict in identifying the resource being acted on. The unique identifier in the URL and body are different. + framework:resource:conflict + framework:resource:conflict:id - The ID of the resource in the request, {requestedId}, does not match the ID of the given resource, {resourceId} body: application/vnd.com.covisint.error.v1+json: schema: errorResponseSchema 415: *4 500: *2 - putCreateResponse: responses: 406: *1 409: *5 415: *4 500: *2 - taskResponse: responses: 401: *6 403: *7 500: *2 - pagableRequest: queryParameters: page: description: Which page to return in the paginated results. The first page is page 1. type: integer required: false minimum: 1 default: 1 pageSize: description: How many items per page in the paginated results. type: integer required: false minimum: 1 default: 50 maximum: 200 - taggable: queryParameters: tag: description: Get the resource based on specified tag. Multiple parameters are allowed and the search results will be a union. type: string required: false - sortable: queryParameters: sortBy: description: Sort the results based on some criteria. example: +creation, -name (These will sort by creation ascending, name descending. If "+/-" prefix is omitted, then an ascending sort is assumed). type: string required: false - searchable: description: Search resources based on the given filter parameters. Search is case-insensitive. <> <> "/streams": description: Collection endpoint for stream resources. post: description: Create a new stream. headers: Accept: description: Media type. example: application/vnd.com.covisint.platform.stream.v1+json type: string required: true Content-Type: description: Media type of the response body. example: application/vnd.com.covisint.platform.stream.v1+json type: string required: true is: - postResponse - secured body: application/vnd.com.covisint.platform.stream.v1+json: schema: stream responses: 201: description: Stream created successfully body: application/vnd.com.covisint.platform.stream.v1+json: schema: stream 400: description: | There was a problem with the client's request. ___ Substatus codes and error messages are mentioned below: + framework:request + framework:request:io + framework:request:io:read - Invalid input. There was an error while parsing. + framework:request:io:read:parsing + framework:request:io:write + framework:request:header:missing - Missing request header: {headerName} + framework:request:data:missing - The following information was missing from the resource: {resourceFieldName(s)} + framework:request:invalid:header:value - Invalid x-requester header value. Valid values are [person, application] body: application/vnd.com.covisint.error.v1+json: schema: errorResponseSchema get: is: - pagableRequest - sortable - getSearchResponse - secured description: Search streams in the realm based on the specified query parameters. headers: Accept: description: Media type. example: application/vnd.com.covisint.platform.stream.v1+json type: string required: true queryParameters: id: description: Filter streams by their unique id. Multiple parameter values can be provided, in which case any matching event sources will be returned. type: string required: false name: description: Retrieve attribute types with the specified streamName. Case-insensitive, wild card and fuzzy search is supported. Multiple parameters are allowed and the search results will be a union. type: string required: false streamType: description: Retrieve attribute types with the specified streamType. Case-insensitive, wild card and fuzzy search is supported. Multiple parameters are allowed and the search results will be a union. type: string required: false realmId: description: Retrieve attribute types with the specified realmId. Case-insensitive, wild card and fuzzy search is supported. Multiple parameters are allowed and the search results will be a union. type: string required: false protocolType: description: Retrieve attribute types with the specified protocolType. Case-insensitive, wild card and fuzzy search is supported. Multiple parameters are allowed and the search results will be a union. type: string required: false deviceId: description: Retrieve attribute types with the specified deviceId. Case-insensitive, wild card and fuzzy search is supported. Multiple parameters are allowed and the search results will be a union. type: string required: false creation: description: Retrieve attribute types with the specified creation. Range search is supported. Multiple parameters are allowed and the search results will be a union. the pattern would be creation=>value1&creation=value1&creation=