Skip to content

The Postgres development platform. Supabase gives you a dedicated Postgres database to build your web, mobile, and AI applications.

docs: automate js libs docs update (#39036)

Katerina Skroumpelou8d87b66974dc
diff --git a/.github/workflows/docs-js-libs-update.yml b/.github/workflows/docs-js-libs-update.yml
new file mode 100644
index 00000000000..8848405c3ea
--- /dev/null
+++ b/.github/workflows/docs-js-libs-update.yml
@@ -0,0 +1,70 @@
+name: Update JS Client Libraries Docs
+
+on:
+ workflow_dispatch:
+ inputs:
+ version:
+ description: "Version that was released (e.g., patch, minor, major, or v2.1.0)"
+ required: true
+ type: string
+ source:
+ description: "Source of the documentation update"
+ required: false
+ type: string
+ default: "manual"
+
+permissions:
+ pull-requests: write
+ contents: write
+
+jobs:
+ update-docs:
+ runs-on: blacksmith-4vcpu-ubuntu-2404
+
+ steps:
+ - uses: actions/checkout@v4
+ with:
+ ref: master
+ sparse-checkout: |
+ apps/docs
+
+ - uses: pnpm/action-setup@v4
+ name: Install pnpm
+ with:
+ run_install: false
+
+ - name: Use Node.js
+ uses: actions/setup-node@v4
+ with:
+ node-version-file: ".nvmrc"
+ cache: "pnpm"
+
+ - name: Install deps
+ run: pnpm i
+
+ - name: Regenerate JS client libraries tsdoc files
+ working-directory: apps/docs/spec
+ run: |
+ echo "Regenerating tsdoc files for JS client libraries..."
+ echo "Source: ${{ github.event.inputs.source }}"
+ echo "Version: ${{ github.event.inputs.version }}"
+ make
+
+ - name: Create pull request
+ uses: peter-evans/create-pull-request@v6
+ with:
+ token: ${{ secrets.GITHUB_TOKEN }}
+ commit-message: "docs: update js client libraries (${{ github.event.inputs.version }})"
+ title: "docs: update js client libraries (${{ github.event.inputs.version }})"
+ body: |
+ Updates JS client libraries documentation following stable release.
+ Ran `make` in apps/docs/spec to regenerate tsdoc files.
+
+ **Details:**
+ - **Version:** `${{ github.event.inputs.version }}`
+ - **Source:** `${{ github.event.inputs.source }}`
+ - **Changes:** Regenerated tsdoc files from latest spec files
+
+ 🤖 Auto-generated from supabase-js-libs stable release.
+ branch: "gha/update-js-libs-docs-${{ github.run_number }}"
+ base: "master"