@nostrbox/cli 1.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +77 -0
- package/dist/nip05check.d.ts +3 -0
- package/dist/nip05check.d.ts.map +1 -0
- package/dist/nip05check.js +67 -0
- package/dist/nip05check.js.map +1 -0
- package/dist/nip05lookup.d.ts +3 -0
- package/dist/nip05lookup.d.ts.map +1 -0
- package/dist/nip05lookup.js +74 -0
- package/dist/nip05lookup.js.map +1 -0
- package/package.json +46 -0
package/README.md
ADDED
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
# @nostrbox/cli
|
|
2
|
+
|
|
3
|
+
Simple CLI tools for NIP-05 operations.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
### From npm
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
npm install -g @nostrbox/cli
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
### From source (development)
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
# Clone the repository and navigate to CLI directory
|
|
17
|
+
cd cli
|
|
18
|
+
|
|
19
|
+
# Install dependencies
|
|
20
|
+
npm install
|
|
21
|
+
|
|
22
|
+
# Build the TypeScript files
|
|
23
|
+
npm run build
|
|
24
|
+
|
|
25
|
+
# Install globally from source
|
|
26
|
+
npm install -g .
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
The commands will then be available globally as `nip05lookup` and `nip05check`.
|
|
30
|
+
|
|
31
|
+
## Commands
|
|
32
|
+
|
|
33
|
+
### nip05lookup
|
|
34
|
+
|
|
35
|
+
Look up a single NIP-05 identifier.
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
# Get all information (hex, npub, relays)
|
|
39
|
+
nip05lookup john@domain.com
|
|
40
|
+
|
|
41
|
+
# Get only hex pubkey
|
|
42
|
+
nip05lookup -t hex john@domain.com
|
|
43
|
+
|
|
44
|
+
# Get only npub (bech32)
|
|
45
|
+
nip05lookup -t bech32 john@domain.com
|
|
46
|
+
|
|
47
|
+
# Get only relays
|
|
48
|
+
nip05lookup -t relays john@domain.com
|
|
49
|
+
|
|
50
|
+
# Domain-only lookup (equivalent to _@domain.com)
|
|
51
|
+
nip05lookup domain.com
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
### nip05check
|
|
55
|
+
|
|
56
|
+
Validate an entire domain's NIP-05 setup.
|
|
57
|
+
|
|
58
|
+
```bash
|
|
59
|
+
nip05check domain.com
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
This will check:
|
|
63
|
+
- Does the well-known directory exist?
|
|
64
|
+
- Does the nostr.json file exist?
|
|
65
|
+
- Is the nostr.json file valid?
|
|
66
|
+
- How many entries are there?
|
|
67
|
+
- Are the relays valid and reachable?
|
|
68
|
+
|
|
69
|
+
## Examples
|
|
70
|
+
|
|
71
|
+
```bash
|
|
72
|
+
$ nip05lookup john@domain.com
|
|
73
|
+
|
|
74
|
+
$ nip05lookup -t hex john@domain.com
|
|
75
|
+
|
|
76
|
+
$ nip05check domain.com
|
|
77
|
+
```
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nip05check.d.ts","sourceRoot":"","sources":["../src/nip05check.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
const core_1 = require("@nostrbox/core");
|
|
5
|
+
async function main() {
|
|
6
|
+
const args = process.argv.slice(2);
|
|
7
|
+
if (args.length === 0) {
|
|
8
|
+
console.error('Usage: nip05check <domain>');
|
|
9
|
+
console.error('Example: nip05check nostrdev.com');
|
|
10
|
+
process.exit(1);
|
|
11
|
+
}
|
|
12
|
+
const domain = args[0];
|
|
13
|
+
try {
|
|
14
|
+
const result = await (0, core_1.validateDomain)(domain);
|
|
15
|
+
console.log(`š NIP-05 Domain Validation: ${result.domain}`);
|
|
16
|
+
console.log('='.repeat(50));
|
|
17
|
+
// Main validation results
|
|
18
|
+
const status = result.nostrJsonValid ? 'ā
' : 'ā';
|
|
19
|
+
console.log(`${status} Overall Status: ${result.nostrJsonValid ? 'Valid' : 'Invalid'}`);
|
|
20
|
+
console.log(`š Well-known directory: ${result.wellKnownExists ? 'ā
Exists' : 'ā Missing'}`);
|
|
21
|
+
console.log(`š nostr.json file: ${result.nostrJsonExists ? 'ā
Found' : 'ā Not found'}`);
|
|
22
|
+
console.log(`āļø nostr.json valid: ${result.nostrJsonValid ? 'ā
Valid' : 'ā Invalid'}`);
|
|
23
|
+
console.log(`š„ Entries count: ${result.entriesCount}`);
|
|
24
|
+
if (result.relayValidation) {
|
|
25
|
+
console.log(`\nš Relay Validation:`);
|
|
26
|
+
console.log(` Total relays: ${result.relayValidation.totalRelays}`);
|
|
27
|
+
console.log(` Unique relays: ${result.relayValidation.uniqueRelays}`);
|
|
28
|
+
console.log(` Valid relays: ${result.relayValidation.validRelays}`);
|
|
29
|
+
console.log(` Invalid relays: ${result.relayValidation.invalidRelays}`);
|
|
30
|
+
if (result.relayValidation.relayDetails && result.relayValidation.relayDetails.length > 0) {
|
|
31
|
+
console.log(`\nš Relay Details:`);
|
|
32
|
+
for (const relay of result.relayValidation.relayDetails) {
|
|
33
|
+
const status = relay.isValid ? 'ā
' : 'ā';
|
|
34
|
+
const timeInfo = relay.responseTime ? `[${relay.responseTime}ms]` : '';
|
|
35
|
+
const errorInfo = relay.error ? `(${relay.error})` : '';
|
|
36
|
+
console.log(` ${status} ${relay.url} ${errorInfo} ${timeInfo}`);
|
|
37
|
+
}
|
|
38
|
+
}
|
|
39
|
+
}
|
|
40
|
+
if (result.errors.length > 0) {
|
|
41
|
+
console.log(`\nā Errors:`);
|
|
42
|
+
for (const error of result.errors) {
|
|
43
|
+
console.log(` ⢠${error}`);
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
if (result.warnings.length > 0) {
|
|
47
|
+
console.log(`\nā ļø Warnings:`);
|
|
48
|
+
for (const warning of result.warnings) {
|
|
49
|
+
console.log(` ⢠${warning}`);
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
console.log(`\nā° Checked at: ${result.timestamp.toLocaleString()}`);
|
|
53
|
+
// Exit with error code if validation failed
|
|
54
|
+
if (!result.nostrJsonValid) {
|
|
55
|
+
process.exit(1);
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
catch (error) {
|
|
59
|
+
console.error(`Error: ${error instanceof Error ? error.message : 'Unknown error'}`);
|
|
60
|
+
process.exit(1);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
main().catch(error => {
|
|
64
|
+
console.error(`Fatal error: ${error instanceof Error ? error.message : 'Unknown error'}`);
|
|
65
|
+
process.exit(1);
|
|
66
|
+
});
|
|
67
|
+
//# sourceMappingURL=nip05check.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nip05check.js","sourceRoot":"","sources":["../src/nip05check.ts"],"names":[],"mappings":";;;AAEA,yCAA+C;AAE/C,KAAK,UAAU,IAAI;IACjB,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAA;IAElC,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACtB,OAAO,CAAC,KAAK,CAAC,4BAA4B,CAAC,CAAA;QAC3C,OAAO,CAAC,KAAK,CAAC,kCAAkC,CAAC,CAAA;QACjD,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA;IACjB,CAAC;IAED,MAAM,MAAM,GAAG,IAAI,CAAC,CAAC,CAAC,CAAA;IAEtB,IAAI,CAAC;QACH,MAAM,MAAM,GAAG,MAAM,IAAA,qBAAc,EAAC,MAAM,CAAC,CAAA;QAE3C,OAAO,CAAC,GAAG,CAAC,gCAAgC,MAAM,CAAC,MAAM,EAAE,CAAC,CAAA;QAC5D,OAAO,CAAC,GAAG,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AG,CAAC,mBAAmB,MAAM,CAAC,SAAS,CAAC,cAAc,EAAE,EAAE,CAAC,CAAA;QAEnE,4CAA4C;QAC5C,IAAI,CAAC,MAAM,CAAC,cAAc,EAAE,CAAC;YAC3B,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA;QACjB,CAAC;IAEH,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO,CAAC,KAAK,CAAC,UAAU,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,EAAE,CAAC,CAAA;QACnF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA;IACjB,CAAC;AACH,CAAC;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE;IACnB,OAAO,CAAC,KAAK,CAAC,gBAAgB,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,EAAE,CAAC,CAAA;IACzF,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA;AACjB,CAAC,CAAC,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nip05lookup.d.ts","sourceRoot":"","sources":["../src/nip05lookup.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
"use strict";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
const core_1 = require("@nostrbox/core");
|
|
5
|
+
async function main() {
|
|
6
|
+
const args = process.argv.slice(2);
|
|
7
|
+
if (args.length === 0) {
|
|
8
|
+
console.error('š NIP-05 Lookup Tool');
|
|
9
|
+
console.error('Usage: nip05lookup [-t <type>] <identifier>');
|
|
10
|
+
console.error('');
|
|
11
|
+
console.error('Types: hex, bech32, relays, all (default)');
|
|
12
|
+
console.error('');
|
|
13
|
+
console.error('Examples:');
|
|
14
|
+
console.error(' nip05lookup dave@jb55.com # All information');
|
|
15
|
+
console.error(' nip05lookup -t hex dave@jb55.com # Hex pubkey only');
|
|
16
|
+
console.error(' nip05lookup -t bech32 dave@jb55.com # Npub format only');
|
|
17
|
+
console.error(' nip05lookup -t relays dave@jb55.com # Relays only');
|
|
18
|
+
console.error(' nip05lookup jb55.com # Domain-only lookup');
|
|
19
|
+
process.exit(1);
|
|
20
|
+
}
|
|
21
|
+
let type = 'all';
|
|
22
|
+
let identifier;
|
|
23
|
+
if (args[0] === '-t' && args.length >= 3) {
|
|
24
|
+
const typeArg = args[1];
|
|
25
|
+
if (!['hex', 'bech32', 'relays', 'all'].includes(typeArg)) {
|
|
26
|
+
console.error(`ā Invalid type: ${typeArg}`);
|
|
27
|
+
console.error('Valid types: hex, bech32, relays, all');
|
|
28
|
+
process.exit(1);
|
|
29
|
+
}
|
|
30
|
+
type = typeArg;
|
|
31
|
+
identifier = args[2];
|
|
32
|
+
}
|
|
33
|
+
else {
|
|
34
|
+
identifier = args[0];
|
|
35
|
+
}
|
|
36
|
+
try {
|
|
37
|
+
const result = await (0, core_1.lookupNip05)(identifier, type);
|
|
38
|
+
const outputs = (0, core_1.formatNip05Output)(result, type);
|
|
39
|
+
// Show what we're looking up
|
|
40
|
+
const displayName = result.name ? `${result.name}@${result.domain}` : `_@${result.domain}`;
|
|
41
|
+
console.log(`š NIP-05 Lookup: ${displayName}`);
|
|
42
|
+
console.log('='.repeat(50));
|
|
43
|
+
// Show the results based on type
|
|
44
|
+
if (type === 'hex' || type === 'all') {
|
|
45
|
+
if (outputs.includes(result.pubkey)) {
|
|
46
|
+
console.log(`\nš Hex pubkey:`);
|
|
47
|
+
console.log(result.pubkey);
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
if (type === 'bech32' || type === 'all') {
|
|
51
|
+
if (result.npub && outputs.includes(result.npub)) {
|
|
52
|
+
console.log(`\nš Npub (bech32):`);
|
|
53
|
+
console.log(result.npub);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
if (type === 'relays' || type === 'all') {
|
|
57
|
+
if (result.relays && result.relays.length > 0) {
|
|
58
|
+
console.log(`\nš Relays:`);
|
|
59
|
+
for (const relay of result.relays) {
|
|
60
|
+
console.log(relay);
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
catch (error) {
|
|
66
|
+
console.error(`ā Error: ${error instanceof Error ? error.message : 'Unknown error'}`);
|
|
67
|
+
process.exit(1);
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
main().catch(error => {
|
|
71
|
+
console.error(`ā Fatal error: ${error instanceof Error ? error.message : 'Unknown error'}`);
|
|
72
|
+
process.exit(1);
|
|
73
|
+
});
|
|
74
|
+
//# sourceMappingURL=nip05lookup.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"nip05lookup.js","sourceRoot":"","sources":["../src/nip05lookup.ts"],"names":[],"mappings":";;;AAEA,yCAAqF;AAGrF,KAAK,UAAU,IAAI;IACjB,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,CAAC,CAAA;IAElC,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC,EAAE,CAAC;QACtB,OAAO,CAAC,KAAK,CAAC,uBAAuB,CAAC,CAAA;QACtC,OAAO,CAAC,KAAK,CAAC,6CAA6C,CAAC,CAAA;QAC5D,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC,CAAA;QACjB,OAAO,CAAC,KAAK,CAAC,2CAA2C,CAAC,CAAA;QAC1D,OAAO,CAAC,KAAK,CAAC,EAAE,CAAC,CAAA;QACjB,OAAO,CAAC,KAAK,CAAC,WAAW,CAAC,CAAA;QAC1B,OAAO,CAAC,KAAK,CAAC,4DAA4D,CAAC,CAAA;QAC3E,OAAO,CAAC,KAAK,CAAC,4DAA4D,CAAC,CAAA;QAC3E,OAAO,CAAC,KAAK,CAAC,6DAA6D,CAAC,CAA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,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA;IACjB,CAAC;AACH,CAAC;AAED,IAAI,EAAE,CAAC,KAAK,CAAC,KAAK,CAAC,EAAE;IACnB,OAAO,CAAC,KAAK,CAAC,kBAAkB,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,eAAe,EAAE,CAAC,CAAA;IAC3F,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC,CAAA;AACjB,CAAC,CAAC,CAAA"}
|
package/package.json
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@nostrbox/cli",
|
|
3
|
+
"version": "1.1.0",
|
|
4
|
+
"description": "CLI tool for NIP-05 operations using NostrBox core",
|
|
5
|
+
"main": "dist/index.js",
|
|
6
|
+
"publishConfig": {
|
|
7
|
+
"access": "public"
|
|
8
|
+
},
|
|
9
|
+
"bin": {
|
|
10
|
+
"nip05lookup": "./dist/nip05lookup.js",
|
|
11
|
+
"nip05check": "./dist/nip05check.js"
|
|
12
|
+
},
|
|
13
|
+
"files": [
|
|
14
|
+
"dist",
|
|
15
|
+
"README.md"
|
|
16
|
+
],
|
|
17
|
+
"scripts": {
|
|
18
|
+
"build": "tsc",
|
|
19
|
+
"dev": "tsc --watch",
|
|
20
|
+
"clean": "rimraf dist"
|
|
21
|
+
},
|
|
22
|
+
"keywords": [
|
|
23
|
+
"nostr",
|
|
24
|
+
"nip05",
|
|
25
|
+
"cli",
|
|
26
|
+
"lookup"
|
|
27
|
+
],
|
|
28
|
+
"author": "",
|
|
29
|
+
"license": "MIT",
|
|
30
|
+
"dependencies": {
|
|
31
|
+
"@nostrbox/core": "1.2.2"
|
|
32
|
+
},
|
|
33
|
+
"devDependencies": {
|
|
34
|
+
"@saithodev/semantic-release-gitea": "^2.1.0",
|
|
35
|
+
"@semantic-release/changelog": "^6.0.3",
|
|
36
|
+
"@semantic-release/git": "^10.0.1",
|
|
37
|
+
"@semantic-release/npm": "^10.0.6",
|
|
38
|
+
"@types/node": "^20.8.10",
|
|
39
|
+
"rimraf": "^5.0.5",
|
|
40
|
+
"semantic-release": "^24.2.7",
|
|
41
|
+
"typescript": "^5.2.2"
|
|
42
|
+
},
|
|
43
|
+
"engines": {
|
|
44
|
+
"node": ">=16.0.0"
|
|
45
|
+
}
|
|
46
|
+
}
|