@sonill/nepali-dates 1.0.3 → 1.0.6

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 CHANGED
@@ -1,13 +1,27 @@
1
1
  # Nepali Dates
2
2
 
3
- [![npm version](https://img.shields.io/npm/v/nepali-dates.svg)](https://www.npmjs.com/package/@sonill/nepali-dates)
3
+ [![npm version](https://img.shields.io/npm/v/@sonill/nepali-dates.svg)](https://www.npmjs.com/package/@sonill/nepali-dates)
4
4
  [![Tests](https://github.com/sonill/nepali-dates/actions/workflows/test.yml/badge.svg)](https://github.com/sonill/nepali-dates/actions/workflows/test.yml)
5
5
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
6
6
  [![TypeScript](https://img.shields.io/badge/TypeScript-5.3-blue.svg)](https://www.typescriptlang.org/)
7
7
 
8
+ ![nepali dates](https://repository-images.githubusercontent.com/1136702942/c66c6f7c-262c-44cd-888b-336448d2ede2)
9
+
8
10
  Community-driven, accurate Nepali calendar (Bikram Sambat) data and conversion utilities. A trustable source for Nepali date calculations with zero dependencies.
9
11
 
10
- Use this package instead of maintaining your own source of datas.
12
+ The ultimate Nepali date conversion library for developers. Convert between Bikram Sambat (BS) and Gregorian dates with 100% accurate, community-maintained calendar data. Perfect for Nepali calendar apps, date converters, and plugins. No dependencies, fully typed, and production-ready.
13
+
14
+ ### Why Use This Package?
15
+
16
+ Stop maintaining your own Nepali calendar data. This package eliminates the burden of:
17
+ - Manually updating calendar data year after year
18
+ - Debugging date conversion edge cases
19
+ - Verifying data accuracy across multiple sources
20
+
21
+ **Using JavaScript?** Use the full library with type safety and conversion utilities.
22
+ **Using another language?** Access the calendar data directly via `calendar-data.json` in the [data/](data/) directory. Examples available for Python, PHP, Ruby, Go, and more.
23
+
24
+ The community maintains the data—you focus on building great features.
11
25
 
12
26
  ## Website
13
27
 
@@ -21,25 +35,95 @@ View website [here](https://sonill.github.io/nepali-dates/)
21
35
  - **Multiple Formats**: Support for object, ISO, string, and array formats
22
36
  - **Well-Tested**: >95% test coverage with extensive validation
23
37
  - **Community-Driven**: Open data sources and transparent validation
38
+ - **AI Agent Ready**: MCP server available for Claude Code and other AI tools
24
39
 
25
40
  ## Installation
26
41
 
27
42
  ```bash
28
- npm install nepali-dates
43
+ npm install @sonill/nepali-dates
29
44
  ```
30
45
 
31
46
  ```bash
32
- yarn add nepali-dates
47
+ yarn add @sonill/nepali-dates
33
48
  ```
34
49
 
35
50
  ```bash
36
- pnpm add nepali-dates
51
+ pnpm add @sonill/nepali-dates
52
+ ```
53
+
54
+ ## MCP Server for AI Agents
55
+
56
+ This package includes a built-in MCP (Model Context Protocol) server with 9 tools for AI agents to work with Nepali calendar dates.
57
+
58
+ ### Setup for Claude Code
59
+
60
+ Add to `~/.claude/config.json`:
61
+
62
+ **Using npx (recommended - no installation required):**
63
+
64
+ ```json
65
+ {
66
+ "mcpServers": {
67
+ "nepali-dates": {
68
+ "command": "npx",
69
+ "args": ["-y", "@sonill/nepali-dates", "nepali-dates-mcp"]
70
+ }
71
+ }
72
+ }
73
+ ```
74
+
75
+ **Using global installation:**
76
+
77
+ ```bash
78
+ npm install -g @sonill/nepali-dates
37
79
  ```
38
80
 
81
+ ```json
82
+ {
83
+ "mcpServers": {
84
+ "nepali-dates": {
85
+ "command": "nepali-dates-mcp"
86
+ }
87
+ }
88
+ }
89
+ ```
90
+
91
+ ### Setup for Claude Desktop
92
+
93
+ Add the same configuration to your Claude Desktop config file:
94
+
95
+ - **macOS:** `~/Library/Application Support/Claude/claude_desktop_config.json`
96
+ - **Windows:** `%APPDATA%\Claude\claude_desktop_config.json`
97
+ - **Linux:** `~/.config/Claude/claude_desktop_config.json`
98
+
99
+ After configuration, restart your AI agent and ask questions like:
100
+
101
+ - "What is today's date in Nepali calendar?"
102
+ - "Convert BS 2081/01/15 to English date"
103
+ - "Show me the calendar for Baisakh 2081"
104
+
105
+ ### Available Tools
106
+
107
+ - `convert_bs_to_ad`, `convert_ad_to_bs` - Date conversion
108
+ - `get_month_calendar`, `get_year_calendar` - Calendar generation
109
+ - `validate_bs_date`, `validate_ad_date` - Date validation
110
+ - `navigate_month`, `get_nepali_month_name` - Navigation & localization
111
+ - `get_current_nepali_date` - Get today's BS date
112
+
113
+ ### Testing
114
+
115
+ Test the MCP server with the visual inspector:
116
+
117
+ ```bash
118
+ npx @modelcontextprotocol/inspector npx @sonill/nepali-dates nepali-dates-mcp
119
+ ```
120
+
121
+ For detailed MCP documentation, see [docs/MCP.md](docs/MCP.md).
122
+
39
123
  ## Quick Start
40
124
 
41
125
  ```typescript
42
- import { bsToAd, adToBs, getTotalDaysInMonth } from 'nepali-dates';
126
+ import { bsToAd, adToBs, getTotalDaysInMonth } from '@sonill/nepali-dates';
43
127
 
44
128
  // Convert Nepali date to English date
45
129
  const englishDate = bsToAd(2080, 10, 15);
@@ -371,9 +455,9 @@ Thanks to all contributors and the Nepali developer community for maintaining ac
371
455
 
372
456
  ## Links
373
457
 
374
- - [GitHub Repository](https://github.com/yourusername/nepali-dates)
375
- - [Issue Tracker](https://github.com/yourusername/nepali-dates/issues)
376
- - [NPM Package](https://www.npmjs.com/package/nepali-dates)
458
+ - [GitHub Repository](https://github.com/sonill/nepali-dates)
459
+ - [Issue Tracker](https://github.com/sonill/nepali-dates/issues)
460
+ - [NPM Package](https://www.npmjs.com/package/@sonill/nepali-dates)
377
461
 
378
462
  ---
379
463