-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
Hi Peter,
I am implementing the sample students yang model, and want to try POST/PUT/GET/DELETE REST API endpoints.
https://github.com/sureshkvl/yangforge-examples/blob/master/students.yang
I am able to run the students.yang as below,
yfc run students.yang
- POST API.
I am able to POST the student in the below API
POST - http://localhost:5000/restjson/students-yang/students-container/students-list - GET API
I am able to get the students lists as below,
http://localhost:5000/restjson/students-yang/students-container/students-list
output :
[
{
"name": "ramesh",
"rollno": 22,
"address": "bangalore,india"
},
{
"name": "suresh",
"rollno": 34,
"address": "chennai,india"
}
]
Query: How to get the specific index or key student object from the student list.?
Basically i want to get only "suresh" student details from the list.
- PUT API:
What is the API(URL) to modify the specific student details?
http://localhost:5000/restjson/students-yang/students-container/students-list/xxxxxxx - DELETE API:
Is it possible to delete the object from the list..?
Thanks
suresh
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels