Altitude Units Clarification

I have been using the FlightAware API for C# to get flight information such as altitude and position. For some reason the data about the altitude don’t seem right. For flights that the FlightAware site gives 8,000 feet altitude the output of the InFlightAircraftStruct.altitude is 40. Is the output of the function in different units or is there something wrong with my script.
Thanks.

Altitude from Search and SearchBirdseyeInFlight are returned in 100s of feet (ie: flight levels). Note that those altitudes will also be the most recently received actual altitude for the flight, and not necessarily the filed cruising altitude from the flight plan.