Div | ||
---|---|---|
| ||
Intake Service Home |
Brief Description
Insert excerpt | ||||||||
---|---|---|---|---|---|---|---|---|
|
Assumptions
For a complete list of assumptions, visit the Service Description and Assumptions page.
References
Object Entry Requirements
Intake Stories
Intake Service Description and Assumptions
Intake Service Entity Diagrams
Intake Schema
REST-based API
The Intake Service offers a REST-based Application Programming Interface (API) to CRUD (create, read, update, and delete) operations on individual Intake instances, plus list operations on multiple Intake instances. These follow the Common model for CollectionSpace REST services.
Intake CRUD+L services
Create an Intake
Creates a new Intake record. Assigns a unique, service-specified CollectionSpace ID (CSID) /wiki/spaces/collectionspace/pages/666274321 to that Intake record. Follows standard Create model. See the documentation of the Intake schema, below. Example:
Code Block |
---|
POST /cspace-services/intakes HTTP/1.1 |
Read an Intake
Reads an existing Intake record, specified by its CollectionSpace ID (CSID) /wiki/spaces/collectionspace/pages/666274321. Follows standard Read model. See the documentation of the Intake schema, below. Example:
Code Block |
---|
GET /cspace-services/intakes/{id} HTTP/1.1 |
Update an Intake
Updates an existing Intake record, specified by its CollectionSpace ID (CSID) /wiki/spaces/collectionspace/pages/666274321. Follows standard Update model. See the documentation of the Intake schema, below. Example:
Code Block |
---|
PUT /cspace-services/intakes/{id} HTTP/1.1 |
Delete an Intake
Deletes an existing Intake record, specified by its CollectionSpace ID (CSID) /wiki/spaces/collectionspace/pages/666274321. Follows standard Delete model. Example:
Code Block |
---|
DELETE /cspace-services/intakes/{id} HTTP/1.1 |
List Intake instances
Lists existing Intake records, with summary information for each. Follows standard List model, with pagination support. See the documentation of the Intake list schema, below. Example:
Note |
---|
Aron to verify pagination support in Intake service |
Intake supports the following common parameters for List results, pagination controls and query filters:
- pgSz for page size
- pgNum for page size
...
Code Block |
---|
GET /cspace-services/intakes HTTP/1.1
|
List supports query parameters for customizing list results, such as pagination controls, query filters, and sorting options. For example:
Code Block |
---|
GET /cspace-services/intakes/?pgSz=10 HTTP/1.1 |
List also supports query parameters for searching for matching records, including keyword search. For example:
Code Block |
---|
GET /cspace-services/intakes/?kw=foo&pgSz=10 HTTP/1.1 |
Intake REST payload schemas
Intake instance schema
Info |
---|
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 Intake records, please see the Intake record schema for release 0.5. |
Create and Update should use the following schema.
Note |
---|
Aron to update with Intake instance schema used in payloads to create and update |
:
Code Block |
---|
<?xml version="1.0" encoding="utf-8" standalone="yes"?> <ns2:orgauthorities-intakes_common xmlns:ns2="http://collectionspace.org/services/intake" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://collectionspace.org/services/intake http://services.collectionspace.org/organization/intake/intakes_common.xsd"> <displayName>Museum Internal</displayName><entryNumber>IN2010.2</entryNumber> <refName>urn<depositor>urn:cspace:org.collectionspace.demo:orgauthority:personauthority:name(TestPersonAuth):person:name(Museum InternalAlfred L. Kroeber)'Museum InternalAlfred L. Kroeber'</refName>depositor> <vocabType>OrgAuthority</vocabType>... </ns2:orgauthorities-intakes_common> |
Read will return the above, plus additional fields (uri and csid) for accessfollowing schema:
Code Block |
---|
<?xml version="1.0" encoding="utf-8" standalone="yes"?> <ns2:intakes-_common xmlns:ns2="http://collectionspace.org/services/intake" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://collectionspace.org/services/intake http://services.collectionspace.org/intake/intakes_common.xsd"> <entryNumber>IN2010.2</entryNumber> <depositor>urn:cspace:org.collectionspace.demo:personauthority:name(TestPersonAuth):person:name(Alfred L. Kroeber)'Alfred L. <uri>/intakes/f0cf4c50-8f8a-4df0-869a</uri> <csid>f0cf4c50-8f8a-4df0-869a</csid>Kroeber'</depositor> ... </ns2:intakes-_common> |
Intake schema
List (and variants) will return the following schema.
...
This schema includes the uri and csid fields to help facilitate access to individual records:
Code Block |
---|
<?xml version="1.0" encoding="utf-8" standalone="yes"?> <ns2:orgauthoritiesintakes-common-list xmlns:ns2="http://services.collectionspace.org/organizationservices/intake"> <pageNum>0</pageNum> <pageSize>40</pageSize> <totalItems>3</totalItems> <orgauthorities_list_<intake-list-item> <displayName>Museum Internal</displayName><entryNumber>IN2010.2</entryNumber> <refName>urn:cspace:org.collectionspace.demo:orgauthority:name(Museum Internal)'Museum Internal'</refName> <vocabType>OrgAuthority</vocabType><depositor>Alfred L. Kroeber</depositor> <uri>/orgauthoritiesintakes/f0cf4c50b59d0c6f-8f8a08f2-4df04fb5-869a<b5f7</uri> <csid>f0cf4c50<csid>b59d0c6f-8f8a08f2-4df04fb5-869a<b5f7</csid> </orgauthorities_intake-list_-item> .... </ns2:orgauthoritiesintakes-common-list> |