Summary
Campaigns targeting non-English audiences need localized name and description fields. The backend should store translations alongside the default English content and serve the appropriate locale based on the Accept-Language header.
Acceptance Criteria
References
backend/src/schemas.js
backend/src/dal/sqliteCampaignRepository.js
Summary
Campaigns targeting non-English audiences need localized name and description fields. The backend should store translations alongside the default English content and serve the appropriate locale based on the
Accept-Languageheader.Acceptance Criteria
translationsJSON column to campaigns table:{ 'es': { name, description }, 'fr': { name, description } }PUT /api/v1/campaigns/:id/translations/:locale— upsert a translation (API key required); validate locale is BCP-47 format (e.g.es,fr,zh-CN)GET /api/v1/campaigns/:id/translations— return all stored translationsGET /api/v1/campaignsandGET /api/v1/campaigns/:idserve translatedname/descriptionbased onAccept-Languageheader; fallback toenif translation unavailable?locale=esquery param override for explicit locale selectionavailable_localesarray to campaign response listing which locales have translationsReferences
backend/src/schemas.jsbackend/src/dal/sqliteCampaignRepository.js