featurebase-node 0.14.2 → 0.15.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/CHANGELOG.md +16 -0
- package/client.d.mts +5 -5
- package/client.d.mts.map +1 -1
- package/client.d.ts +5 -5
- package/client.d.ts.map +1 -1
- package/package.json +1 -1
- package/resources/audit-logs.d.mts +3 -3
- package/resources/audit-logs.d.mts.map +1 -1
- package/resources/audit-logs.d.ts +3 -3
- package/resources/audit-logs.d.ts.map +1 -1
- package/resources/changelogs/changelogs.d.mts +116 -116
- package/resources/changelogs/changelogs.d.mts.map +1 -1
- package/resources/changelogs/changelogs.d.ts +116 -116
- package/resources/changelogs/changelogs.d.ts.map +1 -1
- package/resources/changelogs/changelogs.js +74 -74
- package/resources/changelogs/changelogs.js.map +1 -1
- package/resources/changelogs/changelogs.mjs +74 -74
- package/resources/changelogs/changelogs.mjs.map +1 -1
- package/resources/changelogs/index.d.mts +1 -1
- package/resources/changelogs/index.d.mts.map +1 -1
- package/resources/changelogs/index.d.ts +1 -1
- package/resources/changelogs/index.d.ts.map +1 -1
- package/resources/changelogs/subscribers.d.mts +3 -3
- package/resources/changelogs/subscribers.d.mts.map +1 -1
- package/resources/changelogs/subscribers.d.ts +3 -3
- package/resources/changelogs/subscribers.d.ts.map +1 -1
- package/resources/conversation-attributes.d.mts +17 -17
- package/resources/conversation-attributes.d.mts.map +1 -1
- package/resources/conversation-attributes.d.ts +17 -17
- package/resources/conversation-attributes.d.ts.map +1 -1
- package/resources/conversation-attributes.js +19 -19
- package/resources/conversation-attributes.js.map +1 -1
- package/resources/conversation-attributes.mjs +19 -19
- package/resources/conversation-attributes.mjs.map +1 -1
- package/resources/feedback/boards.d.mts +19 -19
- package/resources/feedback/boards.d.mts.map +1 -1
- package/resources/feedback/boards.d.ts +19 -19
- package/resources/feedback/boards.d.ts.map +1 -1
- package/resources/feedback/boards.js +20 -20
- package/resources/feedback/boards.js.map +1 -1
- package/resources/feedback/boards.mjs +20 -20
- package/resources/feedback/boards.mjs.map +1 -1
- package/resources/feedback/comments.d.mts +113 -113
- package/resources/feedback/comments.d.mts.map +1 -1
- package/resources/feedback/comments.d.ts +113 -113
- package/resources/feedback/comments.d.ts.map +1 -1
- package/resources/feedback/comments.js +93 -93
- package/resources/feedback/comments.js.map +1 -1
- package/resources/feedback/comments.mjs +93 -93
- package/resources/feedback/comments.mjs.map +1 -1
- package/resources/feedback/custom-fields.d.mts +36 -36
- package/resources/feedback/custom-fields.d.mts.map +1 -1
- package/resources/feedback/custom-fields.d.ts +36 -36
- package/resources/feedback/custom-fields.d.ts.map +1 -1
- package/resources/feedback/custom-fields.js +36 -36
- package/resources/feedback/custom-fields.js.map +1 -1
- package/resources/feedback/custom-fields.mjs +36 -36
- package/resources/feedback/custom-fields.mjs.map +1 -1
- package/resources/feedback/feedback.d.mts +6 -6
- package/resources/feedback/feedback.d.mts.map +1 -1
- package/resources/feedback/feedback.d.ts +6 -6
- package/resources/feedback/feedback.d.ts.map +1 -1
- package/resources/feedback/feedback.js.map +1 -1
- package/resources/feedback/feedback.mjs.map +1 -1
- package/resources/feedback/index.d.mts +5 -5
- package/resources/feedback/index.d.mts.map +1 -1
- package/resources/feedback/index.d.ts +5 -5
- package/resources/feedback/index.d.ts.map +1 -1
- package/resources/feedback/index.js.map +1 -1
- package/resources/feedback/index.mjs.map +1 -1
- package/resources/feedback/post-statuses.d.mts +20 -20
- package/resources/feedback/post-statuses.d.mts.map +1 -1
- package/resources/feedback/post-statuses.d.ts +20 -20
- package/resources/feedback/post-statuses.d.ts.map +1 -1
- package/resources/feedback/post-statuses.js +23 -23
- package/resources/feedback/post-statuses.js.map +1 -1
- package/resources/feedback/post-statuses.mjs +23 -23
- package/resources/feedback/post-statuses.mjs.map +1 -1
- package/resources/feedback/posts/index.d.mts +1 -1
- package/resources/feedback/posts/index.d.mts.map +1 -1
- package/resources/feedback/posts/index.d.ts +1 -1
- package/resources/feedback/posts/index.d.ts.map +1 -1
- package/resources/feedback/posts/index.js.map +1 -1
- package/resources/feedback/posts/index.mjs.map +1 -1
- package/resources/feedback/posts/posts.d.mts +169 -102
- package/resources/feedback/posts/posts.d.mts.map +1 -1
- package/resources/feedback/posts/posts.d.ts +169 -102
- package/resources/feedback/posts/posts.d.ts.map +1 -1
- package/resources/feedback/posts/posts.js +144 -75
- package/resources/feedback/posts/posts.js.map +1 -1
- package/resources/feedback/posts/posts.mjs +144 -75
- package/resources/feedback/posts/posts.mjs.map +1 -1
- package/resources/feedback/posts/voters.d.mts +3 -3
- package/resources/feedback/posts/voters.d.mts.map +1 -1
- package/resources/feedback/posts/voters.d.ts +3 -3
- package/resources/feedback/posts/voters.d.ts.map +1 -1
- package/resources/help-center/articles.d.mts +213 -97
- package/resources/help-center/articles.d.mts.map +1 -1
- package/resources/help-center/articles.d.ts +213 -97
- package/resources/help-center/articles.d.ts.map +1 -1
- package/resources/help-center/articles.js +73 -73
- package/resources/help-center/articles.js.map +1 -1
- package/resources/help-center/articles.mjs +73 -73
- package/resources/help-center/articles.mjs.map +1 -1
- package/resources/help-center/collections.d.mts +158 -71
- package/resources/help-center/collections.d.mts.map +1 -1
- package/resources/help-center/collections.d.ts +158 -71
- package/resources/help-center/collections.d.ts.map +1 -1
- package/resources/help-center/collections.js +65 -65
- package/resources/help-center/collections.js.map +1 -1
- package/resources/help-center/collections.mjs +65 -65
- package/resources/help-center/collections.mjs.map +1 -1
- package/resources/help-center/help-center.d.mts +4 -4
- package/resources/help-center/help-center.d.mts.map +1 -1
- package/resources/help-center/help-center.d.ts +4 -4
- package/resources/help-center/help-center.d.ts.map +1 -1
- package/resources/help-center/help-centers.d.mts +77 -48
- package/resources/help-center/help-centers.d.mts.map +1 -1
- package/resources/help-center/help-centers.d.ts +77 -48
- package/resources/help-center/help-centers.d.ts.map +1 -1
- package/resources/help-center/help-centers.js +43 -43
- package/resources/help-center/help-centers.js.map +1 -1
- package/resources/help-center/help-centers.mjs +43 -43
- package/resources/help-center/help-centers.mjs.map +1 -1
- package/resources/help-center/index.d.mts +4 -4
- package/resources/help-center/index.d.mts.map +1 -1
- package/resources/help-center/index.d.ts +4 -4
- package/resources/help-center/index.d.ts.map +1 -1
- package/resources/help-center/redirect-rules.d.mts +124 -124
- package/resources/help-center/redirect-rules.d.mts.map +1 -1
- package/resources/help-center/redirect-rules.d.ts +124 -124
- package/resources/help-center/redirect-rules.d.ts.map +1 -1
- package/resources/help-center/redirect-rules.js +112 -112
- package/resources/help-center/redirect-rules.js.map +1 -1
- package/resources/help-center/redirect-rules.mjs +112 -112
- package/resources/help-center/redirect-rules.mjs.map +1 -1
- package/resources/index.d.mts +5 -5
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +5 -5
- package/resources/index.d.ts.map +1 -1
- package/resources/organization/admins.d.mts +26 -26
- package/resources/organization/admins.d.mts.map +1 -1
- package/resources/organization/admins.d.ts +26 -26
- package/resources/organization/admins.d.ts.map +1 -1
- package/resources/organization/admins.js +25 -25
- package/resources/organization/admins.js.map +1 -1
- package/resources/organization/admins.mjs +25 -25
- package/resources/organization/admins.mjs.map +1 -1
- package/resources/organization/brands.d.mts +52 -52
- package/resources/organization/brands.d.mts.map +1 -1
- package/resources/organization/brands.d.ts +52 -52
- package/resources/organization/brands.d.ts.map +1 -1
- package/resources/organization/brands.js +54 -54
- package/resources/organization/brands.js.map +1 -1
- package/resources/organization/brands.mjs +54 -54
- package/resources/organization/brands.mjs.map +1 -1
- package/resources/organization/index.d.mts +3 -3
- package/resources/organization/index.d.mts.map +1 -1
- package/resources/organization/index.d.ts +3 -3
- package/resources/organization/index.d.ts.map +1 -1
- package/resources/organization/organization.d.mts +3 -3
- package/resources/organization/organization.d.mts.map +1 -1
- package/resources/organization/organization.d.ts +3 -3
- package/resources/organization/organization.d.ts.map +1 -1
- package/resources/organization/teams.d.mts +47 -47
- package/resources/organization/teams.d.mts.map +1 -1
- package/resources/organization/teams.d.ts +47 -47
- package/resources/organization/teams.d.ts.map +1 -1
- package/resources/organization/teams.js +44 -44
- package/resources/organization/teams.js.map +1 -1
- package/resources/organization/teams.mjs +44 -44
- package/resources/organization/teams.mjs.map +1 -1
- package/resources/reports.d.mts +347 -180
- package/resources/reports.d.mts.map +1 -1
- package/resources/reports.d.ts +347 -180
- package/resources/reports.d.ts.map +1 -1
- package/resources/reports.js +124 -99
- package/resources/reports.js.map +1 -1
- package/resources/reports.mjs +124 -99
- package/resources/reports.mjs.map +1 -1
- package/resources/support/conversation-tags.d.mts +43 -43
- package/resources/support/conversation-tags.d.mts.map +1 -1
- package/resources/support/conversation-tags.d.ts +43 -43
- package/resources/support/conversation-tags.d.ts.map +1 -1
- package/resources/support/conversation-tags.js +32 -32
- package/resources/support/conversation-tags.js.map +1 -1
- package/resources/support/conversation-tags.mjs +32 -32
- package/resources/support/conversation-tags.mjs.map +1 -1
- package/resources/support/conversations/conversations.d.mts +402 -351
- package/resources/support/conversations/conversations.d.mts.map +1 -1
- package/resources/support/conversations/conversations.d.ts +402 -351
- package/resources/support/conversations/conversations.d.ts.map +1 -1
- package/resources/support/conversations/conversations.js +340 -295
- package/resources/support/conversations/conversations.js.map +1 -1
- package/resources/support/conversations/conversations.mjs +340 -295
- package/resources/support/conversations/conversations.mjs.map +1 -1
- package/resources/support/conversations/index.d.mts +1 -1
- package/resources/support/conversations/index.d.mts.map +1 -1
- package/resources/support/conversations/index.d.ts +1 -1
- package/resources/support/conversations/index.d.ts.map +1 -1
- package/resources/support/conversations/participants.d.mts +2 -2
- package/resources/support/conversations/participants.d.mts.map +1 -1
- package/resources/support/conversations/participants.d.ts +2 -2
- package/resources/support/conversations/participants.d.ts.map +1 -1
- package/resources/support/index.d.mts +3 -3
- package/resources/support/index.d.mts.map +1 -1
- package/resources/support/index.d.ts +3 -3
- package/resources/support/index.d.ts.map +1 -1
- package/resources/support/support.d.mts +3 -3
- package/resources/support/support.d.mts.map +1 -1
- package/resources/support/support.d.ts +3 -3
- package/resources/support/support.d.ts.map +1 -1
- package/resources/support/tickets/categories.d.mts +20 -20
- package/resources/support/tickets/categories.d.mts.map +1 -1
- package/resources/support/tickets/categories.d.ts +20 -20
- package/resources/support/tickets/categories.d.ts.map +1 -1
- package/resources/support/tickets/categories.js +25 -25
- package/resources/support/tickets/categories.js.map +1 -1
- package/resources/support/tickets/categories.mjs +25 -25
- package/resources/support/tickets/categories.mjs.map +1 -1
- package/resources/support/tickets/custom-fields.d.mts +22 -22
- package/resources/support/tickets/custom-fields.d.mts.map +1 -1
- package/resources/support/tickets/custom-fields.d.ts +22 -22
- package/resources/support/tickets/custom-fields.d.ts.map +1 -1
- package/resources/support/tickets/custom-fields.js +19 -19
- package/resources/support/tickets/custom-fields.js.map +1 -1
- package/resources/support/tickets/custom-fields.mjs +19 -19
- package/resources/support/tickets/custom-fields.mjs.map +1 -1
- package/resources/support/tickets/index.d.mts +4 -4
- package/resources/support/tickets/index.d.mts.map +1 -1
- package/resources/support/tickets/index.d.ts +4 -4
- package/resources/support/tickets/index.d.ts.map +1 -1
- package/resources/support/tickets/statuses.d.mts +19 -19
- package/resources/support/tickets/statuses.d.mts.map +1 -1
- package/resources/support/tickets/statuses.d.ts +19 -19
- package/resources/support/tickets/statuses.d.ts.map +1 -1
- package/resources/support/tickets/statuses.js +21 -21
- package/resources/support/tickets/statuses.js.map +1 -1
- package/resources/support/tickets/statuses.mjs +21 -21
- package/resources/support/tickets/statuses.mjs.map +1 -1
- package/resources/support/tickets/tickets.d.mts +75 -75
- package/resources/support/tickets/tickets.d.mts.map +1 -1
- package/resources/support/tickets/tickets.d.ts +75 -75
- package/resources/support/tickets/tickets.d.ts.map +1 -1
- package/resources/support/tickets/tickets.js +44 -44
- package/resources/support/tickets/tickets.js.map +1 -1
- package/resources/support/tickets/tickets.mjs +44 -44
- package/resources/support/tickets/tickets.mjs.map +1 -1
- package/resources/surveys.d.mts +43 -43
- package/resources/surveys.d.mts.map +1 -1
- package/resources/surveys.d.ts +43 -43
- package/resources/surveys.d.ts.map +1 -1
- package/resources/surveys.js +44 -44
- package/resources/surveys.js.map +1 -1
- package/resources/surveys.mjs +44 -44
- package/resources/surveys.mjs.map +1 -1
- package/resources/users/companies/companies.d.mts +121 -130
- package/resources/users/companies/companies.d.mts.map +1 -1
- package/resources/users/companies/companies.d.ts +121 -130
- package/resources/users/companies/companies.d.ts.map +1 -1
- package/resources/users/companies/companies.js +125 -125
- package/resources/users/companies/companies.js.map +1 -1
- package/resources/users/companies/companies.mjs +125 -125
- package/resources/users/companies/companies.mjs.map +1 -1
- package/resources/users/companies/contacts.d.mts +3 -3
- package/resources/users/companies/contacts.d.mts.map +1 -1
- package/resources/users/companies/contacts.d.ts +3 -3
- package/resources/users/companies/contacts.d.ts.map +1 -1
- package/resources/users/companies/index.d.mts +1 -1
- package/resources/users/companies/index.d.mts.map +1 -1
- package/resources/users/companies/index.d.ts +1 -1
- package/resources/users/companies/index.d.ts.map +1 -1
- package/resources/users/contacts/by-user-id/by-user-id.d.mts +2 -2
- package/resources/users/contacts/by-user-id/by-user-id.d.mts.map +1 -1
- package/resources/users/contacts/by-user-id/by-user-id.d.ts +2 -2
- package/resources/users/contacts/by-user-id/by-user-id.d.ts.map +1 -1
- package/resources/users/contacts/by-user-id/email-preferences.d.mts +2 -2
- package/resources/users/contacts/by-user-id/email-preferences.d.mts.map +1 -1
- package/resources/users/contacts/by-user-id/email-preferences.d.ts +2 -2
- package/resources/users/contacts/by-user-id/email-preferences.d.ts.map +1 -1
- package/resources/users/contacts/contacts.d.mts +249 -235
- package/resources/users/contacts/contacts.d.mts.map +1 -1
- package/resources/users/contacts/contacts.d.ts +249 -235
- package/resources/users/contacts/contacts.d.ts.map +1 -1
- package/resources/users/contacts/contacts.js +211 -184
- package/resources/users/contacts/contacts.js.map +1 -1
- package/resources/users/contacts/contacts.mjs +211 -184
- package/resources/users/contacts/contacts.mjs.map +1 -1
- package/resources/users/contacts/email-preferences.d.mts +2 -2
- package/resources/users/contacts/email-preferences.d.mts.map +1 -1
- package/resources/users/contacts/email-preferences.d.ts +2 -2
- package/resources/users/contacts/email-preferences.d.ts.map +1 -1
- package/resources/users/contacts/index.d.mts +1 -1
- package/resources/users/contacts/index.d.mts.map +1 -1
- package/resources/users/contacts/index.d.ts +1 -1
- package/resources/users/contacts/index.d.ts.map +1 -1
- package/resources/users/index.d.mts +2 -2
- package/resources/users/index.d.mts.map +1 -1
- package/resources/users/index.d.ts +2 -2
- package/resources/users/index.d.ts.map +1 -1
- package/resources/users/users.d.mts +2 -2
- package/resources/users/users.d.mts.map +1 -1
- package/resources/users/users.d.ts +2 -2
- package/resources/users/users.d.ts.map +1 -1
- package/resources/webhooks.d.mts +83 -83
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +83 -83
- package/resources/webhooks.d.ts.map +1 -1
- package/resources/webhooks.js +77 -77
- package/resources/webhooks.js.map +1 -1
- package/resources/webhooks.mjs +77 -77
- package/resources/webhooks.mjs.map +1 -1
- package/src/client.ts +6 -6
- package/src/resources/audit-logs.ts +7 -1
- package/src/resources/changelogs/changelogs.ts +320 -175
- package/src/resources/changelogs/index.ts +1 -1
- package/src/resources/changelogs/subscribers.ts +31 -2
- package/src/resources/conversation-attributes.ts +34 -34
- package/src/resources/feedback/boards.ts +30 -30
- package/src/resources/feedback/comments.ts +137 -137
- package/src/resources/feedback/custom-fields.ts +46 -46
- package/src/resources/feedback/feedback.ts +9 -5
- package/src/resources/feedback/index.ts +7 -5
- package/src/resources/feedback/post-statuses.ts +33 -33
- package/src/resources/feedback/posts/index.ts +3 -1
- package/src/resources/feedback/posts/posts.ts +232 -128
- package/src/resources/feedback/posts/voters.ts +3 -3
- package/src/resources/help-center/articles.ts +631 -109
- package/src/resources/help-center/collections.ts +349 -88
- package/src/resources/help-center/help-center.ts +5 -5
- package/src/resources/help-center/help-centers.ts +202 -57
- package/src/resources/help-center/index.ts +5 -5
- package/src/resources/help-center/redirect-rules.ts +294 -178
- package/src/resources/index.ts +6 -6
- package/src/resources/organization/admins.ts +36 -36
- package/src/resources/organization/brands.ts +68 -68
- package/src/resources/organization/index.ts +3 -3
- package/src/resources/organization/organization.ts +3 -3
- package/src/resources/organization/teams.ts +54 -54
- package/src/resources/reports.ts +454 -232
- package/src/resources/support/conversation-tags.ts +62 -62
- package/src/resources/support/conversations/conversations.ts +489 -438
- package/src/resources/support/conversations/index.ts +4 -4
- package/src/resources/support/conversations/participants.ts +2 -2
- package/src/resources/support/index.ts +7 -7
- package/src/resources/support/support.ts +7 -7
- package/src/resources/support/tickets/categories.ts +35 -35
- package/src/resources/support/tickets/custom-fields.ts +29 -29
- package/src/resources/support/tickets/index.ts +4 -4
- package/src/resources/support/tickets/statuses.ts +31 -31
- package/src/resources/support/tickets/tickets.ts +101 -101
- package/src/resources/surveys.ts +60 -60
- package/src/resources/users/companies/companies.ts +158 -172
- package/src/resources/users/companies/contacts.ts +3 -3
- package/src/resources/users/companies/index.ts +2 -2
- package/src/resources/users/contacts/by-user-id/by-user-id.ts +2 -2
- package/src/resources/users/contacts/by-user-id/email-preferences.ts +2 -2
- package/src/resources/users/contacts/contacts.ts +284 -280
- package/src/resources/users/contacts/email-preferences.ts +2 -2
- package/src/resources/users/contacts/index.ts +3 -3
- package/src/resources/users/index.ts +5 -5
- package/src/resources/users/users.ts +5 -5
- package/src/resources/webhooks.ts +106 -100
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.ts +1 -1
- package/version.js +1 -1
- package/version.mjs +1 -1
|
@@ -23,6 +23,86 @@ import { path } from '../../../internal/utils/path';
|
|
|
23
23
|
export class Companies extends APIResource {
|
|
24
24
|
contacts: ContactsAPI.Contacts = new ContactsAPI.Contacts(this._client);
|
|
25
25
|
|
|
26
|
+
/**
|
|
27
|
+
* Retrieves a single company by its Featurebase ID.
|
|
28
|
+
*
|
|
29
|
+
* ### Path Parameters
|
|
30
|
+
*
|
|
31
|
+
* - `id` - The Featurebase internal ID of the company (MongoDB ObjectId)
|
|
32
|
+
*
|
|
33
|
+
* ### Response
|
|
34
|
+
*
|
|
35
|
+
* Returns a company object with:
|
|
36
|
+
*
|
|
37
|
+
* - `id` - Featurebase internal ID
|
|
38
|
+
* - `companyId` - External company ID from your system
|
|
39
|
+
* - `name` - Company name
|
|
40
|
+
* - `monthlySpend` - Monthly spend/revenue
|
|
41
|
+
* - `industry` - Industry
|
|
42
|
+
* - `website` - Company website URL
|
|
43
|
+
* - `plan` - Plan/tier name
|
|
44
|
+
* - `linkedUsers` - Number of users linked to this company
|
|
45
|
+
* - `companySize` - Employee headcount
|
|
46
|
+
* - `lastActivity` - Last activity timestamp
|
|
47
|
+
* - `customFields` - Custom field values
|
|
48
|
+
* - `createdAt` - Creation timestamp
|
|
49
|
+
* - `updatedAt` - Last update timestamp
|
|
50
|
+
*
|
|
51
|
+
* ### Example Response
|
|
52
|
+
*
|
|
53
|
+
* ```json
|
|
54
|
+
* {
|
|
55
|
+
* "object": "company",
|
|
56
|
+
* "id": "507f1f77bcf86cd799439011",
|
|
57
|
+
* "companyId": "comp_12345",
|
|
58
|
+
* "name": "Acme Inc",
|
|
59
|
+
* "monthlySpend": 5000,
|
|
60
|
+
* "industry": "Technology",
|
|
61
|
+
* "website": "https://acme.com",
|
|
62
|
+
* "plan": "enterprise",
|
|
63
|
+
* "linkedUsers": 15,
|
|
64
|
+
* "companySize": 250,
|
|
65
|
+
* "lastActivity": "2025-01-15T00:00:00.000Z",
|
|
66
|
+
* "customFields": { "location": "Europe" },
|
|
67
|
+
* "createdAt": "2025-01-01T12:00:00.000Z",
|
|
68
|
+
* "updatedAt": "2025-01-10T15:30:00.000Z"
|
|
69
|
+
* }
|
|
70
|
+
* ```
|
|
71
|
+
*
|
|
72
|
+
* ### Error Responses
|
|
73
|
+
*
|
|
74
|
+
* - **404 Not Found** - Company with the specified ID does not exist
|
|
75
|
+
*
|
|
76
|
+
* ### Version Availability
|
|
77
|
+
*
|
|
78
|
+
* This endpoint is only available in API version 2026-01-01.nova and newer.
|
|
79
|
+
*
|
|
80
|
+
* @example
|
|
81
|
+
* ```ts
|
|
82
|
+
* const company = await client.users.companies.retrieve(
|
|
83
|
+
* '507f1f77bcf86cd799439011',
|
|
84
|
+
* );
|
|
85
|
+
* ```
|
|
86
|
+
*/
|
|
87
|
+
retrieve(
|
|
88
|
+
id: string,
|
|
89
|
+
params: CompanyRetrieveParams | null | undefined = {},
|
|
90
|
+
options?: RequestOptions,
|
|
91
|
+
): APIPromise<Company> {
|
|
92
|
+
const { 'Featurebase-Version': featurebaseVersion } = params ?? {};
|
|
93
|
+
return this._client.get(path`/v2/companies/${id}`, {
|
|
94
|
+
...options,
|
|
95
|
+
headers: buildHeaders([
|
|
96
|
+
{
|
|
97
|
+
...(featurebaseVersion?.toString() != null ?
|
|
98
|
+
{ 'Featurebase-Version': featurebaseVersion?.toString() }
|
|
99
|
+
: undefined),
|
|
100
|
+
},
|
|
101
|
+
options?.headers,
|
|
102
|
+
]),
|
|
103
|
+
});
|
|
104
|
+
}
|
|
105
|
+
|
|
26
106
|
/**
|
|
27
107
|
* Returns all companies in your organization with cursor-based pagination.
|
|
28
108
|
*
|
|
@@ -115,6 +195,61 @@ export class Companies extends APIResource {
|
|
|
115
195
|
});
|
|
116
196
|
}
|
|
117
197
|
|
|
198
|
+
/**
|
|
199
|
+
* Deletes a company by its Featurebase ID.
|
|
200
|
+
*
|
|
201
|
+
* This will also remove the company from all linked users' associations.
|
|
202
|
+
*
|
|
203
|
+
* ### Path Parameters
|
|
204
|
+
*
|
|
205
|
+
* - `id` - The Featurebase internal ID of the company (MongoDB ObjectId)
|
|
206
|
+
*
|
|
207
|
+
* ### Response
|
|
208
|
+
*
|
|
209
|
+
* Returns a deletion confirmation object:
|
|
210
|
+
*
|
|
211
|
+
* ```json
|
|
212
|
+
* {
|
|
213
|
+
* "id": "507f1f77bcf86cd799439011",
|
|
214
|
+
* "object": "company",
|
|
215
|
+
* "deleted": true
|
|
216
|
+
* }
|
|
217
|
+
* ```
|
|
218
|
+
*
|
|
219
|
+
* ### Error Responses
|
|
220
|
+
*
|
|
221
|
+
* - **404 Not Found** - Company with the specified ID does not exist
|
|
222
|
+
*
|
|
223
|
+
* ### Version Availability
|
|
224
|
+
*
|
|
225
|
+
* This endpoint is only available in API version 2026-01-01.nova and newer.
|
|
226
|
+
*
|
|
227
|
+
* @example
|
|
228
|
+
* ```ts
|
|
229
|
+
* const deletedCompany = await client.users.companies.delete(
|
|
230
|
+
* '507f1f77bcf86cd799439011',
|
|
231
|
+
* );
|
|
232
|
+
* ```
|
|
233
|
+
*/
|
|
234
|
+
delete(
|
|
235
|
+
id: string,
|
|
236
|
+
params: CompanyDeleteParams | null | undefined = {},
|
|
237
|
+
options?: RequestOptions,
|
|
238
|
+
): APIPromise<DeletedCompany> {
|
|
239
|
+
const { 'Featurebase-Version': featurebaseVersion } = params ?? {};
|
|
240
|
+
return this._client.delete(path`/v2/companies/${id}`, {
|
|
241
|
+
...options,
|
|
242
|
+
headers: buildHeaders([
|
|
243
|
+
{
|
|
244
|
+
...(featurebaseVersion?.toString() != null ?
|
|
245
|
+
{ 'Featurebase-Version': featurebaseVersion?.toString() }
|
|
246
|
+
: undefined),
|
|
247
|
+
},
|
|
248
|
+
options?.headers,
|
|
249
|
+
]),
|
|
250
|
+
});
|
|
251
|
+
}
|
|
252
|
+
|
|
118
253
|
/**
|
|
119
254
|
* Creates a new company or updates an existing one.
|
|
120
255
|
*
|
|
@@ -206,141 +341,6 @@ export class Companies extends APIResource {
|
|
|
206
341
|
});
|
|
207
342
|
}
|
|
208
343
|
|
|
209
|
-
/**
|
|
210
|
-
* Retrieves a single company by its Featurebase ID.
|
|
211
|
-
*
|
|
212
|
-
* ### Path Parameters
|
|
213
|
-
*
|
|
214
|
-
* - `id` - The Featurebase internal ID of the company (MongoDB ObjectId)
|
|
215
|
-
*
|
|
216
|
-
* ### Response
|
|
217
|
-
*
|
|
218
|
-
* Returns a company object with:
|
|
219
|
-
*
|
|
220
|
-
* - `id` - Featurebase internal ID
|
|
221
|
-
* - `companyId` - External company ID from your system
|
|
222
|
-
* - `name` - Company name
|
|
223
|
-
* - `monthlySpend` - Monthly spend/revenue
|
|
224
|
-
* - `industry` - Industry
|
|
225
|
-
* - `website` - Company website URL
|
|
226
|
-
* - `plan` - Plan/tier name
|
|
227
|
-
* - `linkedUsers` - Number of users linked to this company
|
|
228
|
-
* - `companySize` - Employee headcount
|
|
229
|
-
* - `lastActivity` - Last activity timestamp
|
|
230
|
-
* - `customFields` - Custom field values
|
|
231
|
-
* - `createdAt` - Creation timestamp
|
|
232
|
-
* - `updatedAt` - Last update timestamp
|
|
233
|
-
*
|
|
234
|
-
* ### Example Response
|
|
235
|
-
*
|
|
236
|
-
* ```json
|
|
237
|
-
* {
|
|
238
|
-
* "object": "company",
|
|
239
|
-
* "id": "507f1f77bcf86cd799439011",
|
|
240
|
-
* "companyId": "comp_12345",
|
|
241
|
-
* "name": "Acme Inc",
|
|
242
|
-
* "monthlySpend": 5000,
|
|
243
|
-
* "industry": "Technology",
|
|
244
|
-
* "website": "https://acme.com",
|
|
245
|
-
* "plan": "enterprise",
|
|
246
|
-
* "linkedUsers": 15,
|
|
247
|
-
* "companySize": 250,
|
|
248
|
-
* "lastActivity": "2025-01-15T00:00:00.000Z",
|
|
249
|
-
* "customFields": { "location": "Europe" },
|
|
250
|
-
* "createdAt": "2025-01-01T12:00:00.000Z",
|
|
251
|
-
* "updatedAt": "2025-01-10T15:30:00.000Z"
|
|
252
|
-
* }
|
|
253
|
-
* ```
|
|
254
|
-
*
|
|
255
|
-
* ### Error Responses
|
|
256
|
-
*
|
|
257
|
-
* - **404 Not Found** - Company with the specified ID does not exist
|
|
258
|
-
*
|
|
259
|
-
* ### Version Availability
|
|
260
|
-
*
|
|
261
|
-
* This endpoint is only available in API version 2026-01-01.nova and newer.
|
|
262
|
-
*
|
|
263
|
-
* @example
|
|
264
|
-
* ```ts
|
|
265
|
-
* const company = await client.users.companies.retrieve(
|
|
266
|
-
* '507f1f77bcf86cd799439011',
|
|
267
|
-
* );
|
|
268
|
-
* ```
|
|
269
|
-
*/
|
|
270
|
-
retrieve(
|
|
271
|
-
id: string,
|
|
272
|
-
params: CompanyRetrieveParams | null | undefined = {},
|
|
273
|
-
options?: RequestOptions,
|
|
274
|
-
): APIPromise<Company> {
|
|
275
|
-
const { 'Featurebase-Version': featurebaseVersion } = params ?? {};
|
|
276
|
-
return this._client.get(path`/v2/companies/${id}`, {
|
|
277
|
-
...options,
|
|
278
|
-
headers: buildHeaders([
|
|
279
|
-
{
|
|
280
|
-
...(featurebaseVersion?.toString() != null ?
|
|
281
|
-
{ 'Featurebase-Version': featurebaseVersion?.toString() }
|
|
282
|
-
: undefined),
|
|
283
|
-
},
|
|
284
|
-
options?.headers,
|
|
285
|
-
]),
|
|
286
|
-
});
|
|
287
|
-
}
|
|
288
|
-
|
|
289
|
-
/**
|
|
290
|
-
* Deletes a company by its Featurebase ID.
|
|
291
|
-
*
|
|
292
|
-
* This will also remove the company from all linked users' associations.
|
|
293
|
-
*
|
|
294
|
-
* ### Path Parameters
|
|
295
|
-
*
|
|
296
|
-
* - `id` - The Featurebase internal ID of the company (MongoDB ObjectId)
|
|
297
|
-
*
|
|
298
|
-
* ### Response
|
|
299
|
-
*
|
|
300
|
-
* Returns a deletion confirmation object:
|
|
301
|
-
*
|
|
302
|
-
* ```json
|
|
303
|
-
* {
|
|
304
|
-
* "id": "507f1f77bcf86cd799439011",
|
|
305
|
-
* "object": "company",
|
|
306
|
-
* "deleted": true
|
|
307
|
-
* }
|
|
308
|
-
* ```
|
|
309
|
-
*
|
|
310
|
-
* ### Error Responses
|
|
311
|
-
*
|
|
312
|
-
* - **404 Not Found** - Company with the specified ID does not exist
|
|
313
|
-
*
|
|
314
|
-
* ### Version Availability
|
|
315
|
-
*
|
|
316
|
-
* This endpoint is only available in API version 2026-01-01.nova and newer.
|
|
317
|
-
*
|
|
318
|
-
* @example
|
|
319
|
-
* ```ts
|
|
320
|
-
* const deletedCompany = await client.users.companies.delete(
|
|
321
|
-
* '507f1f77bcf86cd799439011',
|
|
322
|
-
* );
|
|
323
|
-
* ```
|
|
324
|
-
*/
|
|
325
|
-
delete(
|
|
326
|
-
id: string,
|
|
327
|
-
params: CompanyDeleteParams | null | undefined = {},
|
|
328
|
-
options?: RequestOptions,
|
|
329
|
-
): APIPromise<DeletedCompany> {
|
|
330
|
-
const { 'Featurebase-Version': featurebaseVersion } = params ?? {};
|
|
331
|
-
return this._client.delete(path`/v2/companies/${id}`, {
|
|
332
|
-
...options,
|
|
333
|
-
headers: buildHeaders([
|
|
334
|
-
{
|
|
335
|
-
...(featurebaseVersion?.toString() != null ?
|
|
336
|
-
{ 'Featurebase-Version': featurebaseVersion?.toString() }
|
|
337
|
-
: undefined),
|
|
338
|
-
},
|
|
339
|
-
options?.headers,
|
|
340
|
-
]),
|
|
341
|
-
});
|
|
342
|
-
}
|
|
343
|
-
|
|
344
344
|
/**
|
|
345
345
|
* Permanently deletes a company by its external company ID (the `companyId` from
|
|
346
346
|
* your system).
|
|
@@ -715,12 +715,28 @@ export namespace CompanySearchResponse {
|
|
|
715
715
|
}
|
|
716
716
|
}
|
|
717
717
|
|
|
718
|
+
export interface CompanyRetrieveParams {
|
|
719
|
+
/**
|
|
720
|
+
* API version for this request. Defaults to your organization's configured API
|
|
721
|
+
* version if not specified.
|
|
722
|
+
*/
|
|
723
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
724
|
+
}
|
|
725
|
+
|
|
718
726
|
export interface CompanyListParams extends CursorPageParams {
|
|
719
727
|
/**
|
|
720
728
|
* Header param: API version for this request. Defaults to your organization's
|
|
721
729
|
* configured API version if not specified.
|
|
722
730
|
*/
|
|
723
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
731
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
732
|
+
}
|
|
733
|
+
|
|
734
|
+
export interface CompanyDeleteParams {
|
|
735
|
+
/**
|
|
736
|
+
* API version for this request. Defaults to your organization's configured API
|
|
737
|
+
* version if not specified.
|
|
738
|
+
*/
|
|
739
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
724
740
|
}
|
|
725
741
|
|
|
726
742
|
export interface CompanyCreateOrUpdateParams {
|
|
@@ -749,7 +765,7 @@ export interface CompanyCreateOrUpdateParams {
|
|
|
749
765
|
* Body param: Custom field values on the company. Values can be string, number,
|
|
750
766
|
* boolean, null, or array of primitives.
|
|
751
767
|
*/
|
|
752
|
-
customFields?:
|
|
768
|
+
customFields?: { [key: string]: string | number | boolean | Array<string | number | boolean> | null };
|
|
753
769
|
|
|
754
770
|
/**
|
|
755
771
|
* Body param: Industry the company operates in
|
|
@@ -775,37 +791,7 @@ export interface CompanyCreateOrUpdateParams {
|
|
|
775
791
|
* Header param: API version for this request. Defaults to your organization's
|
|
776
792
|
* configured API version if not specified.
|
|
777
793
|
*/
|
|
778
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
779
|
-
}
|
|
780
|
-
|
|
781
|
-
export namespace CompanyCreateOrUpdateParams {
|
|
782
|
-
/**
|
|
783
|
-
* Custom field values on the company. Values can be string, number, boolean, null,
|
|
784
|
-
* or array of primitives.
|
|
785
|
-
*/
|
|
786
|
-
export interface CustomFields {
|
|
787
|
-
priority?: string;
|
|
788
|
-
|
|
789
|
-
region?: string;
|
|
790
|
-
|
|
791
|
-
tier?: string;
|
|
792
|
-
}
|
|
793
|
-
}
|
|
794
|
-
|
|
795
|
-
export interface CompanyRetrieveParams {
|
|
796
|
-
/**
|
|
797
|
-
* API version for this request. Defaults to your organization's configured API
|
|
798
|
-
* version if not specified.
|
|
799
|
-
*/
|
|
800
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
801
|
-
}
|
|
802
|
-
|
|
803
|
-
export interface CompanyDeleteParams {
|
|
804
|
-
/**
|
|
805
|
-
* API version for this request. Defaults to your organization's configured API
|
|
806
|
-
* version if not specified.
|
|
807
|
-
*/
|
|
808
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
794
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
809
795
|
}
|
|
810
796
|
|
|
811
797
|
export interface CompanyDeleteByCompanyIDParams {
|
|
@@ -813,7 +799,7 @@ export interface CompanyDeleteByCompanyIDParams {
|
|
|
813
799
|
* API version for this request. Defaults to your organization's configured API
|
|
814
800
|
* version if not specified.
|
|
815
801
|
*/
|
|
816
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
802
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
817
803
|
}
|
|
818
804
|
|
|
819
805
|
export interface CompanySearchParams {
|
|
@@ -859,7 +845,7 @@ export interface CompanySearchParams {
|
|
|
859
845
|
* Header param: API version for this request. Defaults to your organization's
|
|
860
846
|
* configured API version if not specified.
|
|
861
847
|
*/
|
|
862
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
848
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
863
849
|
}
|
|
864
850
|
|
|
865
851
|
Companies.Contacts = Contacts;
|
|
@@ -870,10 +856,10 @@ export declare namespace Companies {
|
|
|
870
856
|
type DeletedCompany as DeletedCompany,
|
|
871
857
|
type CompanySearchResponse as CompanySearchResponse,
|
|
872
858
|
type CompaniesCursorPage as CompaniesCursorPage,
|
|
873
|
-
type CompanyListParams as CompanyListParams,
|
|
874
|
-
type CompanyCreateOrUpdateParams as CompanyCreateOrUpdateParams,
|
|
875
859
|
type CompanyRetrieveParams as CompanyRetrieveParams,
|
|
860
|
+
type CompanyListParams as CompanyListParams,
|
|
876
861
|
type CompanyDeleteParams as CompanyDeleteParams,
|
|
862
|
+
type CompanyCreateOrUpdateParams as CompanyCreateOrUpdateParams,
|
|
877
863
|
type CompanyDeleteByCompanyIDParams as CompanyDeleteByCompanyIDParams,
|
|
878
864
|
type CompanySearchParams as CompanySearchParams,
|
|
879
865
|
};
|
|
@@ -269,7 +269,7 @@ export interface ContactListParams extends CursorPageParams {
|
|
|
269
269
|
* Header param: API version for this request. Defaults to your organization's
|
|
270
270
|
* configured API version if not specified.
|
|
271
271
|
*/
|
|
272
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
272
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
273
273
|
}
|
|
274
274
|
|
|
275
275
|
export interface ContactAttachParams {
|
|
@@ -283,7 +283,7 @@ export interface ContactAttachParams {
|
|
|
283
283
|
* Header param: API version for this request. Defaults to your organization's
|
|
284
284
|
* configured API version if not specified.
|
|
285
285
|
*/
|
|
286
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
286
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
287
287
|
}
|
|
288
288
|
|
|
289
289
|
export interface ContactRemoveParams {
|
|
@@ -296,7 +296,7 @@ export interface ContactRemoveParams {
|
|
|
296
296
|
* Header param: API version for this request. Defaults to your organization's
|
|
297
297
|
* configured API version if not specified.
|
|
298
298
|
*/
|
|
299
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
299
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
300
300
|
}
|
|
301
301
|
|
|
302
302
|
export declare namespace Contacts {
|
|
@@ -5,10 +5,10 @@ export {
|
|
|
5
5
|
type Company,
|
|
6
6
|
type DeletedCompany,
|
|
7
7
|
type CompanySearchResponse,
|
|
8
|
-
type CompanyListParams,
|
|
9
|
-
type CompanyCreateOrUpdateParams,
|
|
10
8
|
type CompanyRetrieveParams,
|
|
9
|
+
type CompanyListParams,
|
|
11
10
|
type CompanyDeleteParams,
|
|
11
|
+
type CompanyCreateOrUpdateParams,
|
|
12
12
|
type CompanyDeleteByCompanyIDParams,
|
|
13
13
|
type CompanySearchParams,
|
|
14
14
|
type CompaniesCursorPage,
|
|
@@ -181,7 +181,7 @@ export interface ByUserIDRetrieveParams {
|
|
|
181
181
|
* API version for this request. Defaults to your organization's configured API
|
|
182
182
|
* version if not specified.
|
|
183
183
|
*/
|
|
184
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
184
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
185
185
|
}
|
|
186
186
|
|
|
187
187
|
export interface ByUserIDDeleteParams {
|
|
@@ -189,7 +189,7 @@ export interface ByUserIDDeleteParams {
|
|
|
189
189
|
* API version for this request. Defaults to your organization's configured API
|
|
190
190
|
* version if not specified.
|
|
191
191
|
*/
|
|
192
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
192
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
193
193
|
}
|
|
194
194
|
|
|
195
195
|
ByUserID.EmailPreferences = EmailPreferences;
|
|
@@ -197,7 +197,7 @@ export interface EmailPreferenceRetrieveParams {
|
|
|
197
197
|
* API version for this request. Defaults to your organization's configured API
|
|
198
198
|
* version if not specified.
|
|
199
199
|
*/
|
|
200
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
200
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
201
201
|
}
|
|
202
202
|
|
|
203
203
|
export interface EmailPreferenceUpdateParams {
|
|
@@ -210,7 +210,7 @@ export interface EmailPreferenceUpdateParams {
|
|
|
210
210
|
* Header param: API version for this request. Defaults to your organization's
|
|
211
211
|
* configured API version if not specified.
|
|
212
212
|
*/
|
|
213
|
-
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
213
|
+
'Featurebase-Version'?: '2026-08-19.orbit' | '2026-01-01.nova' | '2025-12-12.clover';
|
|
214
214
|
}
|
|
215
215
|
|
|
216
216
|
export namespace EmailPreferenceUpdateParams {
|