pushmess
is a Stata module for sending push notifications using the PushNotifier App and Python package pushnotifier.
pushmess
requires Python with the packages pushnotifier and requests.
You can install the packages from STATA using pip:
!pip install pushnotifier
!pip install requests
pushmess
also requires the free push notification service Pushnotifier, which can be set up as follows:
-
Create a free Pushnotifier account.
-
Create an API token under API settings.
-
Create an API application under API settings by clicking "create application". The name you give to this app will be fed to the "app" option of the pushmess command.
-
Install the Pushnotifier client on your device (Android, iOS) and register your device in the Webbrowser under Devices. The device ID will be fed to the "device" option of the pushmess command.
To push a message to your device, you will need to provide your API token, user ID, password, app name, and device id, e.g.:
pushmess, token("ABDCE") userid("myid") password("password123") device("393K") app("com.myapp.app") message("Stata job done") savepref
Use option savepref
to save your credentials in pushmessconfig.ado so that you don't need to speficy them every time you run the command (use with caution!).
Use option stop
to interrupt dofile (optional).
Use option message("some message")
to customize push notification (optional).
To install from Github, type:
net install pushmess, from("https://raw.githubusercontent.com/jvali1/stata-pushmess/master/") replace
For questions and suggestions, please contact:
Jean-Victor Alipour
LMU Munich & ifo Institute
[email protected]