caterva2.subscribe#
- caterva2.subscribe(root, urlbase=None, auth_cookie=None)#
Subscribe to a root.
- Parameters:
- Returns:
The response from the server.
- Return type:
str
Examples
>>> import caterva2 as cat2 >>> urlbase = 'https://demo.caterva2.net' >>> root_name = 'h5numbers_j2k' >>> cat2.subscribe(root_name, urlbase) 'Ok' >>> cat2.get_roots(urlbase)[root_name] {'name': 'h5numbers_j2k', 'http': 'localhost:8011', 'subscribed': True}