kalima-sdk-discovery.yml workflow
This is a reusable workflow at .github/workflows/kalima-sdk-discovery.yml.
It is workflow_call only, so it does not auto-run in this repository.
Clients call it from their own repo workflows.
What it does
- Scans source files for phrase candidates
- Deduplicates and filters noisy values
- Uploads batches to
POST /phrases/batch-extract - Produces discovery outputs and a JSON report artifact
Outputs
discovered_countuploaded_counterrors_countreport_path
Supported controls
dry-runfail-on-thresholdnew-phrases-thresholdenvironmentmetadata (qaorprod)
Required secrets
KALIMA_PROJECT_KEYKALIMA_API_URL(optional; defaults tohttps://sdk-api.kalima.digital/api/v1)
LOCALE_* fallback secrets are no longer supported.
Example reusable call (copy/paste)
jobs:
discover:
uses: bishoywadie/locale/.github/workflows/kalima-sdk-discovery.yml@main
with:
dry_run: false
environment: prod
secrets:
KALIMA_PROJECT_KEY: ${{ secrets.KALIMA_PROJECT_KEY }}
KALIMA_API_URL: ${{ secrets.KALIMA_API_URL }}
Client trigger example (in client repo)
name: Kalima SDK Discovery
on:
pull_request:
paths:
- 'src/**'
- 'app/**'
- 'pages/**'
- 'components/**'
- 'packages/**'
workflow_dispatch:
inputs:
dry_run:
type: boolean
default: false
jobs:
discover:
uses: bishoywadie/locale/.github/workflows/kalima-sdk-discovery.yml@main
with:
dry_run: ${{ github.event_name == 'workflow_dispatch' && github.event.inputs.dry_run || true }}
environment: prod
secrets:
KALIMA_PROJECT_KEY: ${{ secrets.KALIMA_PROJECT_KEY }}
KALIMA_API_URL: ${{ secrets.KALIMA_API_URL }}
For complete behavior and inputs, see .github/workflows/kalima-sdk-discovery.yml.