Skip to content

feat(nip66): add relay monitor settings schema and defaults#689

Open
Ferryx349 wants to merge 3 commits into
cameri:mainfrom
Ferryx349:nip-66-settings
Open

feat(nip66): add relay monitor settings schema and defaults#689
Ferryx349 wants to merge 3 commits into
cameri:mainfrom
Ferryx349:nip-66-settings

Conversation

@Ferryx349

Copy link
Copy Markdown
Collaborator

Description

Add nip66.* settings (probe interval, timeouts, targets, monitor key, DNS cache TTL) to default-settings.yaml and settings types, config only, no worker yet. Disabled by default.

Related Issue

fixes - #687

Motivation and Context

How Has This Been Tested?

Screenshots (if appropriate):

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.

@changeset-bot

changeset-bot Bot commented Jul 16, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 4c4032d

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
nostream Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@coveralls

coveralls commented Jul 16, 2026

Copy link
Copy Markdown
Collaborator

Coverage Status

Coverage is 67.664%Ferryx349:nip-66-settings into cameri:main. No base build found for cameri:main.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds the foundational configuration surface for a future NIP-66 relay monitor by introducing nip66.* settings defaults, TypeScript settings types, documentation entries, and unit tests to ensure default/override behavior. This aligns with issue #687’s “config only” scope.

Changes:

  • Add nip66 settings block (enabled flag, probe interval, timeouts, targets, monitor identity, DNS cache TTL) to default-settings.yaml.
  • Add Nip66Settings / Nip66ProbeTimeouts to the Settings TypeScript types and a unit test validating defaults + override merge behavior.
  • Document the new settings and introduce an example env var + changeset entry.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
test/unit/utils/settings.spec.ts Adds tests asserting nip66 defaults exist and that user config overrides merge correctly.
src/@types/settings.ts Introduces Nip66Settings / Nip66ProbeTimeouts and wires nip66 into the Settings interface.
resources/default-settings.yaml Adds a new nip66: defaults block (disabled by default).
CONFIGURATION.md Documents the new nip66.* settings (but currently includes duplicated rows and wording that implies implementation exists).
.env.example Adds MONITOR_PRIVATE_KEY to the example environment file.
.changeset/nip66-settings-foundation.md Adds a minor changeset describing the new settings foundation.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread CONFIGURATION.md Outdated
Comment thread CONFIGURATION.md Outdated
Comment thread resources/default-settings.yaml Outdated
Comment thread src/@types/settings.ts
Comment thread src/@types/settings.ts
Comment thread .env.example Outdated
@Ferryx349
Ferryx349 requested a review from cameri July 16, 2026 05:11
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.

3 participants