@firfi/huly-mcp 0.10.2 → 0.10.3

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/index.cjs CHANGED
@@ -171326,7 +171326,7 @@ var PostHog = class extends PostHogBackendClient {
171326
171326
  };
171327
171327
 
171328
171328
  // src/version.ts
171329
- var VERSION = true ? "0.10.1" : "0.0.0-dev";
171329
+ var VERSION = true ? "0.10.3" : "0.0.0-dev";
171330
171330
 
171331
171331
  // src/telemetry/posthog.ts
171332
171332
  var POSTHOG_API_KEY = "phc_TGfFqCGdnF0p68wuFzd5WSw1IsBvOJW0YgoMJDyZPjm";
@@ -172318,6 +172318,11 @@ var buildDocumentUrl = (baseUrl, workspaceUrlSlug, title, id) => {
172318
172318
  return UrlString.make(`${trimmedBase}/workbench/${workspaceUrlSlug}/document/${pathSegment}`);
172319
172319
  };
172320
172320
  var buildDocumentUrlFromConfig = (config3, title, id) => buildDocumentUrl(config3.baseUrl, config3.workspaceUrlSlug, title, id);
172321
+ var buildContactUrl = (baseUrl, workspaceUrlSlug, id) => {
172322
+ const trimmedBase = baseUrl.replace(/\/+$/, "");
172323
+ return UrlString.make(`${trimmedBase}/workbench/${workspaceUrlSlug}/contact/${id}`);
172324
+ };
172325
+ var buildContactUrlFromConfig = (config3, id) => buildContactUrl(config3.baseUrl, config3.workspaceUrlSlug, id);
172321
172326
 
172322
172327
  // src/huly/operations/documents-edit.ts
172323
172328
  var editDocument = (params) => Effect_exports.gen(function* () {
@@ -178888,13 +178893,17 @@ var listOrganizations = (params) => Effect_exports.gen(function* () {
178888
178893
  sort: { modifiedOn: import_core31.SortingOrder.Descending }
178889
178894
  }
178890
178895
  );
178891
- return orgs.map((org) => ({
178892
- id: OrganizationId.make(org._id),
178893
- name: org.name,
178894
- city: org.city,
178895
- members: org.members,
178896
- modifiedOn: org.modifiedOn
178897
- }));
178896
+ return orgs.map((org) => {
178897
+ const id = OrganizationId.make(org._id);
178898
+ return {
178899
+ id,
178900
+ name: org.name,
178901
+ city: org.city,
178902
+ members: org.members,
178903
+ url: buildContactUrlFromConfig(client.documentUrlConfig, id),
178904
+ modifiedOn: org.modifiedOn
178905
+ };
178906
+ });
178898
178907
  });
178899
178908
  var createOrganization = (params) => Effect_exports.gen(function* () {
178900
178909
  const client = yield* HulyClient;
@@ -178940,12 +178949,14 @@ var getOrganization = (params) => Effect_exports.gen(function* () {
178940
178949
  org.description,
178941
178950
  "markdown"
178942
178951
  ) : void 0;
178952
+ const id = OrganizationId.make(org._id);
178943
178953
  return {
178944
- id: OrganizationId.make(org._id),
178954
+ id,
178945
178955
  name: org.name,
178946
178956
  city: org.city || void 0,
178947
178957
  description: descriptionText,
178948
178958
  members: org.members,
178959
+ url: buildContactUrlFromConfig(client.documentUrlConfig, id),
178949
178960
  modifiedOn: org.modifiedOn
178950
178961
  };
178951
178962
  });
@@ -179199,11 +179210,13 @@ var listPersons = (params) => Effect_exports.gen(function* () {
179199
179210
  const emailMap = yield* batchGetEmailsForPersons(client, personIds);
179200
179211
  return persons.map((person) => {
179201
179212
  const emailValue = emailMap.get(person._id);
179213
+ const id = PersonId.make(person._id);
179202
179214
  return {
179203
- id: PersonId.make(person._id),
179215
+ id,
179204
179216
  name: PersonName.make(person.name),
179205
179217
  city: person.city,
179206
179218
  email: emailValue !== void 0 ? Email.make(emailValue) : void 0,
179219
+ url: buildContactUrlFromConfig(client.documentUrlConfig, id),
179207
179220
  modifiedOn: person.modifiedOn
179208
179221
  };
179209
179222
  });
@@ -179225,8 +179238,9 @@ var getPerson = (params) => Effect_exports.gen(function* () {
179225
179238
  const organizations = yield* findOrganizationsForPerson(client, person._id);
179226
179239
  const { firstName, lastName } = parseName(person.name);
179227
179240
  const emailChannel = channels.find((c) => c.provider === contact.channelProvider.Email);
179241
+ const id = PersonId.make(person._id);
179228
179242
  return {
179229
- id: PersonId.make(person._id),
179243
+ id,
179230
179244
  name: PersonName.make(person.name),
179231
179245
  firstName,
179232
179246
  lastName,
@@ -179237,6 +179251,7 @@ var getPerson = (params) => Effect_exports.gen(function* () {
179237
179251
  value: c.value
179238
179252
  })),
179239
179253
  organizations: organizations.length > 0 ? organizations : void 0,
179254
+ url: buildContactUrlFromConfig(client.documentUrlConfig, id),
179240
179255
  modifiedOn: person.modifiedOn,
179241
179256
  createdOn: person.createdOn
179242
179257
  };
@@ -179326,12 +179341,14 @@ var listEmployees = (params) => Effect_exports.gen(function* () {
179326
179341
  const emailMap = yield* batchGetEmailsForPersons(client, employeeIds);
179327
179342
  return employees.map((emp) => {
179328
179343
  const emailValue = emailMap.get(emp._id);
179344
+ const id = PersonId.make(emp._id);
179329
179345
  return {
179330
- id: PersonId.make(emp._id),
179346
+ id,
179331
179347
  name: PersonName.make(emp.name),
179332
179348
  email: emailValue !== void 0 ? Email.make(emailValue) : void 0,
179333
179349
  position: emp.position ?? void 0,
179334
179350
  active: emp.active,
179351
+ url: buildContactUrlFromConfig(client.documentUrlConfig, id),
179335
179352
  modifiedOn: emp.modifiedOn
179336
179353
  };
179337
179354
  });