Toolpack:Add Edit Routeset Files RestFul A: Difference between revisions
(Created page with "{{DISPLAYTITLE:Add/Edit Routeset files with RestFul API}} You can Add/Edit routeset files in your system with RestFul API using JSON format. The JSON must be in the following...") |
mNo edit summary |
||
| Line 1: | Line 1: | ||
{{DISPLAYTITLE:Add/Edit Routeset files with RestFul API}} | {{DISPLAYTITLE:Add/Edit Routeset files with RestFul API}} | ||
You can Add | You can Add and Edit routeset files in your system with RestFul API using JSON format. The JSON must be in the following format: | ||
<pre> | <pre> | ||
{ | { | ||
| Line 30: | Line 30: | ||
[[Image:RestFul_routeset_Post_Send.png|800px| ]] | [[Image:RestFul_routeset_Post_Send.png|800px| ]] | ||
If the import is successful | If the import is successful, the following message is returned in the Postman Tool | ||
[[Image:RestFul_Routeset_Post_Response.png|800px| ]] | [[Image:RestFul_Routeset_Post_Response.png|800px| ]] | ||
| Line 43: | Line 43: | ||
[[Image:RestFul_Routeset_Put_Send.png|800px| ]] | [[Image:RestFul_Routeset_Put_Send.png|800px| ]] | ||
If the update is successful | If the update is successful, the following message is returned in the Postman Tool | ||
[[Image:RestFul_Routeset_Put_Response.png|800px| ]] | [[Image:RestFul_Routeset_Put_Response.png|800px| ]] | ||
Learn about how to use RestFul API and Postman Tool from the following link [[Northbound_interface:RESTful]] | |||
Revision as of 11:53, 22 February 2023
You can Add and Edit routeset files in your system with RestFul API using JSON format. The JSON must be in the following format:
{
"***meta***": {
"version": "3.1.135",
"src_path": ""
},
"name": "routeset_1.csv",
"content": "routeset_name,priority,weight\r\nNAP_1,3,100\r\nNAP_2,4,100"
}
- name: routeset file name
- \r\n: new line. Each routesets you entered must start with the new line.
Adding a new Routeset File
You can add a new Routeset file with the POST command:
POST http://ProSBCIP:12358/configurations/Configurationname/file_dbs/File_DB/routesets_definitions/
ProSBC will create a new Routeset file from the name in the JSON file.
Example: We use the Postman tool in this example and the URL is:
http://192.168.1.25:12358/configurations/config_2/file_dbs/File_DB/routesets_definitions/
If the import is successful, the following message is returned in the Postman Tool
Updating a Routeset File
You can update the existing Routeset file with the PUT command:
Example: We use the Postman tool in this example and the URL is http://192.168.1.25:12358/configurations/config_2/file_dbs/File_DB/routesets_definitions/routeset_1%2Ecsv
If the update is successful, the following message is returned in the Postman Tool
Learn about how to use RestFul API and Postman Tool from the following link Northbound_interface:RESTful