@cyanheads/reliefweb-mcp-server 0.1.1

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.
Files changed (77) hide show
  1. package/CLAUDE.md +391 -0
  2. package/Dockerfile +98 -0
  3. package/LICENSE +201 -0
  4. package/README.md +320 -0
  5. package/changelog/0.1.x/0.1.0.md +24 -0
  6. package/changelog/0.1.x/0.1.1.md +29 -0
  7. package/changelog/template.md +119 -0
  8. package/dist/config/server-config.d.ts +14 -0
  9. package/dist/config/server-config.d.ts.map +1 -0
  10. package/dist/config/server-config.js +19 -0
  11. package/dist/config/server-config.js.map +1 -0
  12. package/dist/index.d.ts +7 -0
  13. package/dist/index.d.ts.map +1 -0
  14. package/dist/index.js +42 -0
  15. package/dist/index.js.map +1 -0
  16. package/dist/mcp-server/prompts/definitions/crisis-briefing.prompt.d.ts +14 -0
  17. package/dist/mcp-server/prompts/definitions/crisis-briefing.prompt.d.ts.map +1 -0
  18. package/dist/mcp-server/prompts/definitions/crisis-briefing.prompt.js +62 -0
  19. package/dist/mcp-server/prompts/definitions/crisis-briefing.prompt.js.map +1 -0
  20. package/dist/mcp-server/resources/definitions/country.resource.d.ts +9 -0
  21. package/dist/mcp-server/resources/definitions/country.resource.d.ts.map +1 -0
  22. package/dist/mcp-server/resources/definitions/country.resource.js +30 -0
  23. package/dist/mcp-server/resources/definitions/country.resource.js.map +1 -0
  24. package/dist/mcp-server/resources/definitions/disaster.resource.d.ts +9 -0
  25. package/dist/mcp-server/resources/definitions/disaster.resource.d.ts.map +1 -0
  26. package/dist/mcp-server/resources/definitions/disaster.resource.js +30 -0
  27. package/dist/mcp-server/resources/definitions/disaster.resource.js.map +1 -0
  28. package/dist/mcp-server/resources/definitions/report.resource.d.ts +9 -0
  29. package/dist/mcp-server/resources/definitions/report.resource.d.ts.map +1 -0
  30. package/dist/mcp-server/resources/definitions/report.resource.js +30 -0
  31. package/dist/mcp-server/resources/definitions/report.resource.js.map +1 -0
  32. package/dist/mcp-server/tools/definitions/get-country.tool.d.ts +35 -0
  33. package/dist/mcp-server/tools/definitions/get-country.tool.d.ts.map +1 -0
  34. package/dist/mcp-server/tools/definitions/get-country.tool.js +106 -0
  35. package/dist/mcp-server/tools/definitions/get-country.tool.js.map +1 -0
  36. package/dist/mcp-server/tools/definitions/get-disaster.tool.d.ts +42 -0
  37. package/dist/mcp-server/tools/definitions/get-disaster.tool.d.ts.map +1 -0
  38. package/dist/mcp-server/tools/definitions/get-disaster.tool.js +127 -0
  39. package/dist/mcp-server/tools/definitions/get-disaster.tool.js.map +1 -0
  40. package/dist/mcp-server/tools/definitions/get-report.tool.d.ts +30 -0
  41. package/dist/mcp-server/tools/definitions/get-report.tool.d.ts.map +1 -0
  42. package/dist/mcp-server/tools/definitions/get-report.tool.js +92 -0
  43. package/dist/mcp-server/tools/definitions/get-report.tool.js.map +1 -0
  44. package/dist/mcp-server/tools/definitions/list-countries.tool.d.ts +20 -0
  45. package/dist/mcp-server/tools/definitions/list-countries.tool.d.ts.map +1 -0
  46. package/dist/mcp-server/tools/definitions/list-countries.tool.js +83 -0
  47. package/dist/mcp-server/tools/definitions/list-countries.tool.js.map +1 -0
  48. package/dist/mcp-server/tools/definitions/list-sources.tool.d.ts +22 -0
  49. package/dist/mcp-server/tools/definitions/list-sources.tool.d.ts.map +1 -0
  50. package/dist/mcp-server/tools/definitions/list-sources.tool.js +82 -0
  51. package/dist/mcp-server/tools/definitions/list-sources.tool.js.map +1 -0
  52. package/dist/mcp-server/tools/definitions/search-disasters.tool.d.ts +35 -0
  53. package/dist/mcp-server/tools/definitions/search-disasters.tool.d.ts.map +1 -0
  54. package/dist/mcp-server/tools/definitions/search-disasters.tool.js +163 -0
  55. package/dist/mcp-server/tools/definitions/search-disasters.tool.js.map +1 -0
  56. package/dist/mcp-server/tools/definitions/search-jobs.tool.d.ts +32 -0
  57. package/dist/mcp-server/tools/definitions/search-jobs.tool.d.ts.map +1 -0
  58. package/dist/mcp-server/tools/definitions/search-jobs.tool.js +148 -0
  59. package/dist/mcp-server/tools/definitions/search-jobs.tool.js.map +1 -0
  60. package/dist/mcp-server/tools/definitions/search-reports.tool.d.ts +40 -0
  61. package/dist/mcp-server/tools/definitions/search-reports.tool.d.ts.map +1 -0
  62. package/dist/mcp-server/tools/definitions/search-reports.tool.js +191 -0
  63. package/dist/mcp-server/tools/definitions/search-reports.tool.js.map +1 -0
  64. package/dist/mcp-server/tools/definitions/search-training.tool.d.ts +35 -0
  65. package/dist/mcp-server/tools/definitions/search-training.tool.d.ts.map +1 -0
  66. package/dist/mcp-server/tools/definitions/search-training.tool.js +166 -0
  67. package/dist/mcp-server/tools/definitions/search-training.tool.js.map +1 -0
  68. package/dist/services/reliefweb/reliefweb-service.d.ts +103 -0
  69. package/dist/services/reliefweb/reliefweb-service.d.ts.map +1 -0
  70. package/dist/services/reliefweb/reliefweb-service.js +546 -0
  71. package/dist/services/reliefweb/reliefweb-service.js.map +1 -0
  72. package/dist/services/reliefweb/types.d.ts +345 -0
  73. package/dist/services/reliefweb/types.d.ts.map +1 -0
  74. package/dist/services/reliefweb/types.js +7 -0
  75. package/dist/services/reliefweb/types.js.map +1 -0
  76. package/package.json +78 -0
  77. package/server.json +111 -0
