SR003

Severity: error

Summary: schema is empty — must have at least one field

What this means

The schema: section exists but contains no field definitions. Shaperail cannot generate a table, struct, or any endpoints without at least one field. At minimum, every resource needs a primary key field.

Example that triggers this

resource: users
version: 1
schema: {}

How to fix it

Add at least an id field to the schema section:

schema:
  id: { type: uuid, primary: true, generated: true }

Back to top

Shaperail documentation lives in the same repository as the framework so every release has versioned instructions. See the latest release for the most recent version.

This site uses Just the Docs, a documentation theme for Jekyll.