Skip to content

theopensystemslab/planx-crm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PlanX CRM scripts

This repository contains Python scripts for syncing data from the PlanX to our Notion CRM,


Setup & installation

This project uses uv for package and environment management.

  1. Install uv:

    pip install uv
  2. Create the virtual environment:

    uv venv
  3. Activate the environment:

    • Mac/Linux:
      source .venv/bin/activate
    • Windows:
      .venv\Scripts\activate
  4. Install dependencies:

    uv sync

Linting & formatting

We use Ruff to keep the code clean and consistent. Ruff is ran as a step in our CI.

To format all files:

ruff format .

To check for errors and auto-fix them:

ruff check --fix .

Scripts

sync-planx-services

What it does

Syncs the list of online services per team from the PlanX GraphQL API into the "PlanX Live Services" Notion database.

How it runs

This script is run via a GitHub Action.

  • On a schedule: Runs automatically every night at midnight UTC.
  • Manually: Can be triggered at any time by going to the Actions tab in this repo and running the "Sync PlanX teams to Notion CRM" workflow.

Local development

To run this locally you'll need a populated .env file (see .env.example). Values can be found via the Open Systems Lab 1Password vault.

Once you've activated the virtual environment and installed the necessary dependencies (see above), you can run the following in your terminal -

uv run src/sync-planx-services/main.py

About

Scripts for syncing data to the PlanX CRM in Notion

Resources

License

Stars

Watchers

Forks

Languages