HTTP GET from web API with Photon

I am trying to use HTTP GET to get the content from the api at this page: jsonparsingdemo-cec5b.firebaseapp.com/jsonData/moviesDemoItem.txt
Here is my code:

#include <HttpClient.h>

unsigned int nextTime = 0;    // Next time to contact the server
HttpClient http;

http_header_t headers[] = {
    { "Accept" , "*/*"},
    { NULL, NULL } // NOTE: Always terminate headers will NULL
};

http_request_t request;
http_response_t response;

void setup() {
    Serial.begin(9600);
}

void loop() {
    if (nextTime > millis()) {
        return;
    }

    Serial.println();
    Serial.println("Application>\tStart of Loop.");
    request.hostname = "jsonparsingdemo-cec5b.firebaseapp.com";
    request.port = 80;
    request.path = "/jsonData/moviesDemoItem.txt";

    http.get(request, response, headers);
    Serial.print("Application>\tResponse status: ");
    Serial.println(response.status);

    Serial.print("Application>\tHTTP Response Body: ");
    Serial.println(response.body);

    nextTime = millis() + 10000;
}

Here is my output:
Application> Start of Loop.
Application> Response status: 301
Application> HTTP Response Body:

I get nothing in the body. Let me know if anyone knows how to get this working. Thank you.

@SlinkyMation The answer is in the response status “301”.

This is explained here:

Ok. Thank you a lot!! but just one question, how do you add username and password authentication? Is there a way to add it in the headers? Thanks.

Refer to "Client side" section from here Basic access authentication - Wikipedia

So, using the example above, you would use:

http_header_t headers = {
{ "Accept" , "/"},
{ "Authorization", "Basic QWxhZGRpbjpPcGVuU2VzYW1l" },
{ NULL, NULL } // NOTE: Always terminate headers will NULL
};

Note that you are using HTTP not HTTPS so others could snoop your token.