@cavuno/board 4.26.0 → 4.27.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.
Files changed (50) hide show
  1. package/CHANGELOG.md +89 -0
  2. package/dist/{_spec-EgN7VmAI.d.mts → _spec-B_pBNVUd.d.mts} +487 -47
  3. package/dist/{_spec-EgN7VmAI.d.ts → _spec-B_pBNVUd.d.ts} +487 -47
  4. package/dist/bin.mjs +7989 -10
  5. package/dist/{blog-BIjFcNcm.d.ts → blog-DzGRUsj5.d.ts} +1 -1
  6. package/dist/{blog-T7gQ0ciz.d.mts → blog-fhXRik6k.d.mts} +1 -1
  7. package/dist/{board-q0svBKW3.d.mts → board-DEiEHcpe.d.mts} +25 -4
  8. package/dist/{board-CsEAgsKh.d.ts → board-fVAXZ8T5.d.ts} +25 -4
  9. package/dist/{breadcrumbs-xuDid8BS.d.ts → breadcrumbs-DNaaP3xa.d.ts} +2 -2
  10. package/dist/{breadcrumbs-CFcCjuG7.d.mts → breadcrumbs-qE3CD--N.d.mts} +2 -2
  11. package/dist/browser/cavuno-board.global.min.js +1 -1
  12. package/dist/{chunk-DP2ZZZEO.mjs → chunk-DUTQOLOF.mjs} +1 -0
  13. package/dist/doctor.js +7989 -10
  14. package/dist/doctor.mjs +7989 -10
  15. package/dist/filters.d.mts +19 -3
  16. package/dist/filters.d.ts +19 -3
  17. package/dist/filters.js +10 -1
  18. package/dist/filters.mjs +10 -1
  19. package/dist/format.d.mts +4 -4
  20. package/dist/format.d.ts +4 -4
  21. package/dist/index.d.mts +173 -13
  22. package/dist/index.d.ts +173 -13
  23. package/dist/index.js +175 -23
  24. package/dist/index.mjs +175 -24
  25. package/dist/{jobs-ub3gywNQ.d.ts → jobs-BRysn2m0.d.ts} +25 -3
  26. package/dist/{jobs-CfrxlDMU.d.mts → jobs-R-h3A3kl.d.mts} +25 -3
  27. package/dist/{search-Dx1TiAZk.d.ts → search-BK_zHHNQ.d.ts} +1 -1
  28. package/dist/{search-DKS7OIn2.d.mts → search-BlB690ma.d.mts} +1 -1
  29. package/dist/{seo-CI3wLKUW.d.mts → seo-0mbZ7M_E.d.mts} +1 -1
  30. package/dist/{seo-BbG2Ujyo.d.ts → seo-C7gMl6Y7.d.ts} +1 -1
  31. package/dist/seo-files.d.mts +2 -2
  32. package/dist/seo-files.d.ts +2 -2
  33. package/dist/seo.d.mts +6 -6
  34. package/dist/seo.d.ts +6 -6
  35. package/dist/server.d.mts +6 -6
  36. package/dist/server.d.ts +6 -6
  37. package/dist/server.mjs +1 -1
  38. package/dist/sitemap.d.mts +6 -6
  39. package/dist/sitemap.d.ts +6 -6
  40. package/dist/sitemap.mjs +1 -1
  41. package/dist/suggest.d.mts +2 -2
  42. package/dist/suggest.d.ts +2 -2
  43. package/package.json +2 -1
  44. package/skills/cavuno-board-account/SKILL.md +95 -1
  45. package/skills/cavuno-board-collections/SKILL.md +148 -0
  46. package/skills/cavuno-board-companies/SKILL.md +43 -1
  47. package/skills/cavuno-board-filters/SKILL.md +71 -1
  48. package/skills/cavuno-board-paywall/SKILL.md +5 -2
  49. package/skills/cavuno-board-post-a-job/SKILL.md +64 -0
  50. package/skills/manifest.json +11 -4
