Public API for the Manageabiltiy RPC services.
This IDL defines the APIs for the Junos specific management services.
Commit Message Structure
Field | Type | Label | Description |
commit_type | ConfigCommitType | optional | This will specify the type of commit operation commit operation can be commit or commit-synchronize |
comment | string | optional | Specify the comment for the commit log |
Edit Ephemeral Configuration Database Request Message Structure
Field | Type | Label | Description |
request_id | uint64 | optional | The request id corresponding to the request |
eph_config_operations | EditEphemeralConfigRequest.ConfigOperationList | repeated | List of configuration data items, each consisting of the data model path and corresponding data encoded based on the requested format |
eph_instance_name | string | optional | EphInstanceName: Empty for the default ephemeral instance or The Name of the ephemeral instance for dynamic instance |
enable_config_validation | bool | optional | Enable validation of config For Internal Use only. |
Configuration Operation List
Field | Type | Label | Description |
operation_id | string | optional | The operation id is used to identify a specific configuration command, e.g., when the RPC may contain multiple commands. The response for each command can be identified based on the operation-id returned by the target device |
operation | ConfigCommands | optional | The type of configuration modification requested for the corresponding path.Note that some commands, such as 'delete' do not specify any associated data with the path |
path | string | optional | Specifies a path in the data model path corresponding to the data in the message |
xml_config | string | optional | XML format |
json_config | string | optional | JSON format |
Edit Ephemeral Configuration Database Response Message Structure
Field | Type | Label | Description |
request_id | uint64 | optional | The request id corresponding to the request |
response | EditEphemeralConfigResponse.ResponseList | repeated | List of responses for each configuration request |
Response data
Field | Type | Label | Description |
operation_id | string | optional | The operation id is used to identify a specific configuration command. For example, when the RPC may contain multiple commands, the response for each command can be identified based on the operation-id returned by the target device |
status | JunosRpcResponseTypes | optional | Response code indicating the result of the command |
message | string | optional | Error or information text associated with the return-code value |
Ephemeral Configuration Database Request Message Structure
Field | Type | Label | Description |
operation_id | string | optional | Identifier for the request |
path | string | optional | Data model path to retrieve |
Execute Configuration Command Request Message Structure
Field | Type | Label | Description |
request_id | uint64 | optional | The request id corresponding to the request |
xml_config | string | optional | XML format |
json_config | string | optional | JSON format |
text_config | string | optional | Text format |
load_type | ConfigLoadType | optional | Specify the type of load operation |
commit | ConfigCommit | optional | Specify the type of commit operation |
Execute Configuration Command Response Message Structure
Field | Type | Label | Description |
request_id | uint64 | optional | The request id corresponding to the request |
status | JunosRpcResponseTypes | optional | Response code indicating the result of the command |
message | string | optional | Error or information text associated with the return-code value |
Operation Commands Message Structure
Field | Type | Label | Description |
request_id | uint64 | optional | The request id corresponding to the request |
cli_command | string | optional | CLI command |
xml_command | string | optional | XML command |
json_command | string | optional | JSON command |
out_format | OperationFormatType | optional | Output format, default is JSON |
Operational Command Response Message Structure
Field | Type | Label | Description |
request_id | uint64 | optional | The request id corresponding to the request |
data | string | optional | Command Data |
status | JunosRpcResponseTypes | optional | Response code indicating the result of the command |
message | string | optional | Error or information text associated with the return-code value |
Get Ephemeral Configuration Database Request Message Structure
Field | Type | Label | Description |
request_id | uint64 | optional | The request id corresponding to the request |
encoding | JunosDataEncodingTypes | optional | Identifier for the encoding scheme |
eph_config_requests | EphConfigRequestList | repeated | EphConfigRequest will contain the Path |
eph_instance_name | string | optional | EphInstanceName: Empty for default ephemeral instance or the name of the ephemeral instance for dynamic instance |
merge_view | bool | optional | MergeView : True, if merge view configuration needed |
Get Ephemeral Configuration Database Response Message Structure
Field | Type | Label | Description |
request_id | uint64 | optional | The request id corresponding to the request |
response | GetEphemeralConfigResponse.ResponseList | repeated | List of responses for each configuration request |
Response Data
Field | Type | Label | Description |
operation_id | string | optional | The operation id is used to identify a specific configuration command, e.g., when the RPC may contain multiple commands. The response for each command can be identified based on the operation-id returned by the target device |
path | string | optional | Specifies a path in the data model path corresponding to the data in the message |
value | string | optional | Data encoded using the encoding specified in set-data-encoding, or encoding specified in the request. This data may be populated by the management system. |
status | JunosRpcResponseTypes | optional | Response code indicating the result of the command |
message | string | optional | Error or information text associated with the return-code value |
Configuration Commands
Name | Number | Description |
UPDATE_CONFIG | 0 | Update configuration |
REPLACE_CONFIG | 1 | Replace configuration |
DELETE_CONFIG | 2 | Delete configuration |
Commit Types
Name | Number | Description |
CONFIG_COMMIT_SYNCHRONIZE | 0 | Commit synchronize |
CONFIG_COMMIT | 1 | Commit |
Configuration Load Types
Name | Number | Description |
CONFIG_LOAD_REPLACE | 0 | Load replace |
CONFIG_LOAD_MERGE | 1 | Load merge |
CONFIG_LOAD_OVERRIDE | 2 | Load override |
CONFIG_LOAD_UPDATE | 3 | Load update |
CONFIG_LOAD_SET | 4 | Load set |
Data Encoding Types
Name | Number | Description |
ENCODING_XML | 0 | XML encoding |
ENCODING_JSON | 1 | JSON encoding |
Response Types
Name | Number | Description |
SUCCESS | 0 | Success |
NOK | 1 | Failure |
UNSUPPORTED_PATH | 2 | Unsupported path |
INVALID_PATH | 3 | Invalid path |
INVALID_CONFIGURATION | 4 | Invalid configuration |
UNSUPPORTED_ENCODING | 5 | Unsupported encoding |
Text Format of the Opertation
Name | Number | Description |
OPERATION_FORMAT_JSON | 0 | JSON format, this is default |
OPERATION_FORMAT_XML | 1 | XML format |
OPERATION_FORMAT_CLI | 2 | Text CLI format |
MGD Service Definitions
Method Name | Request Type | Response Type | Description |
ExecuteOpCommand | ExecuteOpCommandRequest | ExecuteOpCommandResponse | It executes the operational command specified in ExecuteOpCommandRequest. This is a streaming api |
ExecuteCfgCommand | ExecuteCfgCommandRequest | ExecuteCfgCommandResponse | The RPC will enable user to load and commit configuration on a junos device |
GetEphemeralConfig | GetEphemeralConfigRequest | GetEphemeralConfigResponse | This RPC will return the configuration in the ephemeral database for Path specified in the request |
EditEphemeralConfig | EditEphemeralConfigRequest | EditEphemeralConfigResponse | This RPC will perfom load-configuration and commit in JUNOS in ephemeral database |
.proto Type | Notes | C++ Type | Java Type | Python Type |
double | double | double | float | |
float | float | float | float | |
int32 | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. | int32 | int | int |
int64 | Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. | int64 | long | int/long |
uint32 | Uses variable-length encoding. | uint32 | int | int/long |
uint64 | Uses variable-length encoding. | uint64 | long | int/long |
sint32 | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. | int32 | int | int |
sint64 | Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. | int64 | long | int/long |
fixed32 | Always four bytes. More efficient than uint32 if values are often greater than 2^28. | uint32 | int | int |
fixed64 | Always eight bytes. More efficient than uint64 if values are often greater than 2^56. | uint64 | long | int/long |
sfixed32 | Always four bytes. | int32 | int | int |
sfixed64 | Always eight bytes. | int64 | long | int/long |
bool | bool | boolean | boolean | |
string | A string must always contain UTF-8 encoded or 7-bit ASCII text. | string | String | str/unicode |
bytes | May contain any arbitrary sequence of bytes. | string | ByteString | str |