From e0ae260f316064bbf514e051f5fc5835690b5607 Mon Sep 17 00:00:00 2001 From: "Jeffrey C. Witt" Date: Wed, 22 May 2024 15:05:05 -0400 Subject: [PATCH] added some search api starter stuff --- dhsi/SUMMARY.md | 12 ++++++++- dhsi/day-four/iiif-search-api.md | 43 ++++++++++++++++++++++++++------ 2 files changed, 47 insertions(+), 8 deletions(-) diff --git a/dhsi/SUMMARY.md b/dhsi/SUMMARY.md index a59238de..91f0bb1e 100644 --- a/dhsi/SUMMARY.md +++ b/dhsi/SUMMARY.md @@ -55,7 +55,17 @@ 2. [Work Period](day-two/configuring-viewers.md#work-period) - +## Thursday Session ??: 1:00pm-2:15pm + +1. [Search API](day-four/iiif-search-api.md) + + +--- + +TODO: delete below + +--- + - [Overview](README.md) - [Guest Presentations](GuestPresentations.md) diff --git a/dhsi/day-four/iiif-search-api.md b/dhsi/day-four/iiif-search-api.md index 92e20778..c2735e08 100644 --- a/dhsi/day-four/iiif-search-api.md +++ b/dhsi/day-four/iiif-search-api.md @@ -1,13 +1,42 @@ -# Searching Annotations +# IIIF Search API -In the last session we looked at downloading annotations so they could be linked to a manifest. In this session we are going to look at adding a Search service to the manifest so that the annotations you created can be searched using a IIIF Viewer. The procedure to achieve this is: +TODO overview of API - * Find the SAS IIIF Search URL - * Add a link to the Search service in your manifest - * Test with a IIIF Viewer +## Creating a Search Service. +* Your service needs to be able to take in a query via a web request to a designated endpoint +* Search for Hits +* Return Results in the JSON format required by the IIIF api. -## Step 1: Find the IIIF Search URL +## Announcing a Search Service + +* Once you have a search service running, you need to announce. +* Someone loading your manifest will not automatically know that a search service exist +* So, we have to declare this in the manifest like so: + ```json + "service": { + "profile": "http://iiif.io/api/search/0/search", + "@id": , + "@context": "http://iiif.io/api/search/0/context.json" + }, + ``` +* Here's what my service looks like + ```json + "service": { + "@context": "http://iiif.io/api/search/1/context.json", + "@id": "https://exist.scta.info/exist/apps/scta-app/iiif2/lon/search", + "profile": "http://iiif.io/api/search/1/search", + "label": "Search within this manifest" + }, + ``` + +# Example Search Service + +Implementing a serv + + + +