{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "https://poseidat.org/schema/core/equipment/device.json",
  "title": "Device",
  "description": "A device which is a part of a piece of equipment installed on a vessel",
  "properties": {
    "device_id": {
      "type": "string",
      "format": "uuid",
      "description": "The unique identifier for the device (UUID v4)"
    },
    "name": {
      "description": "Name of the device",
      "type": "string"
    },
    "type": {
      "description": "The type of device",
      "$ref": "https://poseidat.org/schema/enum/device-type.json"
    },
    "brand": {
      "description": "The brand of the device",
      "type": "string"
    },
    "product_no": {
      "description": "The product number of the device",
      "type": "string"
    },
    "serial_no": {
      "description": "The serial number of the device",
      "type": "string"
    },
    "supplier": {
      "description": "The company which supplied the device",
      "$ref": "https://poseidat.org/schema/core/persona/company.json"
    },
    "installer": {
      "description": "The company which has installed the device",
      "$ref": "https://poseidat.org/schema/core/persona/company.json"
    },
    "maintainer": {
      "description": "The company which maintains the device",
      "$ref": "https://poseidat.org/schema/core/persona/company.json"
    }
  },
  "required": [
    "device_id",
    "name",
    "type"
  ],
  "type": "object",
  "additionalProperties": false
}
