foliolib.folio.api.notify.PatronNotice
- class foliolib.folio.api.notify.PatronNotice(tenant: str, okapi: Optional[foliolib.okapi.okapiClient.OkapiClient] = None)
Bases:
foliolib.folio.FolioApimod-notify API
This documents the API calls that can be made to post patron notices for users
- Parameters
tenant (str) – Tenant id
okapi (OkapiClient, optional) – Instance of OkapiClient. Defaults to None.
Methods
set_patronNotice(patronNotice, **kwargs)Send patron notice
- set_patronNotice(patronNotice: dict, **kwargs)
Send patron notice
POST /patron-notice- Parameters
patronNotice (dict) –
**kwargs (properties) – Keyword Arguments: See Schema below
- Keyword Arguments
lang (str) – (default=en) Requested language. Optional. [lang=en]
- Raises
OkapiRequestUnprocessableEntity – Unprocessable Entity
OkapiFatalError – Server Error
Schema
{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "description": "Patron Notice", "additionalProperties": false, "properties": { "recipientId": { "description": "The UUID of the receiving user", "type": "string" }, "deliveryChannel": { "description": "delivery channel", "type": "string" }, "templateId": { "description": "The UUID of the notice template", "type": "string" }, "outputFormat": { "description": "Output format e.g email", "type": "string", "default": "text/html" }, "lang": { "description": "Notice language", "type": "string", "default": "en" }, "context": { "type": "object", "description": "Context object" } }, "required": [ "recipientId", "templateId", "deliveryChannel", "outputFormat" ] }