Saltar al contenido principal
GET
/
api
/
v2
/
logos
/
search
البحث عن الشعارات
curl --request GET \
  --url 'https://api.benzinga.com/api/v2/logos/search?token='
import requests

url = "https://api.benzinga.com/api/v2/logos/search?token="

response = requests.get(url)

print(response.text)
const options = {method: 'GET'};

fetch('https://api.benzinga.com/api/v2/logos/search?token=', 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.benzinga.com/api/v2/logos/search?token=",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
]);

$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.benzinga.com/api/v2/logos/search?token="

	req, _ := http.NewRequest("GET", url, nil)

	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.benzinga.com/api/v2/logos/search?token=")
  .asString();
require 'uri'
require 'net/http'

url = URI("https://api.benzinga.com/api/v2/logos/search?token=")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)

response = http.request(request)
puts response.read_body
{
  "ok": true,
  "data": [
    {
      "id": "efc3943a-ddac-4f59-a2cc-47a67583068b",
      "search_key": "TSLA",
      "created_at": "2022-05-18T05:19:45.008547Z",
      "updated_at": "2025-02-05T09:43:14.303261Z",
      "colors": {
        "background_light": "#FFFFFF",
        "background_dark": "#000000"
      },
      "files": {
        "logo_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/logo_light.png?x-bz-cred=...",
        "logo_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/logo_dark.png?x-bz-cred=...",
        "logo_vector_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/logo_vector_light.svg?x-bz-cred=...",
        "logo_vector_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/logo_vector_dark.svg?x-bz-cred=...",
        "mark_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_light.png?x-bz-cred=...",
        "mark_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_dark.png?x-bz-cred=...",
        "mark_composite_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_composite_light.png?x-bz-cred=...",
        "mark_composite_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_composite_dark.png?x-bz-cred=...",
        "mark_vector_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_vector_light.svg?x-bz-cred=...",
        "mark_vector_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_vector_dark.svg?x-bz-cred=...",
        "mark_vector_composite_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_vector_composite_light.svg?x-bz-cred=...",
        "mark_vector_composite_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_vector_composite_dark.svg?x-bz-cred=..."
      },
      "securities": [
        {
          "symbol": "TSLA",
          "name": "TESLA INC",
          "cik": "1318605",
          "exchange": "NASDAQ",
          "mic_code": "XNAS",
          "exchange_name": "NASDAQ Global Select Consolidated",
          "cusip": "88160R101",
          "isin": "US88160R1014",
          "country": "US",
          "figi_share_class": "BBG001SQKGD7",
          "figi": "BBG000N9MNX3",
          "security_type": "Acción Común"
        },
        {
          "symbol": "TL0",
          "name": "TESLA INC",
          "cik": "1318605",
          "exchange": "MUN",
          "mic_code": "XMUN",
          "exchange_name": "Munich Stock Exchange",
          "cusip": "88160R101",
          "isin": "US88160R1014",
          "country": "DE",
          "figi_share_class": "BBG001SQKGD7",
          "figi": "BBG000WGWVP7",
          "security_type": "Acción Común"
        }
      ]
    }
  ]
}
{
  "ok": false,
  "errors": [
    {
      "code": "bad_request",
      "id": "invalid_parameter",
      "value": "Parámetro search_keys_type no válido"
    }
  ]
}
{
  "ok": false,
  "errors": [
    {
      "code": "auth_failed",
      "id": "unauthorized",
      "value": "Token de autenticación inválido o ausente"
    }
  ]
}
{
  "ok": false,
  "errors": [
    {
      "code": "no_data_found",
      "id": "not_found",
      "value": "No se encontraron logos para la clave de búsqueda especificada"
    }
  ]
}
{
  "ok": false,
  "errors": [
    {
      "code": "internal_server_error",
      "id": "server_error",
      "value": "Ocurrió un error inesperado al procesar tu solicitud"
    }
  ]
}
{
  "ok": true,
  "data": [
    {
      "id": "efc3943a-ddac-4f59-a2cc-47a67583068b",
      "search_key": "TSLA",
      "created_at": "2022-05-18T05:19:45.008547Z",
      "updated_at": "2025-02-05T09:43:14.303261Z",
      "colors": {
        "background_light": "#FFFFFF",
        "background_dark": "#000000"
      },
      "files": {
        "logo_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/logo_light.png?x-bz-cred=...",
        "logo_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/logo_dark.png?x-bz-cred=...",
        "logo_vector_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/logo_vector_light.svg?x-bz-cred=...",
        "logo_vector_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/logo_vector_dark.svg?x-bz-cred=...",
        "mark_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_light.png?x-bz-cred=...",
        "mark_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_dark.png?x-bz-cred=...",
        "mark_composite_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_composite_light.png?x-bz-cred=...",
        "mark_composite_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_composite_dark.png?x-bz-cred=...",
        "mark_vector_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_vector_light.svg?x-bz-cred=...",
        "mark_vector_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_vector_dark.svg?x-bz-cred=...",
        "mark_vector_composite_light": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_vector_composite_light.svg?x-bz-cred=...",
        "mark_vector_composite_dark": "https://image-util.benzinga.com/api/v2/logos/file/image/1318605/mark_vector_composite_dark.svg?x-bz-cred=..."
      },
      "securities": [
        {
          "symbol": "TSLA",
          "name": "TESLA INC",
          "cik": "1318605",
          "exchange": "NASDAQ",
          "mic_code": "XNAS",
          "exchange_name": "NASDAQ Global Select Consolidated",
          "cusip": "88160R101",
          "isin": "US88160R1014",
          "country": "US",
          "figi_share_class": "BBG001SQKGD7",
          "figi": "BBG000N9MNX3",
          "security_type": "Acción Común"
        },
        {
          "symbol": "TL0",
          "name": "TESLA INC",
          "cik": "1318605",
          "exchange": "MUN",
          "mic_code": "XMUN",
          "exchange_name": "Munich Stock Exchange",
          "cusip": "88160R101",
          "isin": "US88160R1014",
          "country": "DE",
          "figi_share_class": "BBG001SQKGD7",
          "figi": "BBG000WGWVP7",
          "security_type": "Acción Común"
        }
      ]
    }
  ]
}
{
  "ok": false,
  "errors": [
    {
      "code": "bad_request",
      "id": "invalid_parameter",
      "value": "Parámetro search_keys_type no válido"
    }
  ]
}
{
  "ok": false,
  "errors": [
    {
      "code": "auth_failed",
      "id": "unauthorized",
      "value": "Token de autenticación inválido o ausente"
    }
  ]
}
{
  "ok": false,
  "errors": [
    {
      "code": "no_data_found",
      "id": "not_found",
      "value": "No se encontraron logos para la clave de búsqueda especificada"
    }
  ]
}
{
  "ok": false,
  "errors": [
    {
      "code": "internal_server_error",
      "id": "server_error",
      "value": "Ocurrió un error inesperado al procesar tu solicitud"
    }
  ]
}

