Auth Token Help

Auth Token Help

I just noticed that my API Key and API ticket are not working, and have seemed to be replaced with Auth Token. Can somone please  tell me how to change the below script from API Key to Auth Token

string Fetch_Reports(int House, int Crop, string Select_Farm)
{
    if (input.Select_Farm  =  "Kennett Farm")
    {
        farm = "1";
    }
    else if (input.Select_Farm  =  "Alpine Farm")
    {
        farm = "2";
    }
    else if (input.Select_Farm  =  "West Grove Farm")
    {
        farm = "93";
    }
    else if (input.Select_Farm  =  "MJ Farm")
    {
        farm = "3";
    }
    ticketDetails = getUrl(("https://accounts.zoho.com/login?servicename=ZohoReports&FROM_AGENT=true&LOGIN_ID=myuser&PASSWORD=mypassword"));
    ticket = (ticketDetails.toString()).subString(((ticketDetails).indexOf("TICKET=")  +  7),((ticketDetails).indexOf("RESULT")  -  1));
    query = "select StartPickDate, StopPickDate, CaseDate, Supplement, SpawnStrain from receiving where HouseID = '" + input.House + "' and GrowerID = '" + farm + "' and CropID = '" + input.Crop + "'";
    url = "http://reports.zoho.com/api/jpiajr/Compost_Chart/receiving?ZOHO_ACTION=EXPORT&ZOHO_OUTPUT_FORMAT=XML&ZOHO_ERROR_FORMAT=XML&ZOHO_API_KEY=e6fb7417b6be1b79f5917bcb24afd91d&ticket=" + ticket + "&ZOHO_API_VERSION=1.0&ZOHO_SQLQUERY=" + query;
    response = getUrl(url);
    result = response.executeXPath("/response/result/rows/row");
    return result;
}