Version/Environment (if relevant):
This applies to all versions of Domino.
Issue:
You need a way to programmatically download all project files using an automated script.
Resolution:
1. Download the attached Download_project_files.py file at the bottom of this article to a new folder where you want to download all your project files to.
2. In the file, enter these 3 items:
- Line 5: Your API key
- Line 6: Host name of your Domino deployment without the trailing slash (/), e.g. https://deploymentname.domino.tech
- Line 64: Your Project id
3. Save your changes.
4. In a terminal, cd
over to the folder where you want to download all your project files.
5. Run python3 Download_project_files.py
6. Check your folder and confirm that the files match those in your Project Files.
Notes/Information:
Troubleshooting
If you get this error:
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
then install python with xcode-select --install
If you get these errors:
ModuleNotFoundError: No module named 'requests’
ModuleNotFoundError: No module named 'domino’
Then run pip3 install requests dominodatalab
If you get this error: <Response [404]>
Then check your host URL. If there is a trailing slash at the end of the URL, remove it.
How do I find my Project ID?
From your Project page, right-click to pull up Chrome Inspect > switch to the Network tab > refresh the page> click on findProjectByOwnerAndName > copy the value for "id" on the first line.
References/Internal Records:
- PS-9500
Comments
0 comments
Please sign in to leave a comment.