Profile properties

Retrieving profile property objects

class ProfilePropertyMixin

This class defines all functions related to BlueConic profile properties.

get_profile_properties(start=0, count=10000000)

Gets all profile properties and returns them in a generator with all BlueConic profile properties.

Parameters:
  • start (int, optional) – The profile property to start from. Defaults to 0.

  • count (int, optional) – The number of profile properties to retrieve. Defaults to 10000000.

Returns:

Iterator with ProfileProperty

Return type:

Iterator[ProfileProperty]

Usage:
>>> import blueconic
>>> bc = blueconic.Client()
>>> for profile_property in bc.get_profile_properties():
>>>     print(profile_property.get_name(), profile_property.get_description())
get_profile_property(profile_property_id)

Gets the profile property with the profile property ID and returns it as a BlueConic profile property.

Parameters:

profile_property_id (str) – The ID of the profile property to retrieve

Raises:

HTTPError: Request fails

Returns:

A profile property

Return type:

ProfileProperty

Usage:
>>> import blueconic
>>> bc = blueconic.Client()
>>> bc.get_profile_property('age')
<client.domain.profileProperty.ProfileProperty>

Using profile property objects

class ProfileProperty
get_description(locale=None)

Gets the description of this profile property.

Parameters:

locale (str, optional) – The locale of the linked description

Returns:

The description of the linked locale

Return type:

str

Usage:
>>> import blueconic
>>> bc = blueconic.Client()
>>> my_property = bc.get_profile_property("frequency")
>>> print(my_property.get_description())
Index for the average amount of visits per day of the visitor from the first visit until today. Value is 100 for the visitors with the highest average in your universe. Value is 0 for visitors with an average of (almost) 0 visits per day from the first visit date.
get_name(locale=None)

Gets the name of this profile property.

Parameters:

locale (str, optional) – The locale of the name

Returns:

The name of the linked locale

Return type:

str

Usage:
>>> import blueconic
>>> bc = blueconic.Client()
>>> my_property = bc.get_profile_property("frequency")
>>> print(my_property.get_name())
Behavioral: Frequency
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 currency

Returns the currency of this profile property; only has a value for profile properties of type CURRENCY.

property description
Returns:

Description of this object.

Return type:

Optional[str]

property group_type

The group_type that is linked to this property.

property id

Returns the ID of this profile property.

property is_unique_identifier

Returns if this profile property is a unique identifier.

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 linking_group_type_id

The id of the group_type that this profile property contains group references for.

property name
Returns:

Name of this object.

Return type:

Optional[str]

property permission_level

Returns the permission level of this profile property.

property precision

Returns the precision of this profile property. Has a value only for profile properties of type DECIMAL and CURRENCY.

property type

Returns the type of this profile property. BlueConic uses the following types:

Type

Description

RANGE

Returns a number (int).

SELECT

Returns a text (str).

DATETIME

Returns a date and time (datetime).

DECIMAL

Returns a float (float); has a value in the precision parameter.

CURRENCY

Returns a float (float); has a value in the precision and currency parameters.

EMAIL

Returns an email address (str).