curl --request POST \
--url https://api.aisa.one/apis/v1/github/repositories/advisory \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"ghsa_id": "GHSA-jfh8-c2jp-5v3q"
}
'import requests
url = "https://api.aisa.one/apis/v1/github/repositories/advisory"
payload = { "ghsa_id": "GHSA-jfh8-c2jp-5v3q" }
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({ghsa_id: 'GHSA-jfh8-c2jp-5v3q'})
};
fetch('https://api.aisa.one/apis/v1/github/repositories/advisory', 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.aisa.one/apis/v1/github/repositories/advisory",
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([
'ghsa_id' => 'GHSA-jfh8-c2jp-5v3q'
]),
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.aisa.one/apis/v1/github/repositories/advisory"
payload := strings.NewReader("{\n \"ghsa_id\": \"GHSA-jfh8-c2jp-5v3q\"\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.aisa.one/apis/v1/github/repositories/advisory")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"ghsa_id\": \"GHSA-jfh8-c2jp-5v3q\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/github/repositories/advisory")
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 \"ghsa_id\": \"GHSA-jfh8-c2jp-5v3q\"\n}"
response = http.request(request)
puts response.read_bodyAdvisory
One GitHub Advisory Database record by GHSA id, CVE id or github.com/advisories URL: type (reviewed, unreviewed or malware), severity, CVSS v3 and v4, the EPSS exploit probability and percentile, CWE ids with names, every affected package with its vulnerable range, first patched version and vulnerable functions, credits (finder, reporter, remediation developer …), references, the markdown description, and the GitHub review, NVD publication and withdrawal dates. Adds over osv-dev vuln and nvd-nist-gov cve: EPSS, CWE names, credit roles, the advisory type and vulnerable functions in one record. A CVE shared by several GHSA records returns the reviewed one and lists the rest. An unknown id is not_found. CC BY 4.0, attribute GitHub.
curl --request POST \
--url https://api.aisa.one/apis/v1/github/repositories/advisory \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"ghsa_id": "GHSA-jfh8-c2jp-5v3q"
}
'import requests
url = "https://api.aisa.one/apis/v1/github/repositories/advisory"
payload = { "ghsa_id": "GHSA-jfh8-c2jp-5v3q" }
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({ghsa_id: 'GHSA-jfh8-c2jp-5v3q'})
};
fetch('https://api.aisa.one/apis/v1/github/repositories/advisory', 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.aisa.one/apis/v1/github/repositories/advisory",
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([
'ghsa_id' => 'GHSA-jfh8-c2jp-5v3q'
]),
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.aisa.one/apis/v1/github/repositories/advisory"
payload := strings.NewReader("{\n \"ghsa_id\": \"GHSA-jfh8-c2jp-5v3q\"\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.aisa.one/apis/v1/github/repositories/advisory")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"ghsa_id\": \"GHSA-jfh8-c2jp-5v3q\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/github/repositories/advisory")
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 \"ghsa_id\": \"GHSA-jfh8-c2jp-5v3q\"\n}"
response = http.request(request)
puts response.read_bodyRequest contract
- Method and path: POST /apis/v1/github/repositories/advisory
- Availability: enabled
- Request URL template:
https://api.aisa.one/apis/v1/github/repositories/advisory
{
"operationId": "github.repositories.advisory",
"method": "POST",
"path": "/apis/v1/github/repositories/advisory",
"servers": [
{
"url": "https://api.aisa.one"
}
],
"parameters": [],
"security": [
{
"bearerAuth": []
}
],
"requestBody": {
"content": {
"application/json": {
"examples": {
"provider": {
"summary": "Official provider example; checked against AIsa request constraints",
"value": {
"ghsa_id": "GHSA-jfh8-c2jp-5v3q"
}
}
},
"schema": {
"additionalProperties": true,
"allOf": [
{
"anyOf": [
{
"properties": {
"cve_id": {}
},
"required": [
"cve_id"
]
},
{
"properties": {
"ghsa_id": {}
},
"required": [
"ghsa_id"
]
},
{
"properties": {
"url": {}
},
"required": [
"url"
]
}
]
}
],
"properties": {
"cve_id": {
"description": "CVE id, for example CVE-2021-44228. Pattern: ^[Cc][Vv][Ee]-\\d{4}-\\d{4,19}$.",
"type": "string"
},
"ghsa_id": {
"description": "GHSA id, for example GHSA-jfh8-c2jp-5v3q. Pattern: ^[Gg][Hh][Ss][Aa](?:-[23456789cfghjmpqrvwxCFGHJMPQRVWX]{4}){3}$.",
"type": "string"
},
"url": {
"description": "https://github.com/advisories/GHSA-..., the api.github.com/advisories URL, or a repository security advisory URL (looked up in the global database by its GHSA id). Pattern: ^(?:https?://)?(?:www\\.|api\\.)?github\\.com/(?:advisories|[A-Za-z0-9-]{1,39}/[A-Za-z0-9._-]{1,100}/security/advisories)/[Gg][Hh][Ss][Aa](?:-[23456789cfghjmpqrvwxCFGHJMPQRVWX]{4}){3}/?(?:[?#].*)?$.",
"type": "string"
}
},
"type": "object"
}
}
},
"required": true
},
"x-aisa-status": "enabled",
"components": {
"securitySchemes": {
"bearerAuth": {
"scheme": "bearer",
"type": "http"
}
}
}
}
Cost and request rules
Usage-based pricing. Default request estimate: $0.0005 USD. The final charge depends on actual usage. Your account price may differ; use a request quote where supported.Authorizations
Body
- Option 1
- Option 2
- Option 3
https://github.com/advisories/GHSA-..., the api.github.com/advisories URL, or a repository security advisory URL (looked up in the global database by its GHSA id). Pattern: ^(?:https?://)?(?:www.|api.)?github.com/(?:advisories|[A-Za-z0-9-]{1,39}/[A-Za-z0-9._-]{1,100}/security/advisories)/[Gg][Hh][Ss [blocked]]Aa [blocked]{3}/?(?:[?#].*)?$.
Response
One GitHub Advisory Database record by GHSA id, CVE id or github.com/advisories URL: type (reviewed, unreviewed or malware), severity, CVSS v3 and v4, the EPSS exploit probability and percentile, CWE ids with names, every affected package with its vulnerable range, first patched version and vulnerable functions, credits (finder, reporter, remediation developer ...), references, the markdown description, and the GitHub review, NVD publication and withdrawal dates. Adds over osv-dev vuln and nvd-nist-gov cve: EPSS, CWE names, credit roles, the advisory type and vulnerable functions in one record. A CVE shared by several GHSA records returns the reviewed one and lists the rest. An unknown id is not_found. CC BY 4.0, attribute GitHub.
The response contains the tool result directly.
| Documented field | Provider type | Description |
|---|---|---|
advisory | object | |
attribution | string | |
license | string | CC-BY-4.0: attribute the GitHub Advisory Database when re-serving. |
observed_at_ms | number | |
other_ghsa_ids | string[] | Other GHSA records carrying the same CVE (CVE lookups only). |
source_url | string | The github.com page a human would read for the same answer. |
upstream_requests | number |
These are the provider's documented fields. Field requiredness, nullability and nested object structures are specified only where the descriptions explicitly say so.