Skip to main content
GET
/
v1
/
risk-score
/
ppa-telematics
/
job
/
{job_id}
/
result
Get Job Result
curl --request GET \
  --url https://api.example.com/v1/risk-score/ppa-telematics/job/{job_id}/result \
  --header 'Authorization: Bearer <token>'
import requests

url = "https://api.example.com/v1/risk-score/ppa-telematics/job/{job_id}/result"

headers = {"Authorization": "Bearer <token>"}

response = requests.get(url, headers=headers)

print(response.text)
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};

fetch('https://api.example.com/v1/risk-score/ppa-telematics/job/{job_id}/result', 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://api.example.com/v1/risk-score/ppa-telematics/job/{job_id}/result",
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://api.example.com/v1/risk-score/ppa-telematics/job/{job_id}/result"

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://api.example.com/v1/risk-score/ppa-telematics/job/{job_id}/result")
.header("Authorization", "Bearer <token>")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.example.com/v1/risk-score/ppa-telematics/job/{job_id}/result")

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
{
  "policy_holder_id": "<string>",
  "vehicle_risk_scores": [
    {
      "vehicle_id": "<string>",
      "vehicle_risk_score": 0.5,
      "version": "v1",
      "metadata": {
        "start": "2023-11-07T05:31:56Z",
        "end": "2023-11-07T05:31:56Z",
        "num_trips": 123,
        "exposure_seconds": 123,
        "state_exposure": [
          {
            "exposure_seconds": 8100,
            "share": 0.5,
            "usstate": "OH"
          },
          {
            "exposure_seconds": 4500,
            "share": 0.25,
            "usstate": "MI"
          },
          {
            "exposure_seconds": 3600,
            "share": 0.25,
            "usstate": "ID"
          }
        ]
      }
    }
  ],
  "job_type": "ppa-telematics-risk-score",
  "version": "v1"
}
{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

job_id
string
required

Response

Successful Response

policy_holder_id
string
required

Unique identifier for the policyholder.

Example:

"policy-holder-123"

vehicle_risk_scores
VehicleRiskScore · object[]
required

Risk scores for each vehicle.

job_type
string
default:ppa-telematics-risk-score

Type of job that was run.

Allowed value: "ppa-telematics-risk-score"
Example:

"ppa-telematics-risk-score"

version
string
default:v1

Version of the risk scoring model used.

Allowed value: "v1"
Example:

"v1"