Run function asynchronously from Node.js

Support
  • // Dummy async function to simulate BAS processing
    async function processWithBAS(lead_id,vin, mileage, options,body_type,cylinders,series,transmission,fuel_type,year,make,model,doors,save_app) {
    try{
    console.log("parms",lead_id,vin, mileage, options,body_type,cylinders,series,transmission); // Should log the vin
    var Result = await BAS_FUNCTION(
    "Get_Appraisal",
    {MILEAGE_PARAM: mileage, OPTIONS_PARAM: options,VIN_PARAM: vin,
    Body_Type_PARAM:body_type,Cylinders_PARAM : cylinders,SERIES_PARAM : series,
    Transmission:transmission,lead_ID:lead_id, year: year, make : make,model:model,fuel_type:fuel_type,Doors_PARAM:doors,
    Save_APP_PARAM: save_app })
    console.log(vin,Result);
    }

    catch (error) {
        // Catch and send any errors that occur during processing
        console.log(error.message);
    }
    return Result
    

    }
    I want to run this var Result = await BAS_FUNCTION(
    asynchronously with a separate browser, how can I do it?
    OI tried copy paste it gives weird code with hash

  • I createa server in Node.js and I want to run this function when it is called, and then do the task asynchronously in a seperate thread and browser and then return the result how can I do this ?

  • Send mail function not working

    Support
    0 Votes
    1 Posts
    410 Views
  • 1 Votes
    28 Posts
    6539 Views
  • Compiled App Exit Function

    Support
    0 Votes
    5 Posts
    689 Views
  • Limit the running threads

    Support
    0 Votes
    4 Posts
    893 Views
  • Remove node from project

    Support
    0 Votes
    2 Posts
    497 Views