Since 2001, the Computer Science department has maintained its own collection of photos of CSE faculty, staff, and students. We have a number of web apps such as photo directories or class lists that display these images. We long ago settled on a standard size for the images and developed a procedure for adding a person’s name to the image. But with Autumn quarter bringing in close to 200 new students, the process of capturing and processing these images is a lengthy one.
With the release of the IdCard web service this quarter, the work involved has dropped to near zero. We can now automatically retrieve a student’s photo from the IdCard service rather than taking our own (note that by policy, we can only retrieve student photos, not those of staff or faculty). Our undergrad program alone admitted 105 new students this quarter, and if we assume 10 minutes per photo, it would take over 17 staff-hours to collect all photos. I was able to modify our existing infrastructure to take advantage of the IdCard service in one afternoon. This quarter alone, the time savings is huge.
The process was simplified because access to our local store of photos all went through a single PHP web app. Students have the right to opt-out of having their photos displayed to the public or their peers, and one of the main jobs of this application was to control access to the photos depending on the person making the request. My strategy is first to look in our local store of photos, and if one is not found then to try the IdCard service. If found there, the photo is retrieved, normalized to our standards, and then stored locally. The next time the photo is requested, it is found in local “cache” and no request to the web service is needed.
The design of the IdCard service makes this task quite easy. The photo resource lets you retrieve the photo in the size that’s most convenient to you. I request the photos in our standard dimensions and then use the PHP interface to the GD image processing functions to add a student’s name to the image. That image is then stored locally along with all the others, and all of our existing infrastructure now takes full advantage of the IdCard’s photo resource. If we wish to “override” one of the ID card photos, we simply take and upload a person’s photograph as before, and the new one is served preferentially.
One side-note is that, as with most web resources concerning students, the native identifier for a person is his regid. We had never before used regids, keeping instead system_key and uwnetid for each user. In order to collect regids, we use the person resource of the SWS to do a system_key to regid translation, and then save the regid locally so that this translation only happens once per person.
The listing of the IdCard service in the registry is awaiting some polishing of the documentation (restricted) but expected soon. For access, contact Tony Chang or Paul Schurr. To use this service, you will need to obtain a test and a development client certificate for your application which you will use to authenticate to the IdCard service. Permission to use the resource is granted by the registrar, and before getting the final OK, you and they will do a short security review of your application. It’s all easier than it sounds, and if you get stuck you can contact firstname.lastname@example.org and they’ll hook you up with someone who can answer your questions.