Update Notion with TMDb Data #6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update Notion with TMDb Data | |
on: | |
push: | |
paths: | |
- 'series_list.txt' # Trigger the workflow when this file is updated | |
workflow_dispatch: # Allow manual triggering | |
jobs: | |
update-notion: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: '3.x' | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install requests notion-client | |
- name: Run script | |
env: | |
TMDB_API_KEY: ${{ secrets.TMDB_API_KEY }} | |
NOTION_API_KEY: ${{ secrets.NOTION_API_KEY }} | |
NOTION_DATABASE_ID: ${{ secrets.NOTION_DATABASE_ID }} | |
run: python script.py |