REST based Service:
MG Web Service also exposes methods based on REST design principles for making a
Web Service call by simply using a URL string, http://boar.cs.kent.edu/Glossary/SiteEngine/glossaryrestservice.php?
as the endpoint with parameters.
Table 2 highlights API functions and the associated URL to invoke MG REST Web Service.
Function
|
URL
|
GetTerm
|
http://boar.cs.kent.edu/Glossary/SiteEngine/glossaryrestservice.php?term=[value]
|
GetTermByAuthor
|
http://boar.cs.kent.edu/Glossary/SiteEngine/glossaryrestservice.php?term=[value1]&user=[value2]
|
GetTermsByCategory
|
http://boar.cs.kent.edu/Glossary/SiteEngine/glossaryrestservice.php?cat=[value1]
|
GetTermsByAuthorCategory
|
http://boar.cs.kent.edu/Glossary/SiteEngine/glossaryrestservice.php?cat=[value1]&user=[value2]
|
GetAllTerms
|
http://boar.cs.kent.edu/Glossary/SiteEngine/glossaryrestservice.php
|
Table 2: Functions in the REST Web Service.
Figure 1 show a sample request and response of the REST service.
Figure 1: Request and Response from the REST Web Service