Acquisition Service REST APIs

The Acquisition Service offers a REST-based Application Programming Interface (API) to CRUD (create, read, update, and delete) operations on individual Acquisition instances, plus list operations on multiple Acquisition instances. These follow the Common model for CollectionSpace REST services.

Acquisition CRUD+L services

Create an Acquisition

Creates a new Acquisition record. Assigns a unique, service-specified CollectionSpace ID (CSID) to that Acquisition record. Follows standard Create model. See the documentation of the Acquisition schema, below. Example:

POST /cspace-services/acquisitions HTTP/1.1
Read an Acquisition

Reads an existing Acquisition record, specified by its CollectionSpace ID (CSID). Follows standard Read model. See the documentation of the Acquisition schema, below. Example:

GET /cspace-services/acquisitions/{id} HTTP/1.1
Update an Acquisition

Updates an existing Acquisition record, specified by its CollectionSpace ID (CSID). Follows standard Update model. See the documentation of the Acquisition schema, below. Example:

PUT /cspace-services/acquisitions/{id} HTTP/1.1
Delete an Acquisition

Deletes an existing Acquisition record, specified by its CollectionSpace ID (CSID). Follows standard Delete model. Example:

DELETE /cspace-services/acquisitions/{id} HTTP/1.1
List Acquisition instances

Lists existing Acquisition records, with summary information for each. Follows standard List model. See the documentation of the Acquisition list schema, below. Example:

GET /cspace-services/acquisitions HTTP/1.1

List supports query parameters for customizing list results, such as pagination controls, query filters, and sorting options. For example:

GET /cspace-services/acquisitions?pgSz=10 HTTP/1.1

List also supports query parameters for searching for matching records, including keyword search. For example:

GET /cspace-services/acquisitions?kw=foo&pgSz=10 HTTP/1.1

Acquisition REST payload schemas

Acquisition instance schema

This section needs to be brought up to date per current schema documentation practices.

The schemas below are severely abbreviated, and are thus illustrative. For a full list of the fields that may potentially be present in payloads when creating, updating, or reading individual Acquisition records, please see the Acquisition record schema for release 0.5.

Create and Update should use the following schema:

<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<ns2:acquisitions_common xmlns:ns2="http://collectionspace.org/services/acquisition">
  <acquisitionReferenceNumber>2010.1</acquisitionReferenceNumber>
  <acquisitionSources>
    <acquisitionSource>urn:cspace:org.collectionspace.demo:orgauthority:name(TestOrgAuth):organization:name(Hasbro, Inc.)'Hasbro, Inc.'</acquisitionSource>
  </acquisitionSources>
  <acquisitionReason>Supplement collection of board games.</acquisitionReason>
  ...
</ns2:acquisitions_common>

Read will return the following schema:

<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<ns2:acquisitions_common xmlns:ns2="http://collectionspace.org/services/acquisition" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://collectionspace.org/services/acquisition http://services.collectionspace.org/acquisition/acquisitions_common.xsd">
  <acquisitionReferenceNumber>2010.1</acquisitionReferenceNumber>
  <acquisitionSources>
    <acquisitionSource>urn:cspace:org.collectionspace.demo:orgauthority:name(TestOrgAuth):organization:name(Hasbro, Inc.)'Hasbro, Inc.'</acquisitionSource>
  </acquisitionSources>
  <acquisitionReason>Supplement collection of board games.</acquisitionReason>
  ...
</ns2:acquisitions_common>
Acquisition list schema

List (and variants) will return the following schema. This schema includes the uri and csid fields to help facilitate access to individual records:

<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<ns2:acquisitions-common-list xmlns:ns2="http://collectionspace.org/services/acquisition">
  <acquisition-list-item>
    <acquisitionReferenceNumber>2010.1.51</acquisitionReferenceNumber>
    <acquisitionSources>
      <acquisitionSource>urn:cspace:org.collectionspace.demo:orgauthority:name(TestOrgAuth):organization:name(Hasbro, Inc.)'Hasbro, Inc.'</acquisitionSource>
    </acquisitionSources>
    <uri>/acquisitions/c6563617-a129-4b92-8d38</uri>
    <csid>c6563617-a129-4b92-8d38</csid>
  </acquisition-list-item>
  ....
</ns2:acquisitions-common-list>

See also

Common Services REST API documentation