Record a Run's Fabric job
curl --request POST \
--url https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"job_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
'import requests
url = "https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission"
payload = { "job_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({job_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a'})
};
fetch('https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission', 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.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'job_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission"
payload := strings.NewReader("{\n \"job_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"job_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"job_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n}"
response = http.request(request)
puts response.read_body{
"alerted_at": "2023-11-07T05:31:56Z",
"charge": "free",
"config": {},
"created_at": "2023-11-07T05:31:56Z",
"error_code": "submission_unknown",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"job_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"pair_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"result": {
"pair_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"results": [
{
"function": "COUNT_ROWS",
"reason_code": "equal",
"status": "passed",
"test_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"compared_count": 4503599627370495,
"mismatch_count": 4503599627370495
}
],
"run_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "passed"
},
"settings": {
"api_connection_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"lakehouse_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"pipeline_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"run_connection_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"spark_job_definition_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"workspace_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"workspace_identity_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"copy_pipeline_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"sample_data": true
},
"status": "prepared",
"updated_at": "2023-11-07T05:31:56Z",
"provenance": "user_reported"
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}Runs
Record a Run's Fabric job
Record the Fabric job that runs the Run, so the app can link it to Fabric Monitor. Repeating the same job ID is safe; a different one returns 409.
Requires the GV.APIContributor application role, or a higher role (Owner > Contributor > Reader).
POST
/
api
/
v1
/
fabric
/
runs
/
{run_id}
/
submission
Record a Run's Fabric job
curl --request POST \
--url https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"job_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
'import requests
url = "https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission"
payload = { "job_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({job_id: '3c90c3cc-0d44-4b50-8888-8dd25736052a'})
};
fetch('https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission', 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.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'job_id' => '3c90c3cc-0d44-4b50-8888-8dd25736052a'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission"
payload := strings.NewReader("{\n \"job_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"job_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.generalvalidation.com/api/v1/fabric/runs/{run_id}/submission")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"job_id\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\"\n}"
response = http.request(request)
puts response.read_body{
"alerted_at": "2023-11-07T05:31:56Z",
"charge": "free",
"config": {},
"created_at": "2023-11-07T05:31:56Z",
"error_code": "submission_unknown",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"job_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"pair_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"result": {
"pair_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"results": [
{
"function": "COUNT_ROWS",
"reason_code": "equal",
"status": "passed",
"test_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"compared_count": 4503599627370495,
"mismatch_count": 4503599627370495
}
],
"run_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"status": "passed"
},
"settings": {
"api_connection_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"lakehouse_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"pipeline_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"run_connection_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"spark_job_definition_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"workspace_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"workspace_identity_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"copy_pipeline_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"sample_data": true
},
"status": "prepared",
"updated_at": "2023-11-07T05:31:56Z",
"provenance": "user_reported"
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}{
"code": "<string>",
"detail": "<string>",
"instance": "<string>",
"requestId": "<string>",
"status": 123,
"title": "<string>",
"type": "<string>",
"diagnostics": {}
}Authorizations
Body
application/json
Response
Successful Response
What the Run was granted when it was prepared: free uses one of the Organization's free Runs, unmetered runs under a plan in effect, and metered is for a plan with Marketplace meters. It is charged only if every Test returns a verdict.
Available options:
free, metered, unmetered Why the Run has no Result. no_report means nothing recorded a Result or failure within 24 hours of preparing the Run; a Result recorded later still replaces it.
Available options:
submission_unknown, submission_rejected, no_report, fabric_job_failed, fabric_job_cancelled, invalid_arguments, invalid_config, run_reservation_failed, artifact_write_failed, summary_too_large, execution_failed