Summary
pipefy_automation is managed but not readable. This is the one case in the parity set where the read is already fully implemented and just needs to be shared.
Part of #89.
What the API allows
resource_automation.go:593 uses a singular query, unlike most of the others:
query GetAutomation_tf($id:ID!){ automation(id:$id){ ... } }
So pipefy_automation keyed on id is directly buildable. Whether a pipe exposes an automations list, which would allow a plural form, needs checking first.
Proposed
pipefy_automation, taking id and returning what automationSelection (resource_automation.go:127) reads today: name, active, event_id, action_id, event_repo, action_repo_v2, scheduler_frequency, scheduler_cron, search_for, response_schema, condition.
Two behaviors from the resource have to carry over, or the data source will report things that are not true:
Non-scheduler automations come back with an all-null schedulerCron and an empty searchFor. The resource normalizes those to null rather than surfacing an object full of nulls. The data source needs the same normalization.
action_params is deliberately not in the selection. Do not add it here without checking what the API returns for actions that carry credentials, since a data source has no equivalent of the resource's write-only handling and anything readable lands in plan output.
Notes
automationSelection and automationData are private to resource_automation.go. Unlike the other entities in this milestone there is no automationgql package yet, so this issue includes extracting one, following the pattern pipegql set for the pipe resource and data source.
That extraction is the same shape as #88 and should follow it rather than land separately.
Summary
pipefy_automationis managed but not readable. This is the one case in the parity set where the read is already fully implemented and just needs to be shared.Part of #89.
What the API allows
resource_automation.go:593uses a singular query, unlike most of the others:So
pipefy_automationkeyed onidis directly buildable. Whether a pipe exposes an automations list, which would allow a plural form, needs checking first.Proposed
pipefy_automation, takingidand returning whatautomationSelection(resource_automation.go:127) reads today:name,active,event_id,action_id,event_repo,action_repo_v2,scheduler_frequency,scheduler_cron,search_for,response_schema,condition.Two behaviors from the resource have to carry over, or the data source will report things that are not true:
Non-scheduler automations come back with an all-null
schedulerCronand an emptysearchFor. The resource normalizes those to null rather than surfacing an object full of nulls. The data source needs the same normalization.action_paramsis deliberately not in the selection. Do not add it here without checking what the API returns for actions that carry credentials, since a data source has no equivalent of the resource's write-only handling and anything readable lands in plan output.Notes
automationSelectionandautomationDataare private toresource_automation.go. Unlike the other entities in this milestone there is noautomationgqlpackage yet, so this issue includes extracting one, following the patternpipegqlset for the pipe resource and data source.That extraction is the same shape as #88 and should follow it rather than land separately.