diff --git a/README.md b/README.md
index 92b648f..3518d01 100644
--- a/README.md
+++ b/README.md
@@ -1 +1,22 @@
-XOS service for ONOS OLT app
+# vOLT 
+
+This repositoritory contains the XOS service that is responsible for the integration with VOLTHA.
+
+At the moment the `RCORDService` assume that this service (or a service exposing the same APIs) is sitting after it in the service chain. 
+
+## ONU activation discovery
+
+This service will listen for events on the kafka bus, in the topic `onu.events`
+
+The events this service will react to are:
+- onu activated
+
+### ONU Activation policy
+
+We assume that:
+- the  `vOLTService` service is a subscriber of `MyOssService` via `ServiceDependency`
+- `MyOssService` has `type = oss`
+- `MyOssService` expose and API named `validate_onu`
+    - the `validate_onu` API will be responsible to create a subscriber in XOS
+    
+If no OSS Service is found in between the providers of `vOLTService` no action is taken as a consequence of an event.
diff --git a/docs/README.md b/docs/README.md
new file mode 100644
index 0000000..ec62a99
--- /dev/null
+++ b/docs/README.md
@@ -0,0 +1,53 @@
+# vOLT Service Configuration
+
+When you create the OLT Service in your profile there are few things that you may need to configure
+they are described in this TOSCA recipe that you can customize and use (default values are displayed):
+
+```yaml
+tosca_definitions_version: tosca_simple_yaml_1_0
+description: Set up VOLT service
+imports:
+  - custom_types/voltservice.yaml
+
+topology_template:
+  node_templates:
+    service#volt:
+      type: tosca.nodes.VOLTService
+      properties:
+        # Service Name
+        name: volt
+        
+        # Informations on how to reach VOLTHA
+        voltha_url: voltha.voltha.svc.cluster.local
+        voltha_port: 8882
+        voltha_user: voltha
+        voltha_pass: admin
+        
+        # Informations on how to reach ONOS-VOLTHA
+        onos_voltha_url: onos-voltha-ui.voltha.svc.cluster.local
+        onos_voltha_port: 8181
+        onos_voltha_user: karaf
+        onos_voltha_pass: karaf
+        
+        # Which kind of policy is applied when a new ONU is discovered
+        onu_provisioning: allow_all [deny_all, custom_logic]
+``` 
+
+## ONU Porvisioning policies
+
+### Allow all
+
+This means that any discovered onu is activated and the POD is configured to enable dataplane traffic for this user
+
+### Deny all
+
+ONU discovery events are ignored, the operator will manually need to push the subscriber configuration
+
+### Custom Logic
+
+Whenever a more complex logic is required this is delegated to an extenal service, from now on referenced as `MyOssService`.
+We assume that:
+- the  `vOLTService` service is a subscriber of `MyOssService` via `ServiceDependency`
+- `MyOssService` has `type = oss`
+- `MyOssService` expose and API named `validate_onu`
+    - the `validate_onu` API will be responsible to create a subscriber in XOS
\ No newline at end of file
diff --git a/xos/synchronizer/event_steps/onu_event.py b/xos/synchronizer/event_steps/onu_event.py
new file mode 100644
index 0000000..458333f
--- /dev/null
+++ b/xos/synchronizer/event_steps/onu_event.py
@@ -0,0 +1,85 @@
+
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+
+import json
+import os
+import sys
+from synchronizers.new_base.eventstep import EventStep
+from synchronizers.new_base.modelaccessor import VOLTService, ONUDevice, Service, model_accessor
+
+# from xos.exceptions import XOSValidationError
+
+
+# Manually send the event
+
+# import json
+# from kafka import KafkaProducer
+
+# event = json.dumps({
+#     'status': 'activate',
+#     'serial_number': 'BRCM1234',
+#     'uni_port_of_id': 'of:00100101',
+#     'of_dpid': 'of:109299321'
+# })
+# producer = KafkaProducer(bootstrap_servers="cord-kafka-kafka")
+# producer.send("onu.events", event)
+# producer.flush()
+
+
+class ONUEventStep(EventStep):
+    topics = ["onu.events"]
+    technology = "kafka"
+
+    def __init__(self, *args, **kwargs):
+        super(ONUEventStep, self).__init__(*args, **kwargs)
+
+    def get_oss_service(self, onu_serial_number):
+        try:
+            onu = ONUDevice.objects.get(serial_number=onu_serial_number)
+        except IndexError as e:
+            raise Exception("No ONUDevice with serial_number %s is present in XOS" % onu_serial_number)
+
+        volt_service = onu.pon_port.olt_device.volt_service
+        service = Service.objects.get(id=volt_service.id)
+        osses = [s for s in service.provider_services if s.kind.lower() == "oss"]
+
+        if len(osses) > 1:
+            self.log.warn("More than one OSS found for %s" % volt_service.name)
+        try:
+            return osses[0].leaf_model
+        except IndexError as e:
+            return None
+
+    def handle_onu_activate_event(self, event):
+        oss = self.get_oss_service(event["serial_number"])
+
+        if not oss:
+            self.log.info("Not processing events as no OSS service is present (is it a provider of vOLT?")
+        else:
+            try:
+                oss.validate_onu(event)
+            except Exception, e:
+                self.log.exception("Failing to validate ONU in OSS Service %s" % oss.name)
+                raise e
+
+    def process_event(self, event):
+        value = json.loads(event.value)
+        self.log.info("onu.events: received event", value=value)
+
+        if value["status"] == "activate":
+            self.log.info("onu.events: activate onu", value=value)
+            self.handle_onu_activate_event(value)
+
diff --git a/xos/synchronizer/event_steps/test_onu_events.py b/xos/synchronizer/event_steps/test_onu_events.py
new file mode 100644
index 0000000..e1ec0d4
--- /dev/null
+++ b/xos/synchronizer/event_steps/test_onu_events.py
@@ -0,0 +1,134 @@
+# Copyright 2017-present Open Networking Foundation
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+import unittest
+from mock import patch, call, Mock, PropertyMock
+import json
+
+import os, sys
+
+# Hack to load synchronizer framework
+test_path=os.path.abspath(os.path.dirname(os.path.realpath(__file__)))
+xos_dir=os.path.join(test_path, "../../..")
+if not os.path.exists(os.path.join(test_path, "new_base")):
+    xos_dir=os.path.join(test_path, "../../../../../../orchestration/xos/xos")
+    services_dir = os.path.join(xos_dir, "../../xos_services")
+sys.path.append(xos_dir)
+sys.path.append(os.path.join(xos_dir, 'synchronizers', 'new_base'))
+# END Hack to load synchronizer framework
+
+# generate model from xproto
+def get_models_fn(service_name, xproto_name):
+    name = os.path.join(service_name, "xos", xproto_name)
+    if os.path.exists(os.path.join(services_dir, name)):
+        return name
+    else:
+        name = os.path.join(service_name, "xos", "synchronizer", "models", xproto_name)
+        if os.path.exists(os.path.join(services_dir, name)):
+            return name
+    raise Exception("Unable to find service=%s xproto=%s" % (service_name, xproto_name))
+# END generate model from xproto
+
+class TestSyncOLTDevice(unittest.TestCase):
+
+    def setUp(self):
+        global DeferredException
+
+        self.sys_path_save = sys.path
+        sys.path.append(xos_dir)
+        sys.path.append(os.path.join(xos_dir, 'synchronizers', 'new_base'))
+
+        # Setting up the config module
+        from xosconfig import Config
+        config = os.path.join(test_path, "../model_policies/test_config.yaml")
+        Config.clear()
+        Config.init(config, "synchronizer-config-schema.yaml")
+        # END Setting up the config module
+
+        from synchronizers.new_base.mock_modelaccessor_build import build_mock_modelaccessor
+        # build_mock_modelaccessor(xos_dir, services_dir, [get_models_fn("olt-service", "volt.xproto")])
+
+        # FIXME this is to get jenkins to pass the tests, somehow it is running tests in a different order
+        # and apparently it is not overriding the generated model accessor
+        build_mock_modelaccessor(xos_dir, services_dir, [get_models_fn("olt-service", "volt.xproto"),
+                                                         get_models_fn("vsg", "vsg.xproto"),
+                                                         get_models_fn("../profiles/rcord", "rcord.xproto")])
+        import synchronizers.new_base.modelaccessor
+        from onu_event import ONUEventStep, model_accessor
+
+        # import all class names to globals
+        for (k, v) in model_accessor.all_model_classes.items():
+            globals()[k] = v
+
+        self.log = Mock()
+
+        self.event_step = ONUEventStep(self.log)
+
+        self.event = Mock()
+        self.event.value = json.dumps({
+            'status': 'activate',
+            'serial_number': 'BRCM1234',
+            'uni_port_of_id': 'of:00100101',
+            'of_dpid': 'of:109299321'
+        })
+
+        self.onu = Mock()
+        self.onu.serial_number = "BRCM1234"
+        self.onu.pon_port.olt_device.volt_service.id = 1
+
+        self.service = Mock(id=1)
+        self.service.provider_services = []
+
+        self.oss = Mock()
+        self.oss.kind = "OSS"
+        self.oss.leaf_model = Mock()
+
+    def tearDown(self):
+        self.service.provider_services = []
+
+    def test_missing_onu(self):
+        with patch.object(ONUDevice.objects, "get_items") as onu_device_mock:
+            onu_device_mock.side_effect = IndexError("No ONU")
+
+        with self.assertRaises(Exception) as e:
+            self.event_step.process_event(self.event)
+
+        self.assertEqual(e.exception.message, "No ONUDevice with serial_number %s is present in XOS" % self.onu.serial_number)
+
+    def test_do_nothing(self):
+        with patch.object(ONUDevice.objects, "get_items") as onu_device_mock , \
+            patch.object(Service.objects, "get_items") as service_mock, \
+            patch.object(self.log, "info") as logInfo:
+
+            onu_device_mock.return_value = [self.onu]
+            service_mock.return_value = [self.service]
+
+            self.event_step.process_event(self.event)
+
+            logInfo.assert_called_with("Not processing events as no OSS service is present (is it a provider of vOLT?")
+
+    def test_call_oss(self):
+        self.service.provider_services = [self.oss]
+
+        with patch.object(ONUDevice.objects, "get_items") as onu_device_mock , \
+            patch.object(Service.objects, "get_items") as service_mock, \
+            patch.object(self.oss.leaf_model, "validate_onu") as validate_onu:
+
+            onu_device_mock.return_value = [self.onu]
+
+            service_mock.return_value = [self.service]
+
+            self.event_step.process_event(self.event)
+
+            validate_onu.assert_called_with(json.loads(self.event.value))
diff --git a/xos/synchronizer/models/volt.xproto b/xos/synchronizer/models/volt.xproto
index 355ddaf..941f102 100644
--- a/xos/synchronizer/models/volt.xproto
+++ b/xos/synchronizer/models/volt.xproto
@@ -14,7 +14,7 @@
     required int32 onos_voltha_port = 6 [help_text = "The Voltha API port. By default 8181", default=8181, null = False, db_index = False, blank = False];
     required string onos_voltha_user = 7 [help_text = "The ONOS Voltha username. By default sdn", max_length = 254, default="onos", null = True, db_index = False, blank = False];
     required string onos_voltha_pass = 8 [help_text = "The ONOS Voltha password. By default rocks", max_length = 254, default="rocks", null = True, db_index = False, blank = False];
-    required string onu_provisioning = 9 [help_text = "If to automatically discover and provision the ONU or not", default = "allow_all", choices = "(('allow_all', 'Allow All'), ('pre_provisioned', 'Pre-provisione'), ('oss', 'OSS'))", null = False, db_index = False, blank = False];
+    required string onu_provisioning = 9 [help_text = "If to automatically discover and provision the ONU or not", default = "allow_all", choices = "(('allow_all', 'Allow All'), ('deny_all', 'Deny All'), ('custom_logic', 'Custom Logic'))", null = False, db_index = False, blank = False];
 }
 
 message VOLTServiceInstance (ServiceInstance){
diff --git a/xos/unittest.cfg b/xos/unittest.cfg
index 44c6ea4..123cb69 100644
--- a/xos/unittest.cfg
+++ b/xos/unittest.cfg
@@ -4,3 +4,4 @@
                  model_policies
                  steps
                  pull_steps
+                 event_steps
