blob: 2dfeff07e3a16d13a2bc667c690b5ff098603a97 [file] [log] [blame]
Author Namea594e632018-08-10 11:33:58 -04001//Copyright 2017 the original author or authors.
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6
7// http://www.apache.org/licenses/LICENSE-2.0
8
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15syntax = "proto3";
16package api;
17import "google/api/annotations.proto";
18
19message AddChassisMessage{
20 string CLLI =1;
21 string VCoreIP =2;
22 int32 VCorePort=3;
23}
24message Error {
25 int32 ErrorNum = 1;
26 string ErrorMessage=2;
27 int32 Serverity=3;
28}
29message AddChassisReturn{
30 string DeviceID = 1;
31 Error error = 2;
32}
33message AddOLTChassisMessage{
34 string CLLI=1;
35 string SlotIP=2;
36 fixed32 SlotPort=3;
37 string Hostname=4;
38 fixed32 NumPorts = 5;
39 bool Activate = 6;
40 enum OltDriver {
41 openoltDriver = 0;
42 asfvolt16Driver=1;
43 adtranDriver=2;
44 tibitsDriver=3;
45 }
46 OltDriver Driver=7;
47 enum OltType{
48 edgecore=0;
49 adtran=1;
50 tibit=2;
51 }
52 OltType Type=8;
53
54}
55message AddOLTChassisReturn {
56 string DeviceID =1;
57 string ChassisDeviceID =2;
58 Error error = 3;
59}
60message ActivateSlotMessage{
61 string SlotDeviceID = 1;
62}
63message ActivateSlotReturn{
64 bool Success = 1;
65 Error error = 2;
66}
67message AddOntMessage{
68 string ChassisDeviceID=1;
69 string SlotDeviceID=2;
70 int32 PortNumber=3;
71 int32 OntNumber=4;
72}
73message AddOntReturn{
74 bool Success=1;
75 Error error = 2;
76}
77
78service AddChassis{
79 rpc CreateChassis(AddChassisMessage) returns (AddChassisReturn) {
80 option(google.api.http) = {
81 post: "/1/CreateAbstractChassis"
82 body:"*"
83 };
84 }
85}
86
87service AddOLTChassis {
88 rpc CreateOLTChassis(AddOLTChassisMessage) returns (AddOLTChassisReturn) {
89 option(google.api.http) = {
90 post: "/1/CreateOLTChassis"
91 body:"*"
92 };
93 }
94}
95service ActivateSlot{
96 rpc EnableSlot(ActivateSlotMessage) returns (ActivateSlotReturn){
97 option(google.api.http) = {
98 post: "/1/EnableSlot"
99 body:"*"
100 };
101 }
102}
103service ActivateOnt {
104 rpc ProvisionOnt(AddOntMessage) returns (AddOntReturn) {}
105}
106