Got a response this time!
May 3, 09:00:01 PM: ab9cd85c INFO Received event: {
May 3, 09:00:01 PM: ab9cd85c rawUrl: 'https://main--oceanaffinity-starter.netlify.app/.netlify/functions/automate_build_function',
May 3, 09:00:01 PM: ab9cd85c rawQuery: '',
May 3, 09:00:01 PM: ab9cd85c path: '/.netlify/functions/automate_build_function',
May 3, 09:00:01 PM: ab9cd85c httpMethod: 'POST',
May 3, 09:00:01 PM: ab9cd85c headers: {
May 3, 09:00:01 PM: ab9cd85c 'accept-encoding': 'gzip',
May 3, 09:00:01 PM: ab9cd85c 'content-length': '35',
May 3, 09:00:01 PM: ab9cd85c 'content-type': 'application/json',
May 3, 09:00:01 PM: ab9cd85c host: 'main--oceanaffinity-starter.netlify.app',
May 3, 09:00:01 PM: ab9cd85c 'user-agent': 'Netlify Clockwork',
May 3, 09:00:01 PM: ab9cd85c 'x-country': 'US',
May 3, 09:00:01 PM: ab9cd85c 'x-forwarded-for': '18.190.67.238, 100.64.0.22',
May 3, 09:00:01 PM: ab9cd85c 'x-forwarded-proto': 'https',
May 3, 09:00:01 PM: ab9cd85c 'x-netlify-event': 'schedule',
May 3, 09:00:01 PM: ab9cd85c 'x-nf-client-connection-ip': '18.190.67.238',
May 3, 09:00:01 PM: ab9cd85c 'x-nf-request-id': '01G2699GP7E91VNAYNYYADXY7Y',
May 3, 09:00:01 PM: ab9cd85c 'x-webhook-signature': 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJuZXRsaWZ5Iiwic2hhMjU2IjoiNThmYTNhM2Q2ZTg5NmJmNmFmMmE0NjM0YjY3ZDkzOWJlNTU5YjY0NGJjODMxOGJlNzAyMGE3ZGU5ZDM2MGExYSJ9.7be3eFYqAq45qKOPDy9YuS8VIWxWkh4oxq6lQ4aBSj8'
May 3, 09:00:01 PM: ab9cd85c },
May 3, 09:00:01 PM: ab9cd85c multiValueHeaders: {
May 3, 09:00:01 PM: ab9cd85c 'Accept-Encoding': [ 'gzip' ],
May 3, 09:00:01 PM: ab9cd85c 'Content-Length': [ '35' ],
May 3, 09:00:01 PM: ab9cd85c 'Content-Type': [ 'application/json' ],
May 3, 09:00:01 PM: ab9cd85c 'User-Agent': [ 'Netlify Clockwork' ],
May 3, 09:00:01 PM: ab9cd85c 'X-Country': [ 'US' ],
May 3, 09:00:01 PM: ab9cd85c 'X-Forwarded-For': [ '18.190.67.238, 100.64.0.22' ],
May 3, 09:00:01 PM: ab9cd85c 'X-Forwarded-Proto': [ 'https' ],
May 3, 09:00:01 PM: ab9cd85c 'X-Netlify-Event': [ 'schedule' ],
May 3, 09:00:01 PM: ab9cd85c 'X-Nf-Client-Connection-Ip': [ '18.190.67.238' ],
May 3, 09:00:01 PM: ab9cd85c 'X-Nf-Request-Id': [ '01G2699GP7E91VNAYNYYADXY7Y' ],
May 3, 09:00:01 PM: ab9cd85c 'X-Webhook-Signature': [
May 3, 09:00:01 PM: ab9cd85c 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJuZXRsaWZ5Iiwic2hhMjU2IjoiNThmYTNhM2Q2ZTg5NmJmNmFmMmE0NjM0YjY3ZDkzOWJlNTU5YjY0NGJjODMxOGJlNzAyMGE3ZGU5ZDM2MGExYSJ9.7be3eFYqAq45qKOPDy9YuS8VIWxWkh4oxq6lQ4aBSj8'
May 3, 09:00:01 PM: ab9cd85c ],
May 3, 09:00:01 PM: ab9cd85c host: [ 'main--oceanaffinity-starter.netlify.app' ]
May 3, 09:00:01 PM: ab9cd85c },
May 3, 09:00:01 PM: ab9cd85c queryStringParameters: {},
May 3, 09:00:01 PM: ab9cd85c multiValueQueryStringParameters: {},
May 3, 09:00:01 PM: ab9cd85c body: '{"next_run":"2022-05-04T02:00:00Z"}',
May 3, 09:00:01 PM: ab9cd85c isBase64Encoded: false
May 3, 09:00:01 PM: ab9cd85c }
May 3, 09:00:01 PM: ab9cd85c INFO automated_build_function error: TypeError: Only absolute URLs are supported
May 3, 09:00:01 PM: ab9cd85c at getNodeRequestOptions (/var/task/node_modules/node-fetch/lib/index.js:1327:9)
May 3, 09:00:01 PM: ab9cd85c at /var/task/node_modules/node-fetch/lib/index.js:1440:19
May 3, 09:00:01 PM: ab9cd85c at new Promise (<anonymous>)
May 3, 09:00:01 PM: ab9cd85c at fetch (/var/task/node_modules/node-fetch/lib/index.js:1437:9)
May 3, 09:00:01 PM: ab9cd85c at Runtime.handler (/var/task/netlify/functions/automate_build_function.js:10:30)
May 3, 09:00:01 PM: ab9cd85c at Runtime.handleOnce (/var/runtime/Runtime.js:66:25)
May 3, 09:00:01 PM: ab9cd85c Duration: 16.64 ms Memory Usage: 66 MB Init Duration: 392.10 ms
So, I’ve spent the last little bit trying to understand relative vs absolute urls. My REBUILD_URL is simply the build hook, https://api.netlify.com/build_hooks/xxxx. For some reason, the host is listed as main–oceanaffinity.netlify.app, which is the netlify subdomain for the site. I thought maybe it was because the build hook was originally made for the subdomain (the actual domain was recently purchased), so I deleted the build hook, created a new one linked (linked to ‘main’, the only option), and tried it again. Same thing.
May 3, 10:00:02 PM: 6799a315 INFO Received event: {
rawUrl: 'https://main--oceanaffinity.netlify.app/.netlify/functions/automate_build_function',
rawQuery: '',
path: '/.netlify/functions/automate_build_function',
httpMethod: 'POST',
headers: {
'accept-encoding': 'gzip',
'content-length': '35',
'content-type': 'application/json',
host: 'main--oceanaffinity.netlify.app',
'user-agent': 'Netlify Clockwork',
'x-country': 'US',
'x-forwarded-for': '18.190.67.238, 100.64.0.62',
'x-forwarded-proto': 'https',
'x-netlify-event': 'schedule',
'x-nf-client-connection-ip': '18.190.67.238',
'x-nf-request-id': '01G26CQCPSJ49R4Q6STXW7SREN',
'x-webhook-signature': 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJuZXRsaWZ5Iiwic2hhMjU2IjoiNjAzZjllOTlmODQyZmJkOTZkOTVmNTNhZDExODUyY2JhMzNlYWRjNjRjZjFiYjk0ODJjNTQ4MTI0YzY3ZmQwNyJ9.6AclyvXiD0nZ5btjvNIhcdpgDOA4GDtIZHksmBUYb_0'
},
multiValueHeaders: {
'Accept-Encoding': [ 'gzip' ],
'Content-Length': [ '35' ],
'Content-Type': [ 'application/json' ],
'User-Agent': [ 'Netlify Clockwork' ],
'X-Country': [ 'US' ],
'X-Forwarded-For': [ '18.190.67.238, 100.64.0.62' ],
'X-Forwarded-Proto': [ 'https' ],
'X-Netlify-Event': [ 'schedule' ],
'X-Nf-Client-Connection-Ip': [ '18.190.67.238' ],
'X-Nf-Request-Id': [ '01G26CQCPSJ49R4Q6STXW7SREN' ],
'X-Webhook-Signature': [
'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJuZXRsaWZ5Iiwic2hhMjU2IjoiNjAzZjllOTlmODQyZmJkOTZkOTVmNTNhZDExODUyY2JhMzNlYWRjNjRjZjFiYjk0ODJjNTQ4MTI0YzY3ZmQwNyJ9.6AclyvXiD0nZ5btjvNIhcdpgDOA4GDtIZHksmBUYb_0'
],
host: [ 'main--oceanaffinity.netlify.app' ]
},
queryStringParameters: {},
multiValueQueryStringParameters: {},
body: '{"next_run":"2022-05-04T03:00:00Z"}',
isBase64Encoded: false
}
May 3, 10:00:02 PM: 6799a315 INFO automated_build_function error: TypeError: Only absolute URLs are supported
at getNodeRequestOptions (/var/task/node_modules/node-fetch/lib/index.js:1327:9)
at /var/task/node_modules/node-fetch/lib/index.js:1440:19
at new Promise (<anonymous>)
at fetch (/var/task/node_modules/node-fetch/lib/index.js:1437:9)
at Runtime.handler (/var/task/netlify/functions/automate_build_function.js:13:30)
at Runtime.handleOnce (/var/runtime/Runtime.js:66:25)
May 3, 10:00:02 PM: 6799a315 Duration: 17.89 ms Memory Usage: 66 MB Init Duration: 336.81 ms
Thoughts?