@alfe.ai/microsoft-mcp 0.1.8 → 0.1.9
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/dist/server.d.cts +31 -0
- package/dist/server.d.ts +31 -0
- package/package.json +2 -2
package/dist/server.d.cts
CHANGED
|
@@ -1274,10 +1274,41 @@ declare class ConnectCredentialsApi extends ApiBase {
|
|
|
1274
1274
|
brokerName?: string;
|
|
1275
1275
|
accountNumber?: string;
|
|
1276
1276
|
accessToken: string;
|
|
1277
|
+
/**
|
|
1278
|
+
* The stable per-grant Connection key (`ctid:<userId>`) this account
|
|
1279
|
+
* belongs to. Every trading account under one cTrader login shares one
|
|
1280
|
+
* grant (one OAuth token), so this is the identifier the MCP server
|
|
1281
|
+
* passes to `refreshCTraderAccount()` to rotate the token for the whole
|
|
1282
|
+
* grant on a `CH_ACCESS_TOKEN_INVALID` expiry. Empty string when the
|
|
1283
|
+
* server did not supply one (legacy rows) — such an account can still
|
|
1284
|
+
* trade with its current token but cannot self-refresh.
|
|
1285
|
+
*/
|
|
1286
|
+
accountIdentifier: string;
|
|
1277
1287
|
}[];
|
|
1278
1288
|
clientId: string;
|
|
1279
1289
|
clientSecret: string;
|
|
1280
1290
|
}>;
|
|
1291
|
+
/**
|
|
1292
|
+
* Pattern A: refresh a specific cTrader grant by its stable
|
|
1293
|
+
* `accountIdentifier` (`ctid:<userId>` from `getCTraderAccounts()`).
|
|
1294
|
+
*
|
|
1295
|
+
* cTrader access tokens live ~30 days; the `getCTraderAccounts()` /
|
|
1296
|
+
* credentials reads serve the STORED token without refreshing, so refresh is
|
|
1297
|
+
* the consumer's job. `@alfe.ai/ctrader-mcp` calls this when the cTrader Open
|
|
1298
|
+
* API rejects an account-auth with `CH_ACCESS_TOKEN_INVALID`, then re-runs
|
|
1299
|
+
* the socket handshake with the returned `accessToken`.
|
|
1300
|
+
*
|
|
1301
|
+
* Refreshing one grant rotates the single OAuth token that covers EVERY
|
|
1302
|
+
* trading account under that login. cTrader's refresh token itself does not
|
|
1303
|
+
* expire but may rotate on refresh (`rotatesRefreshToken: true`); connect
|
|
1304
|
+
* persists the rotated refresh token server-side, so the caller only needs
|
|
1305
|
+
* the new `accessToken`. Mirrors `refreshXeroAccountToken`.
|
|
1306
|
+
*/
|
|
1307
|
+
refreshCTraderAccount(accountIdentifier: string): Promise<{
|
|
1308
|
+
accessToken: string;
|
|
1309
|
+
accessTokenExpiresAt: string;
|
|
1310
|
+
expiresAt: string;
|
|
1311
|
+
}>;
|
|
1281
1312
|
/**
|
|
1282
1313
|
* @deprecated Returns a single primary credential blob. Use
|
|
1283
1314
|
* `getShopifyAccounts()` for the multi-account shape required by Pattern A
|
package/dist/server.d.ts
CHANGED
|
@@ -1274,10 +1274,41 @@ declare class ConnectCredentialsApi extends ApiBase {
|
|
|
1274
1274
|
brokerName?: string;
|
|
1275
1275
|
accountNumber?: string;
|
|
1276
1276
|
accessToken: string;
|
|
1277
|
+
/**
|
|
1278
|
+
* The stable per-grant Connection key (`ctid:<userId>`) this account
|
|
1279
|
+
* belongs to. Every trading account under one cTrader login shares one
|
|
1280
|
+
* grant (one OAuth token), so this is the identifier the MCP server
|
|
1281
|
+
* passes to `refreshCTraderAccount()` to rotate the token for the whole
|
|
1282
|
+
* grant on a `CH_ACCESS_TOKEN_INVALID` expiry. Empty string when the
|
|
1283
|
+
* server did not supply one (legacy rows) — such an account can still
|
|
1284
|
+
* trade with its current token but cannot self-refresh.
|
|
1285
|
+
*/
|
|
1286
|
+
accountIdentifier: string;
|
|
1277
1287
|
}[];
|
|
1278
1288
|
clientId: string;
|
|
1279
1289
|
clientSecret: string;
|
|
1280
1290
|
}>;
|
|
1291
|
+
/**
|
|
1292
|
+
* Pattern A: refresh a specific cTrader grant by its stable
|
|
1293
|
+
* `accountIdentifier` (`ctid:<userId>` from `getCTraderAccounts()`).
|
|
1294
|
+
*
|
|
1295
|
+
* cTrader access tokens live ~30 days; the `getCTraderAccounts()` /
|
|
1296
|
+
* credentials reads serve the STORED token without refreshing, so refresh is
|
|
1297
|
+
* the consumer's job. `@alfe.ai/ctrader-mcp` calls this when the cTrader Open
|
|
1298
|
+
* API rejects an account-auth with `CH_ACCESS_TOKEN_INVALID`, then re-runs
|
|
1299
|
+
* the socket handshake with the returned `accessToken`.
|
|
1300
|
+
*
|
|
1301
|
+
* Refreshing one grant rotates the single OAuth token that covers EVERY
|
|
1302
|
+
* trading account under that login. cTrader's refresh token itself does not
|
|
1303
|
+
* expire but may rotate on refresh (`rotatesRefreshToken: true`); connect
|
|
1304
|
+
* persists the rotated refresh token server-side, so the caller only needs
|
|
1305
|
+
* the new `accessToken`. Mirrors `refreshXeroAccountToken`.
|
|
1306
|
+
*/
|
|
1307
|
+
refreshCTraderAccount(accountIdentifier: string): Promise<{
|
|
1308
|
+
accessToken: string;
|
|
1309
|
+
accessTokenExpiresAt: string;
|
|
1310
|
+
expiresAt: string;
|
|
1311
|
+
}>;
|
|
1281
1312
|
/**
|
|
1282
1313
|
* @deprecated Returns a single primary credential blob. Use
|
|
1283
1314
|
* `getShopifyAccounts()` for the multi-account shape required by Pattern A
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@alfe.ai/microsoft-mcp",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.9",
|
|
4
4
|
"description": "Microsoft 365 MCP server — multi-account Microsoft Graph access using Alfe OAuth credentials with server-mediated token refresh",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/server.js",
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"@modelcontextprotocol/sdk": "^1.29.0",
|
|
23
23
|
"zod": "^4.0.5",
|
|
24
24
|
"@alfe.ai/config": "0.4.1",
|
|
25
|
-
"@alfe.ai/agent-api-client": "0.
|
|
25
|
+
"@alfe.ai/agent-api-client": "0.16.0"
|
|
26
26
|
},
|
|
27
27
|
"license": "UNLICENSED",
|
|
28
28
|
"homepage": "https://alfe.ai",
|