API Docs¶
Flask extension for Invenio-SIP2.
- class invenio_sip2.ext.InvenioSIP2(app=None)[source]¶
Invenio-SIP2 extension.
Extension initialization.
- property sip2_current_date¶
Get current date from system.
- property support_offline_status[source]¶
Support of offline status by the automated circulation system.
- property support_online_status[source]¶
Support of online status by the automated circulation system.
- property support_renewal_policy[source]¶
Support of renewal policy by the automated circulation system.
Actions¶
Invenio-SIP2 custom actions.
- class invenio_sip2.actions.actions.AutomatedCirculationSystemStatus(command, response, **kwargs)[source]¶
Action to get status from automated circulation system.
Init action object.
- class invenio_sip2.actions.actions.BlockPatron(command, response, **kwargs)[source]¶
Action to block patron.
Init action object.
- class invenio_sip2.actions.actions.Checkin(command, response, **kwargs)[source]¶
Action to checkin an item.
Init action object.
- class invenio_sip2.actions.actions.Checkout(command, response, **kwargs)[source]¶
Action to checkout an item.
Init action object.
- class invenio_sip2.actions.actions.EndPatronSession(command, response, **kwargs)[source]¶
Action to end patron session on automated circulation system.
Init action object.
- class invenio_sip2.actions.actions.FeePaid(command, response, **kwargs)[source]¶
Action to paid fee.
Init action object.
- class invenio_sip2.actions.actions.Hold(command, response, **kwargs)[source]¶
Action to hold an item.
Init action object.
- class invenio_sip2.actions.actions.ItemInformation(command, response, **kwargs)[source]¶
Action to get item information from automated circulation system.
Init action object.
- class invenio_sip2.actions.actions.ItemStatusUpdate(command, response, **kwargs)[source]¶
Action to update item status.
Init action object.
- class invenio_sip2.actions.actions.PatronEnable(command, response, **kwargs)[source]¶
Action to enable patron on automated circulation system.
Init action object.
- class invenio_sip2.actions.actions.PatronInformation(command, response, **kwargs)[source]¶
Action to get patron information from automated circulation system.
Init action object.
- class invenio_sip2.actions.actions.PatronStatus(command, response, **kwargs)[source]¶
Action to get patron status from automated circulation system.
Init action object.
- class invenio_sip2.actions.actions.Renew(command, response, **kwargs)[source]¶
Action to renew an item.
Init action object.
- class invenio_sip2.actions.actions.RenewAll(command, response, **kwargs)[source]¶
Action to renew all items.
Init action object.
Records API¶
API for manipulating the client.
- class invenio_sip2.records.record.Client(data, **kwargs)[source]¶
class for selfcheck client.
Initialize instance with dictionary data.
- Parameters
data – Dict with record metadata.
- property get_last_sequence_number¶
Shortcut to user id.
- property institution_id¶
Shortcut to institution id.
- property is_authenticated¶
Shortcut to check if the selfcheck client is authenticated.
- property last_request_message¶
Shortcut to user id.
- property last_response_message¶
Shortcut to user id.
- property library_name¶
Shortcut to library name.
- property remote_app¶
Shortcut for remote app.
- property server_id¶
Get server identifier.
- property terminal¶
Shortcut to terminal.
- property transaction_user_id¶
Shortcut to user id.
- class invenio_sip2.records.record.Server(data, **kwargs)[source]¶
class for SIP2 server.
Initialize instance with dictionary data.
- Parameters
data – Dict with record metadata.
- classmethod create(data, id_=None, **kwargs)[source]¶
Create record.
- Parameters
data – Dict with metadata.
id – Specify a UUID to use for the new record.
- property is_running¶
Check if server is running.
- property number_of_clients¶
Shortcut for number of clients.
- class invenio_sip2.records.record.Sip2RecordMetadata(data, **kwargs)[source]¶
Sip2RecordMetadata class.
Initialize instance with dictionary data.
- Parameters
data – Dict with record metadata.
- classmethod create(data, id_=None, **kwargs)[source]¶
Create record.
- Parameters
data – Dict with metadata.
id – Specify a UUID to use for the new record.
- property id¶
Shortcut for id.
Models¶
Models for Invenio-SIP2.
- class invenio_sip2.models.PatronStatusTypes(value)[source]¶
Enum class to list all possible patron status types.
- CARD_REPORTED_LOST = 'card_reported_lost'¶
- CHARGE_PRIVILEGES_DENIED = 'charge_privileges_denied'¶
- EXCESSIVE_OUTSTANDING_FEES = 'excessive_outstanding_fees'¶
- EXCESSIVE_OUTSTANDING_FINES = 'excessive_outstanding_fines'¶
- HOLD_PRIVILEGES_DENIED = 'hold_privileges_denied'¶
- RECALL_OVERDUE = 'recall_overdue'¶
- RECALL_PRIVILEGES_DENIED = 'recall_privileges_denied'¶
- RENEWAL_PRIVILEGES_DENIED = 'renewal_privileges_denied'¶
- TOO_MANY_CLAIMS_OF_ITEMS_RETURNED = 'too_many_claims_of_items_returned'¶
- TOO_MANY_ITEMS_BILLED = 'too_many_items_billed'¶
- TOO_MANY_ITEMS_CHARGED = 'too_many_items_charged'¶
- TOO_MANY_ITEMS_LOST = 'too_many_items_lost'¶
- TOO_MANY_ITEMS_OVERDUE = 'too_many_items_overdue'¶
- TOO_MANY_RENEWALS = 'too_many_renewals'¶
- class invenio_sip2.models.SelfcheckCheckin(permanent_location, checkin=False, alert=False, magnetic_media=False, resensitize=False, **kwargs)[source]¶
Class representing checkin handler response.
Constructor.
:param permanent_location - permanent_location of the item :param checkin - checkin operation is success or not :param alert - indicate if the selcheck will generate sound alert :param magnetic_media - indicate the presence of magnetic media :param resensitize - resensitize an item ? :param kwargs - optional fields
- property has_magnetic_media¶
Shortcut for desensitize.
- property is_success¶
Shortcut for checkin.
- property resensitize¶
Shortcut for resensitize.
- property sound_alert¶
Shortcut for alert.
- class invenio_sip2.models.SelfcheckCheckout(title_id, checkout=False, renewal=False, magnetic_media=False, desensitize=False, **kwargs)[source]¶
Class representing checkout handler response.
Constructor.
:param title_id - title_id (e.g. title, identifier, …) :param checkout - checkout operation is success or not :param renewal - renewal operation is success or not :param magnetic_media - indicate the presence of magnetic media :param desensitize - desensitize an item ? :param kwargs - optional fields
- property desensitize¶
Shortcut for desensitize.
- property due_date¶
Shortcut for renewal ok.
- property has_magnetic_media¶
Shortcut for desensitize.
- property is_renewal¶
Shortcut for renewal ok.
- property is_success¶
Shortcut for checkout ok.
- class invenio_sip2.models.SelfcheckCirculationStatus[source]¶
Class to handle all available circulation status of an item.
- AVAILABLE = '03'¶
- CHARGED = '04'¶
- CHARGED_RECALL = '05'¶
- CLAIMED_RETURNED = '11'¶
- IN_PROCESS = '06'¶
- IN_TRANSIT = '10'¶
- LOST = '12'¶
- MISSING = '13'¶
- ON_ORDER = '02'¶
- OTHER = '01'¶
- RECALLED = '07'¶
- WAITING_ON_HOLD_SHELF = '08'¶
- WAITING_TO_RESHELF = '09'¶
- class invenio_sip2.models.SelfcheckFeeType[source]¶
Class to handle all available fee type.
- ADMINISTRATIVE = '02'¶
- COMPUTER_ACCESS_CHARGE = '08'¶
- DAMAGE = '03'¶
- HOLD_FEE = '09'¶
- OTHER = '01'¶
- OVERDUE = '04'¶
- PROCESSING = '05'¶
- RENTAL = '06'¶
- REPLACEMENT = '07'¶
- class invenio_sip2.models.SelfcheckHold(hold=False, available=False, **kwargs)[source]¶
Class representing hold handler response.
Constructor.
:param hold - hold operation is success or not :param available - item available or not :param kwargs - optional fields
- property is_available¶
Shortcut for available.
- property is_success¶
Shortcut for hold ok.
- class invenio_sip2.models.SelfcheckItemInformation(item_id, title_id, circulation_status, fee_type, **kwargs)[source]¶
Class representing item information handler response.
Constructor.
:param patron_id - patron identifier (e.g. id, barcode, …) :param patron_name - full name of the patron :param institution_id - institution id (or code) of the patron :param language - iso-639-2 language :param kwargs - optional fields
- class invenio_sip2.models.SelfcheckLanguage(value)[source]¶
Enum class to list all available language.
- ARABIC = '016'¶
- BELGIAN = '026'¶
- CANADIAN_FRENCH = '011'¶
- CHINESE = '019'¶
- DANISH = '009'¶
- DUTCH = '005'¶
- ENGLISH = '001'¶
- FINNISH = '007'¶
- FRENCH = '002'¶
- GERMAN = '003'¶
- GREEK = '018'¶
- HEBREW = '013'¶
- ICELANDIC = '025'¶
- ITALIAN = '004'¶
- JAPANESE = '014'¶
- KOREAN = '020'¶
- MALAY = '023'¶
- NORTH_AMERICAN_SPANISH = '021'¶
- NORWEGIAN = '012'¶
- POLISH = '017'¶
- PORTUGUESE = '010'¶
- RUSSIAN = '015'¶
- SPANISH = '008'¶
- SWEDISH = '006'¶
- TAIWANESE = '027'¶
- TAMIL = '022'¶
- UNITED_KINGDOM = '024'¶
- UNKNOWN = '000'¶
- chi = '019'¶
- dan = '009'¶
- dut = '005'¶
- eng = '001'¶
- fin = '007'¶
- fre = '002'¶
- ger = '003'¶
- gre = '018'¶
- heb = '013'¶
- ice = '025'¶
- isl = '025'¶
- ita = '004'¶
- jpn = '014'¶
- kor = '020'¶
- may = '023'¶
- msa = '023'¶
- nor = '012'¶
- pol = '017'¶
- por = '010'¶
- rus = '015'¶
- spa = '008'¶
- swe = '006'¶
- tam = '022'¶
- und = '000'¶
- zho = '019'¶
- class invenio_sip2.models.SelfcheckMediaType[source]¶
Class to handle all available media type.
- AUDIO = '004'¶
- BOOK = '001'¶
- BOOK_WHIT_AUDIO_TAPE = '010'¶
- BOOK_WHIT_CD = '009'¶
- BOOK_WHIT_DISKETTE = '008'¶
- BOUND_JOURNAL = '003'¶
- CD_OR_CDROM = '006'¶
- DISKETTE = '007'¶
- MAGAZINE = '002'¶
- OTHER = '000'¶
- VIDEO = '005'¶
- class invenio_sip2.models.SelfcheckPatronInformation(patron_id, patron_name, patron_status, institution_id, language, **kwargs)[source]¶
Class representing patron information handler response.
Constructor.
:param patron_id - patron identifier (e.g. id, barcode, …) :param patron_name - full name of the patron :param institution_id - institution id (or code) of the patron :param language - iso-639-2 language :param kwargs - optional fields
- property charged_items_count¶
Shortcut for charged items count.
- property fine_items_count¶
Shortcut for fine items count.
- property hold_items_count¶
Shortcut for hold items count.
- property overdue_items_count¶
Shortcut for overdue items count.
- property patron_id¶
Shortcut for patron pid.
- property recall_items_count¶
Shortcut for recall items count.
Shortcut for unavailable items count.
- class invenio_sip2.models.SelfcheckPatronStatus(patron_status, language, **kwargs)[source]¶
Class representing patron information handler response.
Constructor.
:param patron_id - patron identifier (e.g. id, barcode, …) :param patron_name - full name of the patron :param institution_id - institution id (or code) of the patron :param language - iso-639-2 language :param kwargs - optional fields
- class invenio_sip2.models.SelfcheckRenew(title_id, renew=False, renewal=False, magnetic_media=False, desensitize=False, **kwargs)[source]¶
Class representing renew handler response.
Constructor.
:param title_id - title_id (e.g. title, identifier, …) :param renew - renew operation is success or not :param renewal - renewal operation is success or not :param magnetic_media - indicate the presence of magnetic media :param desensitize - desensitize an item ? :param kwargs - optional fields
- property desensitize¶
Shortcut for desensitize.
- property has_magnetic_media¶
Shortcut for desensitize.
- property is_renewal¶
Shortcut for renewal ok.
- property is_success¶
Shortcut for renew ok.
Rest API¶
API blueprint for Invenio-SIP2.
Views¶
Blueprint for Invenio-SIP2.