Search for a concept

Conceptpower offers a search REST method. It can be used as follows:


http://[server.url]/conceptpower/rest/ConceptSearch?{list of fieldname=value}&{operator=and/or}&{page=page number}
          


values encoding

values should be encoded

e.g.:


http://my.server.edu/conceptpower/rest/ConceptSearch?creator=jdoe&word=biology&operator=or
          


The following fields can be queried:

  • Equal to: equal_to
  • Similar to: similar_to
  • Description: description
  • Word: word
  • POS: pos
  • Concept List: concept_list
  • Type id: type_id
  • Creator: creator
  • Modified by: modified_by


The fields that are queried can be connected by "and" or "or" via the operator parameter; default is "and." 

Conceptpower response with 20 search results per page. If you do not provide what page number you would like to retrieve, Conceptpower will send the first page of results. You can specify a different page by adding a page parameter, e.g.:


http://my.server.edu/conceptpower/rest/ConceptSearch?creator=jdoe&word=biology&operator=or&page=2


The method returns a list of found concepts like this:


<conceptpowerReply xmlns:digitalHPS="http://www.digitalhps.org/">
    <digitalHPS:conceptEntry>
        <digitalHPS:id concept_id="CON273fb179-b256-4401-b094-614a5e215692" concept_uri="http://www.digitalhps.org/concepts/CON273fb179-b256-4401-b094-614a5e215692">http://www.digitalhps.org/concepts/CON273fb179-b256-4401-b094-614a5e215692</digitalHPS:id>
        <digitalHPS:lemma>Adolf Ziegler</digitalHPS:lemma>
        <digitalHPS:pos>noun</digitalHPS:pos>
        <digitalHPS:description>German embryo modeler in late 19th century</digitalHPS:description>
        <digitalHPS:conceptList>Persons</digitalHPS:conceptList>
        <digitalHPS:creator_id>vracine</digitalHPS:creator_id>
        <digitalHPS:equal_to>http://viaf.org/viaf/38882290</digitalHPS:equal_to>
        <digitalHPS:modified_by></digitalHPS:modified_by>
        <digitalHPS:similar_to></digitalHPS:similar_to>
        <digitalHPS:synonym_ids></digitalHPS:synonym_ids>
        <digitalHPS:type type_id="986a7cc9-c0c1-4720-b344-853f08c136ab" type_uri="http://www.digitalhps.org/types/TYPE_986a7cc9-c0c1-4720-b344-853f08c136ab">E21 Person</digitalHPS:type>
        <digitalHPS:deleted>false</digitalHPS:deleted>
        <digitalHPS:wordnet_id></digitalHPS:wordnet_id>
        <digitalHPS:alternativeIds>
            <digitalHPS:id concept_id="CON273fb179-b256-4401-b094-614a5e215692" concept_uri="http://www.digitalhps.org/concepts/CON273fb179-b256-4401-b094-614a5e215692">http://www.digitalhps.org/concepts/CON273fb179-b256-4401-b094-614a5e215692</digitalHPS:id>
        </digitalHPS:alternativeIds>
    </digitalHPS:conceptEntry>
    <digitalHPS:pagination number_of_records="1" page_number="1" ></digitalHPS:pagination>
</conceptpowerReply>
          

or as JSON:


{
  "conceptEntries": [
    {
      "id": "CON273fb179-b256-4401-b094-614a5e215692",
      "lemma": "Adolf Ziegler",
      "pos": "noun",
      "description": "German embryo modeler in late 19th century",
      "conceptList": "Persons",
      "type": {
        "type_id": "986a7cc9-c0c1-4720-b344-853f08c136ab",
        "type_uri": "http://www.digitalhps.org/types/TYPE_986a7cc9-c0c1-4720-b344-853f08c136ab",
        "type_name": "E21 Person"
      },
      "deleted": false,
      "alternativeIds": [
        {
          "concept_id": "CON273fb179-b256-4401-b094-614a5e215692",
          "concept_uri": "http://www.digitalhps.org/concepts/CON273fb179-b256-4401-b094-614a5e215692"
        }
      ],
      "concept_uri": "http://www.digitalhps.org/concepts/CON273fb179-b256-4401-b094-614a5e215692",
      "creator_id": "vracine",
      "equal_to": "http://viaf.org/viaf/38882290",
      "modified_by": "",
      "similar_to": "",
      "synonym_ids": "",
      "wordnet_id": ""
    }
  ],
  "pagination": {
    "pageNumber": 1,
    "totalNumberOfRecords": 1
  }
}