Vulnerabilities
Push a vulnerability to a tracker
Creates an issue for the vulnerability in your organization’s connected Linear or Jira workspace, the same as Push to Linear or Push to Jira on the vulnerability page, and returns the issue’s key and URL. Requires the admin role; API keys act as admins. Connect the tracker first under Settings → Integrations.
Pushing is idempotent: pushing the same vulnerability to the same tracker again returns the issue the first push created.
Errors use these codes: tracker_not_connected (409) when the tracker isn’t connected, not_found (404) for an ID outside your organization, and tracker_unavailable (502) when the tracker couldn’t be reached. Retry a 502 after checking the connection.
POST
/
vulnerabilities
/
{id}
/
tracker-issue
Push a vulnerability to a tracker
curl --request POST \
--url https://api.antigen.sh/v1/vulnerabilities/{id}/tracker-issue \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"provider": "linear"
}
'import requests
url = "https://api.antigen.sh/v1/vulnerabilities/{id}/tracker-issue"
payload = { "provider": "linear" }
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({provider: 'linear'})
};
fetch('https://api.antigen.sh/v1/vulnerabilities/{id}/tracker-issue', 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.antigen.sh/v1/vulnerabilities/{id}/tracker-issue",
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([
'provider' => 'linear'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$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.antigen.sh/v1/vulnerabilities/{id}/tracker-issue"
payload := strings.NewReader("{\n \"provider\": \"linear\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<api-key>")
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.antigen.sh/v1/vulnerabilities/{id}/tracker-issue")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"provider\": \"linear\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.antigen.sh/v1/vulnerabilities/{id}/tracker-issue")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"provider\": \"linear\"\n}"
response = http.request(request)
puts response.read_body{
"provider": "linear",
"externalKey": "ENG-123",
"url": "https://linear.app/acme/issue/ENG-123"
}{
"error": {
"code": "invalid_request",
"message": "Check the request fields and values."
}
}{
"error": {
"code": "unauthorized",
"message": "Supply a valid API key or session token."
}
}{
"error": {
"code": "forbidden",
"message": "Your role does not permit this operation, or the requested work is outside approved scope."
}
}{
"error": {
"code": "not_found",
"message": "The resource does not exist in this organization."
}
}{
"error": {
"code": "conflict",
"message": "The resource’s current state does not allow this operation."
}
}{
"error": {
"code": "rate_limited",
"message": "Retry after the interval in Retry-After."
}
}{
"error": {
"code": "tracker_unavailable",
"message": "Unable to push to Linear. Check the connection and try again."
}
}Authorizations
ApiKeyAuthSessionAuth
Path Parameters
Body
application/json
Push a vulnerability to a tracker
curl --request POST \
--url https://api.antigen.sh/v1/vulnerabilities/{id}/tracker-issue \
--header 'Content-Type: application/json' \
--header 'x-api-key: <api-key>' \
--data '
{
"provider": "linear"
}
'import requests
url = "https://api.antigen.sh/v1/vulnerabilities/{id}/tracker-issue"
payload = { "provider": "linear" }
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({provider: 'linear'})
};
fetch('https://api.antigen.sh/v1/vulnerabilities/{id}/tracker-issue', 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.antigen.sh/v1/vulnerabilities/{id}/tracker-issue",
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([
'provider' => 'linear'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"x-api-key: <api-key>"
],
]);
$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.antigen.sh/v1/vulnerabilities/{id}/tracker-issue"
payload := strings.NewReader("{\n \"provider\": \"linear\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-api-key", "<api-key>")
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.antigen.sh/v1/vulnerabilities/{id}/tracker-issue")
.header("x-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"provider\": \"linear\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.antigen.sh/v1/vulnerabilities/{id}/tracker-issue")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"provider\": \"linear\"\n}"
response = http.request(request)
puts response.read_body{
"provider": "linear",
"externalKey": "ENG-123",
"url": "https://linear.app/acme/issue/ENG-123"
}{
"error": {
"code": "invalid_request",
"message": "Check the request fields and values."
}
}{
"error": {
"code": "unauthorized",
"message": "Supply a valid API key or session token."
}
}{
"error": {
"code": "forbidden",
"message": "Your role does not permit this operation, or the requested work is outside approved scope."
}
}{
"error": {
"code": "not_found",
"message": "The resource does not exist in this organization."
}
}{
"error": {
"code": "conflict",
"message": "The resource’s current state does not allow this operation."
}
}{
"error": {
"code": "rate_limited",
"message": "Retry after the interval in Retry-After."
}
}{
"error": {
"code": "tracker_unavailable",
"message": "Unable to push to Linear. Check the connection and try again."
}
}