Hearthstone API
VideojuegosMANTENIDA5 tokens / llamada

Hearthstone API

Todas las cartas de Hearthstone de los datos de Blizzard con clase, expansión, coste, rareza, mecánicas y texto, al día

Base de datos de cartas de Hearthstone a partir de los datos de cartas de Blizzard, actualizada dos veces al día: busca cartas por nombre, clase, expansión, tipo, rareza, coste y mecánicas, u obtén una carta por slug con su texto y estadísticas completos.

Cada llamada necesita la cabecera X-Api-Key. Una clave gratuita incluye 500 tokens al mes, sin tarjeta. 5 tokens por llamada, así que el plan gratuito cubre unas 100 llamadas al mes.

Sin tarjeta de créditoAcceso a más de 125 APIsCancela cuando quieras
response.json
{
  "collectible": 1,
  "slug": "a-light-in-the-darkness",
  "artistName": "Zoltan Boros",
  "manaCost": 2,
  "name": "A Light in the Darkness",
  "text": "Discover a minion. Give it +1/+1.",
  "rarity": {
    "slug": "common",
    "craftingCost": [
      40,
      400
    ],
    "dustValue": [
      5,
      50
    ],
    "name": "Common"
  },
  "class": {
    "slug": "paladin",
    "name": "Paladin"
  },
  "type": {
    "slug": "spell",
    "name": "Spell"
  },
  "spellSchool": {
    "slug": "holy",
    "name": "Holy"
  },
  "cardSet": {
    "name": "Whispers of the Old Gods",
    "slug": "whispers-of-the-old-gods",
    "type": "expansion",
    "collectibleCount": 134
  },
  "keywords": [
    {
      "slug": "discover",
      "name": "Discover",
      "text": "Choose one of three cards to add to your hand."
    }
  ],
  "duels": {
    "relevant": true,
    "constructed": true
  },
  "hasImage": true,
  "hasCropImage": true
}

Also available on

Listo para producción
Infraestructura probada en producción con un SLA de disponibilidad del 99,9 %. Límites de uso generosos y respuestas consistentes.
Integración sencilla
REST + JSON estándar. Funciona con cualquier cliente HTTP. Fragmentos de código listos para copiar en 4 lenguajes.
Una clave, más de 125 APIs
Tu suscripción a DataAndAPIs desbloquea todas las APIs de la plataforma: anime, finanzas, deportes y más.

Casos de uso de Hearthstone API

  • Construir un creador de mazos con filtros por clase, coste de maná, rareza y expansión.

  • Mostrar detalles y arte de cartas en un sitio de estrategia, wiki o superposición de stream.

  • Seguir nuevas expansiones y cambios de equilibrio a medida que se añaden o actualizan cartas.

  • Alimentar el autocompletado de búsqueda de cartas en una app complementaria.

Endpoints de Hearthstone API

Todos los endpoints con sus parámetros y una respuesta de ejemplo real.

GETGet Card By Id

https://hearthstone.dataandapis.com/v1/cards/{slug}

Parámetros de ruta

ParámetroEjemplo
sluga-light-in-the-darknessObligatorio

Petición de ejemplo

curl "https://hearthstone.dataandapis.com/v1/cards/a-light-in-the-darkness" \
  -H "X-Api-Key: YOUR_API_KEY"
