Skip to content
Search! & Match! API
Assessments Service
latest

Assessments Service

Assessments Service🔗

The assessments service allows management of document assessments. It comes with a method to save them. To retrieve assessments for a project call the Projects Service list method.

Method saveAssesmentWithToken🔗

Method call🔗

saveAssessmentWithToken(accessToken, projectID, docID, searchEngine, state, relevance) : saveAssesmentWithTokenResponse

Description🔗

The assessment service persists a new document assessment.

Parameters🔗

Parameter Name Type Description
accessToken string the access token
projectID string identifier for project the assessment belongs to, or null for an isolated query assessment.
docID string the document ID (unique within the searchEngine)
searchEngine string the searchEngine where the results belong to
state string hashed (base64-encoded) search state
relevance integer the relevance score of the result for the given project or query, on a scale of 0 to 10, or -1 for not "don't know".

Returns🔗

Result Name Type Description
saveAssessmentResponse String OK, if successful

Pre-Condition🔗

  • A project with project_id exists.
  • The project with project_id is owned by the user.

Post-Condition🔗

The assessment is stored in the database.

Error Handling🔗

Error Code Description
EMPTY_ARGUMENT One or more mandatory arguments are empty.
METHOD_NOT_AVAILABLE The service method is not enabled in the environment configuration.
INVALID_ACCESS_TOKEN The token is not valid (possibly timed-out) - applies only to token authentication.
ENVIRONMENT_NOT_AVAILABLE The environment is not available (see log-file for possible errors).
DATABASE_ERROR Database communication failed (possibly a misconfiguration issue).
PROJECT_NOT_FOUND A project with projectID is not existing.
PROJECT_ACCESS_DENIED The project with projectID is not owned by the user.