Open logason opened 1 month ago
Really appreciate you raising this and giving the extra detail.
I've discussed this quickly with our CDP and Pipeline teams and they agree that this would be a good solution. Maybe we could even build this into PostHog as a feature so that it could be done without an API too! Right now both those teams are focused on other projects though, so we aren't able to jump on this right away -- but it's on our radar and we'll update you here with more info when we can!
Our entire frontend is run off of APIs you can also access with personal api keys, so this is actually already possible, you just need to get the user to give you their personal api key and transformation ID of the plugin Schema enforcer. The request looks like this, you can just form submit the JSON as a binary file.
PATCH https://us.posthog.com/api/projects/[project_id]/plugin_configs/[transformation_id]/
Feature request
Is your feature request related to a problem?
Tracking plans are commonly maintained in internal tools or in products such as Avo.
Being able to automatically push tracking plan schemas from the single-source-of-truth tracking plan into PostHog's Schema Enforcer would allow users to get the full value of Schema Enforcer without having to worry about manually updating the JSON Schemas it uses for validation.
Describe the solution you'd like
An API that accepts a JSON (ideally some form of a JSON Schema) to update the Schema Enforcer would allow users and 3rd party tools to build direct integrations to automate workflows around updating tracking plans/schemas.
Describe alternatives you've considered
Additional context
I'm the co-founder/CTO of Avo, and we already have shared customers asking for a direct publishing integration between Avo's Tracking Plan and the PostHog Schema Enforcer
Debug info