Experimental Python project using Microsoft Kiota to generate SDK for Autodesk Platform Services API.
- APS application credentials
- Python 3 (tested with version 3.13)
- Docker
- Setup Python virtual env:
python3 -m venv .venv && source .venv/bin/activate - Install Python dependencies:
pip install -r requirements.txt - (Optional) regenerate APS SDK:
./gen_sdk.sh
- Set the following environment variables:
APS_CLIENT_ID- your APS application client IDAPS_CLIENT_SECRET- your APS application client secret
- Run the test script:
python src/test_2_legged_oauth.py
- Set the following environment variables:
APS_ACCESS_TOKEN- your APS access token (3-legged)
- Run the test script:
python src/test_3_legged_oauth.py
There's a bug in Kiota #4600 where in certain cases the auto-generated Python code includes __future__ imports in the wrong place. If you run into this issue, please make sure you are using Kiota 1.27 or later of Kiota.
There's a bug in Kiota #6350 where in certain cases the auto-generated Python code uses [] as default value for a @dataclass field. For now this must be fixed manually by replacing [] with field(default_factory=list). There is a PR #6655 addressing this issue and will be released in Kiota 1.28
The auto-generated code in this project has already been updated to fix this issue.