feat: add sync support for purposes, preferences, and consent workflow triggers#519
Open
michaelfarrell76 wants to merge 4 commits intomainfrom
Open
feat: add sync support for purposes, preferences, and consent workflow triggers#519michaelfarrell76 wants to merge 4 commits intomainfrom
michaelfarrell76 wants to merge 4 commits intomainfrom
Conversation
…w triggers Adds full pull/push CLI support for: - Consent Workflow Triggers (new resource): pull, push with name-based matching, resolves action-type/data-subject-type/purposes to IDs - Purposes (previously pull-only): push via createPurpose/updatePurpose mutations, matched by trackingType, with nested preference topic sync - Preference Topics: synced as nested children of purposes via createOrUpdatePreferenceTopic Closes EPD-11849 Co-authored-by: Cursor <cursoragent@cursor.com>
The backend schema doesn't expose consentWorkflowTriggerPurposes as a queryable field on ConsentWorkflowTrigger — it is only available as a mutation input. Purposes can still be pushed but are not pulled. Co-authored-by: Cursor <cursoragent@cursor.com>
- Default triggerCondition to '{}' when not specified (fixes notNull violation)
- Two-step create for new triggers: create first, then attach purposes
- Add ViewDataSubjectRequestSettings and ViewConsentManager to push scopes
- Update example YAML with correct action-type, data-subject-type, and purposes
Co-authored-by: Cursor <cursoragent@cursor.com>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
ConsentWorkflowTriggers). Adds enum, io-ts codec, GraphQL queries/mutations, paginated fetch, pull mapping, and sync function with name-based matching that resolvesaction-type,data-subject-type, and purposetracking-typeto IDs.trackingType, callscreatePurpose/updatePurposemutations, and syncs nested preference topics viacreateOrUpdatePreferenceTopic.pullTranscendConfigurationandsyncConfigurationToTranscend. Scope mappings, YAML field name mappings, and docgen entries added.Linear: https://linear.app/transcend/issue/EPD-11849
File changes
src/enums.tsConsentWorkflowTriggerstoTranscendPullResourcesrc/codecs.tsConsentWorkflowTriggerInputcodec + add toTranscendInputsrc/constants.tssrc/lib/graphql/gqls/consentWorkflowTrigger.tssrc/lib/graphql/gqls/purpose.tsCREATE_PURPOSE,UPDATE_PURPOSEmutationssrc/lib/graphql/gqls/preferenceTopic.tsCREATE_OR_UPDATE_PREFERENCE_TOPICmutationsrc/lib/graphql/fetchAllConsentWorkflowTriggers.tssrc/lib/graphql/syncConsentWorkflowTriggers.tssrc/lib/graphql/syncPurposes.tssrc/lib/graphql/pullTranscendConfiguration.tssrc/lib/graphql/syncConfigurationToTranscend.tssyncPurposes+syncConsentWorkflowTriggerssrc/lib/docgen/createPullResourceScopesTable.tsexamples/consent-workflow-triggers.ymlTest plan
npx tr-pull --resources=consentWorkflowTriggersnpx tr-pushwithconsent-workflow-triggersin confignpx tr-pull --resources=purposes(existing, verify unchanged)npx tr-pushwithpurposesin configMade with Cursor