Difference between revisions of "searchEac"

From Archives Portal Europe Wiki
Jump to: navigation, search
(filters)
(dateFilters)
Line 47: Line 47:
  
 
== dateFilters ==
 
== dateFilters ==
Request parameters "dateFilters" enables you to filter the result on a certain period of time. The dateFacets are summarized in [[SearchEac#date_facets]]
+
Request parameters "dateFilters" enables you to filter the result on a certain period of time. The dateFacets are summarized in [[searchEac#date_facets]]
 
<br/><br/>
 
<br/><br/>
 +
 
= Response parameters =
 
= Response parameters =
 
The response contains a list of the descriptions where the requested search-term(s) was/were found.
 
The response contains a list of the descriptions where the requested search-term(s) was/were found.

Revision as of 11:43, 8 March 2017

Request url: https://api.archivesportaleurope.net/services/search/eac-cpf. This service is a POST-request.

This search-service delivers a list of authority records for Corporate Bodies, Persons or Families (CPF) with the requested searchterm. A web developer is able to filter results on various facets.



Request parameters

Three request parameters can be used to do a search in descriptions of records creators and two types of filters can be used.

eg.

{
  "count": 5,
  "startIndex": 0,
  "query": "louis",
  "filters": [
    {
      "facetFieldName": "country",
      "facetFieldIds": [
        "7"
      ]
    }
  ],
  "dateFilters": [
    {
      "dateFieldName": "fromDate",
      "dateFieldId": "1800-01-01_2"
    }
  ]
}

This example searches for archival descriptions with the term "louis" and filters on the facet "country" with id = 7 (identifier for "NETHERLANDS") and date-facet "fromDate" with id = "1800-01-01_2" (identifier for the period 1800-1999).

count

The resultlist is delivered in chunks of a certain size. Request parameter "count" describes the number of results that are in one chunk. Optional. Default value is 5.

startIndex

Request parameter "startIndex" enables you to select the results that you want to have. Counting starts at zero. If "count" = 5, the second chunk starts with startIndex 5, the following at startIndex 10, etc. Optional. Default value is 0.

query

Containing the searchterm(s). Required.

filters

Request parameter "filters" enables you to filter the result on facets. The facets are summarized in searchEac#facets.

dateFilters

Request parameters "dateFilters" enables you to filter the result on a certain period of time. The dateFacets are summarized in searchEac#date_facets

Response parameters

The response contains a list of the descriptions where the requested search-term(s) was/were found.

eg.

{
  "totalResults": 549,
  "startIndex": 0,
  "totalPages": 110,
  "eacSearchResults": [
    {
      "id": "2668",
      "recordId": "FRAN_NP_011360",
      "entityType": "person",
      "nameEntries": [
        "Larsonnier, Louis",
        "Larsonnyer, Louis"
      ],
      "nameEntriesWithHighlighting": [
        "Larsonnier, <em>Louis</em>"
      ],
      "existDates": "11 septembre 1709 - 19 juin 1724",
      "description": " notaire substituant dans l'étude LXXII ...",
      "other": " Etude notariale XXXII ET/LXIX/280, 29 mai 1724, ...",
      "otherWithHighlighting": " du répertoire du notaire <em>Louis</em> Larsonnier pour l",
      "repository": "Franse archief",
      "repositoryCode": "NL-00000000660",
      "country": "NETHERLANDS",
      "countryId": "7",
      "numberOfArchivalMaterialRelations": "3",
      "numberOfNameRelations": "1"
    },
   ... skip ...
  ],
  "facetFields": {
    "country": [
      {
        "id": "7",
        "name": "NETHERLANDS",
        "frequency": 180
      },
      {
        "id": "16",
        "name": "FRANCE",
        "frequency": 25
      }
    ],
  ... skip ...
  }
  "facetDateFields": {
      "fromDate": [
        {
          "id": "1800-01-01_2",
          "name": "1800-1999",
          "frequency": 166
        },
        {
          "id": "2000-01-01_2",
          "name": "2000-2199",
          "frequency": 2
        }
      ],
      "toDate": [
        {
          "id": "1800-01-01_2",
          "name": "1800-1999",
          "frequency": 166
        },
        {
          "id": "2000-01-01_2",
          "name": "2000-2199",
          "frequency": 2
        }
      ]
    }
}

totalResults

The response parameter "totalResults" gives the number of results.

startIndex

The response parameter "startIndex" gives the number of the chunk you requested.

totalPages

The response parameter "totalPages" gives the number of chunks.

eacSearchResults

Enumeration of the results. They are all optional except "id".

id
recordId
entityType
nameEntries
nameEntriesWithHighlighting
existDates
description
descriptionWithHighlighting
other
otherWithHighlighting
repository Name of the repository holding the fonds
repositoryCode Code of the repository holding the fonds. Preferably, but not necessarily ISIL.
country Name of the country where the repository is. In English.
countryId
numberOfArchivalMaterialRelations
numberOfNameRelations

facetFields

This respsonse parameter gives an enumeration of facets. Every facet has three variables.

id Internal APE identifier of the value. Use this "id" in the filter request parameter.
name Human readable value (in English).
frequency The number of results of this facet containing the searchterm.

facets

country Name of the country where the repository is. In English.
repository Name of the repository responsible for the record.
entityType
place
language
dateType Type of date describing the archival unit.

date facets

With the date facets you can zoom in on the period of time. Results are grouped in periods of two centuries in the first step. If you use these groupings in the request-parameter dateFilter, you'll have new dateFacets that groups the results into groups of two decads

fromDate Grouping of the search result in starting dates.
toDate Grouping of the search result in ending dates.