I’m working on a presentation for CampusInsight and figured it would great to share some of the cool things you can do with the CampusNexus Graph API. As most of you know, the CampusNexus Graph is based on an open protocol called OData. OData is a standard for REST APIs that gives you the ability to query your model from any technology that supports HTTP.
With traditional web services, a developer is required at design time to define every method an external system would use to interact with an API . In addition, the data being sent over the wire (contract) has to be pre-defined as well. This produces rigid, inefficient and often difficult to use APIs. OData gives us the flexibility and performance to handle the needs for almost all integrations without the requirement of modifying the API. It pushes the ability of defining what you want to do to the consumer rather than the producer.
Campus Management has spent the last few years defining and refining the higher education model for the CampusNexus Graph. As of 19.0, the CampusNexus Graph contains:
- 987 Entities
- 17,692 Properties
- 2,067 Relationships
There are many tools that can be used to visualize and navigate data provided by services that adhere the OData specification:
- Microsoft Excel
- Microsoft Power BI
- Microsoft SQL Server Reporting Services
In a later post, I will go into details on how to connect to OData services using these tools.
For now, I will give some examples of ways to query data services using the simple HTTP GET verb (something you can do simply by copying and pasting a URL into your browser).
Most web developers are familiar with Postman, an API Development Environment with the capability of discovering and testing modern web-based APIs. The OData community has created a Postman collection to familiarize developers with a broad range of OData capabilities. I’ve taken that collection and altered the URLs so they are specific to CampusNexus Graph entities. Below are just a few examples of what you can accomplish using the Graph API:
Read the service root
Read the service meteadata
Read an entity set
Get a single entity from an entity set
Select a property from an entity
Navigate to related entities
Filter a collection
http://hostname/odata/Courses?$filter=CreditHours eq 3
Filter on nested structures
http://hostname/odata/Courses?$filter=CourseType/Name eq ‘Competency Based’
Filter using logic operators
Sort a collection
Counting the elements in a collection
Expand related entities
Select the properties
Request full metadata
Invoke a bound function