0% found this document useful (0 votes)
69 views3 pages

COMP3220 REST Coursework 2019-2020

This document provides instructions for a coursework assignment to document a university facilities API and design an extension. For part 1, students are asked to explore the existing API, add a new equipment item, and document the API in HTML. For part 2, students must design an extension to the API to enable booking of facilities and equipment, including planning the process, drawing a state diagram, and documenting endpoints in OpenAPI. The submission will include evidence of adding equipment, the HTML documentation, a state diagram, and the OpenAPI documentation. Students will be marked based on the coverage and presentation of the documentation, and the appropriate design of the API extension.

Uploaded by

Nikola
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
69 views3 pages

COMP3220 REST Coursework 2019-2020

This document provides instructions for a coursework assignment to document a university facilities API and design an extension. For part 1, students are asked to explore the existing API, add a new equipment item, and document the API in HTML. For part 2, students must design an extension to the API to enable booking of facilities and equipment, including planning the process, drawing a state diagram, and documenting endpoints in OpenAPI. The submission will include evidence of adding equipment, the HTML documentation, a state diagram, and the OpenAPI documentation. Students will be marked based on the coverage and presentation of the documentation, and the appropriate design of the API extension.

Uploaded by

Nikola
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Coursework Specification

Module: COMP3220 Web Infrastructure

Assignment: REST Coursework Weighting: 50 %

Lecturer: Dr Heather Packer [email protected]

Deadline: 4pm Wed 11th December 2019 Feedback: Wed 8th January 2020

Instructions
This coursework is to be completed individually.

Setting the Scene


You’ve just started your new job as a Web Architect at the admin department in the university. Your
predecessor built a REST API to allow people to view details about facilities and equipment in the university,
but they did not finish the API’s documentation. Your boss has asked you to document the API; before they
left for a meeting, they hurriedly scribbled this URI on a piece of paper:
http://comp3220.ecs.soton.ac.uk/facility/27
Try to GET this, as a starting point. You must be connected to the ECS Virtual Private Network to access it.

Part 1
Your first task is to browse and document the University Facilities and Equipment API. You have one starting
URI and should use what you have learned about HTTP and REST to explore the API and make note of what
you find. Your colleagues recommend that you use an HTTP tool like Postman, RESTClient or cURL to do this.
The following questions will help guide your exploration; you should include answers to them in your
documentation:
• What methods can you use on each URI?
• What format can URIs take?
• What other URIs are possible for this service?

You must:
1. Add your choice of a new piece of equipment to a facility of your choice using the University Facilities and
Equipment API so that it appears in the list. Pick a piece of equipment that does not already exist.
2. Write an HTML5 page to document how the API works. You should describe each resource endpoint in the
API that you find. You must have one page for the whole API, ordered and split into sections as appropriate. It
is expected that the documentation for each resource will include:
a. The URI template for the resource.
b. Any parameters, including what type of values they take.
c. Which HTTP methods can be used on the resource.
d. Example representations for the resource.
e. Example inputs for each interaction that modifies the resource.

Late submissions will be penalised at 10% per working day.


No work can be accepted after feedback has been given.
You should expect to spend up to 75 hours on this assignment.
Please note the University regulations regarding academic integrity.
Note: We are assessing your ability to suitably structure an HTML5 document to represent the data, and to
use some basic CSS to make the document readable and navigable. Therefore, you are NOT allowed to use
any frameworks to write your HTML5 or CSS. Your artistic ability is not being assessed!

Part 2
Your boss now wants you to design an extension to the API which enables students and staff to book facilities
and equipment, and which enables administrators to manage the facilities and equipment. The system
should handle:
• Booking of facilities and equipment
• Cancellations
• Reporting of misuse and broken equipment

The following restrictions apply to your API extension:


Staff can:
• Book any facility or equipment;
• Cancel a booking with no penalty
Students can:
• Book a facility or equipment owned by their department;
• Cancel a booking with no penalty if 24 hours’ notice is given;
• If it’s reported that a student does not use a facility or equipment booking, they will be unable to
book a facility or equipment for 14 days
Staff and Students can:
• Report damaged equipment;
• Report an unused facility or equipment, or usage that exceeds a booking

You may include any additional support in your design for the needs of students and staff, as you see
fit. This might include and is not limited to: allowing staff to override a student’s booking; or appealing
penalties of reported misuse.

You must:
1. Plan each of the steps that go into the booking process. Define URIs to identify the required
additional resources and the methods that interact with them to perform the process and move
through the states.
2. Draw a state diagram that shows a user’s (both staff and students) interactions with the API. (like
the one in Figure 4.1 of REST in Practice).
3. Provide structured documentation of all your new API endpoints using OpenAPI and Swagger.

When documenting your extension using OpenAPI, make sure that you document:
a. The URI templates;
b. The parameters in the URI templates (what they mean, and what types of values they take);
c. The HTTP methods that can be used on the resources;
d. The representation formats (inputs and outputs) for each type of resource.

2
Submission
You will be expected to submit the following:
For Part 1:
• Evidence of submitting a new piece of equipment (screenshots or a text log of request and response).
• A single .html file and an accompanying .css stylesheet, documenting the API in the existing system.
For Part 2:
• A state diagram (format up to you, expecting .png, .jpg, .pptx or .pdf)
• OpenAPI documentation, detailing your designed extensions to the API to add the ability to book
facilities and equipment.

Please submit your coursework using the ECS electronic hand-in system (http://handin.ecs.soton.ac.uk/) by
4pm on the due date.

Relevant Learning Outcomes


1. Understand and use the Representational State Transfer (REST) architectural style of Web applications and
APIs.
2. Identify the key characteristics of the Web Architecture.
3. Demonstrate knowledge and understanding of the common standards for identification, representation
and interaction on the Web.
4. Analyse and use RESTful Web applications.

Marking Scheme
Criterion Description Outcomes Total

Documentation Coverage of API endpoints. Documentation of endpoints. 2, 4 28 %


Demonstration of use (sample output).

Presentation Use of appropriate HTML5 and CSS to present the API 3 12 %


documentation.

Extension Design of API extension. State diagram. Appropriate design of 1 60 %


URIs. Appropriate use of HTTP methods. Application of
HATEOAS.

You might also like