Get earnings backtesting results
curl --request GET \
--url https://openapi.ainvest.com/open/calendar/earnings/backtesting \
--header 'Authorization: Bearer <token>'import requests
url = "https://openapi.ainvest.com/open/calendar/earnings/backtesting"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://openapi.ainvest.com/open/calendar/earnings/backtesting', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://openapi.ainvest.com/open/calendar/earnings/backtesting",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://openapi.ainvest.com/open/calendar/earnings/backtesting"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://openapi.ainvest.com/open/calendar/earnings/backtesting")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://openapi.ainvest.com/open/calendar/earnings/backtesting")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"headline": "Backtest CMCSA Earning Beats",
"summary": "The backtest shows CMCSA consistently
outperforms following earnings beats, with an 80% win rate
over three days and sustained positive
returns up to 30 days. In contrast, the broader
Media Industry exhibits negligible impact from earnings
beats, suggesting company-specific factors drive
CMCSA's success. Furthermore, Comcast's earnings
beat positively influences the overall market
but negatively affects the Healthcare Services
sector due to shifting consumer spending.
This indicates a sector-specific dynamic where
strong telecom earnings can bolster market
confidence yet divert attention from healthcare.
Investors might benefit from focusing on CMCSA
directly while monitoring sector rotations."
},
"status_code": 0,
"status_msg": "success"
}
Calendar
Earnings backtesting
Get earnings backtesting results
GET
/
calendar
/
earnings
/
backtesting
Get earnings backtesting results
curl --request GET \
--url https://openapi.ainvest.com/open/calendar/earnings/backtesting \
--header 'Authorization: Bearer <token>'import requests
url = "https://openapi.ainvest.com/open/calendar/earnings/backtesting"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://openapi.ainvest.com/open/calendar/earnings/backtesting', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://openapi.ainvest.com/open/calendar/earnings/backtesting",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://openapi.ainvest.com/open/calendar/earnings/backtesting"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://openapi.ainvest.com/open/calendar/earnings/backtesting")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://openapi.ainvest.com/open/calendar/earnings/backtesting")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"data": {
"headline": "Backtest CMCSA Earning Beats",
"summary": "The backtest shows CMCSA consistently
outperforms following earnings beats, with an 80% win rate
over three days and sustained positive
returns up to 30 days. In contrast, the broader
Media Industry exhibits negligible impact from earnings
beats, suggesting company-specific factors drive
CMCSA's success. Furthermore, Comcast's earnings
beat positively influences the overall market
but negatively affects the Healthcare Services
sector due to shifting consumer spending.
This indicates a sector-specific dynamic where
strong telecom earnings can bolster market
confidence yet divert attention from healthcare.
Investors might benefit from focusing on CMCSA
directly while monitoring sector rotations."
},
"status_code": 0,
"status_msg": "success"
}
Earnings reports are anticipated by analysts and traders because they reveal the hard numbers on a company’s wellbeing.
After the report is published, traders expect price movements. To help them make a decision, our Aime the AI
does some backtesting analysis by looking back at all previous earnings reports and tracking the stock price after each report.
With this data in hand, Aime provides some statistics on how the stock price usually performs after actual earnings beat forecasts.
For example, according to Aime’s analysis on July 31 2025,
the stock price of CMCSA (Comcast) grows within the next 3 days in 80% of cases.
In 30 days after the earnings report, the returns tend to stay positive.
{
"data": {
"headline": "Backtest CMCSA Earning Beats",
"summary": "The backtest shows CMCSA consistently
outperforms following earnings beats, with an 80% win rate
over three days and sustained positive
returns up to 30 days. In contrast, the broader
Media Industry exhibits negligible impact from earnings
beats, suggesting company-specific factors drive
CMCSA's success. Furthermore, Comcast's earnings
beat positively influences the overall market
but negatively affects the Healthcare Services
sector due to shifting consumer spending.
This indicates a sector-specific dynamic where
strong telecom earnings can bolster market
confidence yet divert attention from healthcare.
Investors might benefit from focusing on CMCSA
directly while monitoring sector rotations."
},
"status_code": 0,
"status_msg": "success"
}
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your key. Get the key here
Query Parameters
The unique identifier for the earnings event from Earnings API call