@expandai/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.
package/package.json ADDED
@@ -0,0 +1,61 @@
1
+ {
2
+ "name": "@expandai/mcp-server",
3
+ "version": "0.1.1",
4
+ "description": "MCP server for expand.ai - Give AI agents access to the web",
5
+ "type": "module",
6
+ "publishConfig": {
7
+ "access": "public"
8
+ },
9
+ "bin": {
10
+ "expandai-mcp-server": "./dist/main.cjs"
11
+ },
12
+ "files": [
13
+ "dist",
14
+ "src",
15
+ "README.md",
16
+ "LICENSE"
17
+ ],
18
+ "repository": {
19
+ "type": "git",
20
+ "url": "https://github.com/expandai/expandai-mcp-server.git"
21
+ },
22
+ "homepage": "https://expand.ai",
23
+ "author": "expand.ai",
24
+ "license": "Apache-2.0",
25
+ "keywords": [
26
+ "mcp",
27
+ "model-context-protocol",
28
+ "ai",
29
+ "web",
30
+ "scraping",
31
+ "expand"
32
+ ],
33
+ "dependencies": {
34
+ "@effect/ai": "^0.32.1",
35
+ "@effect/platform": "^0.93.6",
36
+ "@effect/platform-node": "^0.103.0",
37
+ "@expandai/sdk": "^0.5.1",
38
+ "effect": "^3.19.11"
39
+ },
40
+ "devDependencies": {
41
+ "@biomejs/biome": "^2.3.8",
42
+ "@changesets/changelog-github": "^0.5.1",
43
+ "@changesets/cli": "^2.29.7",
44
+ "@tim-smart/openapi-gen": "^0.4.13",
45
+ "@types/node": "^24.7.0",
46
+ "tsup": "^8.5.0",
47
+ "tsx": "^4.20.6",
48
+ "typescript": "^5.9.3"
49
+ },
50
+ "scripts": {
51
+ "build": "tsup",
52
+ "dev": "tsx --watch src/main.ts",
53
+ "check": "tsc --noEmit",
54
+ "lint": "biome check .",
55
+ "lint:fix": "biome check --write .",
56
+ "format": "biome format --write .",
57
+ "changeset": "changeset",
58
+ "version": "changeset version",
59
+ "inspect": "pnpx @modelcontextprotocol/inspector tsx src/main.ts"
60
+ }
61
+ }
@@ -0,0 +1,26 @@
1
+ import { HttpClient, HttpClientRequest } from '@effect/platform'
2
+ import { Config, Effect, Redacted } from 'effect'
3
+ import * as GeneratedClient from './generated/ExpandClient.js'
4
+
5
+ export const ExpandConfig = Config.all({
6
+ apiKey: Config.redacted('EXPAND_API_KEY'),
7
+ baseUrl: Config.withDefault(Config.string('EXPAND_BASE_URL'), 'https://api.expand.ai'),
8
+ })
9
+
10
+ export class ExpandClient extends Effect.Service<ExpandClient>()('ExpandClient', {
11
+ dependencies: [],
12
+ scoped: Effect.gen(function* () {
13
+ const config = yield* ExpandConfig
14
+ const httpClient = yield* HttpClient.HttpClient
15
+
16
+ return GeneratedClient.make(httpClient, {
17
+ transformClient: (client) =>
18
+ Effect.succeed(
19
+ client.pipe(
20
+ HttpClient.mapRequest(HttpClientRequest.prependUrl(config.baseUrl)),
21
+ HttpClient.mapRequest(HttpClientRequest.setHeader('x-expand-api-key', Redacted.value(config.apiKey))),
22
+ ),
23
+ ),
24
+ })
25
+ }),
26
+ }) {}