Data Sharing Policy API: Sample Flows

This article presents possible use cases and corresponding sample flows that you can support. These flows aren't the only ways to use this API, but they can be a helpful starting point as you plan your implementation.

Distribute content across multi-locale marketing networks

You manage a global brand with regional marketing sites that need to display localized content from a central content hub. Each regional site should only show content relevant to its specific market and locale, while maintaining consistent branding and messaging from the central team.

To distribute content across multi-locale marketing networks:

  1. On the central content hub site, call Create Data Sharing Policy to create a sharing policy for your articles collection with locale filtering:

    Copy
  2. Repeat step 1 to create additional policies for other locales. For example, "fr-FR", "de-DE".

  3. On each regional marketing site, call Connect To Shared Collection using the appropriate locale policy ID:

    Copy
  4. Access the shared content on regional sites using the namespaced collection ID central-content/Articles through standard data collection APIs.

  5. When the shared collection's content is modified on any site (central hub or regional sites), the changes automatically propagate to the source site and all target sites in real time.

Notify connected sites when sharing policies change

You manage a customer reviews database that multiple partner sites access through sharing policies. When you update a policy and remove a field from being shared, you want to identify all affected sites and notify them about the change so they can adjust their implementations accordingly.

To notify connected sites when sharing policies change:

  1. Update your sharing policy to remove restrictions by calling Update Data Sharing Policy.

  2. Identify the affected sites by calling List Shared Data Collections for your collection.

  3. Extract the target site IDs from the response to identify all connected partner sites.

  4. Create a Notification template in the app dashboard and send a message about the update to each affected site's dashboard using the Notifications API.

Did this help?