package/LICENSE ADDED
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright 2025 Casey Hand @cyanheads
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.
package/README.md ADDED
@@ -0,0 +1,320 @@
1
+ <div align="center">
2
+ <h1>@cyanheads/reliefweb-mcp-server</h1>
3
+ <p><b>Search ReliefWeb humanitarian reports, disasters, jobs, training, and country profiles via MCP. STDIO or Streamable HTTP.</b>
4
+ <div>9 Tools • 3 Resources • 1 Prompt</div>
5
+ </p>
6
+ </div>
7
+
8
+ <div align="center">
9
+
10
+ [![Version](https://img.shields.io/badge/Version-0.1.1-blue.svg?style=flat-square)](./CHANGELOG.md) [![License](https://img.shields.io/badge/License-Apache%202.0-orange.svg?style=flat-square)](./LICENSE) [![MCP SDK](https://img.shields.io/badge/MCP%20SDK-^1.29.0-green.svg?style=flat-square)](https://modelcontextprotocol.io/) [![npm](https://img.shields.io/npm/v/@cyanheads/reliefweb-mcp-server?style=flat-square&logo=npm&logoColor=white)](https://www.npmjs.com/package/@cyanheads/reliefweb-mcp-server) [![TypeScript](https://img.shields.io/badge/TypeScript-^6.0.3-3178C6.svg?style=flat-square)](https://www.typescriptlang.org/) [![Bun](https://img.shields.io/badge/Bun-v1.3.0-blueviolet.svg?style=flat-square)](https://bun.sh/)
11
+
12
+ </div>
13
+
14
+ <div align="center">
15
+
16
+ [![Install in Claude Desktop](https://img.shields.io/badge/Install_in-Claude_Desktop-D97757?style=for-the-badge&logo=anthropic&logoColor=white)](https://github.com/cyanheads/reliefweb-mcp-server/releases/latest/download/reliefweb-mcp-server.mcpb) [![Install in Cursor](https://cursor.com/deeplink/mcp-install-dark.svg)](https://cursor.com/en/install-mcp?name=reliefweb-mcp-server&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsIkBjeWFuaGVhZHMvcmVsaWVmd2ViLW1jcC1zZXJ2ZXIiXSwiZW52Ijp7IlJFTElFRldFQl9BUFBfTkFNRSI6InlvdXItYXBwLW5hbWUifX0=) [![Install in VS Code](https://img.shields.io/badge/VS_Code-Install_Server-0098FF?style=for-the-badge&logo=visualstudiocode&logoColor=white)](https://vscode.dev/redirect?url=vscode:mcp/install?%7B%22name%22%3A%22reliefweb-mcp-server%22%2C%22command%22%3A%22npx%22%2C%22args%22%3A%5B%22-y%22%2C%22%40cyanheads%2Freliefweb-mcp-server%22%5D%2C%22env%22%3A%7B%22RELIEFWEB_APP_NAME%22%3A%22your-app-name%22%7D%7D)
17
+
18
+ [![Framework](https://img.shields.io/badge/Built%20on-@cyanheads/mcp--ts--core-67E8F9?style=flat-square)](https://www.npmjs.com/package/@cyanheads/mcp-ts-core)
19
+
20
+ </div>
21
+
22
+ ---
23
+
24
+ ## Tools
25
+
26
+ 9 tools for working with ReliefWeb humanitarian data:
27
+
28
+ | Tool | Description |
29
+ |:---|:---|
30
+ | `reliefweb_search_reports` | Search humanitarian reports with filtering by country, disaster, format, theme, language, source, and date |
31
+ | `reliefweb_get_report` | Fetch a single report by numeric ID with full body text and metadata |
32
+ | `reliefweb_search_disasters` | Search disasters by type, country, status, GLIDE number, and date range |
33
+ | `reliefweb_get_disaster` | Fetch a disaster record with profile, key content links, appeals, and response plans |
34
+ | `reliefweb_get_country` | Fetch a country profile by ISO3 code with overview, appeals, and curated links |
35
+ | `reliefweb_list_countries` | List all countries tracked by ReliefWeb, filterable to active humanitarian situations |
36
+ | `reliefweb_search_jobs` | Search humanitarian job listings by country, organization, career category, and experience level |
37
+ | `reliefweb_search_training` | Search training and learning opportunities by format, country, career category, and date |
38
+ | `reliefweb_list_sources` | Browse contributing organizations by name and type |
39
+
40
+ ### `reliefweb_search_reports`
41
+
42
+ Search humanitarian reports on ReliefWeb with rich filtering.
43
+
44
+ - Full-text search across title, body, and key metadata fields
45
+ - Filtering by country (ISO3), disaster ID, format, theme, language, and source organization
46
+ - Date range filtering on source publication date
47
+ - Raw filter object for compound conditions not covered by named params
48
+ - Pagination via offset and limit (up to 1,000 per call)
49
+ - Optional `include_archived=true` for historical research (includes expired and archived content)
50
+ - Returns paginated summaries — use `reliefweb_get_report` to fetch full body text
51
+ - Rate limit: 1,000 calls/day
52
+
53
+ ---
54
+
55
+ ### `reliefweb_get_report`
56
+
57
+ Fetch a single ReliefWeb report by its numeric ID with full body text.
58
+
59
+ - Full body HTML, all metadata, and file attachment URLs
60
+ - Use after `reliefweb_search_reports` to retrieve document content (10–100KB each)
61
+ - Returns structured `not_found` when the ID doesn't exist
62
+
63
+ ---
64
+
65
+ ### `reliefweb_search_disasters`
66
+
67
+ Search active and historical disasters on ReliefWeb.
68
+
69
+ - Filtering by disaster type (Earthquake, Flood, Cyclone, etc.), country, and status
70
+ - GLIDE number lookup for cross-system disaster correlation
71
+ - Date range filtering on disaster creation date
72
+ - Status values: `alert`, `current`, `past`, `alert-archive`, `archive`; multiple values comma-separated
73
+ - Optional `include_archived=true` for historical research
74
+ - Returns IDs for use with `reliefweb_get_disaster` and as `disaster_id` filter in `reliefweb_search_reports`
75
+
76
+ ---
77
+
78
+ ### `reliefweb_get_disaster`
79
+
80
+ Fetch a disaster record by ReliefWeb numeric ID with full details.
81
+
82
+ - Full description, profile overview, affected countries, and GLIDE number
83
+ - Curated key content links from the ReliefWeb editorial team
84
+ - Active appeals and response plans linked to the disaster
85
+ - Useful external links curated by ReliefWeb editors
86
+
87
+ ---
88
+
89
+ ### `reliefweb_get_country`
90
+
91
+ Fetch a country profile from ReliefWeb by ISO3 code.
92
+
93
+ - Situation overview text curated by OCHA editors
94
+ - Key content links maintained by ReliefWeb editors
95
+ - Active humanitarian appeals and response plans
96
+ - Useful external links for the country
97
+ - Country profiles are the authoritative situation summary for humanitarian responders
98
+
99
+ ---
100
+
101
+ ### `reliefweb_list_countries`
102
+
103
+ List all countries and territories tracked by ReliefWeb.
104
+
105
+ - Optional `crisis_only=true` to limit to active humanitarian situations (status alert or current)
106
+ - Returns ISO3 codes, status, and canonical URLs — use ISO3 with `reliefweb_get_country`
107
+ - Pagination up to 1,000 entries per call
108
+
109
+ ---
110
+
111
+ ### `reliefweb_search_jobs`
112
+
113
+ Search humanitarian job listings on ReliefWeb.
114
+
115
+ - Filtering by country, organization short name, career category, theme, and experience level
116
+ - Career category values: Programme and Project Management, Information and Communications Technology, Logistics and Telecommunications, and others
117
+ - Returns current open positions — archived jobs excluded by default
118
+ - Pagination with closing date and canonical URL per listing
119
+
120
+ ---
121
+
122
+ ### `reliefweb_search_training`
123
+
124
+ Search humanitarian training and learning opportunities.
125
+
126
+ - Covers workshops, e-learning, conferences, seminars, and other capacity-building events
127
+ - Filtering by country, source, format, career category, and language
128
+ - Date range filtering on training start date (`date_start_from` / `date_start_to`)
129
+ - Distinct from report date fields — uses `date.start` / `date.end`
130
+
131
+ ---
132
+
133
+ ### `reliefweb_list_sources`
134
+
135
+ Browse organizations that contribute content to ReliefWeb.
136
+
137
+ - Optional filtering by name text or organization type (Government, International Organization, NGO, Academia)
138
+ - Returns short names, types, organization URLs, and homepage URLs
139
+ - Use `shortname` with the `source` filter in `reliefweb_search_reports`, `reliefweb_search_jobs`, and `reliefweb_search_training`
140
+
141
+ ## Resources and prompt
142
+
143
+ | Type | Name | Description |
144
+ |:---|:---|:---|
145
+ | Resource | `reliefweb://reports/{id}` | Full report record by numeric ID — metadata, body text, and file URLs |
146
+ | Resource | `reliefweb://disasters/{id}` | Disaster record by numeric ID — type, status, GLIDE, description, and content links |
147
+ | Resource | `reliefweb://countries/{iso3}` | Country profile by ISO3 code — overview, situation summary, and active response plans |
148
+ | Prompt | `reliefweb_crisis_briefing` | Generate a structured humanitarian briefing for a country or disaster |
149
+
150
+ ## Features
151
+
152
+ Built on [`@cyanheads/mcp-ts-core`](https://github.com/cyanheads/mcp-ts-core):
153
+
154
+ - Declarative tool definitions — single file per tool, framework handles registration and validation
155
+ - Unified error handling across all tools
156
+ - Pluggable auth (`none`, `jwt`, `oauth`)
157
+ - Swappable storage backends: `in-memory`, `filesystem`, `Supabase`, `Cloudflare KV/R2/D1`
158
+ - Structured logging with optional OpenTelemetry tracing
159
+ - Runs locally (stdio/HTTP) or on Cloudflare Workers from the same codebase
160
+
161
+ ReliefWeb-specific:
162
+
163
+ - Full coverage of six ReliefWeb content types: reports, disasters, countries, jobs, training, sources
164
+ - Compound filter builder supporting nested AND/OR conditions for the ReliefWeb API v2
165
+ - `RELIEFWEB_APP_NAME` validated at startup (required by the API since November 2025)
166
+ - 1,000 calls/day quota awareness — prominently documented on each tool
167
+
168
+ Agent-friendly output:
169
+
170
+ - Body text excluded from search results by design — agents fetch it explicitly with `reliefweb_get_report` to control context budget
171
+ - Recovery hints on empty results — echoes applied filters and suggests how to broaden
172
+ - Typed `not_found` error contracts on get-by-ID tools with actionable recovery text
173
+
174
+ ## Getting started
175
+
176
+ ### Prerequisites
177
+
178
+ - [Bun v1.3.0](https://bun.sh/) or higher, or Node.js v24.0.0 or higher.
179
+ - A **pre-approved ReliefWeb appname** — register at [ReliefWeb API](https://reliefweb.int/help/api) and set `RELIEFWEB_APP_NAME`. The API has required pre-approved appnames since November 2025; requests without one are rejected.
180
+
181
+ ### Self-Hosted / Local
182
+
183
+ Add the following to your MCP client configuration file.
184
+
185
+ ```json
186
+ {
187
+ "mcpServers": {
188
+ "reliefweb": {
189
+ "type": "stdio",
190
+ "command": "bunx",
191
+ "args": ["@cyanheads/reliefweb-mcp-server@latest"],
192
+ "env": {
193
+ "MCP_TRANSPORT_TYPE": "stdio",
194
+ "MCP_LOG_LEVEL": "info",
195
+ "RELIEFWEB_APP_NAME": "your-app-name"
196
+ }
197
+ }
198
+ }
199
+ }
200
+ ```
201
+
202
+ Or with npx (no Bun required):
203
+
204
+ ```json
205
+ {
206
+ "mcpServers": {
207
+ "reliefweb": {
208
+ "type": "stdio",
209
+ "command": "npx",
210
+ "args": ["-y", "@cyanheads/reliefweb-mcp-server@latest"],
211
+ "env": {
212
+ "MCP_TRANSPORT_TYPE": "stdio",
213
+ "MCP_LOG_LEVEL": "info",
214
+ "RELIEFWEB_APP_NAME": "your-app-name"
215
+ }
216
+ }
217
+ }
218
+ }
219
+ ```
220
+
221
+ For Streamable HTTP, set the transport and start the server:
222
+
223
+ ```sh
224
+ MCP_TRANSPORT_TYPE=http MCP_HTTP_PORT=3010 RELIEFWEB_APP_NAME=your-app-name bun run start:http
225
+ # Server listens at http://localhost:3010/mcp
226
+ ```
227
+
228
+ ### Installation
229
+
230
+ 1. **Clone the repository:**
231
+
232
+ ```sh
233
+ git clone https://github.com/cyanheads/reliefweb-mcp-server.git
234
+ ```
235
+
236
+ 2. **Navigate into the directory:**
237
+
238
+ ```sh
239
+ cd reliefweb-mcp-server
240
+ ```
241
+
242
+ 3. **Install dependencies:**
243
+
244
+ ```sh
245
+ bun install
246
+ ```
247
+
248
+ 4. **Copy `.env.example` to `.env` and set `RELIEFWEB_APP_NAME`.**
249
+
250
+ ## Configuration
251
+
252
+ All configuration is validated at startup via Zod schemas. Key environment variables:
253
+
254
+ | Variable | Description | Default |
255
+ |:---|:---|:---|
256
+ | `RELIEFWEB_APP_NAME` | **Required.** Pre-approved appname for the ReliefWeb API v2. Register at reliefweb.int/help/api. | — |
257
+ | `MCP_TRANSPORT_TYPE` | Transport: `stdio` or `http` | `stdio` |
258
+ | `MCP_HTTP_PORT` | HTTP server port | `3010` |
259
+ | `MCP_HTTP_ENDPOINT_PATH` | HTTP endpoint path where the MCP server is mounted | `/mcp` |
260
+ | `MCP_PUBLIC_URL` | Public origin override for TLS-terminating reverse-proxy deployments | none |
261
+ | `MCP_AUTH_MODE` | Authentication: `none`, `jwt`, or `oauth` | `none` |
262
+ | `MCP_LOG_LEVEL` | Log level (`debug`, `info`, `warning`, `error`, etc.) | `info` |
263
+ | `MCP_GC_PRESSURE_INTERVAL_MS` | Opt-in Bun-only forced-GC pressure loop (ms). Try `60000` if heap growth is observed under sustained HTTP load. | `0` (disabled) |
264
+ | `LOGS_DIR` | Directory for log files (Node.js only). | `<project-root>/logs` |
265
+ | `STORAGE_PROVIDER_TYPE` | Storage backend: `in-memory`, `filesystem`, `supabase`, `cloudflare-kv/r2/d1` | `in-memory` |
266
+ | `OTEL_ENABLED` | Enable OpenTelemetry | `false` |
267
+
268
+ ## Running the server
269
+
270
+ ### Local development
271
+
272
+ - **Build and run the production version**:
273
+
274
+ ```sh
275
+ # One-time build
276
+ bun run rebuild
277
+
278
+ # Run the built server
279
+ bun run start:http
280
+ # or
281
+ bun run start:stdio
282
+ ```
283
+
284
+ - **Run checks and tests**:
285
+ ```sh
286
+ bun run devcheck # Lints, formats, type-checks, and more
287
+ bun run test # Runs the test suite
288
+ ```
289
+
290
+ ## Project structure
291
+
292
+ | Directory | Purpose |
293
+ |:---|:---|
294
+ | `src/mcp-server/tools` | Tool definitions (`*.tool.ts`). Nine tools across reports, disasters, countries, jobs, training, and sources. |
295
+ | `src/mcp-server/resources` | Resource definitions. Report, disaster, and country resources. |
296
+ | `src/mcp-server/prompts` | Prompt definitions. Crisis briefing prompt. |
297
+ | `src/services/reliefweb` | ReliefWeb API service layer — HTTP client, filter builder, and response normalizers for all six content types. |
298
+ | `src/config` | Server-specific environment variable parsing and validation with Zod. |
299
+ | `tests/` | Unit and integration tests, mirroring the `src/` structure. |
300
+
301
+ ## Development guide
302
+
303
+ See [`CLAUDE.md`](./CLAUDE.md) for development guidelines and architectural rules. The short version:
304
+
305
+ - Handlers throw, framework catches — no `try/catch` in tool logic
306
+ - Use `ctx.log` for logging, `ctx.state` for storage
307
+ - Register new tools and resources in the `createApp()` arrays
308
+
309
+ ## Contributing
310
+
311
+ Issues and pull requests are welcome. Run checks and tests before submitting:
312
+
313
+ ```sh
314
+ bun run devcheck
315
+ bun run test
316
+ ```
317
+
318
+ ## License
319
+
320
+ This project is licensed under the Apache 2.0 License. See the [LICENSE](./LICENSE) file for details.
@@ -0,0 +1,24 @@
1
+ ---
2
+ summary: "Initial release — ReliefWeb humanitarian data API: 9 tools, 3 resources, 1 prompt"
3
+ breaking: false
4
+ security: false
5
+ ---
6
+
7
+ # 0.1.0 — 2026-05-23
8
+
9
+ ## Added
10
+
11
+ - **`reliefweb_search_reports`** — search humanitarian reports with filtering by country, disaster, format, theme, language, source, and date range
12
+ - **`reliefweb_get_report`** — fetch a single report by numeric ID with full body text and metadata
13
+ - **`reliefweb_search_disasters`** — search disasters by type, country, status, GLIDE number, and date range
14
+ - **`reliefweb_get_disaster`** — fetch a disaster record with full profile, key content links, and response plans
15
+ - **`reliefweb_get_country`** — fetch a country profile by ISO3 code including overview, appeals, and curated links
16
+ - **`reliefweb_list_countries`** — list all countries tracked by ReliefWeb, filterable to active humanitarian situations
17
+ - **`reliefweb_search_jobs`** — search humanitarian job listings by country, organization, career category, and experience
18
+ - **`reliefweb_search_training`** — search training and learning opportunities by format, country, career category, and date
19
+ - **`reliefweb_list_sources`** — browse contributing organizations by name and type
20
+ - **`reliefweb://{reportId}`** resource — fetch a report by numeric ID
21
+ - **`reliefweb-disasters://{disasterId}`** resource — fetch a disaster by numeric ID
22
+ - **`reliefweb-countries://{iso3}`** resource — fetch a country profile by ISO3 code
23
+ - **`reliefweb_crisis_briefing`** prompt — generate a structured humanitarian situation brief
24
+ - **`ReliefWebService`** — internal service with retry, filter building, and normalization for all six ReliefWeb content types
@@ -0,0 +1,29 @@
1
+ ---
2
+ summary: "ReliefWeb humanitarian crisis data — 9 tools, 3 resources, 1 prompt"
3
+ breaking: false
4
+ security: false
5
+ ---
6
+
7
+ # 0.1.1 — 2026-05-23
8
+
9
+ Full implementation on top of the initial scaffold: service layer, all tool/resource/prompt definitions, tests, and pre-launch polish.
10
+
11
+ ## Added
12
+
13
+ - **`reliefweb_search_reports`** — search humanitarian reports with filtering by country, disaster, format, theme, language, source, and date range
14
+ - **`reliefweb_get_report`** — fetch a single report by numeric ID with full body text and metadata
15
+ - **`reliefweb_search_disasters`** — search disasters by type, country, status, GLIDE number, and date range
16
+ - **`reliefweb_get_disaster`** — fetch a disaster record with full profile, key content links, and response plans
17
+ - **`reliefweb_get_country`** — fetch a country profile by ISO3 code including overview, appeals, and curated links
18
+ - **`reliefweb_list_countries`** — list all countries tracked by ReliefWeb, filterable to active humanitarian situations
19
+ - **`reliefweb_search_jobs`** — search humanitarian job listings by country, organization, career category, and experience
20
+ - **`reliefweb_search_training`** — search training and learning opportunities by format, country, career category, and date
21
+ - **`reliefweb_list_sources`** — browse contributing organizations by name and type
22
+ - **`reliefweb://{reportId}`** resource — fetch a report by numeric ID
23
+ - **`reliefweb-disasters://{disasterId}`** resource — fetch a disaster by numeric ID
24
+ - **`reliefweb-countries://{iso3}`** resource — fetch a country profile by ISO3 code
25
+ - **`reliefweb_crisis_briefing`** prompt — generate a structured humanitarian situation brief
26
+ - **`ReliefWebService`** — internal service with retry, filter building, and normalization for all six ReliefWeb content types
27
+ - Tests for all tools, resources, and prompts
28
+ - `manifest.json` for MCPB bundle support (one-click Claude Desktop install)
29
+ - Install badges (Claude Desktop, Cursor, VS Code) in README