foliolib.folio.usersImpl.AddressTypesImpl
- class foliolib.folio.usersImpl.AddressTypesImpl(tenant: str)
Bases:
foliolib.folio.FolioAPIImplImplentations of addressTypes related functions.
- Parameters
tenant (str) – Tenant id
Methods
add_addressType(name, **kwargs)Add a addressType.
delete_addressType(name_or_id)Delete a addressType.
get_addressType(name_or_id)Get addressType by given name, code or id.
get_addressTypes([query])Get list of addressTypes.
modify_addressType(name, **kwargs)Modify a addressType.
- add_addressType(name: str, **kwargs)
Add a addressType.
- Parameters
name (str) – Name of the addressType.
- Keyword Arguments
desc (str) – Description of the addressType.
uuid (str) – Id of the addressType.
- Returns
Object of the addressType.
- Return type
dict
- delete_addressType(name_or_id: str)
Delete a addressType.
- Parameters
name_or_id (str) – addressType name or id.
- get_addressType(name_or_id: str)
Get addressType by given name, code or id.
- Parameters
name_or_id (str) – AddressType name or id.
- Raises
AddressTypeNotFound – AddressType not found
- Returns
AddressType Object.
- Return type
dict
- get_addressTypes(query: str = None)
Get list of addressTypes.
- Parameters
query (str, optional) – CQL string. Default to None, all objects will be returned.
- Returns
List of addresstType Objects.
- Return type
list
- modify_addressType(name: str, **kwargs)
Modify a addressType.
In order to change the name of a addressType, the uuid of the addressType must be given.
- Parameters
name (str) – Name of the addressType.
- Keyword Arguments
desc (str) – Description of the addressType.
uuid (str) – Id of the addressType.
- Returns
Object of the addressType.
- Return type
dict