Skip to content

feat: complete NIP-11 relay info parity#557

Open
a-khushal wants to merge 5 commits intocameri:mainfrom
a-khushal:feat/nip11-parity
Open

feat: complete NIP-11 relay info parity#557
a-khushal wants to merge 5 commits intocameri:mainfrom
a-khushal:feat/nip11-parity

Conversation

@a-khushal
Copy link
Copy Markdown
Contributor

this pr improves nip-11 support in nostream. it adds some missing relay info fields, required cors headers, and limitation fields. also updates tests and docs so everything matches what we actually support

Description

this updates the nip-11 relay info to better match the current spec. adds optional fields like banner, icon, self, terms_of_service. adds cors headers. adds limitation fields like created_at_lower_limit, created_at_upper_limit, default_limit, restricted_writes. also uses a shared constant for default limit and updates tests and docs accordingly

Related Issue

#205

Motivation and Context

this just makes nip-11 relay info match the current spec better. adds missing fields, cors headers and limitation fields so clients don’t have to guess how the relay behaves

How Has This Been Tested?

ran tests for the nip-11 changes, mainly unit tests around root request handler fields, headers and limitation mapping. also ran npm run lint and mocha tests for test/unit/handlers/request-handlers/root-request-handler.spec.ts

Screenshots (if appropriate):

image

Types of changes

  • Non-functional change (docs, style, minor refactor)
  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my code changes.
  • I added a changeset, or this is docs-only and I added an empty changeset.
  • All new and existing tests passed.

@coveralls
Copy link
Copy Markdown
Collaborator

coveralls commented Apr 21, 2026

Coverage Status

coverage: 74.695% (+0.2%) from 74.533% — a-khushal:feat/nip11-parity into cameri:main

@a-khushal a-khushal marked this pull request as ready for review April 21, 2026 05:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants