Help required to perform get request from AWS API Gateway.

have an Arduino Nano 33 IoT, I'm using the ArduinoHttpClient Library:

My goal is to send a simple get request to an AWS API-Gateway I have built that just has a URL endpoint, im struggling to get the HttpClient setup correctly.
Looking into the library, when setting up the HttpClient it is expecting 3 arguments, wifi, serverAddress & port. I only have 2 and it doesn't seem to be working.

The wifi connection works, and I have validated internet connection via pinging google.com.

#include <ArduinoHttpClient.h>

#include <SPI.h>
#include <WiFiNINA.h>

#include "config.h"

#define WHITEPIN 11
#define BLUEPIN 10

char endpoint[] = "aws URL";

WiFiClient wifi;
HttpClient client = HttpClient(wifi, endpoint);

///////please enter your sensitive data in the Secret tab/arduino_secrets.h
char ssid[] = SECRET_SSID; // your network SSID (name)
char pass[] = SECRET_PASS; // your network password (use for WPA, or use as key for WEP)
int keyIndex = 0; // your network key Index number
int status = WL_IDLE_STATUS; // the Wifi radio's status

void setup() {
// put your setup code here, to run once:
pinMode(WHITEPIN, OUTPUT);
pinMode(BLUEPIN, OUTPUT);

while (!Serial) {

Serial.begin(9600);
; // wait for serial port to connect. Needed for native USB port only
}

// check for the WiFi module:
if (WiFi.status() == WL_NO_MODULE) {
Serial.println("Communication with WiFi module failed!");
digitalWrite(WHITEPIN, HIGH);
digitalWrite(BLUEPIN, HIGH);
// don't continue
while (true);
}

String fv = WiFi.firmwareVersion();
if (fv < "1.0.0") {
Serial.println("Please upgrade the firmware");
}

// attempt to connect to Wifi network:
while (status != WL_CONNECTED) {
Serial.print("Attempting to connect to WEP network, SSID: ");
Serial.println(ssid);
digitalWrite(WHITEPIN, HIGH);
status = WiFi.begin(ssid, keyIndex, pass);

// wait 10 seconds for connection:
delay(10000);
}

// once you are connected :
Serial.println("You're connected to the network");
digitalWrite(WHITEPIN, LOW);
digitalWrite(BLUEPIN, HIGH);
delay(500);
digitalWrite(BLUEPIN, LOW);

}

void loop() {
// put your main code here, to run repeatedly:
Serial.println("making GET request");

client.get(endpoint);
Serial.println("Finished Request");

int statusCode = client.responseStatusCode();
String response = client.responseBody();

Serial.print("Status code: ");
Serial.println(statusCode);
Serial.print("Response: ");
Serial.println(response);
Serial.println("Wait five seconds");

delay(5000);

}

bloom_iot:
Looking into the library, when setting up the HttpClient it is expecting 3 arguments, wifi, serverAddress & port. I only have 2 and it doesn't seem to be working.

Have you tried giving it the third argument?

Im not sure what the third argument would be, the second argument in the example is an IP address, im assuming I can replace that with the url, I have no idea what to put for the third argument

I don't know anything about AWS, but if it's standard HTTP, that'll be port 80.

Tried that, got error -2 which is "Spent too long waiting for a reply", I also can't see it in any of my could watch logs which means its not actually attempting to reach the right endpoint.