Stores

Retrieving store objects

A store object can be retrieved from a connection object that contains a store. Use the get_store() function of the BlueConic connection object.

Using store objects

class Store
get_items()

Gets the items in this store.

Returns:

[description]

Return type:

Iterator[StoreItem]

Usage:
>>> from datetime import datetime, timedelta
>>> import blueconic
>>> bc = blueconic.Client()
>>> connection_id = bc.get_blueconic_parameter_value("My connection","connection")
>>> connection = bc.get_connection(connection_id)
>>> store = connection.get_store()
>>> items = store.get_items()
>>> past = (datetime.now() - timedelta(days=90))
>>> for item in items:
>>>     if past < item.get_value('creationDate').replace(tzinfo=None):
>>>         print(item.get_value('category'))
BlueConic
BlueConic
Interactions
Insights
property creation_date
Returns:

The creation date of this object.

Return type:

Optional[datetime]

property creator_username
Returns:

The username that created this object.

Return type:

Optional[str]

property description

Returns description of this store.

property id
Returns:

ID of this object.

Return type:

str

property labels
Returns:

The labels this object.

Return type:

Optional[Sequence[str]

property last_modified_date
Returns:

The last modified date of this object.

Return type:

Optional[datetime]

property last_modified_username
Returns:

The last modified username of this object.

Return type:

Optional[str]

property name
Returns:

Name of this object.

Return type:

Optional[str]

property nr_of_items

Returns the number of items in this store.

property type

Returns the type of this store