Respuesta de ejemplo
{
  "collectible": 1,
  "slug": "a-light-in-the-darkness",
  "artistName": "Zoltan Boros",
  "manaCost": 2,
  "name": "A Light in the Darkness",
  "text": "<b>Discover</b> a minion. Give it +1/+1.",
  "flavorText": "Wait, how can you have a light in the dark? If you turn on a light while it’s dark, doesn’t that mean it’s no longer dark?",
  "duels": {
    "relevant": true,
    "constructed": true
  },
  "hasImage": true,
  "hasImageGold": false,
  "hasCropImage": true,
  "keywords": [
    {
      "slug": "discover",
      "name": "Discover",
      "refText": "Choose one of three cards to add to your hand.",
      "text": "Choose one of three cards to add to your hand.",
      "gameModes": []
    }
  ],
  "rarity": {
    "slug": "common",
    "craftingCost": [
      40,
…
Ver la respuesta completa
{
  "collectible": 1,
  "slug": "a-light-in-the-darkness",
  "artistName": "Zoltan Boros",
  "manaCost": 2,
  "name": "A Light in the Darkness",
  "text": "<b>Discover</b> a minion. Give it +1/+1.",
  "flavorText": "Wait, how can you have a light in the dark? If you turn on a light while it’s dark, doesn’t that mean it’s no longer dark?",
  "duels": {
    "relevant": true,
    "constructed": true
  },
  "hasImage": true,
  "hasImageGold": false,
  "hasCropImage": true,
  "keywords": [
    {
      "slug": "discover",
      "name": "Discover",
      "refText": "Choose one of three cards to add to your hand.",
      "text": "Choose one of three cards to add to your hand.",
      "gameModes": []
    }
  ],
  "rarity": {
    "slug": "common",
    "craftingCost": [
      40,
      400
    ],
    "dustValue": [
      5,
      50
    ],
    "name": "Common"
  },
  "class": {
    "slug": "paladin",
    "name": "Paladin"
  },
  "type": {
    "slug": "spell",
    "name": "Spell",
    "gameModes": []
  },
  "cardSet": {
    "name": "Whispers of the Old Gods",
    "slug": "whispers-of-the-old-gods",
    "type": "expansion",
    "collectibleCount": 134,
    "collectibleRevealedCount": 134,
    "nonCollectibleCount": 36,
    "nonCollectibleRevealedCount": 34
  },
  "spellSchool": {
    "slug": "holy",
    "name": "Holy"
  }
}

GETGet Cards

https://hearthstone.dataandapis.com/v1/cards

Parámetros de consulta

ParámetroEjemplo
page1Opcional
pageSize1Opcional

Petición de ejemplo

curl "https://hearthstone.dataandapis.com/v1/cards?page=1&pageSize=1" \
  -H "X-Api-Key: YOUR_API_KEY"
Respuesta de ejemplo
{
  "cards": [
    {
      "collectible": 1,
      "slug": "a-light-in-the-darkness",
      "artistName": "Zoltan Boros",
      "manaCost": 2,
      "name": "A Light in the Darkness",
      "text": "<b>Discover</b> a minion. Give it +1/+1.",
      "flavorText": "Wait, how can you have a light in the dark? If you turn on a light while it’s dark, doesn’t that mean it’s no longer dark?",
      "duels": {
        "relevant": true,
        "constructed": true
      },
      "hasImage": true,
      "hasImageGold": false,
      "hasCropImage": true,
      "keywords": [
        {
          "slug": "discover",
          "name": "Discover",
          "refText": "Choose one of three cards to add to your hand.",
          "text": "Choose one of three cards to add to your hand.",
          "gameModes": [
            {
              "slug": "constructed",
              "name": "Standard & Wild Formats"
            },
…
Ver la respuesta completa
{
  "cards": [
    {
      "collectible": 1,
      "slug": "a-light-in-the-darkness",
      "artistName": "Zoltan Boros",
      "manaCost": 2,
      "name": "A Light in the Darkness",
      "text": "<b>Discover</b> a minion. Give it +1/+1.",
      "flavorText": "Wait, how can you have a light in the dark? If you turn on a light while it’s dark, doesn’t that mean it’s no longer dark?",
      "duels": {
        "relevant": true,
        "constructed": true
      },
      "hasImage": true,
      "hasImageGold": false,
      "hasCropImage": true,
      "keywords": [
        {
          "slug": "discover",
          "name": "Discover",
          "refText": "Choose one of three cards to add to your hand.",
          "text": "Choose one of three cards to add to your hand.",
          "gameModes": [
            {
              "slug": "constructed",
              "name": "Standard & Wild Formats"
            },
            {
              "slug": "battlegrounds",
              "name": "Battlegrounds"
            },
            {
              "slug": "duels",
              "name": "Current Duels Cards"
            },
            {
              "slug": "standard",
              "name": "Standard"
            }
          ]
        }
      ],
      "rarity": {
        "slug": "common",
        "craftingCost": [
          40,
          400
        ],
        "dustValue": [
          5,
          50
        ],
        "name": "Common"
      },
      "class": {
        "slug": "paladin",
        "name": "Paladin"
      },
      "type": {
        "slug": "spell",
        "name": "Spell",
        "gameModes": [
          {
            "slug": "constructed",
            "name": "Standard & Wild Formats"
          },
          {
            "slug": "battlegrounds",
            "name": "Battlegrounds"
          },
          {
            "slug": "duels",
            "name": "Current Duels Cards"
          },
          {
            "slug": "standard",
            "name": "Standard"
          }
        ]
      },
      "cardSet": {
        "name": "Whispers of the Old Gods",
        "slug": "whispers-of-the-old-gods",
        "type": "expansion",
        "collectibleCount": 134,
        "collectibleRevealedCount": 134,
        "nonCollectibleCount": 36,
        "nonCollectibleRevealedCount": 34
      },
      "spellSchool": {
        "slug": "holy",
        "name": "Holy"
      }
    },
    {
      "collectible": 1,
      "slug": "a-new-challenger",
      "artistName": "James Ryman",
      "manaCost": 7,
      "name": "A New Challenger...",
      "text": "<b>Discover</b> a 6-Cost minion. Summon it with <b>Taunt</b> and <b>Divine Shield</b>.",
      "flavorText": "… Arrives? Approaches? TELL US ALREADY!",
      "hasImage": true,
      "hasImageGold": true,
      "hasCropImage": true,
      "keywords": [
        {
          "slug": "taunt",
          "name": "Taunt",
          "refText": "Enemies must attack minions that have Taunt.",
          "text": "Enemies must attack this minion.",
          "gameModes": [
            {
              "slug": "constructed",
              "name": "Standard & Wild Formats"
            },
            {
              "slug": "battlegrounds",
              "name": "Battlegrounds"
            },
            {
              "slug": "duels",
              "name": "Current Duels Cards"
            },
            {
              "slug": "standard",
              "name": "Standard"
            },
            {
              "slug": "mercenaries",
              "name": "Mercenaries"
            }
          ]
        },
        {
          "slug": "divine-shield",
          "name": "Divine Shield",
          "refText": "The first time a Shielded minion takes damage, ignore it.",
          "text": "The first time this minion takes damage, ignore it.",
          "gameModes": [
            {
              "slug": "constructed",
              "name": "Standard & Wild Formats"
            },
            {
              "slug": "battlegrounds",
              "name": "Battlegrounds"
            },
            {
              "slug": "duels",
              "name": "Current Duels Cards"
            },
            {
              "slug": "standard",
              "name": "Standard"
            }
          ]
        },
        {
          "slug": "discover",
          "name": "Discover",
          "refText": "Choose one of three cards to add to your hand.",
          "text": "Choose one of three cards to add to your hand.",
          "gameModes": []
        }
      ],
      "rarity": {
        "slug": "epic",
        "craftingCost": [
          400,
          1600
        ],
        "dustValue": [
          100,
          400
        ],
        "name": "Epic"
      },
      "class": {
        "slug": "paladin",
        "name": "Paladin"
      },
      "type": {
        "slug": "spell",
        "name": "Spell",
        "gameModes": []
      },
      "cardSet": {
        "name": "Rastakhan’s Rumble",
        "slug": "rastakhans-rumble",
        "type": "expansion",
        "collectibleCount": 135,
        "collectibleRevealedCount": 135,
        "nonCollectibleCount": 31,
        "nonCollectibleRevealedCount": 29
      },
      "spellSchool": null
    },
    {
      "collectible": 1,
      "slug": "aberrant-berserker",
      "artistName": "Jim Nelson",
      "health": 5,
      "attack": 3,
      "manaCost": 4,
      "name": "Aberrant Berserker",
      "text": "Has +2 Attack while damaged.",
      "flavorText": "I berserk, therefore I am.",
      "duels": {
        "relevant": true,
        "constructed": true
      },
      "hasImage": true,
      "hasImageGold": false,
      "hasCropImage": true,
      "keywords": [],
      "rarity": {
        "slug": "common",
        "craftingCost": [
          40,
          400
        ],
        "dustValue": [
          5,
          50
        ],
        "name": "Common"
      },
      "class": {
        "slug": "neutral",
        "name": "Neutral"
      },
      "type": {
        "slug": "minion",
        "name": "Minion",
        "gameModes": [
          {
            "slug": "constructed",
            "name": "Standard & Wild Formats"
          },
          {
            "slug": "battlegrounds",
            "name": "Battlegrounds"
          },
          {
            "slug": "duels",
            "name": "Current Duels Cards"
          },
          {
            "slug": "standard",
            "name": "Standard"
          },
          {
            "slug": "mercenaries",
            "name": "Mercenaries"
          }
        ]
      },
      "cardSet": {
        "name": "Whispers of the Old Gods",
        "slug": "whispers-of-the-old-gods",
        "type": "expansion",
        "collectibleCount": 134,
        "collectibleRevealedCount": 134,
        "nonCollectibleCount": 36,
        "nonCollectibleRevealedCount": 34
      },
      "spellSchool": null
    },
    {
      "collectible": 1,
      "slug": "abominable-bowman",
      "artistName": "L. Lullabi & K. Turovec",
      "health": 7,
      "attack": 6,
      "manaCost": 7,
      "name": "Abominable Bowman",
      "text": "<b>Deathrattle:</b> Summon a random friendly Beast that died this game.",
      "flavorText": "Frosty the Bowman... was an angry hateful soul... with a fresh hewn bow and a missing nose...",
      "hasImage": true,
      "hasImageGold": false,
      "hasCropImage": true,
      "keywords": [
        {
          "slug": "deathrattle",
          "name": "Deathrattle",
          "refText": "Does something when it dies.",
          "text": "Does something when it dies.",
          "gameModes": [
            {
              "slug": "constructed",
              "name": "Standard & Wild Formats"
            },
            {
              "slug": "battlegrounds",
              "name": "Battlegrounds"
            },
            {
              "slug": "duels",
              "name": "Current Duels Cards"
            },
            {
              "slug": "standard",
              "name": "Standard"
            },
            {
              "slug": "mercenaries",
              "name": "Mercenaries"
            }
          ]
        }
      ],
      "rarity": {
        "slug": "epic",
        "craftingCost": [
          400,
          1600
        ],
        "dustValue": [
          100,
          400
        ],
        "name": "Epic"
      },
      "class": {
        "slug": "hunter",
        "name": "Hunter"
      },
      "type": {
        "slug": "minion",
        "name": "Minion",
        "gameModes": []
      },
      "cardSet": {
        "name": "Knights of the Frozen Throne",
        "slug": "knights-of-the-frozen-throne",
        "type": "expansion",
        "collectibleCount": 135,
        "collectibleRevealedCount": 135,
        "nonCollectibleCount": 113,
        "nonCollectibleRevealedCount": 51
      },
      "spellSchool": null
    },
    {
      "collectible": 1,
      "slug": "abominable-lieutenant",
      "artistName": "Dave Allsop",
      "health": 5,
      "attack": 3,
      "manaCost": 8,
      "name": "Abominable Lieutenant",
      "text": "At the end of your turn, eat a random enemy minion and gain its stats.",
      "flavorText": "If you can't join 'em, eat 'em.",
      "hasImage": true,
      "hasImageGold": false,
      "hasCropImage": true,
      "keywords": [],
      "rarity": {
        "slug": "epic",
        "craftingCost": [
          400,
          1600
        ],
        "dustValue": [
          100,
          400
        ],
        "name": "Epic"
      },
      "class": {
        "slug": "neutral",
        "name": "Neutral"
      },
      "type": {
        "slug": "minion",
        "name": "Minion",
        "gameModes": []
      },
      "cardSet": {
        "name": "Fractured in Alterac Valley",
        "slug": "fractured-in-alterac-valley",
        "type": "expansion",
        "collectibleCount": 170,
        "collectibleRevealedCount": 170,
        "nonCollectibleCount": 373,
        "nonCollectibleRevealedCount": 70
      },
      "spellSchool": null
    }
  ],
  "cardCount": 4305,
  "pageCount": 861,
  "page": "1"
}

De dónde salen los datos

Fuente
Datos públicos de cartas de Hearthstone de Blizzard, cargados en la base de datos de la API.
Actualización
Actualizado dos veces al día.

Una instalación. Todos los endpoints.

No necesitas SDKs propietarios. Funciona con cualquier cliente HTTP. Elige tu lenguaje y pega el código.

3lenguajes
2endpoints
RESTarquitectura
1clave para todas las APIs
  • Respuestas totalmente tipadas — autocompletado en tu IDE
  • Sigue la API al día — los nuevos endpoints llegan el mismo día
  • Una sola clave funciona en más de 125 APIs de la plataforma
import axios from 'axios';

const { data } = await axios.get(
  'https://hearthstone.dataandapis.com/v1/cards/{slug}',
  { headers: { 'X-Api-Key': process.env.API_KEY } }
);

Hearthstone API · X-Api-Key

Explora los endpoints

Explora los parámetros de solicitud e inspecciona ejemplos de respuesta en vivo.

Endpoints disponibles

Parámetros de la solicitud

URL de la API

Encabezados

X-Api-Key

Parámetros de ruta

slug
import axios from 'axios';

const url = 'https://hearthstone.dataandapis.com/v1/cards/{slug}';
const { data } = await axios.get(url, {
  headers: { 'X-Api-Key': 'YOUR_API_KEY' }
});

Una suscripción. Todas las APIs.

Los tokens desbloquean esta API y más de 20 más en DataAndAPIs. Cambia de API cuando quieras.

GRATIS

$0/mes

500 tokens / mes

  • Acceso a todas las APIs
  • Tokens se renuevan mensualmente
  • Soporte comunitario
Comienza gratis
Más Popular

STARTER

$6.99/mes

25.000 tokens / mes

  • Acceso a todas las APIs
  • Tokens se renuevan mensualmente
  • Soporte por email
Suscribirse

PRO

$24.99/mes

100.000 tokens / mes

  • Acceso a todas las APIs
  • Tokens se renuevan mensualmente
  • Soporte por email prioritario
Suscribirse

ULTRA

$99.99/mes

1.000.000 tokens / mes

  • Acceso a todas las APIs
  • Tokens se renuevan mensualmente
  • Soporte prioritario
Suscribirse

¿Necesitas mayor volumen, infraestructura dedicada o un contrato personalizado? Habla con ventas →

Preguntas sobre Hearthstone API

Lanza Hearthstone API esta tarde.

500 tokens gratis. Sin tarjeta. Y más de 125 APIs más con la misma clave.