Skip to content

feat: update authentication documentation #80

feat: update authentication documentation

feat: update authentication documentation #80

Workflow file for this run

name: Preview Docs
on:
pull_request:
paths:
- 'fern/**'
jobs:
run:
runs-on: ubuntu-latest
permissions: write-all
defaults:
run:
working-directory: ./fern
env:
COMPOSIO_API_KEY: ${{ inputs.api_key || secrets.COMPOSIO_API_KEY_PROD }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v5
- name: Set up Python
run: uv python install
- name: Install Python Dependencies
run: |
uv sync
uv run composio apps generate-types
- name: Generate Python SDK documentation
run: uv run generators/api_doc_generator/generate_api_docs.py -s ../python/composio/ -o sdk/
- name: Setup Bun
uses: oven-sh/setup-bun@v1
with:
bun-version: latest
- name: Install TypeDoc dependencies
run: bun install typedoc typedoc-plugin-markdown
- name: Generate TypeScript SDK documentation
run: bun run typedoc --plugin typedoc-plugin-markdown ../js/src/index.ts ../js/src/sdk/index.ts --out ./sdk/composio/js --skipErrorChecking
- name: Generate Tool Documentation
run: uv run generators/tool_doc_generator/main.py --workers 10
- name: Install Fern
run: npm install -g fern-api
- name: Pull Latest OpenAPI Specification
run: sh scripts/pull-openapi-spec.sh
- name: Generate preview URL
id: generate-docs
env:
FERN_TOKEN: ${{ secrets.FERN_TOKEN }}
run: |
OUTPUT=$(fern generate --docs --preview 2>&1) || true
echo "$OUTPUT"
URL=$(echo "$OUTPUT" | grep -oP 'Published docs to \K.*(?= \()')
echo "Preview URL: $URL"
echo "🌿 Preview your docs: $URL" > preview_url.txt
- name: Comment URL in PR
uses: thollander/[email protected]
with:
filePath: fern/preview_url.txt