v3.18.0 #4
Workflow file for this run
This file contains hidden or 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
| # SDK Release Documentation Pipeline | |
| # | |
| # When a release is published, this workflow: | |
| # 1. Triggers docs validation (claude-docs-validation) on client-workflows | |
| # 2. Notifies sendbird-docs to generate documentation update PRs | |
| # | |
| # Can also be triggered manually via workflow_dispatch for re-runs. | |
| # | |
| # Required secrets: | |
| # DOCS_REPO_TOKEN - GitHub token with repo access to sendbird-docs | |
| # SDK_REPO_TOKEN - GitHub token with repo access to client-workflows | |
| name: Release Docs Pipeline | |
| on: | |
| release: | |
| types: [published] | |
| workflow_dispatch: | |
| inputs: | |
| release_tag: | |
| description: 'Release tag (e.g., v3.17.0)' | |
| required: true | |
| type: string | |
| env: | |
| SDK_TYPE: uikit-react | |
| PLATFORM: react | |
| DOCS_REPO: sendbird/sendbird-docs | |
| jobs: | |
| docs-validation: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Trigger docs validation | |
| uses: actions/github-script@v7 | |
| with: | |
| github-token: ${{ secrets.SDK_REPO_TOKEN }} | |
| script: | | |
| await github.rest.actions.createWorkflowDispatch({ | |
| owner: 'sendbird', | |
| repo: 'client-workflows', | |
| workflow_id: 'claude-docs-validation.yml', | |
| ref: 'main', | |
| inputs: { | |
| sdk_type: '${{ env.SDK_TYPE }}', | |
| platform: '${{ env.PLATFORM }}', | |
| release_tag: '${{ github.event.release.tag_name || inputs.release_tag }}', | |
| source_repo: '${{ github.repository }}' | |
| } | |
| }); | |
| - name: Summary | |
| run: | | |
| echo "## Docs Validation Triggered" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "- **SDK:** ${{ env.SDK_TYPE }}" >> $GITHUB_STEP_SUMMARY | |
| echo "- **Release:** ${{ github.event.release.tag_name || inputs.release_tag }}" >> $GITHUB_STEP_SUMMARY | |
| notify-docs: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Trigger documentation update | |
| env: | |
| GH_TOKEN: ${{ secrets.DOCS_REPO_TOKEN }} | |
| run: | | |
| SDK_REPO="${{ github.repository }}" | |
| RELEASE_TAG="${{ github.event.release.tag_name || inputs.release_tag }}" | |
| RELEASE_URL="${{ github.event.release.html_url }}" | |
| echo "Triggering docs update for:" | |
| echo " SDK Repo: $SDK_REPO" | |
| echo " Release Tag: $RELEASE_TAG" | |
| echo " SDK Type: $SDK_TYPE" | |
| curl -X POST \ | |
| -H "Accept: application/vnd.github+json" \ | |
| -H "Authorization: Bearer $GH_TOKEN" \ | |
| -H "X-GitHub-Api-Version: 2022-11-28" \ | |
| "https://api.github.com/repos/${{ env.DOCS_REPO }}/dispatches" \ | |
| -d "{ | |
| \"event_type\": \"sdk-release\", | |
| \"client_payload\": { | |
| \"sdk_repo\": \"$SDK_REPO\", | |
| \"release_tag\": \"$RELEASE_TAG\", | |
| \"sdk_type\": \"${{ env.SDK_TYPE }}\", | |
| \"release_url\": \"$RELEASE_URL\" | |
| } | |
| }" | |
| echo "Documentation update triggered successfully!" | |
| - name: Summary | |
| run: | | |
| echo "## Documentation Update Triggered" >> $GITHUB_STEP_SUMMARY | |
| echo "" >> $GITHUB_STEP_SUMMARY | |
| echo "- **SDK:** ${{ env.SDK_TYPE }}" >> $GITHUB_STEP_SUMMARY | |
| echo "- **Release:** ${{ github.event.release.tag_name || inputs.release_tag }}" >> $GITHUB_STEP_SUMMARY | |
| echo "- **Docs Repo:** ${{ env.DOCS_REPO }}" >> $GITHUB_STEP_SUMMARY |