This plugin counts keys provided in payload.
Project description
Key counter
This plugin counts key strings. Key string provided in configuration will be treated as an information
to increase the value of a key in profile. For example if the key equals to ['a','b','a']
then the
key count equals to {"a":2, "b":1}
.
This plugin can be used for simple statistics e.g. count how many user visited us on mobile device vs other devices like desktop or tablet.
Configuration
{
"key": "desktop",
"save_in": "profile@stats.counters.MobileVisits"
}
key
may be a string or a list of strings. Also, a dot notation can be used to access data.save_in
point to data in profile that will hold the information on key counts. It should be empty object{}
or a key-value object.
Example
{
"key1": 1,
"key2": 33
}
Examples
Example of configuration with dot notation in key
and save_in
{
"key": ["event@session.context.browser.agent", "event@session.context.browser.agent.string"],
"save_in": "profile@stats.counters.visits_origins"
}
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for tracardi-key-counter-0.6.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9ed469e7ae5d0e04787095f4745b66039a39c2c6bae98df06533e5e3cfaaf16e |
|
MD5 | 7e828c1871cff5b7389992bb824d2e40 |
|
BLAKE2b-256 | 2d0a38b2ca30d119e7e2ce8290bedb3e04d0de6d3be581707630bb46b02c1f07 |
Close
Hashes for tracardi_key_counter-0.6.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 756db6bfed7bed7b7fcd82a9ebe5808ff2f6bd90b8f67eb7adb75fe94d77706f |
|
MD5 | b33d1dcf1fef3cdefab86692c94c104e |
|
BLAKE2b-256 | 92365c5d65704ec6ea058dc2f65e431b1d73c7d01cf84022387055f3813d679b |