@cavuno/board 1.24.0 → 1.26.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 +88 -0
- package/dist/bin.mjs +67 -34
- package/dist/filters.d.mts +55 -0
- package/dist/filters.d.ts +55 -0
- package/dist/filters.js +193 -0
- package/dist/filters.mjs +170 -0
- package/dist/format.d.mts +240 -0
- package/dist/format.d.ts +240 -0
- package/dist/format.js +453 -0
- package/dist/format.mjs +430 -0
- package/dist/index.d.mts +92 -3825
- package/dist/index.d.ts +92 -3825
- package/dist/index.js +154 -7
- package/dist/index.mjs +151 -4
- package/dist/jobs-CM67_J6H.d.mts +3836 -0
- package/dist/jobs-CM67_J6H.d.ts +3836 -0
- package/dist/theme.d.mts +63 -0
- package/dist/theme.d.ts +63 -0
- package/dist/theme.js +149 -0
- package/dist/theme.mjs +128 -0
- package/package.json +37 -2
- package/skills/cavuno-board-account/SKILL.md +147 -0
- package/skills/cavuno-board-applications/SKILL.md +110 -0
- package/skills/cavuno-board-blog/SKILL.md +99 -0
- package/skills/cavuno-board-companies/SKILL.md +99 -0
- package/skills/cavuno-board-filters/SKILL.md +89 -0
- package/skills/cavuno-board-format/SKILL.md +104 -0
- package/skills/cavuno-board-job-alerts/SKILL.md +115 -0
- package/skills/cavuno-board-job-posting/SKILL.md +130 -0
- package/skills/cavuno-board-jobs/SKILL.md +15 -0
- package/skills/cavuno-board-messaging/SKILL.md +121 -0
- package/skills/cavuno-board-paywall/SKILL.md +108 -0
- package/skills/cavuno-board-salaries/SKILL.md +87 -0
- package/skills/cavuno-board-setup/SKILL.md +26 -2
- package/skills/cavuno-board-smoke-test/SKILL.md +84 -0
- package/skills/cavuno-board-theme/SKILL.md +69 -0
- package/skills/manifest.json +92 -1
package/dist/index.js
CHANGED
|
@@ -18,10 +18,11 @@ var __copyProps = (to, from, except, desc) => {
|
|
|
18
18
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
19
|
|
|
20
20
|
// src/index.ts
|
|
21
|
-
var
|
|
22
|
-
__export(
|
|
21
|
+
var src_exports = {};
|
|
22
|
+
__export(src_exports, {
|
|
23
23
|
ACCESS_TOKEN_KEY: () => ACCESS_TOKEN_KEY,
|
|
24
24
|
BOARD_ACCESS_GRANT_KEY: () => BOARD_ACCESS_GRANT_KEY,
|
|
25
|
+
BOARD_API_ERROR_CODES: () => BOARD_API_ERROR_CODES,
|
|
25
26
|
BoardApiError: () => BoardApiError,
|
|
26
27
|
BoardClient: () => BoardClient,
|
|
27
28
|
REFRESH_TOKEN_KEY: () => REFRESH_TOKEN_KEY,
|
|
@@ -34,11 +35,127 @@ __export(index_exports, {
|
|
|
34
35
|
isNotFound: () => isNotFound,
|
|
35
36
|
isRateLimited: () => isRateLimited,
|
|
36
37
|
isUnauthorized: () => isUnauthorized,
|
|
37
|
-
isValidationError: () => isValidationError
|
|
38
|
+
isValidationError: () => isValidationError,
|
|
39
|
+
paginate: () => paginate
|
|
38
40
|
});
|
|
39
|
-
module.exports = __toCommonJS(
|
|
41
|
+
module.exports = __toCommonJS(src_exports);
|
|
40
42
|
|
|
41
43
|
// src/errors.ts
|
|
44
|
+
var BOARD_API_ERROR_CODES = [
|
|
45
|
+
// Cross-cutting envelope
|
|
46
|
+
"internal_error",
|
|
47
|
+
"validation_bad_request",
|
|
48
|
+
"validation_payload_too_large",
|
|
49
|
+
"rate_limited",
|
|
50
|
+
"rate_limit_unavailable",
|
|
51
|
+
"search_unavailable",
|
|
52
|
+
"too_many_filter_values",
|
|
53
|
+
"pagination_invalid_cursor",
|
|
54
|
+
"pagination_offset_too_large",
|
|
55
|
+
"auth_unauthenticated",
|
|
56
|
+
"auth_forbidden",
|
|
57
|
+
"plan_upgrade_required",
|
|
58
|
+
"unknown_error",
|
|
59
|
+
// Board resolution + custom pages
|
|
60
|
+
"boards_not_found",
|
|
61
|
+
"board_page_not_found",
|
|
62
|
+
// Board-user auth
|
|
63
|
+
"board_auth_email_taken",
|
|
64
|
+
"board_auth_invalid_credentials",
|
|
65
|
+
"board_auth_invalid_token",
|
|
66
|
+
"board_auth_registration_disabled",
|
|
67
|
+
"board_auth_token_expired",
|
|
68
|
+
// Board password gate
|
|
69
|
+
"board_password_required",
|
|
70
|
+
"board_password_invalid",
|
|
71
|
+
// Jobs browse
|
|
72
|
+
"jobs_not_found",
|
|
73
|
+
"jobs_invalid_filter",
|
|
74
|
+
// Taxonomy
|
|
75
|
+
"categories_not_found",
|
|
76
|
+
"skills_not_found",
|
|
77
|
+
"places_not_found",
|
|
78
|
+
// Companies (public reads)
|
|
79
|
+
"companies_not_found",
|
|
80
|
+
"company_markets_not_found",
|
|
81
|
+
"company_salary_not_found",
|
|
82
|
+
"company_category_salary_not_found",
|
|
83
|
+
// Salaries
|
|
84
|
+
"salaries_title_not_found",
|
|
85
|
+
"salaries_skill_not_found",
|
|
86
|
+
"salaries_location_not_found",
|
|
87
|
+
"salaries_title_location_not_found",
|
|
88
|
+
"salaries_skill_location_not_found",
|
|
89
|
+
// Blog (public reads)
|
|
90
|
+
"blog_post_not_found",
|
|
91
|
+
"blog_author_not_found",
|
|
92
|
+
"blog_tag_not_found",
|
|
93
|
+
// Talent directory
|
|
94
|
+
"talent_not_found",
|
|
95
|
+
"talent_directory_not_found",
|
|
96
|
+
"talent_directory_restricted",
|
|
97
|
+
// Job alerts (anonymous + authenticated)
|
|
98
|
+
"job_alert_not_found",
|
|
99
|
+
"job_alerts_disabled",
|
|
100
|
+
"candidate_alert_limit_reached",
|
|
101
|
+
"candidate_alert_not_found",
|
|
102
|
+
// Candidate account
|
|
103
|
+
"candidate_entry_not_found",
|
|
104
|
+
"candidate_handle_taken",
|
|
105
|
+
"candidate_job_not_found",
|
|
106
|
+
"resume_invalid_file",
|
|
107
|
+
"resume_upload_forbidden",
|
|
108
|
+
// Applications
|
|
109
|
+
"applications_external_apply_only",
|
|
110
|
+
"applications_guest_not_allowed",
|
|
111
|
+
"applications_job_not_found",
|
|
112
|
+
"applications_not_found",
|
|
113
|
+
"applications_resume_invalid_file",
|
|
114
|
+
"applications_unprocessable",
|
|
115
|
+
// Messaging
|
|
116
|
+
"messaging_application_not_found",
|
|
117
|
+
"messaging_application_not_linked",
|
|
118
|
+
"messaging_blocked",
|
|
119
|
+
"messaging_cannot_block_self",
|
|
120
|
+
"messaging_cold_rule",
|
|
121
|
+
"messaging_conversation_not_found",
|
|
122
|
+
"messaging_disabled",
|
|
123
|
+
"messaging_edit_window_expired",
|
|
124
|
+
"messaging_message_deleted",
|
|
125
|
+
"messaging_message_not_found",
|
|
126
|
+
"messaging_not_author",
|
|
127
|
+
"messaging_not_participant",
|
|
128
|
+
"messaging_not_permitted",
|
|
129
|
+
"messaging_not_recipient",
|
|
130
|
+
"messaging_rate_limited",
|
|
131
|
+
"messaging_recipient_not_found",
|
|
132
|
+
"messaging_recipient_not_open",
|
|
133
|
+
"messaging_unsend_window_expired",
|
|
134
|
+
// Employer self-service
|
|
135
|
+
"employer_applicant_not_found",
|
|
136
|
+
"employer_ats_unprocessable",
|
|
137
|
+
"employer_checkout_failed",
|
|
138
|
+
"employer_company_exists",
|
|
139
|
+
"employer_company_name_taken",
|
|
140
|
+
"employer_company_not_found",
|
|
141
|
+
"employer_job_not_found",
|
|
142
|
+
"employer_job_slug_taken",
|
|
143
|
+
"employer_jobs_quota_exceeded",
|
|
144
|
+
"employer_not_member",
|
|
145
|
+
"employer_payment_required",
|
|
146
|
+
"employer_pipeline_stage_not_found",
|
|
147
|
+
// Candidate job-access paywall
|
|
148
|
+
"paywall_already_active",
|
|
149
|
+
"paywall_disabled",
|
|
150
|
+
"paywall_invalid_checkout_session",
|
|
151
|
+
"paywall_no_candidate_profile",
|
|
152
|
+
"paywall_no_recurring_subscription",
|
|
153
|
+
"paywall_offer_not_found",
|
|
154
|
+
// Public job posting
|
|
155
|
+
"job_posting_logo_lookup_unavailable",
|
|
156
|
+
"job_posting_logo_not_found",
|
|
157
|
+
"job_posting_rejected"
|
|
158
|
+
];
|
|
42
159
|
var BoardApiError = class extends Error {
|
|
43
160
|
status;
|
|
44
161
|
/** `<domain>_<snake_reason>` code from the v1 error envelope. */
|
|
@@ -149,7 +266,7 @@ async function clearSession(storage) {
|
|
|
149
266
|
}
|
|
150
267
|
|
|
151
268
|
// src/version.ts
|
|
152
|
-
var SDK_VERSION = "1.
|
|
269
|
+
var SDK_VERSION = "1.26.0";
|
|
153
270
|
|
|
154
271
|
// src/client.ts
|
|
155
272
|
function isRawBody(body) {
|
|
@@ -785,7 +902,7 @@ function jobPostingNamespace(client) {
|
|
|
785
902
|
},
|
|
786
903
|
/**
|
|
787
904
|
* Upload a company logo (JPEG/PNG/WebP/GIF, ≤2 MB). Returns the stored
|
|
788
|
-
* `publicUrl` — pass it back as `
|
|
905
|
+
* `publicUrl` — pass it back as the top-level `logoUrl` on `create(...)`.
|
|
789
906
|
*/
|
|
790
907
|
uploadLogo(file, options) {
|
|
791
908
|
const form = new FormData();
|
|
@@ -798,7 +915,7 @@ function jobPostingNamespace(client) {
|
|
|
798
915
|
},
|
|
799
916
|
/**
|
|
800
917
|
* Look up a company logo by domain via Brandfetch, store it, and return its
|
|
801
|
-
* `publicUrl` — pass it back as `
|
|
918
|
+
* `publicUrl` — pass it back as the top-level `logoUrl` on `create(...)`. A
|
|
802
919
|
* `BoardApiError` (`job_posting_logo_not_found`) means no usable logo.
|
|
803
920
|
*/
|
|
804
921
|
fetchLogoByDomain(domain, options) {
|
|
@@ -2400,6 +2517,36 @@ function taxonomyNamespace(client) {
|
|
|
2400
2517
|
};
|
|
2401
2518
|
}
|
|
2402
2519
|
|
|
2520
|
+
// src/pagination.ts
|
|
2521
|
+
function paginate(listFn, query, options) {
|
|
2522
|
+
async function* pages() {
|
|
2523
|
+
let current = query;
|
|
2524
|
+
for (; ; ) {
|
|
2525
|
+
const page = await listFn(current, options);
|
|
2526
|
+
yield page;
|
|
2527
|
+
if (!page.hasMore || page.nextCursor === null) return;
|
|
2528
|
+
const { offset: _offset, ...rest } = current ?? {};
|
|
2529
|
+
current = { ...rest, cursor: page.nextCursor };
|
|
2530
|
+
}
|
|
2531
|
+
}
|
|
2532
|
+
return {
|
|
2533
|
+
pages,
|
|
2534
|
+
async *[Symbol.asyncIterator]() {
|
|
2535
|
+
for await (const page of pages()) {
|
|
2536
|
+
yield* page.data;
|
|
2537
|
+
}
|
|
2538
|
+
},
|
|
2539
|
+
async toArray({ limit }) {
|
|
2540
|
+
const items = [];
|
|
2541
|
+
for await (const page of pages()) {
|
|
2542
|
+
items.push(...page.data);
|
|
2543
|
+
if (items.length >= limit) break;
|
|
2544
|
+
}
|
|
2545
|
+
return items.slice(0, limit);
|
|
2546
|
+
}
|
|
2547
|
+
};
|
|
2548
|
+
}
|
|
2549
|
+
|
|
2403
2550
|
// src/index.ts
|
|
2404
2551
|
function createBoardClient(options) {
|
|
2405
2552
|
const client = new BoardClient({
|
package/dist/index.mjs
CHANGED
|
@@ -1,4 +1,119 @@
|
|
|
1
1
|
// src/errors.ts
|
|
2
|
+
var BOARD_API_ERROR_CODES = [
|
|
3
|
+
// Cross-cutting envelope
|
|
4
|
+
"internal_error",
|
|
5
|
+
"validation_bad_request",
|
|
6
|
+
"validation_payload_too_large",
|
|
7
|
+
"rate_limited",
|
|
8
|
+
"rate_limit_unavailable",
|
|
9
|
+
"search_unavailable",
|
|
10
|
+
"too_many_filter_values",
|
|
11
|
+
"pagination_invalid_cursor",
|
|
12
|
+
"pagination_offset_too_large",
|
|
13
|
+
"auth_unauthenticated",
|
|
14
|
+
"auth_forbidden",
|
|
15
|
+
"plan_upgrade_required",
|
|
16
|
+
"unknown_error",
|
|
17
|
+
// Board resolution + custom pages
|
|
18
|
+
"boards_not_found",
|
|
19
|
+
"board_page_not_found",
|
|
20
|
+
// Board-user auth
|
|
21
|
+
"board_auth_email_taken",
|
|
22
|
+
"board_auth_invalid_credentials",
|
|
23
|
+
"board_auth_invalid_token",
|
|
24
|
+
"board_auth_registration_disabled",
|
|
25
|
+
"board_auth_token_expired",
|
|
26
|
+
// Board password gate
|
|
27
|
+
"board_password_required",
|
|
28
|
+
"board_password_invalid",
|
|
29
|
+
// Jobs browse
|
|
30
|
+
"jobs_not_found",
|
|
31
|
+
"jobs_invalid_filter",
|
|
32
|
+
// Taxonomy
|
|
33
|
+
"categories_not_found",
|
|
34
|
+
"skills_not_found",
|
|
35
|
+
"places_not_found",
|
|
36
|
+
// Companies (public reads)
|
|
37
|
+
"companies_not_found",
|
|
38
|
+
"company_markets_not_found",
|
|
39
|
+
"company_salary_not_found",
|
|
40
|
+
"company_category_salary_not_found",
|
|
41
|
+
// Salaries
|
|
42
|
+
"salaries_title_not_found",
|
|
43
|
+
"salaries_skill_not_found",
|
|
44
|
+
"salaries_location_not_found",
|
|
45
|
+
"salaries_title_location_not_found",
|
|
46
|
+
"salaries_skill_location_not_found",
|
|
47
|
+
// Blog (public reads)
|
|
48
|
+
"blog_post_not_found",
|
|
49
|
+
"blog_author_not_found",
|
|
50
|
+
"blog_tag_not_found",
|
|
51
|
+
// Talent directory
|
|
52
|
+
"talent_not_found",
|
|
53
|
+
"talent_directory_not_found",
|
|
54
|
+
"talent_directory_restricted",
|
|
55
|
+
// Job alerts (anonymous + authenticated)
|
|
56
|
+
"job_alert_not_found",
|
|
57
|
+
"job_alerts_disabled",
|
|
58
|
+
"candidate_alert_limit_reached",
|
|
59
|
+
"candidate_alert_not_found",
|
|
60
|
+
// Candidate account
|
|
61
|
+
"candidate_entry_not_found",
|
|
62
|
+
"candidate_handle_taken",
|
|
63
|
+
"candidate_job_not_found",
|
|
64
|
+
"resume_invalid_file",
|
|
65
|
+
"resume_upload_forbidden",
|
|
66
|
+
// Applications
|
|
67
|
+
"applications_external_apply_only",
|
|
68
|
+
"applications_guest_not_allowed",
|
|
69
|
+
"applications_job_not_found",
|
|
70
|
+
"applications_not_found",
|
|
71
|
+
"applications_resume_invalid_file",
|
|
72
|
+
"applications_unprocessable",
|
|
73
|
+
// Messaging
|
|
74
|
+
"messaging_application_not_found",
|
|
75
|
+
"messaging_application_not_linked",
|
|
76
|
+
"messaging_blocked",
|
|
77
|
+
"messaging_cannot_block_self",
|
|
78
|
+
"messaging_cold_rule",
|
|
79
|
+
"messaging_conversation_not_found",
|
|
80
|
+
"messaging_disabled",
|
|
81
|
+
"messaging_edit_window_expired",
|
|
82
|
+
"messaging_message_deleted",
|
|
83
|
+
"messaging_message_not_found",
|
|
84
|
+
"messaging_not_author",
|
|
85
|
+
"messaging_not_participant",
|
|
86
|
+
"messaging_not_permitted",
|
|
87
|
+
"messaging_not_recipient",
|
|
88
|
+
"messaging_rate_limited",
|
|
89
|
+
"messaging_recipient_not_found",
|
|
90
|
+
"messaging_recipient_not_open",
|
|
91
|
+
"messaging_unsend_window_expired",
|
|
92
|
+
// Employer self-service
|
|
93
|
+
"employer_applicant_not_found",
|
|
94
|
+
"employer_ats_unprocessable",
|
|
95
|
+
"employer_checkout_failed",
|
|
96
|
+
"employer_company_exists",
|
|
97
|
+
"employer_company_name_taken",
|
|
98
|
+
"employer_company_not_found",
|
|
99
|
+
"employer_job_not_found",
|
|
100
|
+
"employer_job_slug_taken",
|
|
101
|
+
"employer_jobs_quota_exceeded",
|
|
102
|
+
"employer_not_member",
|
|
103
|
+
"employer_payment_required",
|
|
104
|
+
"employer_pipeline_stage_not_found",
|
|
105
|
+
// Candidate job-access paywall
|
|
106
|
+
"paywall_already_active",
|
|
107
|
+
"paywall_disabled",
|
|
108
|
+
"paywall_invalid_checkout_session",
|
|
109
|
+
"paywall_no_candidate_profile",
|
|
110
|
+
"paywall_no_recurring_subscription",
|
|
111
|
+
"paywall_offer_not_found",
|
|
112
|
+
// Public job posting
|
|
113
|
+
"job_posting_logo_lookup_unavailable",
|
|
114
|
+
"job_posting_logo_not_found",
|
|
115
|
+
"job_posting_rejected"
|
|
116
|
+
];
|
|
2
117
|
var BoardApiError = class extends Error {
|
|
3
118
|
status;
|
|
4
119
|
/** `<domain>_<snake_reason>` code from the v1 error envelope. */
|
|
@@ -109,7 +224,7 @@ async function clearSession(storage) {
|
|
|
109
224
|
}
|
|
110
225
|
|
|
111
226
|
// src/version.ts
|
|
112
|
-
var SDK_VERSION = "1.
|
|
227
|
+
var SDK_VERSION = "1.26.0";
|
|
113
228
|
|
|
114
229
|
// src/client.ts
|
|
115
230
|
function isRawBody(body) {
|
|
@@ -745,7 +860,7 @@ function jobPostingNamespace(client) {
|
|
|
745
860
|
},
|
|
746
861
|
/**
|
|
747
862
|
* Upload a company logo (JPEG/PNG/WebP/GIF, ≤2 MB). Returns the stored
|
|
748
|
-
* `publicUrl` — pass it back as `
|
|
863
|
+
* `publicUrl` — pass it back as the top-level `logoUrl` on `create(...)`.
|
|
749
864
|
*/
|
|
750
865
|
uploadLogo(file, options) {
|
|
751
866
|
const form = new FormData();
|
|
@@ -758,7 +873,7 @@ function jobPostingNamespace(client) {
|
|
|
758
873
|
},
|
|
759
874
|
/**
|
|
760
875
|
* Look up a company logo by domain via Brandfetch, store it, and return its
|
|
761
|
-
* `publicUrl` — pass it back as `
|
|
876
|
+
* `publicUrl` — pass it back as the top-level `logoUrl` on `create(...)`. A
|
|
762
877
|
* `BoardApiError` (`job_posting_logo_not_found`) means no usable logo.
|
|
763
878
|
*/
|
|
764
879
|
fetchLogoByDomain(domain, options) {
|
|
@@ -2360,6 +2475,36 @@ function taxonomyNamespace(client) {
|
|
|
2360
2475
|
};
|
|
2361
2476
|
}
|
|
2362
2477
|
|
|
2478
|
+
// src/pagination.ts
|
|
2479
|
+
function paginate(listFn, query, options) {
|
|
2480
|
+
async function* pages() {
|
|
2481
|
+
let current = query;
|
|
2482
|
+
for (; ; ) {
|
|
2483
|
+
const page = await listFn(current, options);
|
|
2484
|
+
yield page;
|
|
2485
|
+
if (!page.hasMore || page.nextCursor === null) return;
|
|
2486
|
+
const { offset: _offset, ...rest } = current ?? {};
|
|
2487
|
+
current = { ...rest, cursor: page.nextCursor };
|
|
2488
|
+
}
|
|
2489
|
+
}
|
|
2490
|
+
return {
|
|
2491
|
+
pages,
|
|
2492
|
+
async *[Symbol.asyncIterator]() {
|
|
2493
|
+
for await (const page of pages()) {
|
|
2494
|
+
yield* page.data;
|
|
2495
|
+
}
|
|
2496
|
+
},
|
|
2497
|
+
async toArray({ limit }) {
|
|
2498
|
+
const items = [];
|
|
2499
|
+
for await (const page of pages()) {
|
|
2500
|
+
items.push(...page.data);
|
|
2501
|
+
if (items.length >= limit) break;
|
|
2502
|
+
}
|
|
2503
|
+
return items.slice(0, limit);
|
|
2504
|
+
}
|
|
2505
|
+
};
|
|
2506
|
+
}
|
|
2507
|
+
|
|
2363
2508
|
// src/index.ts
|
|
2364
2509
|
function createBoardClient(options) {
|
|
2365
2510
|
const client = new BoardClient({
|
|
@@ -2419,6 +2564,7 @@ function createBoardClient(options) {
|
|
|
2419
2564
|
export {
|
|
2420
2565
|
ACCESS_TOKEN_KEY,
|
|
2421
2566
|
BOARD_ACCESS_GRANT_KEY,
|
|
2567
|
+
BOARD_API_ERROR_CODES,
|
|
2422
2568
|
BoardApiError,
|
|
2423
2569
|
BoardClient,
|
|
2424
2570
|
REFRESH_TOKEN_KEY,
|
|
@@ -2431,5 +2577,6 @@ export {
|
|
|
2431
2577
|
isNotFound,
|
|
2432
2578
|
isRateLimited,
|
|
2433
2579
|
isUnauthorized,
|
|
2434
|
-
isValidationError
|
|
2580
|
+
isValidationError,
|
|
2581
|
+
paginate
|
|
2435
2582
|
};
|