Skip to content

Conversation

@jcortes
Copy link
Collaborator

@jcortes jcortes commented Dec 10, 2025

WHY

Resolves #13419

Summary by CodeRabbit

  • New Features
    • Added Survicate integration with comprehensive survey management capabilities.
    • New actions to list and retrieve surveys, questions, and responses.
    • New actions to retrieve respondent attributes and responses.
    • New actions to retrieve personal data counters and delete personal data.
    • Support for pagination across all list operations.

✏️ Tip: You can customize this high-level summary in your review settings.

@jcortes jcortes self-assigned this Dec 10, 2025
@vercel
Copy link

vercel bot commented Dec 10, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

2 Skipped Deployments
Project Deployment Preview Comments Updated (UTC)
pipedream-docs Ignored Ignored Dec 10, 2025 5:29pm
pipedream-docs-redirect-do-not-edit Ignored Ignored Dec 10, 2025 5:29pm

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 10, 2025

Walkthrough

This PR introduces a new Survicate component integration with ten action modules and a complete API client layer in the app module, enabling data retrieval and management operations through the Survicate Data Export API.

Changes

Cohort / File(s) Summary
New Survicate Actions
components/survicate/actions/delete-personal-data/delete-personal-data.mjs, components/survicate/actions/get-personal-data-counters/get-personal-data-counters.mjs, components/survicate/actions/get-response/get-response.mjs, components/survicate/actions/get-survey/get-survey.mjs, components/survicate/actions/list-questions/list-questions.mjs, components/survicate/actions/list-respondent-attributes/list-respondent-attributes.mjs, components/survicate/actions/list-respondent-responses/list-respondent-responses.mjs, components/survicate/actions/list-responses/list-responses.mjs, components/survicate/actions/list-surveys/list-surveys.mjs
Adds nine action modules for survey data retrieval, response management, respondent attribute queries, and personal data handling operations. Each exports a default action object with metadata, props, and a run method invoking corresponding app API methods.
Configuration & Constants
components/survicate/common/constants.mjs
New module exporting VERSION_PATH, BASE_URL, and DEFAULT_LIMIT constants for API configuration.
App Module & Dependencies
components/survicate/survicate.app.mjs, components/survicate/package.json
Updates app module with HTTP client layer (getUrl, _headers, _makeRequest methods) and implements nine API methods (listSurveys, getSurvey, listQuestions, listResponses, getResponse, listRespondentAttributes, listRespondentResponses, getPersonalDataCounters, deletePersonalData). Adds propDefinitions for surveys, responses, respondent identifiers, and pagination. Bumps version to 0.1.0 and adds @pipedream/platform dependency.

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

  • survicate.app.mjs: Verify HTTP client implementation (_makeRequest, _headers, getUrl), propDefinitions correctness for async options with pagination support, and API method signatures align with Survicate Data Export API documentation.
  • Action modules: Confirm consistent patterns across action definitions, prop mappings to app methods, and summary export formatting.
  • Constants: Validate BASE_URL and API versioning path are current and correct.

Pre-merge checks and finishing touches

❌ Failed checks (2 warnings, 1 inconclusive)
Check name Status Explanation Resolution
Linked Issues check ⚠️ Warning The PR implements data-export actions and list operations but fails to implement the required webhook sources and create-note action specified in issue #13419. Implement the webhook sources (new-question-answer-instant, new-survey-completion-instant) and the create-note action to meet the linked issue requirements.
Out of Scope Changes check ⚠️ Warning The PR introduces data-export API actions (list/get responses, surveys, etc.) that were not specified in the linked issue requirements. Remove out-of-scope actions or clarify in the issue description that these additional data-export utilities are desired alongside the required components.
Description check ❓ Inconclusive The PR description only references the issue number but lacks substantive detail about what components are being added. Expand the description to explain which components are being implemented and their purpose.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies that this PR adds new Survicate components/actions to the codebase.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch survicate-new-components

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 4

📜 Review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between dd65b8e and 7ca2ad3.

⛔ Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
📒 Files selected for processing (12)
  • components/survicate/actions/delete-personal-data/delete-personal-data.mjs (1 hunks)
  • components/survicate/actions/get-personal-data-counters/get-personal-data-counters.mjs (1 hunks)
  • components/survicate/actions/get-response/get-response.mjs (1 hunks)
  • components/survicate/actions/get-survey/get-survey.mjs (1 hunks)
  • components/survicate/actions/list-questions/list-questions.mjs (1 hunks)
  • components/survicate/actions/list-respondent-attributes/list-respondent-attributes.mjs (1 hunks)
  • components/survicate/actions/list-respondent-responses/list-respondent-responses.mjs (1 hunks)
  • components/survicate/actions/list-responses/list-responses.mjs (1 hunks)
  • components/survicate/actions/list-surveys/list-surveys.mjs (1 hunks)
  • components/survicate/common/constants.mjs (1 hunks)
  • components/survicate/package.json (2 hunks)
  • components/survicate/survicate.app.mjs (1 hunks)
🧰 Additional context used
🧠 Learnings (4)
📚 Learning: 2024-10-08T15:33:38.240Z
Learnt from: GTFalcao
Repo: PipedreamHQ/pipedream PR: 12731
File: components/hackerone/actions/get-members/get-members.mjs:3-28
Timestamp: 2024-10-08T15:33:38.240Z
Learning: When exporting a summary message in the `run` method of an action, ensure the message is correctly formatted. For example, in the `hackerone-get-members` action, the correct format is `Successfully retrieved ${response.data.length} members`.

Applied to files:

  • components/survicate/actions/get-personal-data-counters/get-personal-data-counters.mjs
  • components/survicate/actions/list-responses/list-responses.mjs
  • components/survicate/actions/list-respondent-responses/list-respondent-responses.mjs
  • components/survicate/actions/get-response/get-response.mjs
📚 Learning: 2025-06-04T17:52:05.780Z
Learnt from: GTFalcao
Repo: PipedreamHQ/pipedream PR: 16954
File: components/salesloft/salesloft.app.mjs:14-23
Timestamp: 2025-06-04T17:52:05.780Z
Learning: In the Salesloft API integration (components/salesloft/salesloft.app.mjs), the _makeRequest method returns response.data which directly contains arrays for list endpoints like listPeople, listCadences, listUsers, and listAccounts. The propDefinitions correctly call .map() directly on these responses without needing to destructure a nested data property.

Applied to files:

  • components/survicate/actions/list-responses/list-responses.mjs
  • components/survicate/survicate.app.mjs
📚 Learning: 2024-12-12T19:23:09.039Z
Learnt from: jcortes
Repo: PipedreamHQ/pipedream PR: 14935
File: components/sailpoint/package.json:15-18
Timestamp: 2024-12-12T19:23:09.039Z
Learning: When developing Pipedream components, do not add built-in Node.js modules like `fs` to `package.json` dependencies, as they are native modules provided by the Node.js runtime.

Applied to files:

  • components/survicate/package.json
📚 Learning: 2025-09-15T22:01:11.472Z
Learnt from: GTFalcao
Repo: PipedreamHQ/pipedream PR: 18362
File: components/leonardo_ai/actions/generate-image/generate-image.mjs:103-105
Timestamp: 2025-09-15T22:01:11.472Z
Learning: In Pipedream components, pipedream/platform's axios implementation automatically excludes undefined values from HTTP requests, so there's no need to manually check for truthiness before including properties in request payloads.

Applied to files:

  • components/survicate/survicate.app.mjs
🧬 Code graph analysis (8)
components/survicate/actions/get-personal-data-counters/get-personal-data-counters.mjs (6)
components/survicate/actions/delete-personal-data/delete-personal-data.mjs (1)
  • response (28-33)
components/survicate/actions/get-response/get-response.mjs (1)
  • response (39-43)
components/survicate/actions/get-survey/get-survey.mjs (1)
  • response (29-32)
components/survicate/actions/list-responses/list-responses.mjs (1)
  • response (52-60)
components/survicate/actions/list-surveys/list-surveys.mjs (1)
  • response (43-50)
components/survicate/survicate.app.mjs (2)
  • response (17-22)
  • response (52-58)
components/survicate/actions/list-questions/list-questions.mjs (9)
components/survicate/actions/delete-personal-data/delete-personal-data.mjs (1)
  • response (28-33)
components/survicate/actions/get-personal-data-counters/get-personal-data-counters.mjs (1)
  • response (28-33)
components/survicate/actions/get-response/get-response.mjs (1)
  • response (39-43)
components/survicate/actions/get-survey/get-survey.mjs (1)
  • response (29-32)
components/survicate/actions/list-respondent-attributes/list-respondent-attributes.mjs (1)
  • response (44-51)
components/survicate/actions/list-respondent-responses/list-respondent-responses.mjs (1)
  • response (44-51)
components/survicate/actions/list-responses/list-responses.mjs (1)
  • response (52-60)
components/survicate/actions/list-surveys/list-surveys.mjs (1)
  • response (43-50)
components/survicate/survicate.app.mjs (2)
  • response (17-22)
  • response (52-58)
components/survicate/actions/list-responses/list-responses.mjs (3)
components/survicate/actions/list-questions/list-questions.mjs (1)
  • response (44-51)
components/survicate/actions/list-surveys/list-surveys.mjs (1)
  • response (43-50)
components/survicate/survicate.app.mjs (2)
  • response (17-22)
  • response (52-58)
components/survicate/actions/list-respondent-attributes/list-respondent-attributes.mjs (2)
components/survicate/actions/list-respondent-responses/list-respondent-responses.mjs (1)
  • response (44-51)
components/survicate/actions/list-surveys/list-surveys.mjs (1)
  • response (43-50)
components/survicate/actions/delete-personal-data/delete-personal-data.mjs (4)
components/survicate/actions/get-personal-data-counters/get-personal-data-counters.mjs (1)
  • response (28-33)
components/survicate/actions/get-response/get-response.mjs (1)
  • response (39-43)
components/survicate/actions/get-survey/get-survey.mjs (1)
  • response (29-32)
components/survicate/survicate.app.mjs (2)
  • response (17-22)
  • response (52-58)
components/survicate/actions/get-survey/get-survey.mjs (7)
components/survicate/actions/get-response/get-response.mjs (1)
  • response (39-43)
components/survicate/actions/list-questions/list-questions.mjs (1)
  • response (44-51)
components/survicate/actions/list-respondent-attributes/list-respondent-attributes.mjs (1)
  • response (44-51)
components/survicate/actions/list-respondent-responses/list-respondent-responses.mjs (1)
  • response (44-51)
components/survicate/actions/list-responses/list-responses.mjs (1)
  • response (52-60)
components/survicate/actions/list-surveys/list-surveys.mjs (1)
  • response (43-50)
components/survicate/survicate.app.mjs (2)
  • response (17-22)
  • response (52-58)
components/survicate/actions/list-surveys/list-surveys.mjs (9)
components/survicate/actions/delete-personal-data/delete-personal-data.mjs (1)
  • response (28-33)
components/survicate/actions/get-personal-data-counters/get-personal-data-counters.mjs (1)
  • response (28-33)
components/survicate/actions/get-response/get-response.mjs (1)
  • response (39-43)
components/survicate/actions/get-survey/get-survey.mjs (1)
  • response (29-32)
components/survicate/actions/list-questions/list-questions.mjs (1)
  • response (44-51)
components/survicate/actions/list-respondent-attributes/list-respondent-attributes.mjs (1)
  • response (44-51)
components/survicate/actions/list-respondent-responses/list-respondent-responses.mjs (1)
  • response (44-51)
components/survicate/actions/list-responses/list-responses.mjs (1)
  • response (52-60)
components/survicate/survicate.app.mjs (2)
  • response (17-22)
  • response (52-58)
components/survicate/survicate.app.mjs (9)
components/survicate/actions/delete-personal-data/delete-personal-data.mjs (1)
  • response (28-33)
components/survicate/actions/get-personal-data-counters/get-personal-data-counters.mjs (1)
  • response (28-33)
components/survicate/actions/get-response/get-response.mjs (1)
  • response (39-43)
components/survicate/actions/get-survey/get-survey.mjs (1)
  • response (29-32)
components/survicate/actions/list-questions/list-questions.mjs (1)
  • response (44-51)
components/survicate/actions/list-respondent-attributes/list-respondent-attributes.mjs (1)
  • response (44-51)
components/survicate/actions/list-respondent-responses/list-respondent-responses.mjs (1)
  • response (44-51)
components/survicate/actions/list-responses/list-responses.mjs (1)
  • response (52-60)
components/survicate/actions/list-surveys/list-surveys.mjs (1)
  • response (43-50)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: Lint Code Base
  • GitHub Check: pnpm publish
  • GitHub Check: Verify TypeScript components
  • GitHub Check: Publish TypeScript components
🔇 Additional comments (10)
components/survicate/package.json (1)

3-3: LGTM!

The version bump to 0.1.0 appropriately reflects the addition of new features, and the @pipedream/platform dependency is correctly added.

Also applies to: 15-16

components/survicate/actions/list-surveys/list-surveys.mjs (1)

1-55: LGTM!

The action follows the standard Pipedream pattern with appropriate annotations for a read-only list operation. The use of optional chaining in the summary export safely handles cases where response.data might be undefined.

components/survicate/common/constants.mjs (1)

1-9: LGTM!

Clean constants definition for the Survicate API integration.

components/survicate/actions/list-respondent-responses/list-respondent-responses.mjs (1)

1-56: LGTM!

The action correctly implements the list respondent responses functionality with appropriate props and a detailed summary message that includes the respondent UUID.

Note: The start parameter description at line 29 has the same potential clarity issue flagged in list-responses.mjs regarding "before this timestamp."

components/survicate/actions/list-respondent-attributes/list-respondent-attributes.mjs (1)

1-56: LGTM!

The action follows the established pattern with appropriate props and a detailed summary. The start parameter usage for pagination by attribute ID is noted (see comment on list-questions.mjs regarding start parameter semantics).

components/survicate/actions/list-questions/list-questions.mjs (1)

28-34: Verify the start parameter semantics against the actual Survicate API.

The start prop description indicates it's "The unique identifier of the question" for pagination, but other actions use it differently:

  • list-responses.mjs: "Optional start timestamp for filtering responses"
  • list-respondent-attributes.mjs: "The unique identifier of the attribute"

Confirm whether these different usages align with the actual Survicate API endpoint specifications, as the public documentation does not explicitly document a "start" parameter.

components/survicate/actions/list-responses/list-responses.mjs (1)

28-41: [rewritten comment]
[classification tag]

components/survicate/actions/get-response/get-response.mjs (1)

3-47: Correct dependent prop wiring and run implementation

This action is wired cleanly:

  • responseId correctly depends on surveyId via the third propDefinition argument, so response options are scoped to the selected survey.
  • run forwards surveyId and responseId to app.getResponse and returns the API result.
  • Summary string uses response.uuid, which matches how responseId options are built from the uuid field.

Assuming the underlying app method returns the expected JSON object (see app review), this action looks good.

components/survicate/actions/get-survey/get-survey.mjs (1)

3-36: Use the known surveyId prop in the summary instead of response.id

For the summary you currently rely on a field from the API response:

$.export("$summary", `Successfully retrieved survey with ID \`${response.id}\``);

Since the user already provided surveyId and that’s what you passed to the API, you can decouple the summary from the exact response shape and avoid issues if the API uses a different key or nesting:

-    $.export("$summary", `Successfully retrieved survey with ID \`${response.id}\``);
+    $.export("$summary", `Successfully retrieved survey with ID \`${surveyId}\``);

This keeps the UX the same while being more robust to API schema changes.

⛔ Skipped due to learnings
Learnt from: GTFalcao
Repo: PipedreamHQ/pipedream PR: 12731
File: components/hackerone/actions/get-members/get-members.mjs:3-28
Timestamp: 2024-10-08T15:33:38.240Z
Learning: When exporting a summary message in the `run` method of an action, ensure the message is correctly formatted. For example, in the `hackerone-get-members` action, the correct format is `Successfully retrieved ${response.data.length} members`.
Learnt from: GTFalcao
Repo: PipedreamHQ/pipedream PR: 12731
File: components/hackerone/actions/get-members/get-members.mjs:3-28
Timestamp: 2024-07-04T18:11:59.822Z
Learning: When exporting a summary message in the `run` method of an action, ensure the message is correctly formatted. For example, in the `hackerone-get-members` action, the correct format is `Successfully retrieved ${response.data.length} members`.
components/survicate/actions/get-personal-data-counters/get-personal-data-counters.mjs (1)

3-37: Action wiring and summary are correct

The action implementation accurately reflects the Survicate API:

  • email is correctly passed as a query parameter to the GET /v2/personal-data/counters endpoint.
  • The operation is read-only (GET method), matching the readOnlyHint: true annotation.
  • Summary "Successfully retrieved personal data counters" is appropriate and does not expose the email value.

No changes needed.

Copy link
Collaborator

@michelle0927 michelle0927 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Ready for QA!

@vunguyenhung
Copy link
Collaborator

Hi everyone, all test cases are passed! Ready for release!

Test reports

@jcortes jcortes merged commit 7d3d2c6 into master Dec 11, 2025
10 checks passed
@jcortes jcortes deleted the survicate-new-components branch December 11, 2025 12:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Components] survicate

4 participants