Create a data feed transformation
Adds a transformation for an event type to a data feed. The event type must belong to the project. Parameters are sent at the top level of the JSON body, not nested.
Optionally send script_content and description to create the first transformation version in the same request; that requires the API token to be associated with a user (same rule as PATCH). Without a script, the feed reports it is not ready until one is added.
If the data feed already has an active transformation for the event type, none is created: a script_content that differs from the current script adds a new version to it, and the response is 200 instead of 201. Requires the read:project and write:project token scopes.
Authorizations
Path Parameters
The project's friendly ID (e.g. prj_aBcD1234eFgH5678).
The data feed's friendly ID (e.g. datafd_aBcD1234eFgH5678).
Body
The friendly ID of an event type in the project (e.g. et_aBcD1234eFgH5678).
"et_aBcD1234eFgH5678"
When set, creates a transformation version with this Python script. Requires the API token to be associated with a user (same as PATCH transformation).
Optional note stored on the new transformation version when script_content is provided, up to 500 characters
Response
The event type already had a transformation; returns the data feed
A data feed. List rows omit each transformation's script_content and each source's config; single-feed responses include them.
The data feed's friendly ID.
"datafd_aBcD1234eFgH5678"
"Daily Production Data"
"Imports daily production metrics"
Row number (1-based) containing column headers. Rows above are ignored during ingestion. 1 until a schema sets another value.
1
Why automatic setup could not build the schema (for example an unreadable sample file), or null.
Why the feed cannot accept data yet, or null when it is ready. A new feed reports "Transformation scripts are still being generated" until its scripts are drafted, and "Schema not defined" until a schema exists.
null
The columns of the current schema. Empty until a schema is defined.
The event types the feed's active transformations create.
Active (unarchived) transformations, one per event type.
Link to the data feed's page in the app.
"https://app.gomangrove.com/nexus/prj_aBcD1234eFgH5678/data-inputs/data-feeds/datafd_aBcD1234eFgH5678"