![]() |
Grima
2018-08
Whispering into Alma's ear
|
grima-lib.php - a library for running API calls in Alma More...
Public Member Functions | |
| session_init ( $force=false) | |
| session_save ($result) | |
| session_destroy () | |
| __construct () | |
| request ($method, $url, $URLparams, $QSparams, $body=null) | |
| general function for REST API calls More... |
|
| get ($url, $URLparams, $QSparams) | |
| general function for GET (retrieve) API calls More... |
|
| post ($url, $URLparams, $QSparams, $body) | |
| general function for POST (create) API calls More... |
|
| put ($url, $URLparams, $QSparams, $body) | |
| general function for PUT (update) API calls More... |
|
| delete ($url, $URLparams, $QSparams) | |
| general function for DELETE API calls More... |
|
| checkForErrorMessage ($xml) | |
| checks for errorMessage tag, throws exceptions More... |
|
Bib APIs | |
| getBib ($mms_id, $view='full', $expand='None') | |
| Retrieve Bib - retrieve a bib record from Alma. More... |
|
| postBib ($bib) | |
| Create Record - adds a new bib record to Alma. More... |
|
| putBib ($mms_id, $bib) | |
| Update Bib Record - updates the copy of the bib in Alma. More... |
|
| deleteBib ($mms_id, $override='false') | |
| Delete Bib Record - deletes the bib record from Alma. More... |
|
Holdings List APIs | |
| getHoldingsList ($mms_id) | |
| Retrieve Holdings list - download brief descriptions of holdings for the bib. More... |
|
Holding APIs | |
| getHolding ($mms_id, $holding_id) | |
| Retrieve Holdings Record - retrieve holdings record from Alma. More... |
|
| postHolding ($mms_id, $holding) | |
| Create holding record - add a new holdings record to a bib. More... |
|
| putHolding ($mms_id, $holding_id, $holding) | |
| Update Holdings Record - replace the holdings record in Alma. More... |
|
| deleteHolding ($mms_id, $holding_id, $override='false') | |
| Delete Holdings Record - delete the holdings record from Alma. More... |
|
Item List APIs | |
| getItemList ($mms_id, $holding_id, $limit, $offset) | |
| Retrieve Items list - retrieve the items list from a holding or bib from Alma. More... |
|
Item APIs | |
| getItem ($mms_id, $holding_id, $item_pid) | |
| Retrieve Item and print label information. More... |
|
| getItemBC ($barcode) | |
| Retrieve Item and print label information (by barcode)) More... |
|
| postItem ($mms_id, $holding_id, $item) | |
| Create Item - add a new item to a holding in Alma. More... |
|
| putItem ($mms_id, $holding_id, $item_pid, $item) | |
| Update Item information - replace item record in Alma. More... |
|
| deleteItem ($mms_id, $holding_id, $item_pid, $override="false", $holdings="retain") | |
| Withdraw Item - delete an item record from Alma. More... |
|
Electronic APIs | |
| getElectronicPortfolio ($collection_id, $service_id, $portfolio_id) | |
| Retrieve Portfolio - retrieve a portfolio record from Alma. More... |
|
| getElectronicPortfolioFromBib ($mms_id, $portfolio_id) | |
| Retrieve Portfolio - retrieve a portfolio record from Alma. More... |
|
| postElectronicPortfolio ($collection_id, $service_id, $portfolio) | |
| Create Electronic Portfolio - add a new portfolio to Alma. More... |
|
| postElectronicPortfolioOnBib ($mms_id, $portfolio, $update=true) | |
| Create Electronic Portfolio - add a new portfolio to Alma Bib. More... |
|
| putElectronicPortfolioOnBib ($mms_id, $portfolio_id, $portfolio) | |
| Update Electronic Portfolio - update portfolio in Alma. More... |
|
| deleteElectronicPortfolio ($collection_id, $service_id, $portfolio_id) | |
| Delete Electronic Portfolio - delete portfolio from Alma. More... |
|
| getElectronicPortfoliosForService ($collection_id, $service_id, $limit, $offset) | |
| Retrieve Portfolios - retrieve a list of portfolios from Alma. More... |
|
| getElectronicPortfoliosForBib ($mms_id, $limit, $offset) | |
| Retrieve Portfolios list (Bib) - retrieve a list of portfolios from Alma. More... |
|
| getElectronicCollection ($collection_id) | |
| Retrieve Electronic Collection - retrieve a collection record from Alma. More... |
|
| putElectronicCollection ($collection_id, $collection) | |
| Update Electronic Collection Record - updates the copy of the collection in Alma. More... |
|
| getElectronicServices ($collection_id) | |
| Retrieve Electronic Services - retrieve a list of services from a collection in Alma. More... |
|
Library APIs | |
| getLibrary ($libraryCode) | |
| Retrieve a Library - retrieve a Library from Alma. More... |
|
| getAllLibraries () | |
| Retrieve Libraries - retrieve all libraries. More... |
|
| getAllLocations ($libraryCode) | |
| Retrieve Locations - retrieve all locations in a library. More... |
|
Location APIs | |
| getLocation ($libraryCode, $locationCode) | |
| Retrieve Location - retrieve a Library Location from Alma. More... |
|
Set APIs | |
| getSet ($set_id) | |
| Retrieve a Set - retrieve a Set from Alma. More... |
|
| postSet ($set) | |
| Create a Set - add a new set to Alma. More... |
|
| postSetManageMembers ($set_id, $id_type, $op, $set) | |
| Manage Members - modify sets in Alma. More... |
|
| createSetFromImport ($job_instance_id, $population) | |
| Create a Set from an import job. More... |
|
| deleteSet ($set_id) | |
| Delete a Set - delete a set (not its items) from Alma. More... |
|
| getSetMembers ($set_id, $limit=10, $offset=0) | |
| get the members of a set, IF IT WORKS?!?! More... |
|
Analytics APIs | |
| getAnalytics ($path, $filter, $limit=25, $token=null) | |
Job APIs | |
| postJob ($job_id, $op, $job) | |
| Submit a manual or scheduled job. More... |
|
Public Attributes | |
| $server | |
| $apikey | |
grima-lib.php - a library for running API calls in Alma
(c) 2019 Kathryn Lybarger. CC-BY-SA
Definition at line 15 of file grima-lib.php.
| Grima::__construct | ( | ) |
Definition at line 83 of file grima-lib.php.
References $apikey, $server, getenvWithFileFallbackAndDefault(), and session_init().
| Grima::checkForErrorMessage | ( | $xml | ) |
checks for errorMessage tag, throws exceptions
| DomDocument | $xml |
Definition at line 288 of file grima-lib.php.
Referenced by createSetFromImport(), deleteBib(), deleteElectronicPortfolio(), deleteHolding(), deleteItem(), deleteSet(), getAllLibraries(), getAllLocations(), getBib(), getElectronicCollection(), getElectronicPortfolio(), getElectronicPortfolioFromBib(), getElectronicPortfoliosForBib(), getElectronicPortfoliosForService(), getElectronicServices(), getHolding(), getHoldingsList(), getItem(), getItemBC(), getItemList(), getLibrary(), getLocation(), getSet(), getSetMembers(), postBib(), postElectronicPortfolio(), postElectronicPortfolioOnBib(), postHolding(), postItem(), postJob(), postSet(), postSetManageMembers(), putBib(), putElectronicCollection(), and putElectronicPortfolioOnBib().
| Grima::createSetFromImport | ( | $job_instance_id, | |
| $population | |||
| ) |
Create a Set from an import job.
Makes a call to the API: (API docs)
POST /almaws/v1/conf/sets
| string | $job_instance_id | ID of the import job |
| string | $population | ... |
Definition at line 1161 of file grima-lib.php.
References checkForErrorMessage(), and post().
| Grima::delete | ( | $url, | |
| $URLparams, | |||
| $QSparams | |||
| ) |
general function for DELETE API calls
| string | $url | - URL pattern string with parameters in {} |
| array | $URLparams | - URL parameters |
| array | $QSparams | - query string parameters |
Definition at line 278 of file grima-lib.php.
References request().
| Grima::deleteBib | ( | $mms_id, | |
$override = 'false' |
|||
| ) |
Delete Bib Record - deletes the bib record from Alma.
Makes a call to the API: (API docs)
DELETE /almaws/v1/bibs/{mms_id}
| string | $mms_id | MMS ID of Alma Bib record to delete |
| string | $override | Optional. Default=false |
Definition at line 389 of file grima-lib.php.
References checkForErrorMessage().
| Grima::deleteElectronicPortfolio | ( | $collection_id, | |
| $service_id, | |||
| $portfolio_id | |||
| ) |
Delete Electronic Portfolio - delete portfolio from Alma.
Makes a call to the API: (API docs)
DELETE /almaws/v1/electronic/e-collections/{collection_id}/e-services/{service_id}/portfolios/{portfolio_id}
| string | $collection_id | ID of collection |
| string | $service_id | ID of service |
| string | $portfolio_id | ID of portfolio |
Definition at line 842 of file grima-lib.php.
References checkForErrorMessage().
| Grima::deleteHolding | ( | $mms_id, | |
| $holding_id, | |||
$override = 'false' |
|||
| ) |
Delete Holdings Record - delete the holdings record from Alma.
Makes a call to the API: (API docs)
DELETE /almaws/v1/bibs/{mms_id}/holdings/{holding_id}
| string | $mms_id | MMS ID of Alma Bib record |
| string | $holding_id | Holding ID of Holding record to delete from Alma |
| string | $override | Optional. Default=false |
Definition at line 521 of file grima-lib.php.
References checkForErrorMessage().
| Grima::deleteItem | ( | $mms_id, | |
| $holding_id, | |||
| $item_pid, | |||
$override = "false", |
|||
$holdings = "retain" |
|||
| ) |
Withdraw Item - delete an item record from Alma.
Makes a call to the API: (API docs)
DELETE /almaws/v1/bibs/{mms_id}/holdings/{holding_id}/items/{item_pid}
| string | $mms_id | MMS ID of Bib record |
| string | $holding_id | Holding ID of holding record |
| string | $item_pid | Item ID of item record |
| string | $override | Override warnings? (false, true) |
| string | $holdings | How to handle holdings with inventory? (retain, delete or suppress) |
Definition at line 685 of file grima-lib.php.
References checkForErrorMessage().
| Grima::deleteSet | ( | $set_id | ) |
Delete a Set - delete a set (not its items) from Alma.
Makes a call to the API: (API docs)
DELETE /almaws/v1/conf/sets/{set_id}
| string | $set_id | Set ID |
Definition at line 1212 of file grima-lib.php.
References checkForErrorMessage().
| Grima::get | ( | $url, | |
| $URLparams, | |||
| $QSparams | |||
| ) |
general function for GET (retrieve) API calls
| string | $url | - URL pattern string with parameters in {} |
| array | $URLparams | - URL parameters |
| array | $QSparams | - query string parameters |
Definition at line 234 of file grima-lib.php.
References request().
| Grima::getAllLibraries | ( | ) |
Retrieve Libraries - retrieve all libraries.
Makes a call to the API: (API docs)
GET /almaws/v1/conf/libraries
Definition at line 1009 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getAllLocations | ( | $libraryCode | ) |
Retrieve Locations - retrieve all locations in a library.
Makes a call to the API: (API docs)
GET /almaws/v1/conf/libraries/{libraryCode}/locations
Definition at line 1030 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getAnalytics | ( | $path, | |
| $filter, | |||
$limit = 25, |
|||
$token = null |
|||
| ) |
Definition at line 1254 of file grima-lib.php.
| Grima::getBib | ( | $mms_id, | |
$view = 'full', |
|||
$expand = 'None' |
|||
| ) |
Retrieve Bib - retrieve a bib record from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/bibs/{mms_id}
| string | $mms_id | The Bib Record ID. |
| string | $view | Optional. Default=full |
| string | $expand | Optional. Default=None |
Definition at line 320 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getElectronicCollection | ( | $collection_id | ) |
Retrieve Electronic Collection - retrieve a collection record from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/electronic/e-collections/{collection_id}
| string | $collection_id | ID of collection |
Definition at line 912 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getElectronicPortfolio | ( | $collection_id, | |
| $service_id, | |||
| $portfolio_id | |||
| ) |
Retrieve Portfolio - retrieve a portfolio record from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/electronic/e-collections/{collection_id}/e-services/{service_id}/portfolios/{portfolio_id}
| string | $collection_id | ID of collection |
| string | $service_id | ID of service |
| string | $portfolio_id | ID of portfolio |
Definition at line 721 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getElectronicPortfolioFromBib | ( | $mms_id, | |
| $portfolio_id | |||
| ) |
Retrieve Portfolio - retrieve a portfolio record from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/bibs/{mms_id}/portfolios/{portfolio_id}
| string | $mms_id | ID of bib record |
| string | $portfolio_id | ID of portfolio |
Definition at line 744 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getElectronicPortfoliosForBib | ( | $mms_id, | |
| $limit, | |||
| $offset | |||
| ) |
Retrieve Portfolios list (Bib) - retrieve a list of portfolios from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/bibs/{mms_id}/portfolios
| string | $mms_id | ID of bib |
| string | $limit | Max number of portfolios to retrieve |
| string | $offset | Offset of the results |
Definition at line 890 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getElectronicPortfoliosForService | ( | $collection_id, | |
| $service_id, | |||
| $limit, | |||
| $offset | |||
| ) |
Retrieve Portfolios - retrieve a list of portfolios from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/electronic/e-collections/{collection_id}/e-services/{service_id}/portfolios
| string | $collection_id | ID of collection |
| string | $service_id | ID of service |
| string | $limit | Max number of portfolios to retrieve |
| string | $offset | Offset of the results |
Definition at line 866 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getElectronicServices | ( | $collection_id | ) |
Retrieve Electronic Services - retrieve a list of services from a collection in Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/electronic/e-collections/{collection_id}/e-services
| string | $collection_id | ID of collection |
Definition at line 959 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getHolding | ( | $mms_id, | |
| $holding_id | |||
| ) |
Retrieve Holdings Record - retrieve holdings record from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/bibs/{mms_id}/holdings/{holding_id}
Definition at line 448 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getHoldingsList | ( | $mms_id | ) |
Retrieve Holdings list - download brief descriptions of holdings for the bib.
Makes a call to the API: (API docs)
GET /almaws/v1/bibs/{mms_id}/holdings
| string | $mms_id | MMS ID of Alma Bib to gather holdings from |
Definition at line 418 of file grima-lib.php.
References checkForErrorMessage().
Referenced by Bib\getHoldings(), and Bib\hasInventory().
| Grima::getItem | ( | $mms_id, | |
| $holding_id, | |||
| $item_pid | |||
| ) |
Retrieve Item and print label information.
Makes a call to the API: (API docs)
GET /almaws/v1/bibs/{mms_id}/holdings/{holding_id}/items/{item_pid}
| string | $mms_id | MMS ID of Alma Bib |
| string | $holding_id | Holding ID of Alma Holding |
| string | $item_pid | Item ID of Alma Holding |
Definition at line 584 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getItemBC | ( | $barcode | ) |
Retrieve Item and print label information (by barcode))
Makes a call to the API: (API docs)
GET /almaws/v1/items?item_barcode={item_barcode}
| string | $barcode | Barcode of Alma item |
Definition at line 608 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getItemList | ( | $mms_id, | |
| $holding_id, | |||
| $limit, | |||
| $offset | |||
| ) |
Retrieve Items list - retrieve the items list from a holding or bib from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/bibs/{mms_id}/holdings/{holding_id}/items
| string | $mms_id | MMS ID of Alma bib |
| string | $holding_id | MMS ID of Alma holding |
| string | $limit | Max number of items to retrieve |
| string | $offset | Offset of the results returned |
Definition at line 555 of file grima-lib.php.
References checkForErrorMessage().
Referenced by Holding\deleteTreeFromAlma(), Bib\getItems(), Holding\getItems(), and Holding\hasItems().
| Grima::getLibrary | ( | $libraryCode | ) |
Retrieve a Library - retrieve a Library from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/conf/libraries/{libraryCode}
| string | $libraryCode | ID of the library to retrieve |
Definition at line 988 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getLocation | ( | $libraryCode, | |
| $locationCode | |||
| ) |
Retrieve Location - retrieve a Library Location from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/conf/libraries/{libraryCode}/locations/{locationCode}
| string | $libraryCode | ID of the library to retrieve |
Definition at line 1059 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getSet | ( | $set_id | ) |
Retrieve a Set - retrieve a Set from Alma.
Makes a call to the API: (API docs)
GET /almaws/v1/conf/sets/{set_id}
| string | $set_id | ID of the set to retrieve |
Definition at line 1091 of file grima-lib.php.
References checkForErrorMessage().
| Grima::getSetMembers | ( | $set_id, | |
$limit = 10, |
|||
$offset = 0 |
|||
| ) |
get the members of a set, IF IT WORKS?!?!
Makes a call to the API: (API docs)
GET /almaws/v1/conf/sets/{set_id}/members
| string | $set_id | Set ID |
| number | $limit | How many to return at most (default 10) |
| number | $offset | Where to start from, for continuation (default 0, the beginning) |
Definition at line 1236 of file grima-lib.php.
References checkForErrorMessage().
| Grima::post | ( | $url, | |
| $URLparams, | |||
| $QSparams, | |||
| $body | |||
| ) |
general function for POST (create) API calls
| string | $url | - URL pattern string with parameters in {} |
| array | $URLparams | - URL parameters |
| array | $QSparams | - query string parameters |
| DomDocument | $body | - object to add to Alma |
Definition at line 249 of file grima-lib.php.
References request().
Referenced by createSetFromImport(), postBib(), postElectronicPortfolio(), postElectronicPortfolioOnBib(), postHolding(), postItem(), postJob(), postSet(), and postSetManageMembers().
| Grima::postBib | ( | $bib | ) |
Create Record - adds a new bib record to Alma.
Makes a call to the API: (API docs)
POST /almaws/v1/bibs https://developers.exlibrisgroup.com/alma/apis/bibs#Resources
| DomDocument | $bib | Bib object to add to Alma as new record |
Definition at line 342 of file grima-lib.php.
References checkForErrorMessage(), and post().
| Grima::postElectronicPortfolio | ( | $collection_id, | |
| $service_id, | |||
| $portfolio | |||
| ) |
Create Electronic Portfolio - add a new portfolio to Alma.
Makes a call to the API: (API docs)
POST /almaws/v1/electronic/e-collections/{collection_id}/e-services/{service_id}/portfolios/
| string | $collection_id | ID of collection |
| string | $service_id | ID of service |
| string | $portfolio | A portfolio object to add to Alma |
Definition at line 768 of file grima-lib.php.
References checkForErrorMessage(), and post().
| Grima::postElectronicPortfolioOnBib | ( | $mms_id, | |
| $portfolio, | |||
$update = true |
|||
| ) |
Create Electronic Portfolio - add a new portfolio to Alma Bib.
Makes a call to the API: (API docs)
POST /almaws/v1/bibs/{mms_id}/portfolios/
| string | $mms_id | ID of bib |
| ElectronicPortfolio | $portfolio | portfolio to add |
| string | $mms_id | ID of bib |
Definition at line 793 of file grima-lib.php.
References checkForErrorMessage(), and post().
| Grima::postHolding | ( | $mms_id, | |
| $holding | |||
| ) |
Create holding record - add a new holdings record to a bib.
Makes a call to the API: (API docs)
POST /almaws/v1/bibs/{mms_id}/holdings
| string | $mms_id | MMS ID of bib record |
| DomDocument | $holding | Holding object to add to Alma as new record |
Definition at line 474 of file grima-lib.php.
References checkForErrorMessage(), and post().
| Grima::postItem | ( | $mms_id, | |
| $holding_id, | |||
| $item | |||
| ) |
Create Item - add a new item to a holding in Alma.
Makes a call to the API: (API docs)
POST /almaws/v1/bibs/{mms_id}/holdings/{holding_id}/items
| string | $mms_id | - MMS ID of Bib record |
| string | $holding_id | - Holding ID of Holding record |
| DomDocument | $item | - Item object to add to Alma as new record |
Definition at line 634 of file grima-lib.php.
References checkForErrorMessage(), and post().
| Grima::postJob | ( | $job_id, | |
| $op, | |||
| $job | |||
| ) |
Submit a manual or scheduled job.
Makes a call to the API: (API docs)
POST /almaws/v1/conf/jobs/{job_id}
| string | $job_id | of job to run |
| op | $op | operation to perform |
| DomDocument | $job | job to run |
Definition at line 1283 of file grima-lib.php.
References checkForErrorMessage(), and post().
| Grima::postSet | ( | $set | ) |
Create a Set - add a new set to Alma.
Makes a call to the API: (API docs)
POST /almaws/v1/conf/sets
Definition at line 1112 of file grima-lib.php.
References checkForErrorMessage(), and post().
| Grima::postSetManageMembers | ( | $set_id, | |
| $id_type, | |||
| $op, | |||
| $set | |||
| ) |
Manage Members - modify sets in Alma.
Makes a call to the API: (API docs)
POST /almaws/v1/conf/sets/{set_id}
| string | $set_id | ID of the set to retrieve |
| string | $id_type | type of identifier used to identify members |
| string | $op | operation to perform on the set |
| DomDocument | $set | to do the operation with |
Definition at line 1138 of file grima-lib.php.
References checkForErrorMessage(), and post().
| Grima::put | ( | $url, | |
| $URLparams, | |||
| $QSparams, | |||
| $body | |||
| ) |
general function for PUT (update) API calls
| string | $url | - URL pattern string with parameters in {} |
| array | $URLparams | - URL parameters |
| array | $QSparams | - query string parameters |
| DomDocument | $body | - record to update Alma record with |
Definition at line 264 of file grima-lib.php.
References request().
Referenced by Set\getMembers(), putBib(), putElectronicCollection(), putElectronicPortfolioOnBib(), putHolding(), and putItem().
| Grima::putBib | ( | $mms_id, | |
| $bib | |||
| ) |
Update Bib Record - updates the copy of the bib in Alma.
Makes a call to the API: (API docs)
PUT /almaws/v1/bibs/{mms_id}
Definition at line 366 of file grima-lib.php.
References checkForErrorMessage(), and put().
| Grima::putElectronicCollection | ( | $collection_id, | |
| $collection | |||
| ) |
Update Electronic Collection Record - updates the copy of the collection in Alma.
Makes a call to the API: (API docs)
PUT /almaws/v1/electronic/e-collections/{collection_id}
| string | $collection_id | Alma ElectronicCollection record to update |
| DomDocument | $collection | ElectronicCollection to replace old record |
Definition at line 935 of file grima-lib.php.
References checkForErrorMessage(), and put().
| Grima::putElectronicPortfolioOnBib | ( | $mms_id, | |
| $portfolio_id, | |||
| $portfolio | |||
| ) |
Update Electronic Portfolio - update portfolio in Alma.
Makes a call to the API: (API docs)
PUT /almaws/v1/bibs/{mms_id}/portfolios/{portfolio_id}
| string | $mms_id | ID of bibliographic record |
| string | $portfolio_id | ID of portfolio |
Definition at line 818 of file grima-lib.php.
References checkForErrorMessage(), and put().
| Grima::putHolding | ( | $mms_id, | |
| $holding_id, | |||
| $holding | |||
| ) |
Update Holdings Record - replace the holdings record in Alma.
Makes a call to the API: (API docs)
PUT /almaws/v1/bibs/{mms_id}/holdings/{holding_id}
| string | $mms_id | MMS ID of Bib |
| string | $holding_id | Holding ID of holding to replace |
| DomDocument | $holding | Holding object to add to Alma as new record |
Definition at line 499 of file grima-lib.php.
References put().
| Grima::putItem | ( | $mms_id, | |
| $holding_id, | |||
| $item_pid, | |||
| $item | |||
| ) |
Update Item information - replace item record in Alma.
Makes a call to the API: (API docs)
PUT /almaws/v1/bibs/{mms_id}/holdings/{holding_id}/items/{item_pid}
| string | $mms_id | MMS ID of Bib record |
| string | $holding_id | Holding ID of Holding record |
| string | $item_pid | Item ID of Item record |
| DomDocument | $item | Item object to update record with in Alma |
Definition at line 660 of file grima-lib.php.
References put().
| Grima::request | ( | $method, | |
| $url, | |||
| $URLparams, | |||
| $QSparams, | |||
$body = null |
|||
| ) |
general function for REST API calls
| string | $method | - GET, POST, PUT, or DELETE |
| string | $url | - URL pattern string with parameters in {} |
| array | $URLparams | - URL parameters |
| array | $QSparams | - query string parameters |
| array | $body | - body content (xml) |
Definition at line 135 of file grima-lib.php.
References arrayToXml().
Referenced by delete(), get(), post(), and put().
| Grima::session_destroy | ( | ) |
Definition at line 65 of file grima-lib.php.
References getenvWithFileFallbackAndDefault(), and session_init().
| Grima::session_init | ( |
$force = false
|
) |
Definition at line 21 of file grima-lib.php.
References getenvWithFileFallbackAndDefault(), and join_paths().
Referenced by __construct(), session_destroy(), and session_save().
| Grima::session_save | ( | $result | ) |
Definition at line 55 of file grima-lib.php.
References $key, getenvWithFileFallbackAndDefault(), and session_init().
| Grima::$apikey |
Definition at line 17 of file grima-lib.php.
Referenced by __construct().
| Grima::$server |
Definition at line 16 of file grima-lib.php.
Referenced by __construct().
1.8.13