Autorizaciones

token
string
query
requerido

Parámetros de consulta

search_keys
string
requerido

قائمة بمعرّفات أوراق مالية مفصولة بفواصل. الحد الأقصى هو 100 معرّف. يعتمد النوع على معامل search_keys_type.

search_keys_type
string

نوع المعرّف الذي يتم البحث عنه. الأنواع المدعومة: symbol (الافتراضي)، cik، cusip، رقم التعريف الدولي للأوراق المالية ISIN

fields
string
requerido

قائمة مفصولة بفواصل لحقول الشعارات المطلوب إرجاعها. الحد الأقصى 12 حقلًا. المتاح: logo_light, logo_dark, logo_vector_light, logo_vector_dark, mark_light, mark_dark, mark_vector_light, mark_vector_dark, mark_composite_light, mark_composite_dark, mark_vector_composite_light, mark_vector_composite_dark, colors

composite_auto
boolean

إذا كانت القيمة true ولا يوجد شعار، يتم إنشاء صورة تركيبية استنادًا إلى اسم الشركة وألوان علامتها التجارية

composite_radius
integer

نصف قطر حافة الصور المركّبة كنسبة مئوية. النطاق من 0 إلى 50، حيث تُنشئ القيمة 50 دائرة. القيمة الافتراضية: 0

scale
string

قم بضبط أبعاد الصورة بتنسيق WIDTHxHEIGHT (مثلًا: 300x300). يتم تصغير الصور فقط ولا يتم تكبيرها مطلقًا. القيمة الافتراضية: 300x300

max_width
string

الحد الأقصى لعرض الصور بعد تحجيمها بالبكسل

flutter_compatible
boolean

إذا كانت القيمة true، فسيُضاف معامل الاستعلام flutter_compatible=true إلى عناوين URL لملفات SVG لضمان التوافق مع مكتبة flutter_svg

Respuesta

استجابة ناجحة تتضمن مصفوفة من كائنات LogoClientResponse ضمن الحقل data

data
object
errors
object[]
ok
boolean