1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

Facebookads API : Check the job status and get the result later in python

Discussion in 'Facebook API' started by rajkoti, Jun 14, 2017.

  1. #1
    submitted the job to in async mode to pull the ad insights data from facebook by using facebookads api.

    r = ad_account.get_insights(params=params, async=True)

    Stored the report_run_id

    I want to check the status of this job in different python code and pull the result in that script instead of same script.

    If it is in the same job, I know how to check the status and get the result.

    while r[AdReportRun.Field.async_percent_completion] < 100:
    result = r.get_result()

    in other words, If I have data (it has report_run_id column). How to check the job status and get the result.
    Planning to move this script to google appengine, google appengine has 60sec time out window. So I need to check the job status later point of time and if the job is success pull the data and load into BigQuery.
    rajkoti, Jun 14, 2017 IP