Transform results in index with missing documents when using the API but works for console

There isn't that kind of notification or eventing (that I know of).

Is the architecture something like one transform writing to an index, then a second transform reading from that index and pushing to another index?

If it is a non-continuous transform (i.e. it does not have sync and frequency in the config), the only way is to poll the stats API and check when the transform moves into STOPPED. If it is a continuous transform, the stats API has a "last checkpoint" timestamp that will get updated when the transform is finished the current iteration. The golang service/process would basically have to busy-wait though while polling for updates.

Alternatively, you could add an ingest pipeline to the destination index of the first tranform, and that ingest pipeline adds the current timestamp when the doc is added to the index. The second transform can use that time field to identify changes and then begin its work.