This is the SDK to access Devo directly from Python. It can be used to:
- Send events and files to Devo.
- Make queries.
- Manage deferred tasks.
The Devo SDK for Python requires Python 3.5+
- Tested compatibility for python 3.5, 3.6 and 3.7
You can install the Devo SDK by using easy_install
or pip
:
#option 1
easy_install devo-sdk
#option 2
pip install devo-sdk
You can use sources files, clonning the project too:
#option 3
python setup.py install
#option 4
pip install .
#option 5 - dev option
pip install -e .
You has specific documentation in docs folder for each part of SDK:
See PyLibs contributing guide.
Pull and merge requests are welcome ☺
To send data with Devo SDK, first choose the required endpoint depending on the region your are accessing from:
- USA:
- url: us.elb.relay.logtrust.net
- port: 443
- EU:
- url: eu.elb.relay.logtrust.net
- port: 443
- VDC:
- url: es.elb.relay.logtrust.net
- port: 443
You have more information in the official documentation of Devo, Sending data to Devo.
To perform a request with API, first choose the required endpoint depending on the region your are accessing from:
- USA: https://apiv2-us.devo.com/search/query
- EU: https://apiv2-eu.devo.com/search/query
- VDC: https://apiv2-es.devo.com/search/query
You have more information in the official documentation of Devo, REST API .
To obtain the access credentials necessary to use this SDK, you must have an account in DEVO.
Check the security credentials info for more details.
You need use a three files (Cert, key and chain) to secure send data to Devo. Administrator users can find them in Administration → Credentials, in the X.509 tab.
You can use a domain API key and API secret to sign the request. These are are a pair of credentials that every Devo account owns. Administrator users can find them in Administration → Credentials, in the Access Keys tab.
You can run tests from the main folder of SDK To launch this script, you need either the environment variables loaded in the system, or the environment.env file in the root of the SDK with the correct values, since to test all the SDK functionalities it is necessary to connect to Devo for the tests of sending and extracting data. You has a example file called environment.env.example
Its normal, by the way, TCP tests fails in clients or not Devo developers systems.
~/projects/devo-python-sdk > python setup.py test
~/projects/devo-python-sdk > python run_tests.py
You can add option "Coverage" for create HTML report about tests.
~/projects/devo-python-sdk > python run_tests.py --coverage
You can see references in unittest documentation
For commands like:
python -m unittest discover -p "*.py"
If you launch this command from the root directory of the SDK, you need to have the environment variables in your system for all the tests that require connection to Devo can work, not being able to use the environment.env file as in the script.
You can contact with us at support@devo.com.
MIT License
(C) 2020 Devo, Inc.
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the 'Software'), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.