Skip to main content
POST
/
firework
/
v2
/
assets
/
cURL
curl --request POST \
  --url https://api.flare.io/firework/v2/assets/ \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "name": "<string>",
  "type": "domain",
  "search_types": [
    "source_code_secrets"
  ],
  "data": {},
  "experimental_search_types": [
    "<string>"
  ],
  "risks": [
    123
  ]
}
'
import requests

url = "https://api.flare.io/firework/v2/assets/"

payload = {
"name": "<string>",
"type": "domain",
"search_types": ["source_code_secrets"],
"data": {},
"experimental_search_types": ["<string>"],
"risks": [123]
}
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({
name: '<string>',
type: 'domain',
search_types: ['source_code_secrets'],
data: {},
experimental_search_types: ['<string>'],
risks: [123]
})
};

fetch('https://api.flare.io/firework/v2/assets/', 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.flare.io/firework/v2/assets/",
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([
'name' => '<string>',
'type' => 'domain',
'search_types' => [
'source_code_secrets'
],
'data' => [

],
'experimental_search_types' => [
'<string>'
],
'risks' => [
123
]
]),
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.flare.io/firework/v2/assets/"

payload := strings.NewReader("{\n \"name\": \"<string>\",\n \"type\": \"domain\",\n \"search_types\": [\n \"source_code_secrets\"\n ],\n \"data\": {},\n \"experimental_search_types\": [\n \"<string>\"\n ],\n \"risks\": [\n 123\n ]\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.flare.io/firework/v2/assets/")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"name\": \"<string>\",\n \"type\": \"domain\",\n \"search_types\": [\n \"source_code_secrets\"\n ],\n \"data\": {},\n \"experimental_search_types\": [\n \"<string>\"\n ],\n \"risks\": [\n 123\n ]\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.flare.io/firework/v2/assets/")

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 \"name\": \"<string>\",\n \"type\": \"domain\",\n \"search_types\": [\n \"source_code_secrets\"\n ],\n \"data\": {},\n \"experimental_search_types\": [\n \"<string>\"\n ],\n \"risks\": [\n 123\n ]\n}"

response = http.request(request)
puts response.read_body
{
  "asset": {
    "type": "domain",
    "search_types": [
      "source_code_secrets"
    ],
    "name": "<string>",
    "data": {},
    "id": 123,
    "tenant_id": 123,
    "feed_id": 123,
    "experimental_search_types": [
      "<string>"
    ],
    "v3_refs": {
      "asset_uuid": "<string>"
    },
    "risks": [
      123
    ],
    "fetching_progress": 123,
    "count": 123,
    "urn": "<string>",
    "is_disabled": true,
    "source": "USER",
    "data_updated_at": "2023-11-07T05:31:56Z"
  }
}
{
"message": "<string>",
"code": "<string>"
}
DEPRECATED: This endpoint should be replaced by /firework/v4/identifiers/

Authorizations

Authorization
string
header
required

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

Body

application/json
name
string
required
Minimum string length: 1
type
enum<string>
required
Available options:
domain,
name,
keyword,
github_repository,
username,
email,
search_query,
bin,
ip,
secret,
azure_tenant,
identity,
ransomleak,
external_id,
address_data,
birth_year,
role,
phone_number
Example:

"domain"

search_types
enum<string>[]
required
Available options:
source_code_secrets,
financial_data,
forum_profile,
stack_exchange,
service,
domain,
invalid_credential,
bucket,
blog_post,
seller,
valid_credential,
forum_topic,
chat_message,
ad,
bucket_object,
bot,
paste,
mitigated_credential,
stealer_log,
ransomleak,
google,
listing,
leak,
source_code_files,
social_media_account,
forum_post,
docker,
illicit_networks,
open_web,
buckets,
source_code,
leaks,
domains,
forum_content,
blog_content,
profile,
ads,
infected_devices,
social_media
data
object
required
experimental_search_types
string[]
risks
integer[]

Response

Success

asset
object