Hi, is it possible to make several external HTTP requests when calling a worker via RPC? My worker d

Hi, is it possible to make several external HTTP requests when calling a worker via RPC?
My worker doesn't want to wait for a response from my other worker even though everything is in await and I've tried putting Promises everywhere.
I'm making requests in a for loop, the first request is done correctly but doesn't want to wait for the response to this one
// Worker A
// Warning : 'await' has no effect on the type of this expression.
const result = await this.#ctx.env.MAIL_AUTH.mailVerify(mails);


// Worker B
async mailVerify(mails: any): Promise<ReturnMailType> {
  return await new AuthManager(this.env).sendMailVerify(mails);
}

... // Deeper in the code ( in sendMailVerify(mails: any) ) in a for loop
const response = await fetch("https://api.brevo.com/v3/smtp/email", {
  method: "POST",
  headers: {
    "Content-Type": "application/json",
    "api-key": env.BREVO_API_KEY,
  },
  body: JSON.stringify(requestBody),
});

// No response
console.log("Response : ", response);


I'm getting a typescript alert that the “await” is not required when calling my entrypoint when it should be.
The request is correct, I have no errors and it is carried out correctly.
Was this page helpful?