@cavuno/board 1.22.0 → 1.23.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/dist/index.d.ts CHANGED
@@ -169,6 +169,30 @@ interface components {
169
169
  resourceId: string;
170
170
  })[];
171
171
  };
172
+ Block: {
173
+ /** @enum {string} */
174
+ object: "block";
175
+ /** @enum {boolean} */
176
+ blocked: true;
177
+ };
178
+ BlockStatus: {
179
+ /** @enum {string} */
180
+ object: "block_status";
181
+ blocked: boolean;
182
+ };
183
+ BlockUserBody: {
184
+ boardUserId: string;
185
+ };
186
+ BlockedUser: {
187
+ id: string;
188
+ /** @enum {string} */
189
+ object: "blocked_user";
190
+ boardUserId: string;
191
+ displayName: string;
192
+ avatarUrl: string | null;
193
+ /** Format: date-time */
194
+ createdAt: string;
195
+ };
172
196
  BlogAuthor: {
173
197
  /** @description Unique identifier for the object. Use this value as the `{id}` path parameter for the author endpoints (e.g. `GET /v1/blog/authors/{id}`). */
174
198
  id: string;
@@ -718,6 +742,43 @@ interface components {
718
742
  ConfirmWorkEmailBody: {
719
743
  token: string;
720
744
  };
745
+ Conversation: {
746
+ id: string;
747
+ /** @enum {string} */
748
+ object: "conversation";
749
+ /** Format: date-time */
750
+ lastMessageAt: string;
751
+ lastMessageSnippet: string;
752
+ lastMessageAuthorBoardUserId: string;
753
+ /** Format: date-time */
754
+ archivedAt: string | null;
755
+ hasUnread: boolean;
756
+ counterparty: components["schemas"]["ConversationCounterparty"];
757
+ };
758
+ ConversationArchive: {
759
+ /** @enum {string} */
760
+ object: "conversation_archive";
761
+ /** Format: date-time */
762
+ archivedAt: string | null;
763
+ };
764
+ ConversationCounterparty: {
765
+ boardUserId: string;
766
+ displayName: string;
767
+ avatarUrl: string | null;
768
+ companyName: string | null;
769
+ handle: string | null;
770
+ companySlug: string | null;
771
+ };
772
+ ConversationDetail: components["schemas"]["Conversation"] & {
773
+ /** @enum {string} */
774
+ viewerRole: "employer" | "candidate";
775
+ viewerLastReadMessageId: string | null;
776
+ };
777
+ ConversationRef: {
778
+ /** @enum {string} */
779
+ object: "conversation_ref";
780
+ conversationId: string | null;
781
+ };
721
782
  CreateAuthorBody: {
722
783
  /** @description URL-friendly slug for the author. Auto-generated from `name` when omitted. */
723
784
  slug?: string;
@@ -1072,6 +1133,9 @@ interface components {
1072
1133
  /** @description Space-separated list of scopes the client may request. */
1073
1134
  scope: string;
1074
1135
  };
1136
+ EditMessageBody: {
1137
+ body: string;
1138
+ };
1075
1139
  EmployerApplicant: {
1076
1140
  id: string;
1077
1141
  /** @enum {string} */
@@ -1970,6 +2034,35 @@ interface components {
1970
2034
  */
1971
2035
  purpose: "board_logo" | "board_hero" | "account_avatar" | "company_logo" | "blog_image";
1972
2036
  };
2037
+ Message: {
2038
+ id: string;
2039
+ /** @enum {string} */
2040
+ object: "message";
2041
+ conversationId: string;
2042
+ authorBoardUserId: string;
2043
+ recipientBoardUserId: string;
2044
+ body: string;
2045
+ author: components["schemas"]["MessageAuthor"];
2046
+ /** Format: date-time */
2047
+ sentAt: string;
2048
+ /** Format: date-time */
2049
+ editedAt: string | null;
2050
+ /** Format: date-time */
2051
+ deletedAt: string | null;
2052
+ /** Format: date-time */
2053
+ readAt: string | null;
2054
+ };
2055
+ MessageAuthor: {
2056
+ displayName: string;
2057
+ avatarUrl: string | null;
2058
+ companyName: string | null;
2059
+ };
2060
+ ModerationReport: {
2061
+ /** @enum {string} */
2062
+ object: "moderation_report";
2063
+ id: string;
2064
+ blocked: boolean;
2065
+ };
1973
2066
  MoveApplicantStageBody: {
1974
2067
  /** @description The target stage id. */
1975
2068
  stageId: string;
@@ -2587,6 +2680,12 @@ interface components {
2587
2680
  */
2588
2681
  expiresAt?: string | null;
2589
2682
  };
2683
+ ReadReceipt: {
2684
+ /** @enum {string} */
2685
+ object: "read_receipt";
2686
+ /** Format: date-time */
2687
+ markedAt: string;
2688
+ };
2590
2689
  RedirectResolution: {
2591
2690
  /** @enum {string} */
2592
2691
  object: "redirect_resolution";
@@ -2616,6 +2715,14 @@ interface components {
2616
2715
  /** @description Every stage id of the job, in the new order. */
2617
2716
  orderedStageIds: string[];
2618
2717
  };
2718
+ ReplyBody: {
2719
+ body: string;
2720
+ };
2721
+ ReportBody: {
2722
+ /** @enum {string} */
2723
+ reason: "spam" | "harassment" | "misrepresentation" | "other";
2724
+ freeText?: string;
2725
+ };
2619
2726
  ResourceLinks: {
2620
2727
  /**
2621
2728
  * Format: uri
@@ -2987,6 +3094,14 @@ interface components {
2987
3094
  boardMedianMax: number | null;
2988
3095
  currency: string;
2989
3096
  };
3097
+ StartAboutApplicationBody: {
3098
+ applicationId: string;
3099
+ body: string;
3100
+ };
3101
+ StartConversationBody: {
3102
+ candidateBoardUserId: string;
3103
+ body: string;
3104
+ };
2990
3105
  TalentDirectoryEntry: {
2991
3106
  /** @enum {string} */
2992
3107
  object: "talent_directory_entry";
@@ -3250,6 +3365,11 @@ interface components {
3250
3365
  /** @description Space-separated list of scopes granted on the issued token. */
3251
3366
  scope: string;
3252
3367
  };
3368
+ UnreadCount: {
3369
+ /** @enum {string} */
3370
+ object: "unread_count";
3371
+ count: number;
3372
+ };
3253
3373
  UnsubscribeBody: {
3254
3374
  boardUserId: string;
3255
3375
  /** @enum {string} */
@@ -3745,7 +3865,7 @@ declare function isConflict(e: unknown): e is BoardApiError;
3745
3865
  * constant because the package is platform-neutral and cannot read
3746
3866
  * package.json at runtime.
3747
3867
  */
3748
- declare const SDK_VERSION = "1.22.0";
3868
+ declare const SDK_VERSION = "1.23.0";
3749
3869
 
3750
3870
  type BoardUser = Schemas['BoardUser'];
3751
3871
  type BoardAuthSession = Schemas['BoardAuthSession'];
@@ -3959,6 +4079,22 @@ type CandidateAvatar = Schemas['CandidateAvatar'];
3959
4079
  type NotificationPreference = Schemas['NotificationPreference'];
3960
4080
  type UpdateNotificationPreferenceBody = Schemas['UpdateNotificationPreferenceBody'];
3961
4081
  type UnsubscribeBody = Schemas['UnsubscribeBody'];
4082
+ /** One inbox row — the counterparty identity is live-resolved. */
4083
+ type Conversation = Schemas['Conversation'];
4084
+ /** A conversation header — adds the viewer's role + last-read pointer. */
4085
+ type ConversationDetail = Schemas['ConversationDetail'];
4086
+ /** One message in a thread. `body` is `''` when unsent (tombstoned). */
4087
+ type Message = Schemas['Message'];
4088
+ /** The distinct-unread-thread count for the inbox badge. */
4089
+ type UnreadCount = Schemas['UnreadCount'];
4090
+ /** Query for `board.me.conversations.list`. */
4091
+ type ConversationsListQuery = {
4092
+ /** `true` for the archived view; omit/false for the main inbox. */
4093
+ archived?: boolean;
4094
+ cursor?: string;
4095
+ /** 1–100. */
4096
+ limit?: number;
4097
+ };
3962
4098
  /** One of the authenticated board user's job-alert preferences. */
3963
4099
  type Alert = Schemas['Alert'];
3964
4100
  /** Create/replace body for `board.me.alerts.create` / `board.me.alerts.update`. */
@@ -3975,6 +4111,42 @@ type ApplicationsListQuery = {
3975
4111
  /** 1–100. */
3976
4112
  limit?: number;
3977
4113
  };
4114
+ /** Query for `board.me.conversations.listMessages`. */
4115
+ type ThreadMessagesQuery = {
4116
+ cursor?: string;
4117
+ /** 1–200. */
4118
+ limit?: number;
4119
+ };
4120
+ /** Body for `board.me.conversations.start` (cold-initiate a candidate). */
4121
+ type StartConversationBody = Schemas['StartConversationBody'];
4122
+ /** Body for `board.me.conversations.startAboutApplication` (message an applicant). */
4123
+ type StartAboutApplicationBody = Schemas['StartAboutApplicationBody'];
4124
+ /** Body for `board.me.conversations.reply`. */
4125
+ type ReplyBody = Schemas['ReplyBody'];
4126
+ /** The result of `board.me.conversations.markRead`. */
4127
+ type ReadReceipt = Schemas['ReadReceipt'];
4128
+ /** The result of `board.me.conversations.{archive,unarchive}`. */
4129
+ type ConversationArchive = Schemas['ConversationArchive'];
4130
+ /** Body for `board.me.messages.edit`. */
4131
+ type EditMessageBody = Schemas['EditMessageBody'];
4132
+ /** Body for `board.me.messages.report`. */
4133
+ type ReportBody = Schemas['ReportBody'];
4134
+ /** The result of `board.me.messages.report` (with the auto-block outcome). */
4135
+ type ModerationReport = Schemas['ModerationReport'];
4136
+ /** One blocked user from `board.me.blocks.list`. */
4137
+ type BlockedUser = Schemas['BlockedUser'];
4138
+ /** Body for `board.me.blocks.create`. */
4139
+ type BlockUserBody = Schemas['BlockUserBody'];
4140
+ /** The result of `board.me.blocks.create`. */
4141
+ type Block = Schemas['Block'];
4142
+ /** The result of `board.me.blocks.status`. */
4143
+ type BlockStatus = Schemas['BlockStatus'];
4144
+ /** The result of `board.me.conversations.findExisting`. */
4145
+ type ConversationRef = Schemas['ConversationRef'];
4146
+ /** Query for `board.me.conversations.findExisting`. */
4147
+ type FindExistingConversationQuery = {
4148
+ candidateBoardUserId: string;
4149
+ };
3978
4150
  /** The candidate's resume state (async parse status + stored file). */
3979
4151
  type Resume = Schemas['Resume'];
3980
4152
  /** Options for `board.me.resume.upload`. */
@@ -5577,6 +5749,155 @@ declare function createBoardClient(options: CreateBoardClientOptions): {
5577
5749
  }>;
5578
5750
  unsave(jobId: string, query?: Record<string, never>, options?: FetchOptions): Promise<void>;
5579
5751
  };
5752
+ conversations: {
5753
+ list(query?: ConversationsListQuery, options?: FetchOptions): Promise<ListEnvelope<{
5754
+ id: string;
5755
+ object: "conversation";
5756
+ lastMessageAt: string;
5757
+ lastMessageSnippet: string;
5758
+ lastMessageAuthorBoardUserId: string;
5759
+ archivedAt: string | null;
5760
+ hasUnread: boolean;
5761
+ counterparty: components["schemas"]["ConversationCounterparty"];
5762
+ }>>;
5763
+ unreadCount(options?: FetchOptions): Promise<{
5764
+ object: "unread_count";
5765
+ count: number;
5766
+ }>;
5767
+ retrieve(id: string, options?: FetchOptions): Promise<{
5768
+ id: string;
5769
+ object: "conversation";
5770
+ lastMessageAt: string;
5771
+ lastMessageSnippet: string;
5772
+ lastMessageAuthorBoardUserId: string;
5773
+ archivedAt: string | null;
5774
+ hasUnread: boolean;
5775
+ counterparty: components["schemas"]["ConversationCounterparty"];
5776
+ } & {
5777
+ viewerRole: "employer" | "candidate";
5778
+ viewerLastReadMessageId: string | null;
5779
+ }>;
5780
+ listMessages(id: string, query?: ThreadMessagesQuery, options?: FetchOptions): Promise<ListEnvelope<{
5781
+ id: string;
5782
+ object: "message";
5783
+ conversationId: string;
5784
+ authorBoardUserId: string;
5785
+ recipientBoardUserId: string;
5786
+ body: string;
5787
+ author: components["schemas"]["MessageAuthor"];
5788
+ sentAt: string;
5789
+ editedAt: string | null;
5790
+ deletedAt: string | null;
5791
+ readAt: string | null;
5792
+ }>>;
5793
+ start(body: StartConversationBody, options?: FetchOptions): Promise<{
5794
+ id: string;
5795
+ object: "message";
5796
+ conversationId: string;
5797
+ authorBoardUserId: string;
5798
+ recipientBoardUserId: string;
5799
+ body: string;
5800
+ author: components["schemas"]["MessageAuthor"];
5801
+ sentAt: string;
5802
+ editedAt: string | null;
5803
+ deletedAt: string | null;
5804
+ readAt: string | null;
5805
+ }>;
5806
+ startAboutApplication(body: StartAboutApplicationBody, options?: FetchOptions): Promise<{
5807
+ id: string;
5808
+ object: "message";
5809
+ conversationId: string;
5810
+ authorBoardUserId: string;
5811
+ recipientBoardUserId: string;
5812
+ body: string;
5813
+ author: components["schemas"]["MessageAuthor"];
5814
+ sentAt: string;
5815
+ editedAt: string | null;
5816
+ deletedAt: string | null;
5817
+ readAt: string | null;
5818
+ }>;
5819
+ reply(id: string, body: ReplyBody, options?: FetchOptions): Promise<{
5820
+ id: string;
5821
+ object: "message";
5822
+ conversationId: string;
5823
+ authorBoardUserId: string;
5824
+ recipientBoardUserId: string;
5825
+ body: string;
5826
+ author: components["schemas"]["MessageAuthor"];
5827
+ sentAt: string;
5828
+ editedAt: string | null;
5829
+ deletedAt: string | null;
5830
+ readAt: string | null;
5831
+ }>;
5832
+ markRead(id: string, options?: FetchOptions): Promise<{
5833
+ object: "read_receipt";
5834
+ markedAt: string;
5835
+ }>;
5836
+ archive(id: string, options?: FetchOptions): Promise<{
5837
+ object: "conversation_archive";
5838
+ archivedAt: string | null;
5839
+ }>;
5840
+ unarchive(id: string, options?: FetchOptions): Promise<{
5841
+ object: "conversation_archive";
5842
+ archivedAt: string | null;
5843
+ }>;
5844
+ findExisting(query: FindExistingConversationQuery, options?: FetchOptions): Promise<{
5845
+ object: "conversation_ref";
5846
+ conversationId: string | null;
5847
+ }>;
5848
+ };
5849
+ blocks: {
5850
+ list(options?: FetchOptions): Promise<ListEnvelope<{
5851
+ id: string;
5852
+ object: "blocked_user";
5853
+ boardUserId: string;
5854
+ displayName: string;
5855
+ avatarUrl: string | null;
5856
+ createdAt: string;
5857
+ }>>;
5858
+ create(body: BlockUserBody, options?: FetchOptions): Promise<{
5859
+ object: "block";
5860
+ blocked: true;
5861
+ }>;
5862
+ remove(boardUserId: string, options?: FetchOptions): Promise<void>;
5863
+ status(boardUserId: string, options?: FetchOptions): Promise<{
5864
+ object: "block_status";
5865
+ blocked: boolean;
5866
+ }>;
5867
+ };
5868
+ messages: {
5869
+ edit(id: string, body: EditMessageBody, options?: FetchOptions): Promise<{
5870
+ id: string;
5871
+ object: "message";
5872
+ conversationId: string;
5873
+ authorBoardUserId: string;
5874
+ recipientBoardUserId: string;
5875
+ body: string;
5876
+ author: components["schemas"]["MessageAuthor"];
5877
+ sentAt: string;
5878
+ editedAt: string | null;
5879
+ deletedAt: string | null;
5880
+ readAt: string | null;
5881
+ }>;
5882
+ unsend(id: string, options?: FetchOptions): Promise<{
5883
+ id: string;
5884
+ object: "message";
5885
+ conversationId: string;
5886
+ authorBoardUserId: string;
5887
+ recipientBoardUserId: string;
5888
+ body: string;
5889
+ author: components["schemas"]["MessageAuthor"];
5890
+ sentAt: string;
5891
+ editedAt: string | null;
5892
+ deletedAt: string | null;
5893
+ readAt: string | null;
5894
+ }>;
5895
+ report(id: string, body: ReportBody, options?: FetchOptions): Promise<{
5896
+ object: "moderation_report";
5897
+ id: string;
5898
+ blocked: boolean;
5899
+ }>;
5900
+ };
5580
5901
  };
5581
5902
  password: {
5582
5903
  verify(password: string, options?: FetchOptions): Promise<BoardAccessGrant>;
@@ -6276,4 +6597,4 @@ declare function createBoardClient(options: CreateBoardClientOptions): {
6276
6597
  };
6277
6598
  type BoardSdk = ReturnType<typeof createBoardClient>;
6278
6599
 
6279
- export { ACCESS_TOKEN_KEY, type AddApplicantNoteBody, type Alert, type AlertBody, type Application, type ApplicationsListQuery, type ApplyBody, type Awaitable, BOARD_ACCESS_GRANT_KEY, type BlogAuthorEmbed, type BlogPostsListQuery, type BlogSearchBody, type BlogSimilarQuery, type BlogTagEmbed, type BoardAccessGrant, BoardApiError, type BoardAuthSession, BoardClient, type BoardRequest, type BoardSdk, type BoardSeo, type BoardUser, type BulkMoveApplicantsBody, type BulkRejectApplicantsBody, type CandidateAvatar, type CandidateEducation, type CandidateExperience, type CandidateLanguage, type CandidateProfile, type CandidateSkill, type ClaimableCompany, type CompaniesListQuery, type CompaniesSearchBody, type CompanyCategorySalary, type CompanyJobsListQuery, type CompanyListEnvelope, type CompanyMarket, type CompanyMarketRef, type CompanyMarketsListQuery, type CompanyMembership, type CompanySalary, type CompanySimilarQuery, type ConfirmWorkEmailBody, type ConsumeMagicLinkBody, type CreateBoardClientOptions, type CreateCompanyBody, type CreateEducationBody, type CreateEmployerJobBody, type CreateExperienceBody, type CreateJobPostingInput, type CreatePipelineStageBody, type CustomStorage, type EducationRequirement, type EmbedJobsQuery, type EmployerApplicant, type EmployerBillingOption, type EmployerCheckout, type EmployerCheckoutBody, type EmployerCompany, type EmployerCompanySearchQuery, type EmployerJob, type EmployerJobSummary, type EmployerJobsListQuery, type EmployerPipeline, type EmployerPipelineQuery, type EmployerPipelineStage, type EmploymentType, type FetchOptions, type ForgotPasswordBody, type HandleAvailability, type JobAlertConfirmation, type JobAlertDeletePreferenceInput, type JobAlertFiltersInput, type JobAlertFrequency, type JobAlertManageQuery, type JobAlertManageResult, type JobAlertManageState, type JobAlertManageTokenInput, type JobAlertPreference, type JobAlertRemoteOption, type JobAlertResendResult, type JobAlertStoredFilters, type JobAlertSubscribeInput, type JobAlertSubscription, type JobAlertUpdatePreferenceInput, type JobCardListEnvelope, type JobCardSearchEnvelope, type JobCompany, type JobPostingBillingCheck, type JobPostingBillingOptions, type JobPostingBillingVerification, type JobPostingLogoResult, type JobPostingPlan, type JobPostingResult, type JobPostingSubscriptionEntitlements, type JobSort, type JobsListQuery, type JobsSearchBody, type LegalEntity, type LegalPageType, type ListEnvelope, type LocationSalaryDetail, type LocationSkillsIndex, type LocationTitlesIndex, type Logger, type LoginBody, type LogoutBody, type MoveApplicantStageBody, type NotificationPreference, type OAuthAuthorizationQuery, type OAuthAuthorizationUrl, type OAuthExchangeBody, type OAuthProvider, type OfficeLocation, type PlacesListQuery, type Plan, type PlanListEnvelope, type PlansListQuery, type PublicBlogAdjacentPosts, type PublicBlogAuthor, type PublicBlogPost, type PublicBlogPostSummary, type PublicBlogTag, type PublicBoard, type PublicBoardAnalytics, type PublicBoardFeatures, type PublicBoardTheme, type PublicCompany, type PublicCompanyDetail, type PublicJob, type PublicJobCard, type PublicLegalPage, type PublicPlace, REFRESH_TOKEN_KEY, type RedirectResolution, type RefreshBody, type RegisterBody, type RelatedSearch, type RemoteOption, type RemotePermit, type RemoteTimezone, type ReorderPipelineStagesBody, type RequestMagicLinkBody, type ResetPasswordBody, type Resume, type ResumeUploadOptions, SDK_VERSION, type SalaryCompany, type SalaryDetailQuery, type SalaryLocation, type SalarySkill, type SalaryTitle, type SalesLedPlan, type SalesLedPlanListEnvelope, type SaveJobBody, type SavedJob, type SavedJobsListQuery, type SearchEnvelope, type SendWorkEmailBody, type Seniority, type SkillLocationSalary, type SkillLocationsIndex, type SkillSalaryDetail, type StorageMode, type StorefrontPagination, type TalentDirectoryEntry, type TalentDirectoryListEnvelope, type TalentDirectoryQuery, type TalentProfile, type TaxonomyGeo, type TaxonomyResolution, type TitleLocationSalary, type TitleLocationsIndex, type TitleSalaryDetail, type UnsubscribeBody, type UpdateApplicationFactsBody, type UpdateCandidateProfileBody, type UpdateEducationBody, type UpdateEmployerCompanyBody, type UpdateEmployerJobBody, type UpdateExperienceBody, type UpdateLanguagesBody, type UpdateNotificationPreferenceBody, type UpdatePipelineStageBody, type UpdateSkillsBody, type VerifyEmailBody, createBoardClient, isBoardApiError, isBoardPasswordRequired, isConflict, isForbidden, isNotFound, isRateLimited, isUnauthorized, isValidationError };
6600
+ export { ACCESS_TOKEN_KEY, type AddApplicantNoteBody, type Alert, type AlertBody, type Application, type ApplicationsListQuery, type ApplyBody, type Awaitable, BOARD_ACCESS_GRANT_KEY, type Block, type BlockStatus, type BlockUserBody, type BlockedUser, type BlogAuthorEmbed, type BlogPostsListQuery, type BlogSearchBody, type BlogSimilarQuery, type BlogTagEmbed, type BoardAccessGrant, BoardApiError, type BoardAuthSession, BoardClient, type BoardRequest, type BoardSdk, type BoardSeo, type BoardUser, type BulkMoveApplicantsBody, type BulkRejectApplicantsBody, type CandidateAvatar, type CandidateEducation, type CandidateExperience, type CandidateLanguage, type CandidateProfile, type CandidateSkill, type ClaimableCompany, type CompaniesListQuery, type CompaniesSearchBody, type CompanyCategorySalary, type CompanyJobsListQuery, type CompanyListEnvelope, type CompanyMarket, type CompanyMarketRef, type CompanyMarketsListQuery, type CompanyMembership, type CompanySalary, type CompanySimilarQuery, type ConfirmWorkEmailBody, type ConsumeMagicLinkBody, type Conversation, type ConversationArchive, type ConversationDetail, type ConversationRef, type ConversationsListQuery, type CreateBoardClientOptions, type CreateCompanyBody, type CreateEducationBody, type CreateEmployerJobBody, type CreateExperienceBody, type CreateJobPostingInput, type CreatePipelineStageBody, type CustomStorage, type EditMessageBody, type EducationRequirement, type EmbedJobsQuery, type EmployerApplicant, type EmployerBillingOption, type EmployerCheckout, type EmployerCheckoutBody, type EmployerCompany, type EmployerCompanySearchQuery, type EmployerJob, type EmployerJobSummary, type EmployerJobsListQuery, type EmployerPipeline, type EmployerPipelineQuery, type EmployerPipelineStage, type EmploymentType, type FetchOptions, type FindExistingConversationQuery, type ForgotPasswordBody, type HandleAvailability, type JobAlertConfirmation, type JobAlertDeletePreferenceInput, type JobAlertFiltersInput, type JobAlertFrequency, type JobAlertManageQuery, type JobAlertManageResult, type JobAlertManageState, type JobAlertManageTokenInput, type JobAlertPreference, type JobAlertRemoteOption, type JobAlertResendResult, type JobAlertStoredFilters, type JobAlertSubscribeInput, type JobAlertSubscription, type JobAlertUpdatePreferenceInput, type JobCardListEnvelope, type JobCardSearchEnvelope, type JobCompany, type JobPostingBillingCheck, type JobPostingBillingOptions, type JobPostingBillingVerification, type JobPostingLogoResult, type JobPostingPlan, type JobPostingResult, type JobPostingSubscriptionEntitlements, type JobSort, type JobsListQuery, type JobsSearchBody, type LegalEntity, type LegalPageType, type ListEnvelope, type LocationSalaryDetail, type LocationSkillsIndex, type LocationTitlesIndex, type Logger, type LoginBody, type LogoutBody, type Message, type ModerationReport, type MoveApplicantStageBody, type NotificationPreference, type OAuthAuthorizationQuery, type OAuthAuthorizationUrl, type OAuthExchangeBody, type OAuthProvider, type OfficeLocation, type PlacesListQuery, type Plan, type PlanListEnvelope, type PlansListQuery, type PublicBlogAdjacentPosts, type PublicBlogAuthor, type PublicBlogPost, type PublicBlogPostSummary, type PublicBlogTag, type PublicBoard, type PublicBoardAnalytics, type PublicBoardFeatures, type PublicBoardTheme, type PublicCompany, type PublicCompanyDetail, type PublicJob, type PublicJobCard, type PublicLegalPage, type PublicPlace, REFRESH_TOKEN_KEY, type ReadReceipt, type RedirectResolution, type RefreshBody, type RegisterBody, type RelatedSearch, type RemoteOption, type RemotePermit, type RemoteTimezone, type ReorderPipelineStagesBody, type ReplyBody, type ReportBody, type RequestMagicLinkBody, type ResetPasswordBody, type Resume, type ResumeUploadOptions, SDK_VERSION, type SalaryCompany, type SalaryDetailQuery, type SalaryLocation, type SalarySkill, type SalaryTitle, type SalesLedPlan, type SalesLedPlanListEnvelope, type SaveJobBody, type SavedJob, type SavedJobsListQuery, type SearchEnvelope, type SendWorkEmailBody, type Seniority, type SkillLocationSalary, type SkillLocationsIndex, type SkillSalaryDetail, type StartAboutApplicationBody, type StartConversationBody, type StorageMode, type StorefrontPagination, type TalentDirectoryEntry, type TalentDirectoryListEnvelope, type TalentDirectoryQuery, type TalentProfile, type TaxonomyGeo, type TaxonomyResolution, type ThreadMessagesQuery, type TitleLocationSalary, type TitleLocationsIndex, type TitleSalaryDetail, type UnreadCount, type UnsubscribeBody, type UpdateApplicationFactsBody, type UpdateCandidateProfileBody, type UpdateEducationBody, type UpdateEmployerCompanyBody, type UpdateEmployerJobBody, type UpdateExperienceBody, type UpdateLanguagesBody, type UpdateNotificationPreferenceBody, type UpdatePipelineStageBody, type UpdateSkillsBody, type VerifyEmailBody, createBoardClient, isBoardApiError, isBoardPasswordRequired, isConflict, isForbidden, isNotFound, isRateLimited, isUnauthorized, isValidationError };
package/dist/index.js CHANGED
@@ -149,7 +149,7 @@ async function clearSession(storage) {
149
149
  }
150
150
 
151
151
  // src/version.ts
152
- var SDK_VERSION = "1.22.0";
152
+ var SDK_VERSION = "1.23.0";
153
153
 
154
154
  // src/client.ts
155
155
  function isRawBody(body) {
@@ -1804,6 +1804,256 @@ function meNamespace(client) {
1804
1804
  { ...options, method: "DELETE", query }
1805
1805
  );
1806
1806
  }
1807
+ },
1808
+ /**
1809
+ * The authenticated board user's messaging inbox (doc 34 / ADR-0053).
1810
+ * The v1 surface is polled REST — there is no realtime primitive; poll
1811
+ * `list` / `listMessages` / `unreadCount` on an interval (3–5s is the
1812
+ * reference cadence) for near-live updates.
1813
+ */
1814
+ conversations: {
1815
+ /**
1816
+ * List my conversations (each page sorted most-recent-activity-first;
1817
+ * cross-page cursor order is approximate — see the API docs). `archived:
1818
+ * true` returns the archived view. Poll for inbox liveness.
1819
+ *
1820
+ * @example
1821
+ * const { data } = await board.me.conversations.list({ limit: 20 });
1822
+ */
1823
+ list(query, options) {
1824
+ return client.fetch("/me/conversations", {
1825
+ ...options,
1826
+ query
1827
+ });
1828
+ },
1829
+ /**
1830
+ * The count of distinct conversations with an unread message — the
1831
+ * inbox badge. Poll for liveness.
1832
+ *
1833
+ * @example
1834
+ * const { count } = await board.me.conversations.unreadCount();
1835
+ */
1836
+ unreadCount(options) {
1837
+ return client.fetch(
1838
+ "/me/conversations/unread-count",
1839
+ options
1840
+ );
1841
+ },
1842
+ /**
1843
+ * A conversation's header — live-resolved counterparty identity, the
1844
+ * viewer's role, and the viewer's last-read pointer. The messages are a
1845
+ * separate paginated call (`listMessages`).
1846
+ *
1847
+ * @example
1848
+ * const convo = await board.me.conversations.retrieve(id);
1849
+ */
1850
+ retrieve(id, options) {
1851
+ return client.fetch(
1852
+ `/me/conversations/${encodeURIComponent(id)}`,
1853
+ options
1854
+ );
1855
+ },
1856
+ /**
1857
+ * A conversation's messages, oldest-first (append order). Unsent
1858
+ * messages are tombstones (empty `body`, `deletedAt` set). Poll for the
1859
+ * live thread.
1860
+ *
1861
+ * @example
1862
+ * const { data } = await board.me.conversations.listMessages(id, { limit: 50 });
1863
+ */
1864
+ listMessages(id, query, options) {
1865
+ return client.fetch(
1866
+ `/me/conversations/${encodeURIComponent(id)}/messages`,
1867
+ { ...options, query }
1868
+ );
1869
+ },
1870
+ /**
1871
+ * Cold-initiate a conversation with a candidate (employer-only).
1872
+ * Converges on the existing thread. Returns the created message.
1873
+ *
1874
+ * @example
1875
+ * const msg = await board.me.conversations.start({ candidateBoardUserId, body: 'Hi!' });
1876
+ */
1877
+ start(body, options) {
1878
+ return client.fetch("/me/conversations", {
1879
+ ...options,
1880
+ method: "POST",
1881
+ body
1882
+ });
1883
+ },
1884
+ /**
1885
+ * Message an applicant from the ATS (application context, outside the
1886
+ * talent paywall). Returns the created message.
1887
+ *
1888
+ * @example
1889
+ * const msg = await board.me.conversations.startAboutApplication({ applicationId, body: '…' });
1890
+ */
1891
+ startAboutApplication(body, options) {
1892
+ return client.fetch("/me/conversations/about-application", {
1893
+ ...options,
1894
+ method: "POST",
1895
+ body
1896
+ });
1897
+ },
1898
+ /**
1899
+ * Reply in an existing conversation. Returns the created message.
1900
+ *
1901
+ * @example
1902
+ * const msg = await board.me.conversations.reply(id, { body: 'Sounds good' });
1903
+ */
1904
+ reply(id, body, options) {
1905
+ return client.fetch(
1906
+ `/me/conversations/${encodeURIComponent(id)}/reply`,
1907
+ { ...options, method: "POST", body }
1908
+ );
1909
+ },
1910
+ /**
1911
+ * Mark a conversation read for the viewer. Idempotent.
1912
+ *
1913
+ * @example
1914
+ * await board.me.conversations.markRead(id);
1915
+ */
1916
+ markRead(id, options) {
1917
+ return client.fetch(
1918
+ `/me/conversations/${encodeURIComponent(id)}/read`,
1919
+ { ...options, method: "POST" }
1920
+ );
1921
+ },
1922
+ /**
1923
+ * Archive a conversation for the viewer (per-side). Idempotent.
1924
+ *
1925
+ * @example
1926
+ * await board.me.conversations.archive(id);
1927
+ */
1928
+ archive(id, options) {
1929
+ return client.fetch(
1930
+ `/me/conversations/${encodeURIComponent(id)}/archive`,
1931
+ { ...options, method: "POST" }
1932
+ );
1933
+ },
1934
+ /**
1935
+ * Move an archived conversation back to the main inbox. Idempotent.
1936
+ *
1937
+ * @example
1938
+ * await board.me.conversations.unarchive(id);
1939
+ */
1940
+ unarchive(id, options) {
1941
+ return client.fetch(
1942
+ `/me/conversations/${encodeURIComponent(id)}/unarchive`,
1943
+ { ...options, method: "POST" }
1944
+ );
1945
+ },
1946
+ /**
1947
+ * The existing employer↔candidate conversation id (or null). Tier-3
1948
+ * talent-contact helper — route to an existing thread instead of opening
1949
+ * a composer.
1950
+ *
1951
+ * @example
1952
+ * const { conversationId } = await board.me.conversations.findExisting({ candidateBoardUserId });
1953
+ */
1954
+ findExisting(query, options) {
1955
+ return client.fetch(
1956
+ "/me/conversations/find-existing",
1957
+ { ...options, query }
1958
+ );
1959
+ }
1960
+ },
1961
+ /**
1962
+ * Blocking (doc 34 §E): list / add / remove blocks + a Tier-3 status check.
1963
+ */
1964
+ blocks: {
1965
+ /**
1966
+ * The users I've blocked.
1967
+ *
1968
+ * @example
1969
+ * const { data } = await board.me.blocks.list();
1970
+ */
1971
+ list(options) {
1972
+ return client.fetch("/me/blocks", options);
1973
+ },
1974
+ /**
1975
+ * Block a user (silent). Idempotent.
1976
+ *
1977
+ * @example
1978
+ * await board.me.blocks.create({ boardUserId });
1979
+ */
1980
+ create(body, options) {
1981
+ return client.fetch("/me/blocks", {
1982
+ ...options,
1983
+ method: "POST",
1984
+ body
1985
+ });
1986
+ },
1987
+ /**
1988
+ * Unblock a user. Idempotent.
1989
+ *
1990
+ * @example
1991
+ * await board.me.blocks.remove(boardUserId);
1992
+ */
1993
+ remove(boardUserId, options) {
1994
+ return client.fetch(
1995
+ `/me/blocks/${encodeURIComponent(boardUserId)}`,
1996
+ { ...options, method: "DELETE" }
1997
+ );
1998
+ },
1999
+ /**
2000
+ * Whether I've blocked a user (Tier-3 helper).
2001
+ *
2002
+ * @example
2003
+ * const { blocked } = await board.me.blocks.status(boardUserId);
2004
+ */
2005
+ status(boardUserId, options) {
2006
+ return client.fetch(
2007
+ `/me/blocks/${encodeURIComponent(boardUserId)}`,
2008
+ options
2009
+ );
2010
+ }
2011
+ },
2012
+ /**
2013
+ * Message-scoped actions (doc 34 §E): edit / unsend your own messages
2014
+ * (15-minute window), and report a message addressed to you.
2015
+ */
2016
+ messages: {
2017
+ /**
2018
+ * Edit one of your own messages (within the 15-minute window). Returns
2019
+ * the updated message.
2020
+ *
2021
+ * @example
2022
+ * const msg = await board.me.messages.edit(id, { body: 'fixed typo' });
2023
+ */
2024
+ edit(id, body, options) {
2025
+ return client.fetch(`/me/messages/${encodeURIComponent(id)}`, {
2026
+ ...options,
2027
+ method: "PATCH",
2028
+ body
2029
+ });
2030
+ },
2031
+ /**
2032
+ * Unsend (soft-delete) one of your own messages (within the 15-minute
2033
+ * window). Idempotent. Returns the tombstoned message (empty `body`).
2034
+ *
2035
+ * @example
2036
+ * await board.me.messages.unsend(id);
2037
+ */
2038
+ unsend(id, options) {
2039
+ return client.fetch(`/me/messages/${encodeURIComponent(id)}`, {
2040
+ ...options,
2041
+ method: "DELETE"
2042
+ });
2043
+ },
2044
+ /**
2045
+ * Report a message addressed to you for moderation. Auto-blocks the
2046
+ * author.
2047
+ *
2048
+ * @example
2049
+ * const { blocked } = await board.me.messages.report(id, { reason: 'spam' });
2050
+ */
2051
+ report(id, body, options) {
2052
+ return client.fetch(
2053
+ `/me/messages/${encodeURIComponent(id)}/report`,
2054
+ { ...options, method: "POST", body }
2055
+ );
2056
+ }
1807
2057
  }
1808
2058
  };
1809
2059
  }