Β 

Changelog

The latest releases and improvements to Knock.

New Android SDK

Today, we’re shipping our new Android SDK, which is a client-side SDK written in Kotlin to interact with the Knock API and to build in-app notification experiences in Android applications.

We have big plans for more in-product experiences that we’ll be bundling into this SDK in the near future. Today’s release is a first step towards that future, giving the base primitives to easily bring all of the functionality of Knock into your applications in an easy-to-consume way.

You can learn more in our Android SDK Documentation, or get started now by following the installation instructions.

Fixes and improvements

  • πŸ‘€ We added support for edge runtimes, like Vercel and Cloudflare Workers, in our Node JS SDK
  • πŸ‘€ We now show a channel data tab when viewing an individual tenant in the dashboard

New React SDK

Today, we’re shipping our new React SDK (@knocklabs/react), which provides a unified set of hooks and components for integrating Knock into your web applications. You can use our React package to power in-app notification experiences like feeds, toasts, and banners for your users, as well as powering notification configuration via our preferences API.

Our new SDK is the home of all in-product notification experiences powered by Knock, superseding the previous react-notification-feed package. If you’re using the old package, you can read here on how to migrate.

We have big plans for more in-product experiences that we’ll be bundling into this package in the near future. Today’s release is a first step towards that future, giving the base primitives to easily bring all of the functionality of Knock into your applications in an easy-to-consume way.

You can install the React SDK from NPM by running npm install @knocklabs/react and can find the package in our brand new Javascript monorepo.

Fixes and improvements

  • πŸ‘€ We improved the loading time of message views within the Dashboard
  • πŸ‘€ We now validate certificates when configuring an APNS channel
  • πŸ‘€ We now validate the service account JSON when configuring a FCM channel

Schedule one-off workflow runs

Earlier this year we released the ability to run recurring workflows for your users via our Schedules API. Today, we're releasing an extension to our schedules API with the ability to schedule a single workflow run in the future for one or more recipients. One-off schedules are perfect to enqueue a workflow that should be run at some future point, without you needing to write your own cron jobs to do so.

Here's an example of creating a one-off schedule for a set of recipients:

await knock.workflows.createSchedules("park-alert", {
  recipients: ["jhammond", "esattler", "dnedry"],
  scheduled_at: "2023-12-25 12:00:00Z"
  data: { type: "dinosaurs-loose" },
  tenant: "jpark",
});

You can learn more about running one-off or recurring schedules in the documentation.

Customize the response of the in-app feed

Today, we’re launching additional privacy controls for our in-app feed API. Previously, when your recipient’s in-app feeds were requested, the response would include the full recipient object, which could lead to personal data about your recipient being returned unnecessarily.

With today's release, you can now use allow or deny lists to control which fields are returned from any entity in your feed request. Here's an example in-app feed response filter:

{
  "actor": {
    "only": ["id"]
  },
  "data": {
    "except": ["credit_card_last4"]
  }
}

Read more in the documentation.

Fixes and improvements

  • πŸ› We fixed an issue where clicking links in a message preview could crash the dashboard
  • πŸ› We fixed an issue where using tenants as a recipient in a workflow trigger would stop workflow runs from showing

Promote individual commits in the CLI

You can now use the Knock CLI to promote individual commits. This was previously available in the dashboard, and today we're bringing it to the CLI. With this addition, it makes it easy to build specific deployement workflows that only promotes the resources you need.

Individual commit promotion is available now in the latest version of the CLI (v0.1.7) and is available across all plans. You can read more in the documentation.

Fixes and improvements

  • πŸ‘€ You can now go directly to the workflow editor from the workflows page using the 3-dot menu
  • πŸ‘€ You can now use cmd+return in the preview data editor to save the data and close the modal
  • πŸ› We fixed an issue where the update schedules endpoint was missing schema validation for an empty properties object
  • πŸ› We fixed an issue where breadcrumbs didn't load properly on our docs site
  • πŸ› We fixed a few tooltip and text display issues in the Dashboard

Manage email layouts via the CLI and management API

With the introduction of our CLI and management API earlier this year, we added support for working with both workflows and translations locally. Now, we've added support for managing email layouts via the CLI and management API, making it possible to pull down your email layouts locally, make changes to those layouts, and push them back up to Knock to be deployed.

Working with email layouts is available now in the latest version of the CLI (v0.1.x) and is available across all plans. You can read more in the documentation.

Control the number of items rendered in a batch template

While our batch function has always allowed an unlimited number of items to be accumulated per-batch, the number of items that could be rendered in a template from that batch has always been limited to the first or last 10 items. Today, we're adding a new setting into our batch function to control the number of items that can be rendered, with the ability to render up-to 100 items.

Batch render limits are available now on our Enterprise plan only. You can read more in the documentation, or contact our sales team today to arrange a demo.

Fixes and improvements

  • πŸ‘€ We now highlight the "Developers > Logs" menu item when viewing workflow runs
  • πŸ‘€ All new accounts now have an in-app feed channel setup by default
  • πŸ› We fixed a bug where in certain cases hourly schedules would not repeat

User deletion and right to be forgotten requests

We've expanded the scope of our user deletion endpoint. Now we permanently delete all content associated with a user upon receiving a deletion request. This means that Knock user deletion is now fully GDPR-compliant and can be used to programmatically process right to be forgotten requests. Previously we had supported these requests in an ad-hoc way through our customer support, but with this change you can now programmatically call the user delete or bulk delete APIs and have all content for a user permanently removed.

You can learn more in our user deletion documentation ->

Bypass recipient preference evaluation

