py4cytoscape.collections.get_collection_suid

get_collection_suid(network=None, base_url='http://127.0.0.1:1234/v1')[source]

Get Collection Suid.

Parameters
  • network (SUID or str or None) – Network name or SUID of a network in the collection

  • base_url (str) – Ignore unless you need to specify a custom domain, port or version to connect to the CyREST API. Default is http://localhost:1234 and the latest version of the CyREST API supported by this version of py4cytoscape.

Returns

the SUID of the collection containing the network

Return type

int

Raises
  • CyError – if no collection exists

  • requests.exceptions.RequestException – if can’t connect to Cytoscape or Cytoscape returns an error

Examples

>>> get_collection_suid()
[851280]
>>> get_collection_suid('current')
[851280]
>>> get_collection_suid(851296)
[851280]
>>> get_collection_suid('galFiltered.sif')
[851280]