package/dist/index.js CHANGED
@@ -56,6 +56,7 @@ var BOARD_API_ERROR_CODES = [
56
56
  "rate_limited",
57
57
  "rate_limit_unavailable",
58
58
  "search_unavailable",
59
+ "search_filter_unavailable",
59
60
  "too_many_filter_values",
60
61
  "pagination_invalid_cursor",
61
62
  "pagination_offset_too_large",
@@ -358,7 +359,7 @@ async function clearSession(storage) {
358
359
  }
359
360
 
360
361
  // src/version.ts
361
- var SDK_VERSION = "4.26.0";
362
+ var SDK_VERSION = "4.27.0";
362
363
 
363
364
  // src/client.ts
364
365
  function isRawBody(body) {
@@ -1078,6 +1079,13 @@ function jobPostingNamespace(client) {
1078
1079
  // src/namespaces/jobs.ts
1079
1080
  function jobsNamespace(client) {
1080
1081
  return {
1082
+ /** List active entries available to a job collection field. Follow nextCursor for more. */
1083
+ collectionChoices(fieldKey, query, options) {
1084
+ return client.fetch(
1085
+ `/job-fields/${encodeURIComponent(fieldKey)}/choices`,
1086
+ { ...options, query }
1087
+ );
1088
+ },
1081
1089
  /**
1082
1090
  * List published jobs.
1083
1091
  *
@@ -1111,7 +1119,7 @@ function jobsNamespace(client) {
1111
1119
  * @example
1112
1120
  * const { data } = await board.jobs.search({
1113
1121
  * query: 'chef',
1114
- * filters: { seniority: ['senior'] },
1122
+ * filters: { seniority: ['senior'], categories: ['engineering'] },
1115
1123
  * });
1116
1124
  */
1117
1125
  search(body, query, options) {
@@ -1322,6 +1330,13 @@ function meNamespace(client) {
1322
1330
  * experience / education / skills / languages collections + avatar.
1323
1331
  */
1324
1332
  profile: {
1333
+ /** List selectable records for an owner-editable catalog field, including private fields. */
1334
+ listObjectReferenceChoices(fieldKey, query, options) {
1335
+ return client.fetch(
1336
+ "/me/profile/object-references/choices",
1337
+ { ...options, query: { ...query, fieldKey } }
1338
+ );
1339
+ },
1325
1340
  /**
1326
1341
  * Retrieve my lean candidate profile.
1327
1342
  *
@@ -1349,6 +1364,34 @@ function meNamespace(client) {
1349
1364
  query
1350
1365
  });
1351
1366
  },
1367
+ /** Retrieve my profile custom-field definitions and current values. */
1368
+ retrieveCustomFields(options) {
1369
+ return client.fetch("/me/profile/custom-fields", {
1370
+ ...options
1371
+ });
1372
+ },
1373
+ /** Additively update my editable candidate profile custom fields. */
1374
+ updateCustomFields(body, options) {
1375
+ return client.fetch("/me/profile/custom-fields", {
1376
+ ...options,
1377
+ method: "PATCH",
1378
+ body
1379
+ });
1380
+ },
1381
+ /** Retrieve editable catalog references on my candidate profile. */
1382
+ retrieveObjectReferences(options) {
1383
+ return client.fetch(
1384
+ "/me/profile/object-references",
1385
+ options
1386
+ );
1387
+ },
1388
+ /** Replace editable catalog references on my candidate profile. */
1389
+ updateObjectReferences(body, options) {
1390
+ return client.fetch(
1391
+ "/me/profile/object-references",
1392
+ { ...options, method: "PUT", body }
1393
+ );
1394
+ },
1352
1395
  /**
1353
1396
  * Check whether a handle is available for me on this board (my own
1354
1397
  * current handle counts as available). Advisory — `update` re-checks.
@@ -1502,6 +1545,27 @@ function meNamespace(client) {
1502
1545
  * claiming a company — the same identity can also be a candidate.
1503
1546
  */
1504
1547
  companies: {
1548
+ /** List selectable records for an approved company's owner-editable catalog field. */
1549
+ listObjectReferenceChoices(slug, fieldKey, query, options) {
1550
+ return client.fetch(
1551
+ `/me/companies/${encodeURIComponent(slug)}/object-references/choices`,
1552
+ { ...options, query: { ...query, fieldKey } }
1553
+ );
1554
+ },
1555
+ /** Retrieve editable catalog references for one of my companies. */
1556
+ retrieveObjectReferences(slug, options) {
1557
+ return client.fetch(
1558
+ `/me/companies/${encodeURIComponent(slug)}/object-references`,
1559
+ options
1560
+ );
1561
+ },
1562
+ /** Replace editable catalog references for one of my companies. */
1563
+ updateObjectReferences(slug, body, options) {
1564
+ return client.fetch(
1565
+ `/me/companies/${encodeURIComponent(slug)}/object-references`,
1566
+ { ...options, method: "PUT", body }
1567
+ );
1568
+ },
1505
1569
  /**
1506
1570
  * Search companies on this board to claim.
1507
1571
  *
@@ -1592,6 +1656,20 @@ function meNamespace(client) {
1592
1656
  { ...options, method: "PATCH", body }
1593
1657
  );
1594
1658
  },
1659
+ /** Retrieve profile custom fields for a company I belong to. */
1660
+ retrieveCustomFields(slug, options) {
1661
+ return client.fetch(
1662
+ `/me/companies/${encodeURIComponent(slug)}/custom-fields`,
1663
+ options
1664
+ );
1665
+ },
1666
+ /** Additively update editable custom fields for a company I belong to. */
1667
+ updateCustomFields(slug, body, options) {
1668
+ return client.fetch(
1669
+ `/me/companies/${encodeURIComponent(slug)}/custom-fields`,
1670
+ { ...options, method: "PATCH", body }
1671
+ );
1672
+ },
1595
1673
  /**
1596
1674
  * Delete a company I admin (soft-delete cascade + Forager
1597
1675
  * exclusion). Resolves void on success (204).
@@ -1628,7 +1706,9 @@ function meNamespace(client) {
1628
1706
  */
1629
1707
  updateMemberRole(slug, memberId, body, options) {
1630
1708
  return client.fetch(
1631
- `/me/companies/${encodeURIComponent(slug)}/members/${encodeURIComponent(memberId)}`,
1709
+ `/me/companies/${encodeURIComponent(
1710
+ slug
1711
+ )}/members/${encodeURIComponent(memberId)}`,
1632
1712
  { ...options, method: "PATCH", body }
1633
1713
  );
1634
1714
  },
@@ -1641,7 +1721,9 @@ function meNamespace(client) {
1641
1721
  */
1642
1722
  removeMember(slug, memberId, options) {
1643
1723
  return client.fetch(
1644
- `/me/companies/${encodeURIComponent(slug)}/members/${encodeURIComponent(memberId)}`,
1724
+ `/me/companies/${encodeURIComponent(
1725
+ slug
1726
+ )}/members/${encodeURIComponent(memberId)}`,
1645
1727
  { ...options, method: "DELETE" }
1646
1728
  );
1647
1729
  },
@@ -1693,7 +1775,9 @@ function meNamespace(client) {
1693
1775
  */
1694
1776
  retrieveMembershipCheckout(slug, sessionId, options) {
1695
1777
  return client.fetch(
1696
- `/me/companies/${encodeURIComponent(slug)}/membership/checkout/${encodeURIComponent(sessionId)}`,
1778
+ `/me/companies/${encodeURIComponent(
1779
+ slug
1780
+ )}/membership/checkout/${encodeURIComponent(sessionId)}`,
1697
1781
  options
1698
1782
  );
1699
1783
  },
@@ -1733,7 +1817,9 @@ function meNamespace(client) {
1733
1817
  */
1734
1818
  revokeInvite(slug, inviteId, options) {
1735
1819
  return client.fetch(
1736
- `/me/companies/${encodeURIComponent(slug)}/invites/${encodeURIComponent(inviteId)}`,
1820
+ `/me/companies/${encodeURIComponent(
1821
+ slug
1822
+ )}/invites/${encodeURIComponent(inviteId)}`,
1737
1823
  { ...options, method: "DELETE" }
1738
1824
  );
1739
1825
  },
@@ -1815,18 +1901,27 @@ function meNamespace(client) {
1815
1901
  */
1816
1902
  retrieve(slug, id, options) {
1817
1903
  return client.fetch(
1818
- `/me/companies/${encodeURIComponent(slug)}/jobs/${encodeURIComponent(id)}`,
1904
+ `/me/companies/${encodeURIComponent(
1905
+ slug
1906
+ )}/jobs/${encodeURIComponent(id)}`,
1819
1907
  options
1820
1908
  );
1821
1909
  },
1822
1910
  /**
1823
1911
  * Create a job as a held draft. Returns the created job.
1912
+ * `remoteOption` is required. A `salaryMin` or `salaryMax` needs both
1913
+ * `salaryCurrency` and `salaryTimeframe`.
1824
1914
  *
1825
1915
  * @example
1826
1916
  * await board.me.companies.jobs.create('acme', {
1827
1917
  * title: 'Staff Engineer',
1828
1918
  * description: '…',
1829
1919
  * applicationUrl: 'https://acme.com/apply',
1920
+ * remoteOption: 'remote',
1921
+ * remotePermits: [{ type: 'worldwide', value: 'worldwide' }],
1922
+ * salaryMin: 150000,
1923
+ * salaryCurrency: 'USD',
1924
+ * salaryTimeframe: 'per_year',
1830
1925
  * });
1831
1926
  */
1832
1927
  create(slug, body, options) {
@@ -1846,7 +1941,9 @@ function meNamespace(client) {
1846
1941
  */
1847
1942
  update(slug, id, body, options) {
1848
1943
  return client.fetch(
1849
- `/me/companies/${encodeURIComponent(slug)}/jobs/${encodeURIComponent(id)}`,
1944
+ `/me/companies/${encodeURIComponent(
1945
+ slug
1946
+ )}/jobs/${encodeURIComponent(id)}`,
1850
1947
  { ...options, method: "PATCH", body }
1851
1948
  );
1852
1949
  },
@@ -1858,7 +1955,9 @@ function meNamespace(client) {
1858
1955
  */
1859
1956
  delete(slug, id, options) {
1860
1957
  return client.fetch(
1861
- `/me/companies/${encodeURIComponent(slug)}/jobs/${encodeURIComponent(id)}`,
1958
+ `/me/companies/${encodeURIComponent(
1959
+ slug
1960
+ )}/jobs/${encodeURIComponent(id)}`,
1862
1961
  { ...options, method: "DELETE" }
1863
1962
  );
1864
1963
  },
@@ -1872,7 +1971,9 @@ function meNamespace(client) {
1872
1971
  */
1873
1972
  publish(slug, id, options) {
1874
1973
  return client.fetch(
1875
- `/me/companies/${encodeURIComponent(slug)}/jobs/${encodeURIComponent(id)}/publish`,
1974
+ `/me/companies/${encodeURIComponent(
1975
+ slug
1976
+ )}/jobs/${encodeURIComponent(id)}/publish`,
1876
1977
  { ...options, method: "POST" }
1877
1978
  );
1878
1979
  },
@@ -1885,7 +1986,9 @@ function meNamespace(client) {
1885
1986
  */
1886
1987
  unpublish(slug, id, options) {
1887
1988
  return client.fetch(
1888
- `/me/companies/${encodeURIComponent(slug)}/jobs/${encodeURIComponent(id)}/unpublish`,
1989
+ `/me/companies/${encodeURIComponent(
1990
+ slug
1991
+ )}/jobs/${encodeURIComponent(id)}/unpublish`,
1889
1992
  { ...options, method: "POST" }
1890
1993
  );
1891
1994
  },
@@ -1904,7 +2007,9 @@ function meNamespace(client) {
1904
2007
  */
1905
2008
  checkout(slug, id, body, options) {
1906
2009
  return client.fetch(
1907
- `/me/companies/${encodeURIComponent(slug)}/jobs/${encodeURIComponent(id)}/checkout`,
2010
+ `/me/companies/${encodeURIComponent(
2011
+ slug
2012
+ )}/jobs/${encodeURIComponent(id)}/checkout`,
1908
2013
  { ...options, method: "POST", body }
1909
2014
  );
1910
2015
  }
@@ -2026,7 +2131,9 @@ function meNamespace(client) {
2026
2131
  */
2027
2132
  timeseries(slug, query, options) {
2028
2133
  return client.fetch(
2029
- `/me/companies/${encodeURIComponent(slug)}/profile-stats/timeseries`,
2134
+ `/me/companies/${encodeURIComponent(
2135
+ slug
2136
+ )}/profile-stats/timeseries`,
2030
2137
  { ...options, query }
2031
2138
  );
2032
2139
  }
@@ -2102,14 +2209,18 @@ function meNamespace(client) {
2102
2209
  */
2103
2210
  update(slug, listId, body, options) {
2104
2211
  return client.fetch(
2105
- `/me/companies/${encodeURIComponent(slug)}/talent-lists/${encodeURIComponent(listId)}`,
2212
+ `/me/companies/${encodeURIComponent(
2213
+ slug
2214
+ )}/talent-lists/${encodeURIComponent(listId)}`,
2106
2215
  { ...options, method: "PATCH", body }
2107
2216
  );
2108
2217
  },
2109
2218
  /** Delete a talent list. Sourced membership is unaffected. */
2110
2219
  remove(slug, listId, options) {
2111
2220
  return client.fetch(
2112
- `/me/companies/${encodeURIComponent(slug)}/talent-lists/${encodeURIComponent(listId)}`,
2221
+ `/me/companies/${encodeURIComponent(
2222
+ slug
2223
+ )}/talent-lists/${encodeURIComponent(listId)}`,
2113
2224
  { ...options, method: "DELETE" }
2114
2225
  );
2115
2226
  }
@@ -2157,7 +2268,9 @@ function meNamespace(client) {
2157
2268
  /** Remove a sourced membership. Does not touch pipeline applications. */
2158
2269
  remove(slug, sourcedId, options) {
2159
2270
  return client.fetch(
2160
- `/me/companies/${encodeURIComponent(slug)}/sourced-candidates/${encodeURIComponent(sourcedId)}`,
2271
+ `/me/companies/${encodeURIComponent(
2272
+ slug
2273
+ )}/sourced-candidates/${encodeURIComponent(sourcedId)}`,
2161
2274
  { ...options, method: "DELETE" }
2162
2275
  );
2163
2276
  },
@@ -2177,7 +2290,9 @@ function meNamespace(client) {
2177
2290
  */
2178
2291
  convert(slug, sourcedId, body, options) {
2179
2292
  return client.fetch(
2180
- `/me/companies/${encodeURIComponent(slug)}/sourced-candidates/${encodeURIComponent(sourcedId)}/convert`,
2293
+ `/me/companies/${encodeURIComponent(
2294
+ slug
2295
+ )}/sourced-candidates/${encodeURIComponent(sourcedId)}/convert`,
2181
2296
  { ...options, method: "POST", body }
2182
2297
  );
2183
2298
  }
@@ -2217,7 +2332,9 @@ function meNamespace(client) {
2217
2332
  */
2218
2333
  move(slug, applicationId, body, options) {
2219
2334
  return client.fetch(
2220
- `/me/companies/${encodeURIComponent(slug)}/applicants/${encodeURIComponent(applicationId)}/stage`,
2335
+ `/me/companies/${encodeURIComponent(
2336
+ slug
2337
+ )}/applicants/${encodeURIComponent(applicationId)}/stage`,
2221
2338
  { ...options, method: "PATCH", body }
2222
2339
  );
2223
2340
  },
@@ -2262,7 +2379,9 @@ function meNamespace(client) {
2262
2379
  */
2263
2380
  addNote(slug, applicationId, body, options) {
2264
2381
  return client.fetch(
2265
- `/me/companies/${encodeURIComponent(slug)}/applicants/${encodeURIComponent(applicationId)}/notes`,
2382
+ `/me/companies/${encodeURIComponent(
2383
+ slug
2384
+ )}/applicants/${encodeURIComponent(applicationId)}/notes`,
2266
2385
  { ...options, method: "POST", body }
2267
2386
  );
2268
2387
  }
@@ -2299,7 +2418,9 @@ function meNamespace(client) {
2299
2418
  */
2300
2419
  update(slug, stageId, body, options) {
2301
2420
  return client.fetch(
2302
- `/me/companies/${encodeURIComponent(slug)}/pipeline-stages/${encodeURIComponent(stageId)}`,
2421
+ `/me/companies/${encodeURIComponent(
2422
+ slug
2423
+ )}/pipeline-stages/${encodeURIComponent(stageId)}`,
2303
2424
  { ...options, method: "PATCH", body }
2304
2425
  );
2305
2426
  },
@@ -2312,7 +2433,9 @@ function meNamespace(client) {
2312
2433
  */
2313
2434
  remove(slug, stageId, options) {
2314
2435
  return client.fetch(
2315
- `/me/companies/${encodeURIComponent(slug)}/pipeline-stages/${encodeURIComponent(stageId)}`,
2436
+ `/me/companies/${encodeURIComponent(
2437
+ slug
2438
+ )}/pipeline-stages/${encodeURIComponent(stageId)}`,
2316
2439
  { ...options, method: "DELETE" }
2317
2440
  );
2318
2441
  },
@@ -2982,8 +3105,11 @@ function meNamespace(client) {
2982
3105
  * profile.
2983
3106
  *
2984
3107
  * @example
3108
+ * const { data: offers } = await board.paywall.offers();
3109
+ * const selectedOffer = offers[0]; // Or the offer selected in your UI.
3110
+ * if (!selectedOffer) throw new Error('No access offers available');
2985
3111
  * const kit = await board.me.access.checkout({
2986
- * offerKey: 'monthly',
3112
+ * offerKey: selectedOffer.offerKey,
2987
3113
  * returnPath: '/account/access',
2988
3114
  * colorMode: 'light',
2989
3115
  * });
@@ -3125,6 +3251,26 @@ function plansNamespace(client) {
3125
3251
  };
3126
3252
  }
3127
3253
 
3254
+ // src/namespaces/profile-fields.ts
3255
+ function profileFieldsNamespace(client) {
3256
+ return {
3257
+ /** Discover public scalar and catalog field definitions for a profile type. */
3258
+ retrieve(entity, options) {
3259
+ return client.fetch(
3260
+ `/profile-fields/${encodeURIComponent(entity)}`,
3261
+ options
3262
+ );
3263
+ },
3264
+ /** Discover active choices for a public catalog field; follow nextCursor for more. */
3265
+ choices(entity, fieldKey, query, options) {
3266
+ return client.fetch(
3267
+ `/profile-fields/${encodeURIComponent(entity)}/${encodeURIComponent(fieldKey)}/choices`,
3268
+ { ...options, query }
3269
+ );
3270
+ }
3271
+ };
3272
+ }
3273
+
3128
3274
  // src/namespaces/redirects.ts
3129
3275
  function redirectsNamespace(client) {
3130
3276
  return {
@@ -3302,9 +3448,14 @@ function talentNamespace(client) {
3302
3448
  * const { data } = await board.talent.list({ skill: 'react', limit: 20 });
3303
3449
  */
3304
3450
  list(query, options) {
3451
+ const serializedQuery = query ? {
3452
+ ...query,
3453
+ customFields: query.customFields ? JSON.stringify(query.customFields) : void 0,
3454
+ objectReferences: query.objectReferences ? JSON.stringify(query.objectReferences) : void 0
3455
+ } : void 0;
3305
3456
  return client.fetch("/talent", {
3306
3457
  ...options,
3307
- query
3458
+ query: serializedQuery
3308
3459
  });
3309
3460
  },
3310
3461
  /**
@@ -3519,6 +3670,7 @@ function createBoardClient(options) {
3519
3670
  jobPosting: jobPostingNamespace(client),
3520
3671
  salaries: salariesNamespace(client),
3521
3672
  talent: talentNamespace(client),
3673
+ profileFields: profileFieldsNamespace(client),
3522
3674
  plans: plansNamespace(client),
3523
3675
  paywall: paywallNamespace(client),
3524
3676
  sitemap: sitemapNamespace(client)