We've introduced a per-workflow control to bypass recipient preferences. This is useful in situations where you need to force a critical notification through to a recipient (such as a password reset email) regardless of that recipient's channel preferences.

You can find the new preference control under "Manage workflow" in the workflow three-dot menu. You can learn more in the preferences documentation.

Fixes and improvements

  • πŸ‘€ We changed the admin role to be able to create and manage environments
  • πŸ‘€ We changed our combobox behavior for selecting recipients and actors to load a page of data to aid with selection
  • πŸ‘€ We added support for per-customer overrides for idempotency windows
  • πŸ› We fixed an issue where the workflow category selector was case sensitive
  • πŸ› We fixed an issue where the knock.messages.delivered metric was not being sent to Datadog

Set a maximum batch limit

Today we're releasing a new way to close your notification batches, by setting a maximum number of items allowed. This means a batch can now close either temporally (when the batch window ends), or when a certain number of items have been accumulated, giving you even more flexibility on how you batch your notifications.

You can set a maximum batch item limit under the batch step settings. Read more in the documentation.

Fixes and improvements

  • πŸ‘€ We added a new bulk add subscriptions API endpoint
  • πŸ‘€ We changed the behavior of our recipient preferences set endpoints to create empty recipient's when setting preferences for new recipients instead of 404-ing
  • πŸ‘€ We increased the limit on all of our bulk operation endpoints from 100 to 1000 items at a time
  • πŸ‘€ We added support for the Mailtrap email testing API
  • πŸ‘€ We added an email field to our docs feedback component
  • πŸ‘€ We now expose subscription information under a recipient when triggering a workflow from a subscription
  • πŸ› We fixed an issue where you could not manage subscriptions under a tenant object
  • πŸ› We fixed an issue where some email clients would not report tracking information correctly
  • πŸ› We fixed an issue with our batch steps where in certain cases, using a sliding batch window could extend to the maximum batch duration
  • πŸ› We fixed an issue where using the CLI to push translations with no changes would result in uncommitted changes being generated
  • πŸ› We fixed an issue where webhooks were not being properly created via the Dashboard
  • πŸ› We fixed an issue where long variable names would break the layout in the variable pane

Today we’re announcing the first major update to our workflow canvas since we first launched Knock in beta two years ago. 😁

With this release we’ve rebuilt the Knock workflow builder from the ground up to support:

  • If-else and multi-branch workflows. Use our branch function to create if-else and multi-path messaging workflows.
  • An improved user experience. It’s now easier to drag-and-drop steps into the canvas and reorder steps. We’ve also shipped pan-and-zoom controls for moving around the canvas.
  • Even better workflow debugging. With our new branch step, we’ve updated our debugger so you can easily see which branch executed in a given workflow.

Read the full announcement here β€”>

Connect event triggers in the workflow builder

When working with Segment or a similar integration source in Knock, previously all the configuration would take place in the Sources pages. We've now added the ability to add and change your event triggers directly in the workflow builder. There's a toggle from API to Event in the trigger step that will open the event trigger pane where you can add an event, edit its field mappings, and commit it alongside your workflow.

Run workflow tests with event data

You can now test your event-driven workflows directly from Knock! Rather than sending a test event from one of your integration sources, the workflow test runner will automatically pull in the latest event received for you to run rehearsals of a workflow powered by events. This helps you fine tune your mappings and make sure you're getting all the necessary data for your notifications without switching between applications.

Improved event logging

Previously, our event logging was too strict - instead of logging malformed events coming into Knock, our system would drop them, making it hard to know what was wrong. Now we're logging every event, whether it's valid or not. If it's already triggering a workflow, we'll let you know why it did or didn't work. We've also added logs for our test events so that after every run you'll get the same detailed feedback about what's missing or malformed in your event.

Both of these improvements decrease the amount of time you spend tracking down missing data and gets your event-driven workflows into production faster.

Fixes and improvements

  • πŸ› We fixed a bug in preference conditions where not_contains wasn't recognizing null as a truthy value
  • πŸ› We fixed a bug where reset uncommitted changes was enabled even if there were no commits
  • πŸ› We fixed a bug where we were sending duplicate invoices
  • πŸ› We fixed a bug where updating workflow categories were hidden under the modal
  • πŸ› We fixed some bugs around usernames, they can now be nullable and they will not replace existing usernames on login
  • πŸ› We fixed a bug where you couldn't add a condition in channel configuration
  • πŸ‘€ The E keybinding for opening a template now works in read-only environments
  • πŸ‘€ We've added a cancel workflow run button in workflow run debugger

Fetch step: preview your fetched data in the variable pane

Previously when you used a fetch step in a workflow, there was no way to keep track of the properties in the returned payload when building your notification workflows. You would have to memorize the data to use it.

We've shipped a big improvement that eliminates this pain point: we're now storing the fetched data in the workflow variable pane. The variable pane is available in every step of your workflow, so it's now easy to know which variables you can reference as you're building your workflows and message templates. If you have multiple fetch steps in your workflow you'll see a section in the variable pane for each step.

Mailtrap integration

We now support Mailtrap as an email provider within Knock!

If you are currently using Mailtrap to test and send emails, you can now configure a new email channel with Mailtrap in Knock and start using it in your workflows.

Learn more in the docs β†’

Fixes and improvements

  • πŸ› We fixed a bug where customers on our legacy plans weren't able to self-service downgrade
  • πŸ› We fixed a bug where tenants weren't able to be inline-identified
  • πŸ› We fixed a bug where users weren't able to open the template gallery
  • πŸ‘€ Cancellation keys are now shown in the workflow run log page