Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Description

NXQL string

DB string

API query string

Required

is object record deleted?

CSpace specific flag

misc.lifestylestate <> 'deleted'

&wf_deleted=false

Y

sort by

CSpace specific flag

ORDER BY collectionspace_core.updatedat

?sortBy=collectionspace_core:updatedAt

N

Query construction

Searching through authority records via API calls requires prior knowledge of the parent authority CSID. For instance, the default person authority CSID can be gathered from a GET call: http://cspacedev.collectionspace.org:8180/cspace-services/personauthorities/ returns the CSID acc60b93-3a09-47eb-bd8f for authority with displayName 'Default Person Authority'.

Foreknowledge of the parent authority ID is no longer necessary. Only the name of the parent authority needs be known, which for MMI is the default person authority. The personauthority service will accept either the CSID or the authority name in the string format urn:cspace:name(person).
The URL structure is formatted as such

Code Block
http://cspacetest.collectionspace.org:8180/cspace-services/personauthorities/acc60b93-3a09-47eb-bd8f/items?as=

or

Code Block

http://cspacetest.collectionspace.org:8180/cspace-services/personauthorities/urn:cspace:name(person)/items?as=

with the latter not requiring a specific CSID.

Get cataloging records referencing a specific person authority record

...

Code Block
http://cspacetest.collectionspace.org:8180/cspace-services/personauthorities/acc60b93-3a09-47eb-bd8furn:cspace:name(person)/items/442a6f9e-e361-4369-a8e3/refObjs?type=object

...