blob: cf6e378f9eac8d1c34a5ceb1687aae26e5699315 [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;
donNewtonAlpha4c0abcd2018-08-14 15:50:52 -040072 string SerialNumber=5;
Author Namea594e632018-08-10 11:33:58 -040073}
74message AddOntReturn{
75 bool Success=1;
76 Error error = 2;
77}
78
79service AddChassis{
80 rpc CreateChassis(AddChassisMessage) returns (AddChassisReturn) {
81 option(google.api.http) = {
82 post: "/1/CreateAbstractChassis"
83 body:"*"
84 };
85 }
86}
87
88service AddOLTChassis {
89 rpc CreateOLTChassis(AddOLTChassisMessage) returns (AddOLTChassisReturn) {
90 option(google.api.http) = {
91 post: "/1/CreateOLTChassis"
92 body:"*"
93 };
94 }
95}
96service ActivateSlot{
97 rpc EnableSlot(ActivateSlotMessage) returns (ActivateSlotReturn){
98 option(google.api.http) = {
99 post: "/1/EnableSlot"
100 body:"*"
101 };
102 }
103}
104service ActivateOnt {
105 rpc ProvisionOnt(AddOntMessage) returns (AddOntReturn) {}
106}
107