Job ID in JHooks Sent to Lambda

Hi everyone. We're attempting to do some additional data processing using JHooks, sending those events to a custom Lambda.

We'd like to be able to correlate these events to the Job that triggered them. We can see in the data that gets sent to the lambda, there's a place for "job" and "parentJob" where there would presumably be a job ID. Here's an abridged verison of a PreSavePage event, as received in the Lambda, as an example:

{
    "data": [
        {
            ...
        }
    ],
    "errors": [],
    "retryData": {},
    "configuration": {},
    "pageIndex": 0,
    "pageContext": {
        "type": "shopify",
        "agent": false,
        "_id": "xxx",
        "_flowId": "xxx"
    },
    "files": [],
    "testMode": false,
    "_exportId": "xxx",
    "_connectionId": "xxx",
    "job": {
        "parentJob": {}
    },
    "_flowId": "xxx",
    "settings": {
        ...
    }
}

For clarity, the "job" part of that is unchanged. I didn't abridge that part.

It seems like when we run this in test mode, the Job IDs populate in the event object and interestingly don't show up in the /jobs API call on the Integrator IO API. However, if we disable test mode the inverse is true. The IDs are removed (as above) and we do see the results in the /jobs API.

Can anyone explain why this would be the case? Is there something we can do to change this behavior? Thank you!

The job IDs made for test mode are most likely just dummy samples, which is why you wouldn't find them in your /jobs endpoint. Out of curiosity, do you have any branching in your flow? If not, can you add a dummy branch anywhere in the flow and then see if it shows up during runtime?

Ah, that would definitely explain why we can't find the test mode ones. Any idea why they wouldn't show up when test mode is off?

We don't have any branching. Just a Shopify request, then two HTTP Posts as sequential imports. What would the dummy branch do for us? Not totally clear there.

Branching forces the flow to run on a newer runtime engine where it should be available.