@browsa/mcp 0.11.0 → 0.12.0
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 +13 -11
- package/dist/server.js +98 -13
- package/manifest.json +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -214,7 +214,7 @@ Everything else from 0.5 is in groups you turn on with `BROWSA_MCP_TOOLS` (comma
|
|
|
214
214
|
| `cdp` | `start_browser`, `stop_browser` (a CDP address, to drive the browser from your own code) |
|
|
215
215
|
| `captcha_page` | `detect_captcha`, `solve_captcha_on_page`, `captcha_allowance`: captcha solving for a browser of your own, [below](#captchas-in-your-own-browser) |
|
|
216
216
|
| `captcha` | `solve_captcha_task` (Browsa's captcha API, for pages outside a Browsa browser; the answer says what the solve cost), `list_captcha_types` (every type with its parameters, price and measured pass rate), `report_captcha_result` (tell Browsa whether the site took a solution; an incorrect report refunds that solve once, within limits: within 15 minutes of the solve, and a capped share of the workspace's solves of the last 24 hours. The answer's `refunded` says whether it did) |
|
|
217
|
-
| `profiles` | `list_profiles`, `create_profile`, `open_profile`, `close_profile`, `update_profile`, `delete_profile`, `profile_runs`: [saved profiles](#saved-profiles) |
|
|
217
|
+
| `profiles` | `list_profiles`, `create_profile`, `open_profile`, `close_profile`, `update_profile`, `delete_profile`, `profile_runs`, `clone_profile`, `bulk_profiles`: [saved profiles](#saved-profiles) |
|
|
218
218
|
| `admin` | `credits`, `list_browsers`, `list_identities`, `proxy_network`, `list_llm_keys`, `list_models` |
|
|
219
219
|
| `all` | every group |
|
|
220
220
|
|
|
@@ -226,19 +226,21 @@ A tool name works too (`BROWSA_MCP_TOOLS=run_task,credits`). A leading `-` takes
|
|
|
226
226
|
|
|
227
227
|
### Saved profiles
|
|
228
228
|
|
|
229
|
-
A saved profile is a browser that keeps its cookies, logins and fingerprint between sessions: log in once, and every later browser on it starts logged in. The
|
|
229
|
+
A saved profile is a browser that keeps its cookies, logins and fingerprint between sessions: log in once, and every later browser on it starts logged in. The nine tools are in the `profiles` group, so they are not in the default ten (`BROWSA_MCP_TOOLS=profiles`).
|
|
230
230
|
|
|
231
231
|
| Tool | Does |
|
|
232
232
|
|---|---|
|
|
233
|
-
| `list_profiles` | Saved profiles: `profile_id`, `name`, `notes`, `status`, `open_session` |
|
|
234
|
-
| `create_profile` | Create one (`name`, `notes`, `country`, `os_type`, `captcha`, `proxy`) and open its first browser; charged on creation and every 30 days |
|
|
235
|
-
| `open_profile` | Open a browser on it (`start_url`, `ttl`, `idle_timeout`, `country`); returns `cdp_http`, `cdp_url`, `live_url` |
|
|
233
|
+
| `list_profiles` | Saved profiles: `profile_id`, `name`, `notes`, `tags`, `favorite`, `exit_setting`, `status`, `open_session`. Filters: `tag`, `favorite`, `include_deleted`, `limit` |
|
|
234
|
+
| `create_profile` | Create one (`name`, `notes`, `tags`, `favorite`, `country`, `os_type`, `captcha`, `proxy`) and open its first browser; charged on creation and every 30 days |
|
|
235
|
+
| `open_profile` | Open a browser on it (`start_url`, `ttl`, `idle_timeout`, `country`, `restart`); returns `cdp_http`, `cdp_url`, `live_url`. A browser on a saved profile is $0.10 an hour, billed per minute; unused time is refunded when it closes. If one is already open, that browser is returned and nothing is charged (`restart: true` opens a new one) |
|
|
236
236
|
| `close_profile` | Stop its open browser and save the cookies; the profile stays |
|
|
237
|
-
| `update_profile` | Set `name`, `notes` or
|
|
237
|
+
| `update_profile` | Set `name`, `notes`, `tags` (replaces the list), `favorite` or `location` (`{network, country}`, `{proxy_id}`, `{none: true}` or `{country}`; needs no open browser, applies from the next open); `""` clears name and notes |
|
|
238
|
+
| `clone_profile` | A new profile with the settings of another (`name`, `tags`; `proxy` or `proxy_id` only when the source's exit cannot be copied); new fingerprint, empty, charged like `create_profile` |
|
|
239
|
+
| `bulk_profiles` | `ids` (1 to 50) and `action`: `close`, `delete`, `tag`, `untag` (with `tags`), `favorite`, `unfavorite`; one result per id |
|
|
238
240
|
| `delete_profile` | Delete it for good, with its cookies |
|
|
239
241
|
| `profile_runs` | Its browser sessions, newest first, with `cost_usd` |
|
|
240
242
|
|
|
241
|
-
`list_identities` (admin group) is the older name for `list_profiles` and keeps working. Pass a profile's id to `run_task` or `start_browser` as `profile_id` to run on it.
|
|
243
|
+
Errors keep the API's `code`: `SESSION_OPEN` (close the browser first), `EXIT_CHANGING` (retry in a few seconds), `PROXY_NOT_COPYABLE`, `NOT_A_SAVED_PROFILE`, `NO_OPEN_SESSION`. `list_identities` (admin group) is the older name for `list_profiles` and keeps working. Pass a profile's id to `run_task` or `start_browser` as `profile_id` to run on it.
|
|
242
244
|
|
|
243
245
|
### What the tool list costs
|
|
244
246
|
|
|
@@ -254,9 +256,9 @@ The tool definitions a client loads before the first message, per setting. Token
|
|
|
254
256
|
| `schedules` | `schedules,-core` | 2 | 505 |
|
|
255
257
|
| `webhooks` | `webhooks,-core` | 3 | 281 |
|
|
256
258
|
| `cdp` | `cdp,-core` | 2 | 795 |
|
|
257
|
-
| `profiles` | `profiles,-core` |
|
|
259
|
+
| `profiles` | `profiles,-core` | 9 | 2,264 |
|
|
258
260
|
| `admin` | `admin,-core` | 6 | 640 |
|
|
259
|
-
| everything | `all` |
|
|
261
|
+
| everything | `all` | 46 | 9,843 |
|
|
260
262
|
|
|
261
263
|
A group adds its row to the default's 1,903. Prompts are fetched only when picked and add nothing. The annotations are about 200 of the default's tokens (0.8.0 listed the same nine tools in 1,244).
|
|
262
264
|
|
|
@@ -265,8 +267,8 @@ A group adds its row to the default's 1,903. Prompts are fetched only when picke
|
|
|
265
267
|
| Hint | Tools |
|
|
266
268
|
|---|---|
|
|
267
269
|
| Read-only (`readOnlyHint: true`): changes nothing, spends nothing | `observe`, `read`, `screenshot`, `secrets`, `get_job`, `list_job_files`, `list_robots`, `get_robot_run`, `list_schedules`, `list_webhooks`, `list_captcha_types`, `detect_captcha`, `captcha_allowance`, `credits`, `list_browsers`, `list_identities`, `list_profiles`, `profile_runs`, `proxy_network`, `list_llm_keys`, `list_models` |
|
|
268
|
-
| Can change something for good (`destructiveHint: true`) | `act`, `flow`, `run_task`, `run_robot` (the page decides what a click does), `close`, `stop_browser`, `close_profile`, `delete_profile`, `cancel_job`, `delete_webhook` |
|
|
269
|
-
| Writes, not destructive | `open`, `handoff`, `respond_to_job`, `create_schedule`, `create_webhook`, `start_browser`, `create_profile`, `open_profile`, `update_profile`, `solve_captcha_task`, `solve_captcha_on_page`, `report_captcha_result` |
|
|
270
|
+
| Can change something for good (`destructiveHint: true`) | `act`, `flow`, `run_task`, `run_robot` (the page decides what a click does), `close`, `stop_browser`, `close_profile`, `delete_profile`, `bulk_profiles`, `cancel_job`, `delete_webhook` |
|
|
271
|
+
| Writes, not destructive | `open`, `handoff`, `respond_to_job`, `create_schedule`, `create_webhook`, `start_browser`, `create_profile`, `open_profile`, `update_profile`, `clone_profile`, `solve_captcha_task`, `solve_captcha_on_page`, `report_captcha_result` |
|
|
270
272
|
|
|
271
273
|
`detect_captcha` and `captcha_allowance` also say `openWorldHint: false`: they run inside the server process and make no request.
|
|
272
274
|
|
package/dist/server.js
CHANGED
|
@@ -682,7 +682,7 @@ var catalogue_snapshot_default = {
|
|
|
682
682
|
import { BrowsaError } from "browsa";
|
|
683
683
|
|
|
684
684
|
// src/config.ts
|
|
685
|
-
var VERSION = "0.
|
|
685
|
+
var VERSION = "0.12.0";
|
|
686
686
|
var USER_AGENT = `browsa-mcp/${VERSION}`;
|
|
687
687
|
var API_KEY = process.env.BROWSA_API_KEY?.trim() || void 0;
|
|
688
688
|
var BASE_URL = (process.env.BROWSA_BASE_URL || "https://browsa.io").replace(/\/+$/, "");
|
|
@@ -740,7 +740,7 @@ var GROUPS = {
|
|
|
740
740
|
cdp: ["start_browser", "stop_browser"],
|
|
741
741
|
captcha: ["solve_captcha_task", "list_captcha_types", "report_captcha_result"],
|
|
742
742
|
captcha_page: ["detect_captcha", "solve_captcha_on_page", "captcha_allowance"],
|
|
743
|
-
profiles: ["list_profiles", "create_profile", "open_profile", "close_profile", "update_profile", "delete_profile", "profile_runs"],
|
|
743
|
+
profiles: ["list_profiles", "create_profile", "open_profile", "close_profile", "update_profile", "delete_profile", "profile_runs", "clone_profile", "bulk_profiles"],
|
|
744
744
|
admin: ["credits", "list_browsers", "list_identities", "proxy_network", "list_llm_keys", "list_models"]
|
|
745
745
|
};
|
|
746
746
|
var CORE_TOOLS = ["open", "observe", "act", "read", "screenshot", "secrets", "handoff", "flow", "close", "fetch_page"];
|
|
@@ -1826,7 +1826,9 @@ var ANNOTATIONS = {
|
|
|
1826
1826
|
create_profile: write("Create a saved profile"),
|
|
1827
1827
|
open_profile: write("Open a saved profile"),
|
|
1828
1828
|
close_profile: destructive("Close a profile's browser", { idempotentHint: true }),
|
|
1829
|
-
update_profile: write("
|
|
1829
|
+
update_profile: write("Change a saved profile", { idempotentHint: true }),
|
|
1830
|
+
clone_profile: write("Clone a saved profile"),
|
|
1831
|
+
bulk_profiles: destructive("Act on several profiles"),
|
|
1830
1832
|
delete_profile: destructive("Delete a saved profile", { idempotentHint: true }),
|
|
1831
1833
|
profile_runs: read("A profile's sessions"),
|
|
1832
1834
|
proxy_network: read("Proxy network"),
|
|
@@ -3710,17 +3712,37 @@ var PROFILE_TOOLS = [
|
|
|
3710
3712
|
"close_profile",
|
|
3711
3713
|
"update_profile",
|
|
3712
3714
|
"delete_profile",
|
|
3713
|
-
"profile_runs"
|
|
3715
|
+
"profile_runs",
|
|
3716
|
+
"clone_profile",
|
|
3717
|
+
"bulk_profiles"
|
|
3714
3718
|
];
|
|
3719
|
+
var TAGS = {
|
|
3720
|
+
type: "array",
|
|
3721
|
+
items: { type: "string" },
|
|
3722
|
+
maxItems: 10,
|
|
3723
|
+
description: "Tags: at most 10, each 1 to 24 characters, no commas."
|
|
3724
|
+
};
|
|
3725
|
+
var LOCATION = {
|
|
3726
|
+
type: "object",
|
|
3727
|
+
description: `Where the profile's next browser leaves from. One of: {"network": "datacenter" or "residential", "country": "de"} (Browsa's proxy network), {"proxy_id": "px_..."} (a saved proxy), {"none": true} (no proxy), or {"country": "de"} alone (a new country on the proxy network). Only while no browser is open on the profile (409 SESSION_OPEN otherwise: close_profile first); it applies from the next open_profile.`,
|
|
3728
|
+
properties: {
|
|
3729
|
+
network: { type: "string", enum: ["datacenter", "residential"] },
|
|
3730
|
+
country: { type: "string", description: 'ISO-2, e.g. "de".' },
|
|
3731
|
+
proxy_id: { type: "string" },
|
|
3732
|
+
none: { type: "boolean", description: "true: no proxy." }
|
|
3733
|
+
}
|
|
3734
|
+
};
|
|
3715
3735
|
var profileTools = [
|
|
3716
3736
|
{
|
|
3717
3737
|
name: "list_profiles",
|
|
3718
|
-
description: "List saved profiles: browsers that keep cookies, logins and a fingerprint between sessions. Each row has id, name, notes, status and open_session (null when no browser is open on it). Pass the id to open_profile, or to run_task as profile_id. Free.",
|
|
3738
|
+
description: "List saved profiles: browsers that keep cookies, logins and a fingerprint between sessions. Each row has id, name, notes, tags, favorite, exit_setting, status and open_session (null when no browser is open on it). Pass the id to open_profile, or to run_task as profile_id. Free.",
|
|
3719
3739
|
inputSchema: {
|
|
3720
3740
|
type: "object",
|
|
3721
3741
|
properties: {
|
|
3722
3742
|
include_deleted: { type: "boolean", description: "Also list deleted profiles. Default false." },
|
|
3723
|
-
limit: { type: "integer", description: "1 to 200. Default 50." }
|
|
3743
|
+
limit: { type: "integer", description: "1 to 200. Default 50." },
|
|
3744
|
+
tag: { type: "string", description: "Only profiles carrying this tag." },
|
|
3745
|
+
favorite: { type: "boolean", description: "true: only favorites; false: only the others." }
|
|
3724
3746
|
}
|
|
3725
3747
|
}
|
|
3726
3748
|
},
|
|
@@ -3732,6 +3754,8 @@ var profileTools = [
|
|
|
3732
3754
|
properties: {
|
|
3733
3755
|
name: { type: "string", description: "A name for the profile, up to 80 characters." },
|
|
3734
3756
|
notes: { type: "string", description: "Free text about it, up to 1500 characters." },
|
|
3757
|
+
tags: TAGS,
|
|
3758
|
+
favorite: { type: "boolean", description: "Star the profile." },
|
|
3735
3759
|
country: { type: "string", description: 'ISO-2 country, e.g. "us". Takes effect only with a proxy.' },
|
|
3736
3760
|
os_type: { type: "string", description: 'Operating system the browser presents, e.g. "linux", "macos", "windows".' },
|
|
3737
3761
|
captcha: { type: "string", enum: ["auto", "off"], description: '"auto" (default): Browsa solves captcha widgets in this browser by itself, charged per solve. "off": it never touches the browser.' },
|
|
@@ -3744,7 +3768,7 @@ var profileTools = [
|
|
|
3744
3768
|
},
|
|
3745
3769
|
{
|
|
3746
3770
|
name: "open_profile",
|
|
3747
|
-
description: "Open a
|
|
3771
|
+
description: "Open a browser on a saved profile, with its cookies and logins. Billed per minute; unused time is refunded when it closes. If a browser is already open on the profile, that browser is returned as it is and nothing is charged (restart: true closes it and opens a new one). Returns the browser's cdp_http (the address to connect a CDP client to), cdp_url and live_url. If the profile's location is being changed, it answers EXIT_CHANGING: retry in a few seconds. Call close_profile when you are done.",
|
|
3748
3772
|
inputSchema: {
|
|
3749
3773
|
type: "object",
|
|
3750
3774
|
required: ["profile_id"],
|
|
@@ -3753,7 +3777,8 @@ var profileTools = [
|
|
|
3753
3777
|
start_url: { type: "string", description: "The page the browser opens on." },
|
|
3754
3778
|
ttl: { type: "string", description: 'How long to keep it, e.g. "30m", "8h" (up to 24h). Default 1h.' },
|
|
3755
3779
|
idle_timeout: { type: "string", description: 'Stop after this long with nothing connected, e.g. "10m"; "off" = never.' },
|
|
3756
|
-
country: { type: "string", description: 'ISO-2 country, e.g. "us".' }
|
|
3780
|
+
country: { type: "string", description: 'ISO-2 country, e.g. "us".' },
|
|
3781
|
+
restart: { type: "boolean", description: "Close the browser already open on the profile and open a new one (charged). Default false." }
|
|
3757
3782
|
}
|
|
3758
3783
|
}
|
|
3759
3784
|
},
|
|
@@ -3764,14 +3789,17 @@ var profileTools = [
|
|
|
3764
3789
|
},
|
|
3765
3790
|
{
|
|
3766
3791
|
name: "update_profile",
|
|
3767
|
-
description: "
|
|
3792
|
+
description: "Change a saved profile: name, notes, tags (replaces the whole list; [] clears it), favorite, or location (where its next browser leaves from). A field you leave out stays as it is, and an empty string clears name or notes. Changing the location needs no open browser. Free.",
|
|
3768
3793
|
inputSchema: {
|
|
3769
3794
|
type: "object",
|
|
3770
3795
|
required: ["profile_id"],
|
|
3771
3796
|
properties: {
|
|
3772
3797
|
profile_id: ID,
|
|
3773
3798
|
name: { type: "string", description: "New name, up to 80 characters." },
|
|
3774
|
-
notes: { type: "string", description: "New notes, up to 1500 characters." }
|
|
3799
|
+
notes: { type: "string", description: "New notes, up to 1500 characters." },
|
|
3800
|
+
tags: TAGS,
|
|
3801
|
+
favorite: { type: "boolean", description: "Star or unstar the profile." },
|
|
3802
|
+
location: LOCATION
|
|
3775
3803
|
}
|
|
3776
3804
|
}
|
|
3777
3805
|
},
|
|
@@ -3788,6 +3816,34 @@ var profileTools = [
|
|
|
3788
3816
|
required: ["profile_id"],
|
|
3789
3817
|
properties: { profile_id: ID, limit: { type: "integer", description: "1 to 200. Default 50." } }
|
|
3790
3818
|
}
|
|
3819
|
+
},
|
|
3820
|
+
{
|
|
3821
|
+
name: "clone_profile",
|
|
3822
|
+
description: "Make a new saved profile with the settings of another (OS, browser, screen, country, proxy network and country, and its tags unless you send tags). It gets a new fingerprint and starts empty: no cookies, logins or notes. It opens its first browser and is charged like create_profile. A source on your own inline proxy cannot be copied (PROXY_NOT_COPYABLE): send proxy or proxy_id. Call close_profile when you are done with the browser.",
|
|
3823
|
+
inputSchema: {
|
|
3824
|
+
type: "object",
|
|
3825
|
+
required: ["profile_id"],
|
|
3826
|
+
properties: {
|
|
3827
|
+
profile_id: ID,
|
|
3828
|
+
name: { type: "string", description: `Name of the copy, up to 80 characters. Default: the source's name plus " (copy)".` },
|
|
3829
|
+
tags: TAGS,
|
|
3830
|
+
proxy: { type: "object", nullable: true, description: "Only for a source whose exit cannot be copied: the copy's proxy, as on create_profile; null for none." },
|
|
3831
|
+
proxy_id: { type: "string", description: "Only for a source whose exit cannot be copied: a saved proxy." }
|
|
3832
|
+
}
|
|
3833
|
+
}
|
|
3834
|
+
},
|
|
3835
|
+
{
|
|
3836
|
+
name: "bulk_profiles",
|
|
3837
|
+
description: "One action on 1 to 50 saved profiles: close (their open browsers), delete (for good), tag or untag (need tags), favorite or unfavorite. Each id is handled on its own; the answer has one result per id (ok, or an error code such as NOT_FOUND). There is no bulk open.",
|
|
3838
|
+
inputSchema: {
|
|
3839
|
+
type: "object",
|
|
3840
|
+
required: ["ids", "action"],
|
|
3841
|
+
properties: {
|
|
3842
|
+
ids: { type: "array", items: { type: "string" }, minItems: 1, maxItems: 50, description: "Profile ids." },
|
|
3843
|
+
action: { type: "string", enum: ["close", "delete", "tag", "untag", "favorite", "unfavorite"] },
|
|
3844
|
+
tags: TAGS
|
|
3845
|
+
}
|
|
3846
|
+
}
|
|
3791
3847
|
}
|
|
3792
3848
|
];
|
|
3793
3849
|
function ok2(payload) {
|
|
@@ -3802,6 +3858,9 @@ function profileView(a) {
|
|
|
3802
3858
|
profile_id: a.id,
|
|
3803
3859
|
name: a.name ?? a.persona ?? "",
|
|
3804
3860
|
notes: a.notes ?? "",
|
|
3861
|
+
...a.tags != null ? { tags: a.tags } : {},
|
|
3862
|
+
...a.favorite != null ? { favorite: a.favorite } : {},
|
|
3863
|
+
...a.exit_setting != null ? { exit_setting: a.exit_setting } : {},
|
|
3805
3864
|
status: a.status,
|
|
3806
3865
|
open_session: a.open_session ?? null,
|
|
3807
3866
|
created_at: a.created_at
|
|
@@ -3821,25 +3880,28 @@ function browserView(a) {
|
|
|
3821
3880
|
}
|
|
3822
3881
|
async function callProfiles(name, args) {
|
|
3823
3882
|
try {
|
|
3824
|
-
if (
|
|
3883
|
+
if (!["list_profiles", "create_profile", "bulk_profiles"].includes(name) && !args.profile_id) return fail2("profile_id is required");
|
|
3825
3884
|
switch (name) {
|
|
3826
3885
|
case "list_profiles": {
|
|
3827
3886
|
const q = new URLSearchParams();
|
|
3828
3887
|
if (Number(args.limit) > 0) q.set("limit", String(Math.floor(Number(args.limit))));
|
|
3829
3888
|
if (args.include_deleted === true) q.set("include_deleted", "true");
|
|
3889
|
+
if (typeof args.tag === "string" && args.tag) q.set("tag", args.tag);
|
|
3890
|
+
if (typeof args.favorite === "boolean") q.set("favorite", String(args.favorite));
|
|
3830
3891
|
const s = q.toString();
|
|
3831
3892
|
const body = await apiGet(`/v1/profiles${s ? `?${s}` : ""}`);
|
|
3832
3893
|
return ok2({ profiles: (body?.agents ?? []).map(profileView) });
|
|
3833
3894
|
}
|
|
3834
3895
|
case "create_profile": {
|
|
3835
3896
|
const body = {};
|
|
3836
|
-
for (const k of ["name", "notes", "country", "os_type", "captcha", "proxy"]) if (args[k] != null) body[k] = args[k];
|
|
3897
|
+
for (const k of ["name", "notes", "tags", "favorite", "country", "os_type", "captcha", "proxy"]) if (args[k] != null) body[k] = args[k];
|
|
3837
3898
|
return ok2(browserView(await apiPost("/v1/profiles", body)));
|
|
3838
3899
|
}
|
|
3839
3900
|
case "open_profile": {
|
|
3840
3901
|
const body = {};
|
|
3841
3902
|
if (args.start_url != null) body.initial_url = args.start_url;
|
|
3842
3903
|
for (const k of ["ttl", "idle_timeout", "country"]) if (args[k] != null) body[k] = args[k];
|
|
3904
|
+
if (args.restart === true) body.restart = true;
|
|
3843
3905
|
return ok2(browserView(await apiPost(`/v1/profiles/${seg(args.profile_id)}/sessions`, body)));
|
|
3844
3906
|
}
|
|
3845
3907
|
case "close_profile": {
|
|
@@ -3854,9 +3916,32 @@ async function callProfiles(name, args) {
|
|
|
3854
3916
|
const body = {};
|
|
3855
3917
|
if (typeof args.name === "string") body.name = args.name;
|
|
3856
3918
|
if (typeof args.notes === "string") body.notes = args.notes;
|
|
3857
|
-
if (
|
|
3919
|
+
if (Array.isArray(args.tags)) body.tags = args.tags;
|
|
3920
|
+
if (typeof args.favorite === "boolean") body.favorite = args.favorite;
|
|
3921
|
+
const loc = args.location;
|
|
3922
|
+
if (loc && typeof loc === "object") {
|
|
3923
|
+
if (loc.none === true) body.proxy = null;
|
|
3924
|
+
else if (typeof loc.proxy_id === "string") body.proxy_id = loc.proxy_id;
|
|
3925
|
+
else if (typeof loc.network === "string") body.proxy = { network: loc.network, ...typeof loc.country === "string" ? { country: loc.country } : {} };
|
|
3926
|
+
else if (typeof loc.country === "string") body.country = loc.country;
|
|
3927
|
+
else return fail2("location needs network, proxy_id, none or country");
|
|
3928
|
+
}
|
|
3929
|
+
if (!Object.keys(body).length) return fail2("send name, notes, tags, favorite or location");
|
|
3858
3930
|
return ok2(profileView(await apiPatch(`/v1/profiles/${seg(args.profile_id)}`, body)));
|
|
3859
3931
|
}
|
|
3932
|
+
case "clone_profile": {
|
|
3933
|
+
const body = {};
|
|
3934
|
+
for (const k of ["name", "tags", "proxy", "proxy_id"]) if (args[k] !== void 0) body[k] = args[k];
|
|
3935
|
+
return ok2(browserView(await apiPost(`/v1/profiles/${seg(args.profile_id)}/clone`, body)));
|
|
3936
|
+
}
|
|
3937
|
+
case "bulk_profiles": {
|
|
3938
|
+
if (!Array.isArray(args.ids) || !args.ids.length) return fail2("ids is required (1 to 50 profile ids)");
|
|
3939
|
+
if (!args.action) return fail2("action is required");
|
|
3940
|
+
const body = { ids: args.ids, action: args.action };
|
|
3941
|
+
if (Array.isArray(args.tags)) body.tags = args.tags;
|
|
3942
|
+
const r = await apiPost("/v1/profiles/bulk", body);
|
|
3943
|
+
return ok2({ results: r?.results ?? [] });
|
|
3944
|
+
}
|
|
3860
3945
|
case "delete_profile":
|
|
3861
3946
|
await apiDelete(`/v1/profiles/${seg(args.profile_id)}`);
|
|
3862
3947
|
return ok2({ deleted: args.profile_id });
|
package/manifest.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"manifest_version": "0.2",
|
|
3
3
|
"name": "browsa",
|
|
4
4
|
"display_name": "Browsa",
|
|
5
|
-
"version": "0.
|
|
5
|
+
"version": "0.12.0",
|
|
6
6
|
"description": "Cloud browsers for AI agents, and captcha solving for a browser of your own.",
|
|
7
7
|
"long_description": "Browsa gives a model a real cloud browser (Phantom): it reads the page as compact text, acts with real input, types saved secrets it never sees, hands over to a person when a check needs one, and replays what it did with no model calls. For agents that drive their own browser, the captcha tools find the captcha in a page's HTML locally and return a solution with the step to apply it in that browser.",
|
|
8
8
|
"author": {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@browsa/mcp",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.12.0",
|
|
4
4
|
"mcpName": "io.browsa/browsa",
|
|
5
5
|
"description": "MCP server for Browsa: real cloud browsers (Phantom) for Claude, Cursor, VS Code and any MCP client, and captcha solving for a browser of your own",
|
|
6
6
|
"license": "MIT",
|