simplepractice-mcp 1.1.3 → 1.1.4
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/.claude-plugin/marketplace.json +2 -2
- package/.claude-plugin/plugin.json +1 -1
- package/dist/bundle.js +21 -8
- package/dist/client.js +25 -12
- package/dist/version.js +1 -1
- package/package.json +1 -1
- package/server.json +2 -2
|
@@ -6,14 +6,14 @@
|
|
|
6
6
|
},
|
|
7
7
|
"metadata": {
|
|
8
8
|
"description": "SimplePractice Client Portal tools for Claude",
|
|
9
|
-
"version": "1.1.
|
|
9
|
+
"version": "1.1.4"
|
|
10
10
|
},
|
|
11
11
|
"plugins": [
|
|
12
12
|
{
|
|
13
13
|
"name": "simplepractice",
|
|
14
14
|
"source": "./",
|
|
15
15
|
"description": "Read a SimplePractice Client Portal — appointments, invoices and superbills, documents to sign, and practice announcements. Signs in with the portal's own passwordless emailed link; requests go straight to the portal's JSON:API over your own session.",
|
|
16
|
-
"version": "1.1.
|
|
16
|
+
"version": "1.1.4",
|
|
17
17
|
"author": {
|
|
18
18
|
"name": "Chris Chall",
|
|
19
19
|
"url": "https://github.com/chrischall"
|
package/dist/bundle.js
CHANGED
|
@@ -34782,7 +34782,7 @@ function toolAnnotations(opts = {}) {
|
|
|
34782
34782
|
}
|
|
34783
34783
|
|
|
34784
34784
|
// src/version.ts
|
|
34785
|
-
var VERSION = "1.1.
|
|
34785
|
+
var VERSION = "1.1.4";
|
|
34786
34786
|
|
|
34787
34787
|
// node_modules/@chrischall/mcp-utils/dist/session/index.js
|
|
34788
34788
|
import { existsSync, readFileSync, writeFileSync, mkdirSync, chmodSync, renameSync, unlinkSync } from "node:fs";
|
|
@@ -35027,14 +35027,27 @@ function buildQuery(params) {
|
|
|
35027
35027
|
return pairs.join("&");
|
|
35028
35028
|
}
|
|
35029
35029
|
var SimplePracticeClient = class {
|
|
35030
|
-
|
|
35030
|
+
/**
|
|
35031
|
+
* The session store, as it is on disk NOW.
|
|
35032
|
+
*
|
|
35033
|
+
* Another server process (Claude Desktop beside Claude Code) shares the
|
|
35034
|
+
* session file, and `SessionStore` reads it only in its constructor, then
|
|
35035
|
+
* rewrites the whole file from its in-memory Map on every add/remove. Held
|
|
35036
|
+
* for the life of the process, that snapshot would write a session another
|
|
35037
|
+
* process signed out of straight back to disk, or drop one it just created.
|
|
35038
|
+
* So by default every access opens the store afresh; an injected store
|
|
35039
|
+
* (tests) is used as given.
|
|
35040
|
+
*/
|
|
35041
|
+
openStore;
|
|
35031
35042
|
fetchImpl;
|
|
35032
35043
|
/** A practice learned at runtime — from a sign-in link, or named on a tool call. */
|
|
35033
35044
|
adoptedHost = null;
|
|
35034
35045
|
constructor(opts = {}) {
|
|
35035
35046
|
this.fetchImpl = opts.fetchImpl ?? globalThis.fetch;
|
|
35036
|
-
|
|
35037
|
-
|
|
35047
|
+
const injected = opts.store;
|
|
35048
|
+
const filePath = sessionFilePath();
|
|
35049
|
+
this.openStore = injected ? () => injected : () => new SessionStore({
|
|
35050
|
+
filePath,
|
|
35038
35051
|
keyOf: (session) => session.host,
|
|
35039
35052
|
normalizeKey: (key) => key.toLowerCase()
|
|
35040
35053
|
});
|
|
@@ -35079,7 +35092,7 @@ var SimplePracticeClient = class {
|
|
|
35079
35092
|
*/
|
|
35080
35093
|
mostRecentSessionHost() {
|
|
35081
35094
|
let newest = null;
|
|
35082
|
-
for (const session of this.
|
|
35095
|
+
for (const session of this.openStore().list()) {
|
|
35083
35096
|
if (!newest || session.createdAt > newest.createdAt) newest = session;
|
|
35084
35097
|
}
|
|
35085
35098
|
return newest?.host ?? null;
|
|
@@ -35160,17 +35173,17 @@ var SimplePracticeClient = class {
|
|
|
35160
35173
|
}
|
|
35161
35174
|
getSession() {
|
|
35162
35175
|
const host = this.knownPortalHost();
|
|
35163
|
-
return host ? this.
|
|
35176
|
+
return host ? this.openStore().get(host) : null;
|
|
35164
35177
|
}
|
|
35165
35178
|
saveSession(cookie) {
|
|
35166
35179
|
const host = this.requireConfig();
|
|
35167
35180
|
const session = { host, cookie, createdAt: (/* @__PURE__ */ new Date()).toISOString() };
|
|
35168
|
-
this.
|
|
35181
|
+
this.openStore().add(session);
|
|
35169
35182
|
return session;
|
|
35170
35183
|
}
|
|
35171
35184
|
clearSession() {
|
|
35172
35185
|
const host = this.knownPortalHost();
|
|
35173
|
-
return host ? this.
|
|
35186
|
+
return host ? this.openStore().remove(host) : false;
|
|
35174
35187
|
}
|
|
35175
35188
|
requireSession() {
|
|
35176
35189
|
const session = this.getSession();
|
package/dist/client.js
CHANGED
|
@@ -20,19 +20,32 @@ export function buildQuery(params) {
|
|
|
20
20
|
return pairs.join('&');
|
|
21
21
|
}
|
|
22
22
|
export class SimplePracticeClient {
|
|
23
|
-
|
|
23
|
+
/**
|
|
24
|
+
* The session store, as it is on disk NOW.
|
|
25
|
+
*
|
|
26
|
+
* Another server process (Claude Desktop beside Claude Code) shares the
|
|
27
|
+
* session file, and `SessionStore` reads it only in its constructor, then
|
|
28
|
+
* rewrites the whole file from its in-memory Map on every add/remove. Held
|
|
29
|
+
* for the life of the process, that snapshot would write a session another
|
|
30
|
+
* process signed out of straight back to disk, or drop one it just created.
|
|
31
|
+
* So by default every access opens the store afresh; an injected store
|
|
32
|
+
* (tests) is used as given.
|
|
33
|
+
*/
|
|
34
|
+
openStore;
|
|
24
35
|
fetchImpl;
|
|
25
36
|
/** A practice learned at runtime — from a sign-in link, or named on a tool call. */
|
|
26
37
|
adoptedHost = null;
|
|
27
38
|
constructor(opts = {}) {
|
|
28
39
|
this.fetchImpl = opts.fetchImpl ?? globalThis.fetch;
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
40
|
+
const injected = opts.store;
|
|
41
|
+
const filePath = sessionFilePath();
|
|
42
|
+
this.openStore = injected
|
|
43
|
+
? () => injected
|
|
44
|
+
: () => new SessionStore({
|
|
45
|
+
filePath,
|
|
46
|
+
keyOf: (session) => session.host,
|
|
47
|
+
normalizeKey: (key) => key.toLowerCase(),
|
|
48
|
+
});
|
|
36
49
|
}
|
|
37
50
|
/**
|
|
38
51
|
* Which practice this server is talking to, and how it found out.
|
|
@@ -76,7 +89,7 @@ export class SimplePracticeClient {
|
|
|
76
89
|
*/
|
|
77
90
|
mostRecentSessionHost() {
|
|
78
91
|
let newest = null;
|
|
79
|
-
for (const session of this.
|
|
92
|
+
for (const session of this.openStore().list()) {
|
|
80
93
|
if (!newest || session.createdAt > newest.createdAt)
|
|
81
94
|
newest = session;
|
|
82
95
|
}
|
|
@@ -159,12 +172,12 @@ export class SimplePracticeClient {
|
|
|
159
172
|
}
|
|
160
173
|
getSession() {
|
|
161
174
|
const host = this.knownPortalHost();
|
|
162
|
-
return host ? this.
|
|
175
|
+
return host ? this.openStore().get(host) : null;
|
|
163
176
|
}
|
|
164
177
|
saveSession(cookie) {
|
|
165
178
|
const host = this.requireConfig();
|
|
166
179
|
const session = { host, cookie, createdAt: new Date().toISOString() };
|
|
167
|
-
this.
|
|
180
|
+
this.openStore().add(session);
|
|
168
181
|
return session;
|
|
169
182
|
}
|
|
170
183
|
clearSession() {
|
|
@@ -172,7 +185,7 @@ export class SimplePracticeClient {
|
|
|
172
185
|
// Not knowing the practice is the same outcome as having no session for
|
|
173
186
|
// it: nothing to sign out of. Throwing would make sign-out the one tool
|
|
174
187
|
// that fails when it has nothing to do.
|
|
175
|
-
return host ? this.
|
|
188
|
+
return host ? this.openStore().remove(host) : false;
|
|
176
189
|
}
|
|
177
190
|
requireSession() {
|
|
178
191
|
const session = this.getSession();
|
package/dist/version.js
CHANGED
|
@@ -2,4 +2,4 @@
|
|
|
2
2
|
* Single source of truth for the server version. release-please rewrites the
|
|
3
3
|
* literal below; every other file imports VERSION rather than repeating it.
|
|
4
4
|
*/
|
|
5
|
-
export const VERSION = '1.1.
|
|
5
|
+
export const VERSION = '1.1.4'; // x-release-please-version
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "simplepractice-mcp",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.4",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"mcpName": "io.github.chrischall/simplepractice-mcp",
|
|
6
6
|
"description": "SimplePractice Client Portal MCP server for Claude — developed and maintained by AI (Claude Code)",
|
package/server.json
CHANGED
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
"url": "https://github.com/chrischall/simplepractice-mcp",
|
|
7
7
|
"source": "github"
|
|
8
8
|
},
|
|
9
|
-
"version": "1.1.
|
|
9
|
+
"version": "1.1.4",
|
|
10
10
|
"packages": [
|
|
11
11
|
{
|
|
12
12
|
"registryType": "npm",
|
|
13
13
|
"identifier": "simplepractice-mcp",
|
|
14
|
-
"version": "1.1.
|
|
14
|
+
"version": "1.1.4",
|
|
15
15
|
"transport": {
|
|
16
16
|
"type": "stdio"
|
|
17
17
|
},
|