samvera / questioning_authority

Question your authorities
Other
54 stars 30 forks source link

add option to include a response header in results #283

Closed elrayle closed 4 years ago

elrayle commented 4 years ago

Add an option to include a response header in results.

Usage

To request the response_header, append parameter &response_header=true to QA requests.

search results example

response_header = {
       start_record: 31          # the number of the first record returned
       requested_records: 10     # the number of records requested (aka page size)
       retrieved_records: 10     # the actual number of records returned in this request
       total_records: 85         # the total number of matches for this search request
}

fetch results example

response_header = {
       predicate_count: 13   # the number of predicates that have the requested URI as the subject
}

Related work

281 add new configurations for identifying parameters related to pagination of linked data results

282 move performance data output generation to a service

elrayle commented 4 years ago

Requested changes in PR #282 are now incorporated here. This is ready for review.