5E2024 Spells - Incorrect components + range information

Open Beginner friendly
#1,503 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
68/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Tech stack
typescript
Domain
api, backend

Research direction

Start by tracing the 2024 spell API response fields for components and range, then compare their data source or mapping with the working 2014 response. Check the listed spells to find whether the malformed range and empty components share one cause. Done means all listed 2024 spells return range and components separately, while the 2014 responses remain correct.

Written by the indexing model from the issue text.

Description

Originally reported by Suchy via Discord; post reproduced below:


When fetching any of the following spells in the 2024 API version:

  • guidance
  • resistance
  • sorcerous-burst
  • divine-smite
  • searing-smite
  • find-steed
  • contagion
  • power-word-heal
  • power-word-kill

The components array is returned empty ([]). Instead, the component information seems to be incorrectly appended to the range property.

Example response (guidance):

{
  "index": "guidance",
  "casting_time": "Action",
  "classes": [
    {
      "index": "cleric",
      "name": "Cleric",
      "url": "/api/2024/classes/cleric"
    },
    {
      "index": "druid",
      "name": "Druid",
      "url": "/api/2024/classes/druid"
    }
  ],
  "components": [],
  "concentration": true,
  "description": "You touch a willing creature and choose a skill. Until the spell ends, the creature adds 1d4 to any ability check using the chosen skill.",
  "duration": "up to 1 minute",
  "level": 0,
  "name": "Guidance",
  "range": "Touch Component: V, S",
  "ritual": false,
  "school": {
    "index": "divination",
    "name": "Divination",
    "url": "/api/2024/magic-schools/divination"
  },
  "updated_at": "2026-09-12T22:42:40.696Z",
  "url": "/api/2024/spells/guidance",
  "subclasses": []
}

As you can see, range contains "Touch Component: V, S" instead of just "Touch", while components is empty.

Expected behavior:

  • range should contain only the spell's range (e.g. "Touch").
  • components should contain the appropriate components (e.g. ["V", "S"]).

This issue appears to affect only the 2024 version of the API. The 2014 version returns the data correctly.

Could someone look into this? Thanks!

Dominant language
TypeScript
Stars
656
Forks
205
Avg merge
14h 21m
Merged PRs (30d)
76

Getting set up

  • No Dockerfile or Docker Compose file
  • Has a pull request template
  • No contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from 5e-bits/5e-srd-api

All issues in 5e-bits/5e-srd-api

Similar issues

More TypeScript issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.