This is a Python sample, created in form of a CLI tool that helps to automate the process of reading and creating exchanges from ACC.
The code was build in a such way that the included data_exchange
lib can be easily reused in other projects.
- Python: Download Python. It is required to use Python > 3.13.
- APS Account: Learn how to create an APS Account, activate subscription and create an app at this tutorial.
The Data Exchange calls requires 3-legged authenticated token.
To simplify the sample and have only the minimum necessary code focused on Data Exchange, the Authentication code is missing.
To run the sample, it is required to have the 3-legged authenticated token and set the AUTH_TOKEN
var within config.py file.
Within the project folder:
- Create a virtual environment:
python -m venv venv
- Activate the virtual environment:
For Windows:
venv\Scripts\activate.bat
For Linux/MacOS systems:
source venv/bin/activate
- Install dependencies via pip:
pip install -r requirements.txt
- The app can be called by running
python main.py
or you can set an alias:
alias dx-tools="python3 main.py"
and call the app with further commands:
dx-tools gethubs
For the entire list of commands check the documentation for the app.
Click the image below to check the demo video:
- For brevity purpose, the error handling is missing from the code and almost all errors will default to
"ERROR: The Auth token expired"
These samples are licensed under the terms of the MIT License. Please see the LICENSE file for full details.
Denis Grigor ([email protected]), APS Partner Development
See more at Developer Community Blog.