featurebase-node 0.3.0 → 0.5.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 +17 -0
- package/README.md +31 -0
- package/client.d.mts +12 -6
- package/client.d.mts.map +1 -1
- package/client.d.ts +12 -6
- package/client.d.ts.map +1 -1
- package/client.js +10 -0
- package/client.js.map +1 -1
- package/client.mjs +10 -0
- package/client.mjs.map +1 -1
- package/core/pagination.d.mts +54 -0
- package/core/pagination.d.mts.map +1 -0
- package/core/pagination.d.ts +54 -0
- package/core/pagination.d.ts.map +1 -0
- package/core/pagination.js +101 -0
- package/core/pagination.js.map +1 -0
- package/core/pagination.mjs +95 -0
- package/core/pagination.mjs.map +1 -0
- package/index.d.mts +1 -0
- package/index.d.mts.map +1 -1
- package/index.d.ts +1 -0
- package/index.d.ts.map +1 -1
- package/index.js +3 -1
- package/index.js.map +1 -1
- package/index.mjs +1 -0
- package/index.mjs.map +1 -1
- package/package.json +11 -1
- package/pagination.d.mts +2 -0
- package/pagination.d.mts.map +1 -0
- package/pagination.d.ts +2 -0
- package/pagination.d.ts.map +1 -0
- package/pagination.js +6 -0
- package/pagination.js.map +1 -0
- package/pagination.mjs +2 -0
- package/pagination.mjs.map +1 -0
- package/resources/changelogs/changelogs.d.mts +16 -60
- package/resources/changelogs/changelogs.d.mts.map +1 -1
- package/resources/changelogs/changelogs.d.ts +16 -60
- package/resources/changelogs/changelogs.d.ts.map +1 -1
- package/resources/changelogs/changelogs.js +41 -9
- package/resources/changelogs/changelogs.js.map +1 -1
- package/resources/changelogs/changelogs.mjs +41 -9
- 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 +2 -2
- package/resources/changelogs/subscribers.d.mts.map +1 -1
- package/resources/changelogs/subscribers.d.ts +2 -2
- package/resources/changelogs/subscribers.d.ts.map +1 -1
- package/resources/changelogs/subscribers.js +10 -2
- package/resources/changelogs/subscribers.js.map +1 -1
- package/resources/changelogs/subscribers.mjs +10 -2
- package/resources/changelogs/subscribers.mjs.map +1 -1
- package/resources/feedback/boards.d.mts +2 -2
- package/resources/feedback/boards.d.mts.map +1 -1
- package/resources/feedback/boards.d.ts +2 -2
- package/resources/feedback/boards.d.ts.map +1 -1
- package/resources/feedback/boards.js +10 -2
- package/resources/feedback/boards.js.map +1 -1
- package/resources/feedback/boards.mjs +10 -2
- package/resources/feedback/boards.mjs.map +1 -1
- package/resources/feedback/comments.d.mts +15 -59
- package/resources/feedback/comments.d.mts.map +1 -1
- package/resources/feedback/comments.d.ts +15 -59
- package/resources/feedback/comments.d.ts.map +1 -1
- package/resources/feedback/comments.js +36 -8
- package/resources/feedback/comments.js.map +1 -1
- package/resources/feedback/comments.mjs +36 -8
- package/resources/feedback/comments.mjs.map +1 -1
- package/resources/feedback/custom-fields.d.mts +2 -2
- package/resources/feedback/custom-fields.d.mts.map +1 -1
- package/resources/feedback/custom-fields.d.ts +2 -2
- package/resources/feedback/custom-fields.d.ts.map +1 -1
- package/resources/feedback/custom-fields.js +10 -2
- package/resources/feedback/custom-fields.js.map +1 -1
- package/resources/feedback/custom-fields.mjs +10 -2
- package/resources/feedback/custom-fields.mjs.map +1 -1
- package/resources/feedback/feedback.d.mts +4 -4
- package/resources/feedback/feedback.d.mts.map +1 -1
- package/resources/feedback/feedback.d.ts +4 -4
- package/resources/feedback/feedback.d.ts.map +1 -1
- package/resources/feedback/feedback.mjs.map +1 -1
- package/resources/feedback/index.d.mts +2 -2
- package/resources/feedback/index.d.mts.map +1 -1
- package/resources/feedback/index.d.ts +2 -2
- package/resources/feedback/index.d.ts.map +1 -1
- package/resources/feedback/post-statuses.d.mts +2 -2
- package/resources/feedback/post-statuses.d.mts.map +1 -1
- package/resources/feedback/post-statuses.d.ts +2 -2
- package/resources/feedback/post-statuses.d.ts.map +1 -1
- package/resources/feedback/post-statuses.js +10 -2
- package/resources/feedback/post-statuses.js.map +1 -1
- package/resources/feedback/post-statuses.mjs +10 -2
- package/resources/feedback/post-statuses.mjs.map +1 -1
- package/resources/feedback/posts/index.d.mts +2 -2
- package/resources/feedback/posts/index.d.mts.map +1 -1
- package/resources/feedback/posts/index.d.ts +2 -2
- 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 +16 -61
- package/resources/feedback/posts/posts.d.mts.map +1 -1
- package/resources/feedback/posts/posts.d.ts +16 -61
- package/resources/feedback/posts/posts.d.ts.map +1 -1
- package/resources/feedback/posts/posts.js +31 -7
- package/resources/feedback/posts/posts.js.map +1 -1
- package/resources/feedback/posts/posts.mjs +31 -7
- package/resources/feedback/posts/posts.mjs.map +1 -1
- package/resources/feedback/posts/voters.d.mts +82 -127
- package/resources/feedback/posts/voters.d.mts.map +1 -1
- package/resources/feedback/posts/voters.d.ts +82 -127
- package/resources/feedback/posts/voters.d.ts.map +1 -1
- package/resources/feedback/posts/voters.js +22 -6
- package/resources/feedback/posts/voters.js.map +1 -1
- package/resources/feedback/posts/voters.mjs +22 -6
- package/resources/feedback/posts/voters.mjs.map +1 -1
- package/resources/help-center/articles.d.mts +14 -32
- package/resources/help-center/articles.d.mts.map +1 -1
- package/resources/help-center/articles.d.ts +14 -32
- package/resources/help-center/articles.d.ts.map +1 -1
- package/resources/help-center/articles.js +31 -7
- package/resources/help-center/articles.js.map +1 -1
- package/resources/help-center/articles.mjs +31 -7
- package/resources/help-center/articles.mjs.map +1 -1
- package/resources/help-center/collections.d.mts +14 -33
- package/resources/help-center/collections.d.mts.map +1 -1
- package/resources/help-center/collections.d.ts +14 -33
- package/resources/help-center/collections.d.ts.map +1 -1
- package/resources/help-center/collections.js +31 -8
- package/resources/help-center/collections.js.map +1 -1
- package/resources/help-center/collections.mjs +31 -8
- package/resources/help-center/collections.mjs.map +1 -1
- package/resources/help-center/help-center.d.mts +8 -8
- package/resources/help-center/help-center.d.mts.map +1 -1
- package/resources/help-center/help-center.d.ts +8 -8
- package/resources/help-center/help-center.d.ts.map +1 -1
- package/resources/help-center/help-center.mjs.map +1 -1
- package/resources/help-center/help-centers.d.mts +11 -30
- package/resources/help-center/help-centers.d.mts.map +1 -1
- package/resources/help-center/help-centers.d.ts +11 -30
- package/resources/help-center/help-centers.d.ts.map +1 -1
- package/resources/help-center/help-centers.js +16 -5
- package/resources/help-center/help-centers.js.map +1 -1
- package/resources/help-center/help-centers.mjs +16 -5
- 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 +15 -34
- package/resources/help-center/redirect-rules.d.mts.map +1 -1
- package/resources/help-center/redirect-rules.d.ts +15 -34
- package/resources/help-center/redirect-rules.d.ts.map +1 -1
- package/resources/help-center/redirect-rules.js +36 -9
- package/resources/help-center/redirect-rules.js.map +1 -1
- package/resources/help-center/redirect-rules.mjs +36 -9
- package/resources/help-center/redirect-rules.mjs.map +1 -1
- package/resources/index.d.mts +3 -3
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +3 -3
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/organization/admins.d.mts +3 -3
- package/resources/organization/admins.d.mts.map +1 -1
- package/resources/organization/admins.d.ts +3 -3
- package/resources/organization/admins.d.ts.map +1 -1
- package/resources/organization/admins.js +15 -3
- package/resources/organization/admins.js.map +1 -1
- package/resources/organization/admins.mjs +15 -3
- package/resources/organization/admins.mjs.map +1 -1
- package/resources/organization/brands.d.mts +7 -28
- package/resources/organization/brands.d.mts.map +1 -1
- package/resources/organization/brands.d.ts +7 -28
- package/resources/organization/brands.d.ts.map +1 -1
- package/resources/organization/brands.js +12 -3
- package/resources/organization/brands.js.map +1 -1
- package/resources/organization/brands.mjs +12 -3
- package/resources/organization/brands.mjs.map +1 -1
- package/resources/organization/index.d.mts +1 -1
- package/resources/organization/index.d.mts.map +1 -1
- package/resources/organization/index.d.ts +1 -1
- package/resources/organization/index.d.ts.map +1 -1
- package/resources/organization/organization.d.mts +2 -2
- package/resources/organization/organization.d.mts.map +1 -1
- package/resources/organization/organization.d.ts +2 -2
- package/resources/organization/organization.d.ts.map +1 -1
- package/resources/organization/organization.js.map +1 -1
- package/resources/organization/organization.mjs.map +1 -1
- package/resources/organization/teams.d.mts +2 -2
- package/resources/organization/teams.d.mts.map +1 -1
- package/resources/organization/teams.d.ts +2 -2
- package/resources/organization/teams.d.ts.map +1 -1
- package/resources/organization/teams.js +10 -2
- package/resources/organization/teams.js.map +1 -1
- package/resources/organization/teams.mjs +10 -2
- package/resources/organization/teams.mjs.map +1 -1
- package/resources/support/conversation-tags.d.mts +4 -4
- package/resources/support/conversation-tags.d.mts.map +1 -1
- package/resources/support/conversation-tags.d.ts +4 -4
- package/resources/support/conversation-tags.d.ts.map +1 -1
- package/resources/support/conversation-tags.js +20 -4
- package/resources/support/conversation-tags.js.map +1 -1
- package/resources/support/conversation-tags.mjs +20 -4
- package/resources/support/conversation-tags.mjs.map +1 -1
- package/resources/support/conversations/conversations.d.mts +17 -36
- package/resources/support/conversations/conversations.d.mts.map +1 -1
- package/resources/support/conversations/conversations.d.ts +17 -36
- package/resources/support/conversations/conversations.d.ts.map +1 -1
- package/resources/support/conversations/conversations.js +41 -10
- package/resources/support/conversations/conversations.js.map +1 -1
- package/resources/support/conversations/conversations.mjs +41 -10
- 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/conversations/participants.js +10 -2
- package/resources/support/conversations/participants.js.map +1 -1
- package/resources/support/conversations/participants.mjs +10 -2
- package/resources/support/conversations/participants.mjs.map +1 -1
- package/resources/support/conversations/tags.d.mts +2 -2
- package/resources/support/conversations/tags.d.mts.map +1 -1
- package/resources/support/conversations/tags.d.ts +2 -2
- package/resources/support/conversations/tags.d.ts.map +1 -1
- package/resources/support/conversations/tags.js +10 -2
- package/resources/support/conversations/tags.js.map +1 -1
- package/resources/support/conversations/tags.mjs +10 -2
- package/resources/support/conversations/tags.mjs.map +1 -1
- package/resources/support/index.d.mts +2 -2
- package/resources/support/index.d.mts.map +1 -1
- package/resources/support/index.d.ts +2 -2
- package/resources/support/index.d.ts.map +1 -1
- package/resources/support/support.d.mts +4 -4
- package/resources/support/support.d.mts.map +1 -1
- package/resources/support/support.d.ts +4 -4
- package/resources/support/support.d.ts.map +1 -1
- package/resources/support/support.mjs.map +1 -1
- package/resources/support/tickets/categories.d.mts +2 -2
- package/resources/support/tickets/categories.d.mts.map +1 -1
- package/resources/support/tickets/categories.d.ts +2 -2
- package/resources/support/tickets/categories.d.ts.map +1 -1
- package/resources/support/tickets/categories.js +10 -2
- package/resources/support/tickets/categories.js.map +1 -1
- package/resources/support/tickets/categories.mjs +10 -2
- package/resources/support/tickets/categories.mjs.map +1 -1
- package/resources/support/tickets/custom-fields.d.mts +2 -2
- package/resources/support/tickets/custom-fields.d.mts.map +1 -1
- package/resources/support/tickets/custom-fields.d.ts +2 -2
- package/resources/support/tickets/custom-fields.d.ts.map +1 -1
- package/resources/support/tickets/custom-fields.js +10 -2
- package/resources/support/tickets/custom-fields.js.map +1 -1
- package/resources/support/tickets/custom-fields.mjs +10 -2
- package/resources/support/tickets/custom-fields.mjs.map +1 -1
- package/resources/support/tickets/index.d.mts +1 -1
- package/resources/support/tickets/index.d.mts.map +1 -1
- package/resources/support/tickets/index.d.ts +1 -1
- package/resources/support/tickets/index.d.ts.map +1 -1
- package/resources/support/tickets/statuses.d.mts +2 -2
- package/resources/support/tickets/statuses.d.mts.map +1 -1
- package/resources/support/tickets/statuses.d.ts +2 -2
- package/resources/support/tickets/statuses.d.ts.map +1 -1
- package/resources/support/tickets/statuses.js +10 -2
- package/resources/support/tickets/statuses.js.map +1 -1
- package/resources/support/tickets/statuses.mjs +10 -2
- package/resources/support/tickets/statuses.mjs.map +1 -1
- package/resources/support/tickets/tickets.d.mts +16 -34
- package/resources/support/tickets/tickets.d.mts.map +1 -1
- package/resources/support/tickets/tickets.d.ts +16 -34
- package/resources/support/tickets/tickets.d.ts.map +1 -1
- package/resources/support/tickets/tickets.js +36 -8
- package/resources/support/tickets/tickets.js.map +1 -1
- package/resources/support/tickets/tickets.mjs +36 -8
- package/resources/support/tickets/tickets.mjs.map +1 -1
- package/resources/surveys.d.mts +37 -82
- package/resources/surveys.d.mts.map +1 -1
- package/resources/surveys.d.ts +37 -82
- package/resources/surveys.d.ts.map +1 -1
- package/resources/surveys.js +19 -6
- package/resources/surveys.js.map +1 -1
- package/resources/surveys.mjs +19 -6
- package/resources/surveys.mjs.map +1 -1
- package/resources/users/companies/companies.d.mts +14 -33
- package/resources/users/companies/companies.d.mts.map +1 -1
- package/resources/users/companies/companies.d.ts +14 -33
- package/resources/users/companies/companies.d.ts.map +1 -1
- package/resources/users/companies/companies.js +31 -7
- package/resources/users/companies/companies.js.map +1 -1
- package/resources/users/companies/companies.mjs +31 -7
- package/resources/users/companies/companies.mjs.map +1 -1
- package/resources/users/companies/contacts.d.mts +14 -19
- package/resources/users/companies/contacts.d.mts.map +1 -1
- package/resources/users/companies/contacts.d.ts +14 -19
- package/resources/users/companies/contacts.d.ts.map +1 -1
- package/resources/users/companies/contacts.js +23 -8
- package/resources/users/companies/contacts.js.map +1 -1
- package/resources/users/companies/contacts.mjs +23 -8
- package/resources/users/companies/contacts.mjs.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/by-user-id.js +10 -2
- package/resources/users/contacts/by-user-id/by-user-id.js.map +1 -1
- package/resources/users/contacts/by-user-id/by-user-id.mjs +10 -2
- package/resources/users/contacts/by-user-id/by-user-id.mjs.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/by-user-id/email-preferences.js +10 -2
- package/resources/users/contacts/by-user-id/email-preferences.js.map +1 -1
- package/resources/users/contacts/by-user-id/email-preferences.mjs +10 -2
- package/resources/users/contacts/by-user-id/email-preferences.mjs.map +1 -1
- package/resources/users/contacts/contacts.d.mts +15 -19
- package/resources/users/contacts/contacts.d.mts.map +1 -1
- package/resources/users/contacts/contacts.d.ts +15 -19
- package/resources/users/contacts/contacts.d.ts.map +1 -1
- package/resources/users/contacts/contacts.js +36 -8
- package/resources/users/contacts/contacts.js.map +1 -1
- package/resources/users/contacts/contacts.mjs +36 -8
- 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/email-preferences.js +10 -2
- package/resources/users/contacts/email-preferences.js.map +1 -1
- package/resources/users/contacts/email-preferences.mjs +10 -2
- package/resources/users/contacts/email-preferences.mjs.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/contacts/index.js.map +1 -1
- package/resources/users/contacts/index.mjs.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/index.js.map +1 -1
- package/resources/users/index.mjs.map +1 -1
- package/resources/users/users.d.mts +4 -4
- package/resources/users/users.d.mts.map +1 -1
- package/resources/users/users.d.ts +4 -4
- package/resources/users/users.d.ts.map +1 -1
- package/resources/users/users.js.map +1 -1
- package/resources/users/users.mjs.map +1 -1
- package/resources/webhooks.d.mts +15 -33
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +15 -33
- package/resources/webhooks.d.ts.map +1 -1
- package/resources/webhooks.js +36 -8
- package/resources/webhooks.js.map +1 -1
- package/resources/webhooks.mjs +36 -8
- package/resources/webhooks.mjs.map +1 -1
- package/src/client.ts +41 -10
- package/src/core/pagination.ts +157 -0
- package/src/index.ts +1 -0
- package/src/pagination.ts +2 -0
- package/src/resources/changelogs/changelogs.ts +53 -78
- package/src/resources/changelogs/index.ts +1 -1
- package/src/resources/changelogs/subscribers.ts +12 -4
- package/src/resources/feedback/boards.ts +12 -4
- package/src/resources/feedback/comments.ts +47 -76
- package/src/resources/feedback/custom-fields.ts +12 -4
- package/src/resources/feedback/feedback.ts +4 -4
- package/src/resources/feedback/index.ts +2 -2
- package/src/resources/feedback/post-statuses.ts +12 -4
- package/src/resources/feedback/posts/index.ts +2 -1
- package/src/resources/feedback/posts/posts.ts +43 -75
- package/src/resources/feedback/posts/voters.ts +105 -146
- package/src/resources/help-center/articles.ts +41 -43
- package/src/resources/help-center/collections.ts +41 -44
- package/src/resources/help-center/help-center.ts +8 -8
- package/src/resources/help-center/help-centers.ts +23 -38
- package/src/resources/help-center/index.ts +4 -4
- package/src/resources/help-center/redirect-rules.ts +47 -46
- package/src/resources/index.ts +6 -5
- package/src/resources/organization/admins.ts +18 -6
- package/src/resources/organization/brands.ts +19 -36
- package/src/resources/organization/index.ts +1 -1
- package/src/resources/organization/organization.ts +2 -2
- package/src/resources/organization/teams.ts +12 -4
- package/src/resources/support/conversation-tags.ts +24 -8
- package/src/resources/support/conversations/conversations.ts +54 -49
- package/src/resources/support/conversations/index.ts +1 -1
- package/src/resources/support/conversations/participants.ts +12 -4
- package/src/resources/support/conversations/tags.ts +12 -4
- package/src/resources/support/index.ts +2 -2
- package/src/resources/support/support.ts +4 -4
- package/src/resources/support/tickets/categories.ts +12 -4
- package/src/resources/support/tickets/custom-fields.ts +12 -4
- package/src/resources/support/tickets/index.ts +1 -1
- package/src/resources/support/tickets/statuses.ts +12 -4
- package/src/resources/support/tickets/tickets.ts +48 -46
- package/src/resources/surveys.ts +71 -107
- package/src/resources/users/companies/companies.ts +41 -44
- package/src/resources/users/companies/contacts.ts +41 -31
- package/src/resources/users/companies/index.ts +1 -1
- package/src/resources/users/contacts/by-user-id/by-user-id.ts +12 -4
- package/src/resources/users/contacts/by-user-id/email-preferences.ts +12 -4
- package/src/resources/users/contacts/contacts.ts +50 -27
- package/src/resources/users/contacts/email-preferences.ts +12 -4
- package/src/resources/users/contacts/index.ts +1 -0
- package/src/resources/users/index.ts +2 -1
- package/src/resources/users/users.ts +4 -2
- package/src/resources/webhooks.ts +47 -45
- 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
package/resources/surveys.d.mts
CHANGED
|
@@ -2,6 +2,7 @@ import { APIResource } from "../core/resource.mjs";
|
|
|
2
2
|
import * as SurveysAPI from "./surveys.mjs";
|
|
3
3
|
import * as ContactsAPI from "./users/contacts/contacts.mjs";
|
|
4
4
|
import { APIPromise } from "../core/api-promise.mjs";
|
|
5
|
+
import { CursorPage, type CursorPageParams, PagePromise } from "../core/pagination.mjs";
|
|
5
6
|
import { RequestOptions } from "../internal/request-options.mjs";
|
|
6
7
|
/**
|
|
7
8
|
* Surveys allow you to collect targeted feedback from your users within your product. Surveys can be targeted to specific user segments or pages and can contain multiple questions with conditional logic.
|
|
@@ -73,7 +74,7 @@ export declare class Surveys extends APIResource {
|
|
|
73
74
|
* - `createdAt` - ISO 8601 timestamp when created
|
|
74
75
|
* - `updatedAt` - ISO 8601 timestamp when last updated
|
|
75
76
|
*/
|
|
76
|
-
list(params?: SurveyListParams | null | undefined, options?: RequestOptions):
|
|
77
|
+
list(params?: SurveyListParams | null | undefined, options?: RequestOptions): PagePromise<SurveysCursorPage, Survey>;
|
|
77
78
|
/**
|
|
78
79
|
* Retrieves all user responses for a specific survey.
|
|
79
80
|
*
|
|
@@ -112,8 +113,10 @@ export declare class Surveys extends APIResource {
|
|
|
112
113
|
*
|
|
113
114
|
* - `404` - Survey not found in your organization
|
|
114
115
|
*/
|
|
115
|
-
|
|
116
|
+
listResponses(id: string, params?: SurveyListResponsesParams | null | undefined, options?: RequestOptions): PagePromise<SurveyListResponsesResponsesCursorPage, SurveyListResponsesResponse>;
|
|
116
117
|
}
|
|
118
|
+
export type SurveysCursorPage = CursorPage<Survey>;
|
|
119
|
+
export type SurveyListResponsesResponsesCursorPage = CursorPage<SurveyListResponsesResponse>;
|
|
117
120
|
export interface Survey {
|
|
118
121
|
/**
|
|
119
122
|
* Unique identifier
|
|
@@ -314,84 +317,54 @@ export interface SurveyNextAction {
|
|
|
314
317
|
*/
|
|
315
318
|
pageId?: string;
|
|
316
319
|
}
|
|
317
|
-
export interface
|
|
320
|
+
export interface SurveyListResponsesResponse {
|
|
318
321
|
/**
|
|
319
|
-
*
|
|
322
|
+
* Unique identifier
|
|
320
323
|
*/
|
|
321
|
-
|
|
324
|
+
id: string;
|
|
322
325
|
/**
|
|
323
|
-
*
|
|
326
|
+
* ISO 8601 timestamp when created
|
|
324
327
|
*/
|
|
325
|
-
|
|
328
|
+
createdAt: string;
|
|
326
329
|
/**
|
|
327
330
|
* Object type identifier
|
|
328
331
|
*/
|
|
329
|
-
object: '
|
|
330
|
-
}
|
|
331
|
-
export interface SurveyRetrieveResponsesResponse {
|
|
332
|
-
/**
|
|
333
|
-
* Array of survey responses
|
|
334
|
-
*/
|
|
335
|
-
data: Array<SurveyRetrieveResponsesResponse.Data>;
|
|
332
|
+
object: 'survey_response';
|
|
336
333
|
/**
|
|
337
|
-
*
|
|
334
|
+
* Individual responses to questions
|
|
338
335
|
*/
|
|
339
|
-
|
|
336
|
+
responses: Array<SurveyListResponsesResponse.Response>;
|
|
340
337
|
/**
|
|
341
|
-
*
|
|
338
|
+
* User who submitted the response
|
|
342
339
|
*/
|
|
343
|
-
|
|
340
|
+
user: ContactsAPI.Contact | null;
|
|
344
341
|
}
|
|
345
|
-
export declare namespace
|
|
346
|
-
interface
|
|
342
|
+
export declare namespace SurveyListResponsesResponse {
|
|
343
|
+
interface Response {
|
|
347
344
|
/**
|
|
348
|
-
*
|
|
345
|
+
* Page ID this response is for
|
|
349
346
|
*/
|
|
350
|
-
|
|
347
|
+
pageId: string;
|
|
351
348
|
/**
|
|
352
|
-
*
|
|
349
|
+
* Response type
|
|
353
350
|
*/
|
|
354
|
-
|
|
351
|
+
type: 'text' | 'link' | 'rating' | 'multiple-choice';
|
|
355
352
|
/**
|
|
356
|
-
*
|
|
353
|
+
* Response value
|
|
357
354
|
*/
|
|
358
|
-
|
|
355
|
+
value: string | number | boolean | Array<string>;
|
|
359
356
|
/**
|
|
360
|
-
*
|
|
357
|
+
* Response ID
|
|
361
358
|
*/
|
|
362
|
-
|
|
359
|
+
id?: string;
|
|
363
360
|
/**
|
|
364
|
-
*
|
|
361
|
+
* ISO 8601 timestamp when created
|
|
365
362
|
*/
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
* Page ID this response is for
|
|
372
|
-
*/
|
|
373
|
-
pageId: string;
|
|
374
|
-
/**
|
|
375
|
-
* Response type
|
|
376
|
-
*/
|
|
377
|
-
type: 'text' | 'link' | 'rating' | 'multiple-choice';
|
|
378
|
-
/**
|
|
379
|
-
* Response value
|
|
380
|
-
*/
|
|
381
|
-
value: string | number | boolean | Array<string>;
|
|
382
|
-
/**
|
|
383
|
-
* Response ID
|
|
384
|
-
*/
|
|
385
|
-
id?: string;
|
|
386
|
-
/**
|
|
387
|
-
* ISO 8601 timestamp when created
|
|
388
|
-
*/
|
|
389
|
-
createdAt?: string;
|
|
390
|
-
/**
|
|
391
|
-
* ISO 8601 timestamp when updated
|
|
392
|
-
*/
|
|
393
|
-
updatedAt?: string;
|
|
394
|
-
}
|
|
363
|
+
createdAt?: string;
|
|
364
|
+
/**
|
|
365
|
+
* ISO 8601 timestamp when updated
|
|
366
|
+
*/
|
|
367
|
+
updatedAt?: string;
|
|
395
368
|
}
|
|
396
369
|
}
|
|
397
370
|
export interface SurveyRetrieveParams {
|
|
@@ -399,22 +372,13 @@ export interface SurveyRetrieveParams {
|
|
|
399
372
|
* API version for this request. Defaults to your organization's configured API
|
|
400
373
|
* version if not specified.
|
|
401
374
|
*/
|
|
402
|
-
'Featurebase-Version'?:
|
|
375
|
+
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
403
376
|
}
|
|
404
|
-
export interface SurveyListParams {
|
|
405
|
-
/**
|
|
406
|
-
* Query param: An opaque cursor for pagination. Use the nextCursor value from a
|
|
407
|
-
* previous response to fetch the next page.
|
|
408
|
-
*/
|
|
409
|
-
cursor?: string;
|
|
377
|
+
export interface SurveyListParams extends CursorPageParams {
|
|
410
378
|
/**
|
|
411
379
|
* Query param: Filter by active status
|
|
412
380
|
*/
|
|
413
381
|
isActive?: boolean | null;
|
|
414
|
-
/**
|
|
415
|
-
* Query param: A limit on the number of objects to be returned, between 1 and 100.
|
|
416
|
-
*/
|
|
417
|
-
limit?: number;
|
|
418
382
|
/**
|
|
419
383
|
* Query param: Filter by survey page type
|
|
420
384
|
*/
|
|
@@ -423,18 +387,9 @@ export interface SurveyListParams {
|
|
|
423
387
|
* Header param: API version for this request. Defaults to your organization's
|
|
424
388
|
* configured API version if not specified.
|
|
425
389
|
*/
|
|
426
|
-
'Featurebase-Version'?:
|
|
390
|
+
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
427
391
|
}
|
|
428
|
-
export interface
|
|
429
|
-
/**
|
|
430
|
-
* Query param: An opaque cursor for pagination. Use the nextCursor value from a
|
|
431
|
-
* previous response to fetch the next page.
|
|
432
|
-
*/
|
|
433
|
-
cursor?: string;
|
|
434
|
-
/**
|
|
435
|
-
* Query param: A limit on the number of objects to be returned, between 1 and 100.
|
|
436
|
-
*/
|
|
437
|
-
limit?: number;
|
|
392
|
+
export interface SurveyListResponsesParams extends CursorPageParams {
|
|
438
393
|
/**
|
|
439
394
|
* Query param: Filter by survey page ID
|
|
440
395
|
*/
|
|
@@ -443,9 +398,9 @@ export interface SurveyRetrieveResponsesParams {
|
|
|
443
398
|
* Header param: API version for this request. Defaults to your organization's
|
|
444
399
|
* configured API version if not specified.
|
|
445
400
|
*/
|
|
446
|
-
'Featurebase-Version'?:
|
|
401
|
+
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
447
402
|
}
|
|
448
403
|
export declare namespace Surveys {
|
|
449
|
-
export { type Survey as Survey, type SurveyNextAction as SurveyNextAction, type
|
|
404
|
+
export { type Survey as Survey, type SurveyNextAction as SurveyNextAction, type SurveyListResponsesResponse as SurveyListResponsesResponse, type SurveysCursorPage as SurveysCursorPage, type SurveyListResponsesResponsesCursorPage as SurveyListResponsesResponsesCursorPage, type SurveyRetrieveParams as SurveyRetrieveParams, type SurveyListParams as SurveyListParams, type SurveyListResponsesParams as SurveyListResponsesParams, };
|
|
450
405
|
}
|
|
451
406
|
//# sourceMappingURL=surveys.d.mts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"surveys.d.mts","sourceRoot":"","sources":["../src/resources/surveys.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,UAAU;OACf,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;
|
|
1
|
+
{"version":3,"file":"surveys.d.mts","sourceRoot":"","sources":["../src/resources/surveys.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,UAAU;OACf,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;OACd,EAAE,UAAU,EAAE,KAAK,gBAAgB,EAAE,WAAW,EAAE;OAElD,EAAE,cAAc,EAAE;AAGzB;;GAEG;AACH,qBAAa,OAAQ,SAAQ,WAAW;IACtC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAgCG;IACH,QAAQ,CACN,EAAE,EAAE,MAAM,EACV,MAAM,GAAE,oBAAoB,GAAG,IAAI,GAAG,SAAc,EACpD,OAAO,CAAC,EAAE,cAAc,GACvB,UAAU,CAAC,MAAM,CAAC;IAerB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA+BG;IACH,IAAI,CACF,MAAM,GAAE,gBAAgB,GAAG,IAAI,GAAG,SAAc,EAChD,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,iBAAiB,EAAE,MAAM,CAAC;IAgBzC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAqCG;IACH,aAAa,CACX,EAAE,EAAE,MAAM,EACV,MAAM,GAAE,yBAAyB,GAAG,IAAI,GAAG,SAAc,EACzD,OAAO,CAAC,EAAE,cAAc,GACvB,WAAW,CAAC,sCAAsC,EAAE,2BAA2B,CAAC;CAmBpF;AAED,MAAM,MAAM,iBAAiB,GAAG,UAAU,CAAC,MAAM,CAAC,CAAC;AAEnD,MAAM,MAAM,sCAAsC,GAAG,UAAU,CAAC,2BAA2B,CAAC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C,EAAE,MAAM,GAAG,MAAM,GAAG,QAAQ,GAAG,iBAAiB,CAAC;IAEtD;;;OAGG;IACH,qBAAqB,CAAC,EAAE,iBAAiB,GAAG,mBAAmB,CAAC;CACjE;AAED,MAAM,WAAW,yBAA0B,SAAQ,gBAAgB;IACjE;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAEhB;;;OAGG;IACH,qBAAqB,CAAC,EAAE,iBAAiB,GAAG,mBAAmB,CAAC;CACjE;AAED,MAAM,CAAC,OAAO,WAAW,OAAO,CAAC;IAC/B,OAAO,EACL,KAAK,MAAM,IAAI,MAAM,EACrB,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,sCAAsC,IAAI,sCAAsC,EACrF,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,yBAAyB,IAAI,yBAAyB,GAC5D,CAAC;CACH"}
|
package/resources/surveys.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import { APIResource } from "../core/resource.js";
|
|
|
2
2
|
import * as SurveysAPI from "./surveys.js";
|
|
3
3
|
import * as ContactsAPI from "./users/contacts/contacts.js";
|
|
4
4
|
import { APIPromise } from "../core/api-promise.js";
|
|
5
|
+
import { CursorPage, type CursorPageParams, PagePromise } from "../core/pagination.js";
|
|
5
6
|
import { RequestOptions } from "../internal/request-options.js";
|
|
6
7
|
/**
|
|
7
8
|
* Surveys allow you to collect targeted feedback from your users within your product. Surveys can be targeted to specific user segments or pages and can contain multiple questions with conditional logic.
|
|
@@ -73,7 +74,7 @@ export declare class Surveys extends APIResource {
|
|
|
73
74
|
* - `createdAt` - ISO 8601 timestamp when created
|
|
74
75
|
* - `updatedAt` - ISO 8601 timestamp when last updated
|
|
75
76
|
*/
|
|
76
|
-
list(params?: SurveyListParams | null | undefined, options?: RequestOptions):
|
|
77
|
+
list(params?: SurveyListParams | null | undefined, options?: RequestOptions): PagePromise<SurveysCursorPage, Survey>;
|
|
77
78
|
/**
|
|
78
79
|
* Retrieves all user responses for a specific survey.
|
|
79
80
|
*
|
|
@@ -112,8 +113,10 @@ export declare class Surveys extends APIResource {
|
|
|
112
113
|
*
|
|
113
114
|
* - `404` - Survey not found in your organization
|
|
114
115
|
*/
|
|
115
|
-
|
|
116
|
+
listResponses(id: string, params?: SurveyListResponsesParams | null | undefined, options?: RequestOptions): PagePromise<SurveyListResponsesResponsesCursorPage, SurveyListResponsesResponse>;
|
|
116
117
|
}
|
|
118
|
+
export type SurveysCursorPage = CursorPage<Survey>;
|
|
119
|
+
export type SurveyListResponsesResponsesCursorPage = CursorPage<SurveyListResponsesResponse>;
|
|
117
120
|
export interface Survey {
|
|
118
121
|
/**
|
|
119
122
|
* Unique identifier
|
|
@@ -314,84 +317,54 @@ export interface SurveyNextAction {
|
|
|
314
317
|
*/
|
|
315
318
|
pageId?: string;
|
|
316
319
|
}
|
|
317
|
-
export interface
|
|
320
|
+
export interface SurveyListResponsesResponse {
|
|
318
321
|
/**
|
|
319
|
-
*
|
|
322
|
+
* Unique identifier
|
|
320
323
|
*/
|
|
321
|
-
|
|
324
|
+
id: string;
|
|
322
325
|
/**
|
|
323
|
-
*
|
|
326
|
+
* ISO 8601 timestamp when created
|
|
324
327
|
*/
|
|
325
|
-
|
|
328
|
+
createdAt: string;
|
|
326
329
|
/**
|
|
327
330
|
* Object type identifier
|
|
328
331
|
*/
|
|
329
|
-
object: '
|
|
330
|
-
}
|
|
331
|
-
export interface SurveyRetrieveResponsesResponse {
|
|
332
|
-
/**
|
|
333
|
-
* Array of survey responses
|
|
334
|
-
*/
|
|
335
|
-
data: Array<SurveyRetrieveResponsesResponse.Data>;
|
|
332
|
+
object: 'survey_response';
|
|
336
333
|
/**
|
|
337
|
-
*
|
|
334
|
+
* Individual responses to questions
|
|
338
335
|
*/
|
|
339
|
-
|
|
336
|
+
responses: Array<SurveyListResponsesResponse.Response>;
|
|
340
337
|
/**
|
|
341
|
-
*
|
|
338
|
+
* User who submitted the response
|
|
342
339
|
*/
|
|
343
|
-
|
|
340
|
+
user: ContactsAPI.Contact | null;
|
|
344
341
|
}
|
|
345
|
-
export declare namespace
|
|
346
|
-
interface
|
|
342
|
+
export declare namespace SurveyListResponsesResponse {
|
|
343
|
+
interface Response {
|
|
347
344
|
/**
|
|
348
|
-
*
|
|
345
|
+
* Page ID this response is for
|
|
349
346
|
*/
|
|
350
|
-
|
|
347
|
+
pageId: string;
|
|
351
348
|
/**
|
|
352
|
-
*
|
|
349
|
+
* Response type
|
|
353
350
|
*/
|
|
354
|
-
|
|
351
|
+
type: 'text' | 'link' | 'rating' | 'multiple-choice';
|
|
355
352
|
/**
|
|
356
|
-
*
|
|
353
|
+
* Response value
|
|
357
354
|
*/
|
|
358
|
-
|
|
355
|
+
value: string | number | boolean | Array<string>;
|
|
359
356
|
/**
|
|
360
|
-
*
|
|
357
|
+
* Response ID
|
|
361
358
|
*/
|
|
362
|
-
|
|
359
|
+
id?: string;
|
|
363
360
|
/**
|
|
364
|
-
*
|
|
361
|
+
* ISO 8601 timestamp when created
|
|
365
362
|
*/
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
* Page ID this response is for
|
|
372
|
-
*/
|
|
373
|
-
pageId: string;
|
|
374
|
-
/**
|
|
375
|
-
* Response type
|
|
376
|
-
*/
|
|
377
|
-
type: 'text' | 'link' | 'rating' | 'multiple-choice';
|
|
378
|
-
/**
|
|
379
|
-
* Response value
|
|
380
|
-
*/
|
|
381
|
-
value: string | number | boolean | Array<string>;
|
|
382
|
-
/**
|
|
383
|
-
* Response ID
|
|
384
|
-
*/
|
|
385
|
-
id?: string;
|
|
386
|
-
/**
|
|
387
|
-
* ISO 8601 timestamp when created
|
|
388
|
-
*/
|
|
389
|
-
createdAt?: string;
|
|
390
|
-
/**
|
|
391
|
-
* ISO 8601 timestamp when updated
|
|
392
|
-
*/
|
|
393
|
-
updatedAt?: string;
|
|
394
|
-
}
|
|
363
|
+
createdAt?: string;
|
|
364
|
+
/**
|
|
365
|
+
* ISO 8601 timestamp when updated
|
|
366
|
+
*/
|
|
367
|
+
updatedAt?: string;
|
|
395
368
|
}
|
|
396
369
|
}
|
|
397
370
|
export interface SurveyRetrieveParams {
|
|
@@ -399,22 +372,13 @@ export interface SurveyRetrieveParams {
|
|
|
399
372
|
* API version for this request. Defaults to your organization's configured API
|
|
400
373
|
* version if not specified.
|
|
401
374
|
*/
|
|
402
|
-
'Featurebase-Version'?:
|
|
375
|
+
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
403
376
|
}
|
|
404
|
-
export interface SurveyListParams {
|
|
405
|
-
/**
|
|
406
|
-
* Query param: An opaque cursor for pagination. Use the nextCursor value from a
|
|
407
|
-
* previous response to fetch the next page.
|
|
408
|
-
*/
|
|
409
|
-
cursor?: string;
|
|
377
|
+
export interface SurveyListParams extends CursorPageParams {
|
|
410
378
|
/**
|
|
411
379
|
* Query param: Filter by active status
|
|
412
380
|
*/
|
|
413
381
|
isActive?: boolean | null;
|
|
414
|
-
/**
|
|
415
|
-
* Query param: A limit on the number of objects to be returned, between 1 and 100.
|
|
416
|
-
*/
|
|
417
|
-
limit?: number;
|
|
418
382
|
/**
|
|
419
383
|
* Query param: Filter by survey page type
|
|
420
384
|
*/
|
|
@@ -423,18 +387,9 @@ export interface SurveyListParams {
|
|
|
423
387
|
* Header param: API version for this request. Defaults to your organization's
|
|
424
388
|
* configured API version if not specified.
|
|
425
389
|
*/
|
|
426
|
-
'Featurebase-Version'?:
|
|
390
|
+
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
427
391
|
}
|
|
428
|
-
export interface
|
|
429
|
-
/**
|
|
430
|
-
* Query param: An opaque cursor for pagination. Use the nextCursor value from a
|
|
431
|
-
* previous response to fetch the next page.
|
|
432
|
-
*/
|
|
433
|
-
cursor?: string;
|
|
434
|
-
/**
|
|
435
|
-
* Query param: A limit on the number of objects to be returned, between 1 and 100.
|
|
436
|
-
*/
|
|
437
|
-
limit?: number;
|
|
392
|
+
export interface SurveyListResponsesParams extends CursorPageParams {
|
|
438
393
|
/**
|
|
439
394
|
* Query param: Filter by survey page ID
|
|
440
395
|
*/
|
|
@@ -443,9 +398,9 @@ export interface SurveyRetrieveResponsesParams {
|
|
|
443
398
|
* Header param: API version for this request. Defaults to your organization's
|
|
444
399
|
* configured API version if not specified.
|
|
445
400
|
*/
|
|
446
|
-
'Featurebase-Version'?:
|
|
401
|
+
'Featurebase-Version'?: '2026-01-01.nova' | '2025-12-12.clover';
|
|
447
402
|
}
|
|
448
403
|
export declare namespace Surveys {
|
|
449
|
-
export { type Survey as Survey, type SurveyNextAction as SurveyNextAction, type
|
|
404
|
+
export { type Survey as Survey, type SurveyNextAction as SurveyNextAction, type SurveyListResponsesResponse as SurveyListResponsesResponse, type SurveysCursorPage as SurveysCursorPage, type SurveyListResponsesResponsesCursorPage as SurveyListResponsesResponsesCursorPage, type SurveyRetrieveParams as SurveyRetrieveParams, type SurveyListParams as SurveyListParams, type SurveyListResponsesParams as SurveyListResponsesParams, };
|
|
450
405
|
}
|
|
451
406
|
//# sourceMappingURL=surveys.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"surveys.d.ts","sourceRoot":"","sources":["../src/resources/surveys.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,UAAU;OACf,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;
|
|
1
|
+
{"version":3,"file":"surveys.d.ts","sourceRoot":"","sources":["../src/resources/surveys.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;OACf,KAAK,UAAU;OACf,KAAK,WAAW;OAChB,EAAE,UAAU,EAAE;OACd,EAAE,UAAU,EAAE,KAAK,gBAAgB,EAAE,WAAW,EAAE;OAElD,EAAE,cAAc,EAAE;AA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KAAK,iBAAiB,IAAI,iBAAiB,EAC3C,KAAK,sCAAsC,IAAI,sCAAsC,EACrF,KAAK,oBAAoB,IAAI,oBAAoB,EACjD,KAAK,gBAAgB,IAAI,gBAAgB,EACzC,KAAK,yBAAyB,IAAI,yBAAyB,GAC5D,CAAC;CACH"}
|
package/resources/surveys.js
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
4
|
exports.Surveys = void 0;
|
|
5
5
|
const resource_1 = require("../core/resource.js");
|
|
6
|
+
const pagination_1 = require("../core/pagination.js");
|
|
6
7
|
const headers_1 = require("../internal/headers.js");
|
|
7
8
|
const path_1 = require("../internal/utils/path.js");
|
|
8
9
|
/**
|
|
@@ -47,7 +48,11 @@ class Surveys extends resource_1.APIResource {
|
|
|
47
48
|
return this._client.get((0, path_1.path) `/v2/surveys/${id}`, {
|
|
48
49
|
...options,
|
|
49
50
|
headers: (0, headers_1.buildHeaders)([
|
|
50
|
-
{
|
|
51
|
+
{
|
|
52
|
+
...(featurebaseVersion?.toString() != null ?
|
|
53
|
+
{ 'Featurebase-Version': featurebaseVersion?.toString() }
|
|
54
|
+
: undefined),
|
|
55
|
+
},
|
|
51
56
|
options?.headers,
|
|
52
57
|
]),
|
|
53
58
|
});
|
|
@@ -86,11 +91,15 @@ class Surveys extends resource_1.APIResource {
|
|
|
86
91
|
*/
|
|
87
92
|
list(params = {}, options) {
|
|
88
93
|
const { 'Featurebase-Version': featurebaseVersion, ...query } = params ?? {};
|
|
89
|
-
return this._client.
|
|
94
|
+
return this._client.getAPIList('/v2/surveys', (pagination_1.CursorPage), {
|
|
90
95
|
query,
|
|
91
96
|
...options,
|
|
92
97
|
headers: (0, headers_1.buildHeaders)([
|
|
93
|
-
{
|
|
98
|
+
{
|
|
99
|
+
...(featurebaseVersion?.toString() != null ?
|
|
100
|
+
{ 'Featurebase-Version': featurebaseVersion?.toString() }
|
|
101
|
+
: undefined),
|
|
102
|
+
},
|
|
94
103
|
options?.headers,
|
|
95
104
|
]),
|
|
96
105
|
});
|
|
@@ -133,13 +142,17 @@ class Surveys extends resource_1.APIResource {
|
|
|
133
142
|
*
|
|
134
143
|
* - `404` - Survey not found in your organization
|
|
135
144
|
*/
|
|
136
|
-
|
|
145
|
+
listResponses(id, params = {}, options) {
|
|
137
146
|
const { 'Featurebase-Version': featurebaseVersion, ...query } = params ?? {};
|
|
138
|
-
return this._client.
|
|
147
|
+
return this._client.getAPIList((0, path_1.path) `/v2/surveys/${id}/responses`, (pagination_1.CursorPage), {
|
|
139
148
|
query,
|
|
140
149
|
...options,
|
|
141
150
|
headers: (0, headers_1.buildHeaders)([
|
|
142
|
-
{
|
|
151
|
+
{
|
|
152
|
+
...(featurebaseVersion?.toString() != null ?
|
|
153
|
+
{ 'Featurebase-Version': featurebaseVersion?.toString() }
|
|
154
|
+
: undefined),
|
|
155
|
+
},
|
|
143
156
|
options?.headers,
|
|
144
157
|
]),
|
|
145
158
|
});
|
package/resources/surveys.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"surveys.js","sourceRoot":"","sources":["../src/resources/surveys.ts"],"names":[],"mappings":";AAAA,sFAAsF;;;AAEtF,kDAA+C;AAI/C,oDAAmD;AAEnD,oDAA8C;AAE9C;;GAEG;AACH,MAAa,OAAQ,SAAQ,sBAAW;IACtC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAgCG;IACH,QAAQ,CACN,EAAU,EACV,SAAkD,EAAE,EACpD,OAAwB;QAExB,MAAM,EAAE,qBAAqB,EAAE,kBAAkB,EAAE,GAAG,MAAM,IAAI,EAAE,CAAC;QACnE,OAAO,IAAI,CAAC,OAAO,CAAC,GAAG,CAAC,IAAA,WAAI,EAAA,eAAe,EAAE,EAAE,EAAE;YAC/C,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC;gBACpB,
|
|
1
|
+
{"version":3,"file":"surveys.js","sourceRoot":"","sources":["../src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iBACb;gBACD,OAAO,EAAE,OAAO;aACjB,CAAC;SACH,CAAC,CAAC;IACL,CAAC;IAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAqCG;IACH,aAAa,CACX,EAAU,EACV,SAAuD,EAAE,EACzD,OAAwB;QAExB,MAAM,EAAE,qBAAqB,EAAE,kBAAkB,EAAE,GAAG,KAAK,EAAE,GAAG,MAAM,IAAI,EAAE,CAAC;QAC7E,OAAO,IAAI,CAAC,OAAO,CAAC,UAAU,CAC5B,IAAA,WAAI,EAAA,eAAe,EAAE,YAAY,EACjC,CAAA,uBAAuC,CAAA,EACvC;YACE,KAAK;YACL,GAAG,OAAO;YACV,OAAO,EAAE,IAAA,sBAAY,EAAC;gBACpB;oBACE,GAAG,CAAC,kBAAkB,EAAE,QAAQ,EAAE,IAAI,IAAI,CAAC,CAAC;wBAC1C,EAAE,qBAAqB,EAAE,kBAAkB,EAAE,QAAQ,EAAE,EAAE;wBAC3D,CAAC,CAAC,SAAS,CAAC;iBACb;gBACD,OAAO,EAAE,OAAO;aACjB,CAAC;SACH,CACF,CAAC;IACJ,CAAC;CACF;AArKD,0BAqKC"}
|
package/resources/surveys.mjs
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
import { APIResource } from "../core/resource.mjs";
|
|
3
|
+
import { CursorPage } from "../core/pagination.mjs";
|
|
3
4
|
import { buildHeaders } from "../internal/headers.mjs";
|
|
4
5
|
import { path } from "../internal/utils/path.mjs";
|
|
5
6
|
/**
|
|
@@ -44,7 +45,11 @@ export class Surveys extends APIResource {
|
|
|
44
45
|
return this._client.get(path `/v2/surveys/${id}`, {
|
|
45
46
|
...options,
|
|
46
47
|
headers: buildHeaders([
|
|
47
|
-
{
|
|
48
|
+
{
|
|
49
|
+
...(featurebaseVersion?.toString() != null ?
|
|
50
|
+
{ 'Featurebase-Version': featurebaseVersion?.toString() }
|
|
51
|
+
: undefined),
|
|
52
|
+
},
|
|
48
53
|
options?.headers,
|
|
49
54
|
]),
|
|
50
55
|
});
|
|
@@ -83,11 +88,15 @@ export class Surveys extends APIResource {
|
|
|
83
88
|
*/
|
|
84
89
|
list(params = {}, options) {
|
|
85
90
|
const { 'Featurebase-Version': featurebaseVersion, ...query } = params ?? {};
|
|
86
|
-
return this._client.
|
|
91
|
+
return this._client.getAPIList('/v2/surveys', (CursorPage), {
|
|
87
92
|
query,
|
|
88
93
|
...options,
|
|
89
94
|
headers: buildHeaders([
|
|
90
|
-
{
|
|
95
|
+
{
|
|
96
|
+
...(featurebaseVersion?.toString() != null ?
|
|
97
|
+
{ 'Featurebase-Version': featurebaseVersion?.toString() }
|
|
98
|
+
: undefined),
|
|
99
|
+
},
|
|
91
100
|
options?.headers,
|
|
92
101
|
]),
|
|
93
102
|
});
|
|
@@ -130,13 +139,17 @@ export class Surveys extends APIResource {
|
|
|
130
139
|
*
|
|
131
140
|
* - `404` - Survey not found in your organization
|
|
132
141
|
*/
|
|
133
|
-
|
|
142
|
+
listResponses(id, params = {}, options) {
|
|
134
143
|
const { 'Featurebase-Version': featurebaseVersion, ...query } = params ?? {};
|
|
135
|
-
return this._client.
|
|
144
|
+
return this._client.getAPIList(path `/v2/surveys/${id}/responses`, (CursorPage), {
|
|
136
145
|
query,
|
|
137
146
|
...options,
|
|
138
147
|
headers: buildHeaders([
|
|
139
|
-
{
|
|
148
|
+
{
|
|
149
|
+
...(featurebaseVersion?.toString() != null ?
|
|
150
|
+
{ 'Featurebase-Version': featurebaseVersion?.toString() }
|
|
151
|
+
: undefined),
|
|
152
|
+
},
|
|
140
153
|
options?.headers,
|
|
141
154
|
]),
|
|
142
155
|
});
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"surveys.mjs","sourceRoot":"","sources":["../src/resources/surveys.ts"],"names":[],"mappings":"AAAA,sFAAsF;OAE/E,EAAE,WAAW,EAAE;OAIf,EAAE,YAAY,EAAE;OA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