Analytics SDK
Project description
SDK Oficial para Python
Está SDK é utilizada para enviar eventos à API de Analytics da Atados
Instalando
pip install @atados/analytics-sdk
Antes de começar, entenda a função track
track(
/**
* Tipo: String
* Use para categorizar esta acao
* Ex.:
* category = 'Apply',
* category = 'Notification',
*/
category: string,
/**
* Tipo: String
* Use para identificar esta ação dentro da categoria
* Ex.:
* label = 'Cancel Apply',
* label = 'View Notification',
*/
label: string,
/**
* Use para enriquecer esta ação dentro da categoria
* Ex.:
* action = ID de inscricao
* action = { notificationId, notificationKind }
*/
action: any,
/**
* Use este argumento para sobrepor as configurações de userId
* ou meta
*/
user_id?: number,
/**
* Use este argumento para sobrepor as configurações de meta
*/
override_meta?: {}
): Promise<void>
Iniciando
from Analytics from analytics
def report_error(error):
print(error.message)
analytics = Analytics(
api_url=API_URL,
api_token=API_TOKEN,
meta=mock_meta,
on_error=report_error,
meta={ 'channelId': 1 }
)
track_result = analytics.track(
category='Category',
label='Label',
action={ 'data': 1 },
# (Opcional)
user_id=1,
# (Opcional)
sessoin_id=1
)
Utilizando
analytics.track('Category', 'Label', 'Action')
Project details
Release history Release notifications | RSS feed
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 atados-analytics-sdk-0.0.4b1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 25e5e50b4ca68d6b77e5ae9aa9202e7f45679df1a4899c3c9cf9d5efd853e1f0 |
|
MD5 | ea9dc33d09e45a9923a1c236e6e85075 |
|
BLAKE2b-256 | d3e419e8257e98ce2a1beb204816a2ef1a40b72b5b2c4d317b702fb012d7d24b |
Close
Hashes for atados_analytics_sdk-0.0.4b1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 842513d81b2e146b2682451a729bce21912065cc62348a24db9400a33adb4766 |
|
MD5 | 525137daea8660e76247ea3b45ed22a6 |
|
BLAKE2b-256 | 65e5d6eb05b1e9f27024fea2813b4d05e102a48182749cbf84e15a3b0d95dbd8 |