Skip to content

Downgrade REG-040 unknown fields from warning to info #6

Description

@a6b8

Problem

The RegistrationValidator flags every field not in KNOWN_SPEC_FIELDS as a validation error via REG-040:

REG-040 {fieldName}: Unknown field not defined in ERC-8004 spec

These messages count toward status: false (invalid), causing registrations with extra fields to fail validation entirely.

However, the ERC-8004 spec explicitly permits additional fields. The spec example includes a "...": { "..." } entry indicating MAY include custom fields.

Impact

  • 45,037 REG-040 messages across all datasets
  • Registrations with custom fields (like tags, capabilities, bio, platform, etc.) are incorrectly marked as invalid
  • Only 266 of 37,082 registrations pass validation — largely because of this overly strict check

Most common "unknown" fields found on-chain:

Field Count Notes
registrations 9,072 Actually in spec (separate issue #4)
supportedTrusts 5,135 Likely typo of supportedTrust
version 3,158 Common metadata field
tags 2,683 Agent categorization
updatedAt 2,455 Timestamp
bio 2,156 Short description
registered 2,156 Registration flag
8004Support 1,978 Custom flag
platform 1,708 Platform identifier
skills 1,572 Agent capabilities
domains 996 Agent domains
capabilities 932 Agent capabilities
created 873 Timestamp

Required Changes

In RegistrationValidator.mjs#validateExtraFields():

Option A (recommended): Change REG-040 to an info-level message that does NOT affect status. Introduce a message severity system:

// Info messages don't affect status
messages.push( `REG-040 ${key}: Additional field not defined in ERC-8004 spec (permitted by spec)` )

And filter info messages out of the status calculation.

Option B (simpler): Keep REG-040 but exclude it from status determination. Only REG-0xx errors that indicate actual spec violations should cause status: false.

Also consider

  • Flag supportedTrusts (5,135 occurrences) as likely typo of supportedTrust with a specific message
  • Flag 8004Support (1,978 occurrences) as likely alternative for x402Support

Validation Data

Validated against ~69,000 Dune-downloaded on-chain registration events (Ethereum: 29,664 / Base: 34,520 / Other Chains: 5,000).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions