From bf1a4028d574c8603e260bacac73d87a571059c9 Mon Sep 17 00:00:00 2001 From: piyush-nudge Date: Wed, 14 May 2025 13:49:44 +0530 Subject: [PATCH 1/3] feat: added docs for Nudge (Actions) Destination integration --- .../catalog/actions-nudge/index.md | 96 +++++++++++++++++++ 1 file changed, 96 insertions(+) create mode 100644 src/connections/destinations/catalog/actions-nudge/index.md diff --git a/src/connections/destinations/catalog/actions-nudge/index.md b/src/connections/destinations/catalog/actions-nudge/index.md new file mode 100644 index 0000000000..b4005e5ad1 --- /dev/null +++ b/src/connections/destinations/catalog/actions-nudge/index.md @@ -0,0 +1,96 @@ +Nudge (Actions) Destination +--- + +{% include content/plan-grid.md name="actions" %} + +[Nudge](https://nudgenow.com/?utm_source=segmentio&utm_medium=docs&utm_campaign=partners){:target="_blank”} is an AI personalization platform for marketing teams for enabling rapid personalization experimentation and for autonomously delivering 1:1 user experiences. + +This destination is maintained by the Nudge Developer Team. For any issues with the destination, [contact the Support team](mailto:support@nudgenow.com). + +## Getting started + +1. From your workspace's [Destination catalog page](https://app.segment.com/goto-my-workspace/destinations/catalog){:target="_blank”} search for "Nudge". +2. Select **Nudge** and click **Add Destination**. +3. Select an existing Source to connect to Nudge (Actions). +4. Go to the [Nudge dashboard](https://dashboard.nudgenow.com){:target="_blank"}, and navigate to the **Settings** page. +5. Go to the **Secret Keys** section and click on the **Create new secret key** button. +6. Give appropriate name for the key, select the **Backend API** option from the permissions dropdown and create the key. +7. Copy the generated key and store it somewhere safe for future reference. +8. Enter the generated API key in the **Nudge** destination settings in Segment. + +## Supported methods + +Nudge (Actions) Destination currently supports the Identify and Track methods listed below in accordance to the core Segment Specs. Reference: [Spec Overview](https://segment.com/docs/connections/spec/) + +### Identify + +The Identify method lets you create or update a user in Nudge’s backend. Every Identify call should include a `userId`. See Segment's Spec for Identify for any reference: [Identify Spec](https://segment.com/docs/connections/spec/identify/) + +**Example (using Segment's Analytics.js SDK)** + +```js +analytics.identify('user123', { + firstName: 'Alice', + lastName: 'Smith', + email: 'alice.smith@example.com', + company: 'Acme Corp', + employees: 150 +}); +``` + +How Nudge handles Identify calls: + +* If `userId` does not exist, the request would throw a 400 validation error as it is a required field. +* If `userId` already exists, Nudge merges or overwrites profile properties with the latest values. +* Identify calls without `userId`, or with only `anonymousId`, are dropped. + +--- + +### Track + +The Track method sends custom events and their properties into Nudge. You must include `event` name in every Track call so events can be associated with the correct user. See Segment's Spec for Track for any reference: [Track Spec](https://segment.com/docs/connections/spec/track/) + +**Example (using Segment's Analytics.js SDK)** + +```js +analytics.track('Product Viewed', { + product_id: 784, + product_sku: 'SH#79817' +}); +``` + +How Nudge handles Track calls: + +* Segment ensures the `userId` is attached to the Track call for a previously successful Identify. +* Events without a valid `userId` or with only `anonymousId` are dropped. +* All other event properties are ingested as event metadata and can be used for trigger conditions. + + +{% include components/actions-fields.html %} + +## Troubleshooting + +### 1. Events not showing up in Nudge + +* **Missing or invalid API key** + Ensure that the API key you generated under **Settings → Secret Keys → Backend API** is correctly entered in your Segment destination settings. +* **Dropped Identify/Track calls** + Calls without `userId`, or with only `anonymousId`, are automatically dropped. Verify your mapping includes the correct identifier field. + +### 2. Timestamp or date format errors + +Nudge expects all date/time properties in UTC ISO-8601 format (Javascript Date object's ISO format). If you see failed events due to timestamp validation: + +* Confirm you’re sending dates like `"2025-05-14T07:30:00Z"`. +* Remove any timezone offsets other than `Z` (UTC). + +### 3. Validation failures + +If requests continue to fail after checking your API key and payload: + +* Compare against Nudge’s specification from the documentation: [https://docs.nudgenow.com/](https://docs.nudgenow.com/). +* Ensure all required fields (e.g., `userId`, `event` name for Track) are present and correctly typed. + +--- + +*If you still encounter issues, please reach out to the Nudge Developer Team or email [support@nudgenow.com](mailto:support@nudgenow.com).* \ No newline at end of file From e410ad3657d51f597ad27ca373f38b4cf65dbfe3 Mon Sep 17 00:00:00 2001 From: piyush-nudge Date: Thu, 12 Jun 2025 16:45:42 +0530 Subject: [PATCH 2/3] fix: fixed readme manifest --- .../destinations/catalog/actions-nudge/index.md | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/connections/destinations/catalog/actions-nudge/index.md b/src/connections/destinations/catalog/actions-nudge/index.md index b4005e5ad1..4c626e7551 100644 --- a/src/connections/destinations/catalog/actions-nudge/index.md +++ b/src/connections/destinations/catalog/actions-nudge/index.md @@ -1,4 +1,6 @@ -Nudge (Actions) Destination +--- +title: Nudge (Actions) Destination +id: --- {% include content/plan-grid.md name="actions" %} @@ -30,8 +32,7 @@ The Identify method lets you create or update a user in Nudge’s backend. Every ```js analytics.identify('user123', { - firstName: 'Alice', - lastName: 'Smith', + name: 'Alice Smith', email: 'alice.smith@example.com', company: 'Acme Corp', employees: 150 @@ -93,4 +94,4 @@ If requests continue to fail after checking your API key and payload: --- -*If you still encounter issues, please reach out to the Nudge Developer Team or email [support@nudgenow.com](mailto:support@nudgenow.com).* \ No newline at end of file +*If you still encounter issues, please reach out to the Nudge Developer Team or email [support@nudgenow.com](mailto:support@nudgenow.com).* From a39543d1d4b0b26005255b1df9a8e4b2ebed8306 Mon Sep 17 00:00:00 2001 From: piyush-nudge Date: Mon, 23 Jun 2025 15:50:10 +0530 Subject: [PATCH 3/3] update: updated Nudge (Action) Destination docs --- .../catalog/actions-nudge/index.md | 34 +++++++++---------- 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/src/connections/destinations/catalog/actions-nudge/index.md b/src/connections/destinations/catalog/actions-nudge/index.md index 4c626e7551..797fd5f946 100644 --- a/src/connections/destinations/catalog/actions-nudge/index.md +++ b/src/connections/destinations/catalog/actions-nudge/index.md @@ -11,24 +11,24 @@ This destination is maintained by the Nudge Developer Team. For any issues with ## Getting started -1. From your workspace's [Destination catalog page](https://app.segment.com/goto-my-workspace/destinations/catalog){:target="_blank”} search for "Nudge". +1. From your workspace's [Destination catalog page](https://app.segment.com/goto-my-workspace/destinations/catalog){:target="_blank”} search for **Nudge**. 2. Select **Nudge** and click **Add Destination**. 3. Select an existing Source to connect to Nudge (Actions). 4. Go to the [Nudge dashboard](https://dashboard.nudgenow.com){:target="_blank"}, and navigate to the **Settings** page. -5. Go to the **Secret Keys** section and click on the **Create new secret key** button. -6. Give appropriate name for the key, select the **Backend API** option from the permissions dropdown and create the key. +5. Go to the **Secret Keys** section and click **Create new secret key**. +6. Give an appropriate name for the key, then select the **Backend API** option from the permissions dropdown and create the key. 7. Copy the generated key and store it somewhere safe for future reference. -8. Enter the generated API key in the **Nudge** destination settings in Segment. +8. Paste the generated API key in the **Nudge** destination settings in Segment. ## Supported methods -Nudge (Actions) Destination currently supports the Identify and Track methods listed below in accordance to the core Segment Specs. Reference: [Spec Overview](https://segment.com/docs/connections/spec/) +The Nudge (Actions) Destination currently supports the Identify and Track methods listed below in accordance to the core Segment Specs. Reference: [Spec Overview](https://segment.com/docs/connections/spec/) ### Identify The Identify method lets you create or update a user in Nudge’s backend. Every Identify call should include a `userId`. See Segment's Spec for Identify for any reference: [Identify Spec](https://segment.com/docs/connections/spec/identify/) -**Example (using Segment's Analytics.js SDK)** +Example (using Segment's Analytics.js SDK): ```js analytics.identify('user123', { @@ -41,7 +41,7 @@ analytics.identify('user123', { How Nudge handles Identify calls: -* If `userId` does not exist, the request would throw a 400 validation error as it is a required field. +* If `userId` doesn't exist, the request throws a 400 validation error as it's a required field. * If `userId` already exists, Nudge merges or overwrites profile properties with the latest values. * Identify calls without `userId`, or with only `anonymousId`, are dropped. @@ -51,7 +51,7 @@ How Nudge handles Identify calls: The Track method sends custom events and their properties into Nudge. You must include `event` name in every Track call so events can be associated with the correct user. See Segment's Spec for Track for any reference: [Track Spec](https://segment.com/docs/connections/spec/track/) -**Example (using Segment's Analytics.js SDK)** +Example (using Segment's Analytics.js SDK): ```js analytics.track('Product Viewed', { @@ -71,27 +71,25 @@ How Nudge handles Track calls: ## Troubleshooting -### 1. Events not showing up in Nudge +### Events aren't showing up in Nudge -* **Missing or invalid API key** - Ensure that the API key you generated under **Settings → Secret Keys → Backend API** is correctly entered in your Segment destination settings. -* **Dropped Identify/Track calls** - Calls without `userId`, or with only `anonymousId`, are automatically dropped. Verify your mapping includes the correct identifier field. +Events may not show up in Nudge due to one of these reasons: +* **Missing or invalid API key**: Ensure that the API key you generated under **Settings → Secret Keys → Backend API** is correctly entered in your Segment destination settings. +* **Dropped Identify/Track calls**: API requests to Nudge's servers without `userId`, or with only `anonymousId`, are automatically dropped. Verify your mapping includes the correct identifier field. -### 2. Timestamp or date format errors +### Timestamp or date format errors Nudge expects all date/time properties in UTC ISO-8601 format (Javascript Date object's ISO format). If you see failed events due to timestamp validation: * Confirm you’re sending dates like `"2025-05-14T07:30:00Z"`. * Remove any timezone offsets other than `Z` (UTC). -### 3. Validation failures +### Validation failures If requests continue to fail after checking your API key and payload: -* Compare against Nudge’s specification from the documentation: [https://docs.nudgenow.com/](https://docs.nudgenow.com/). -* Ensure all required fields (e.g., `userId`, `event` name for Track) are present and correctly typed. +* Compare against Nudge’s specification from the documentation: [Nudge's Documentation](https://docs.nudgenow.com/){:target="_blank"}. +* Ensure all required fields (for example, `userId`, `event` name for Track) are present and correctly typed. ---- *If you still encounter issues, please reach out to the Nudge Developer Team or email [support@nudgenow.com](mailto:support@nudgenow.com).*