Access to the tenancies endpoint.
The user is not expected to use this class directly. It is an attribute of the
For example instantiate an Archivist instance and execute the methods of the class:
with open(".auth_token", mode="r", encoding="utf-8") as tokenfile: authtoken = tokenfile.read().strip() # Initialize connection to Archivist arch = Archivist( "https://app.datatrails.ai", authtoken, ) tenancy = arch.tenancies.read(...)
- class archivist.tenancies.Tenant
- class archivist.tenancies._TenanciesClient(archivist_instance: Archivist)
Access to tenants entities using CRUD interface. This class is usually accessed as an attribute of the Archivist class.
archivist (Archivist) --
- _identity(identity) str
Returns identity suitable for endpoint
- publicinfo(identity: str) Tenant
Read Tenant public info
Reads Tenant public info
identity (str) -- tenancies identity e.g. tenancies/xxxxxxxxxxxxxxxxxxxxxxx or tenant/xxxxxxxxxxxxxxxxxxxxxxx
The tenant identity returned by most endpoints has the prefix 'tenant/'. However the tenancies endpoint expects 'tenancies/'. This is a wart in the archivist API and will be fixed at some future date.