Understanding the Znode 10 Solution Structure

TABLE OF CONTENTS


Understanding the Znode 10 Solution Structure

This guide gives Znode implementation partners a single map of how a Znode 10 solution is put together: which applications Znode hosts for you, which SDKs you download and own, how each code base is organized, and where partner customizations are expected to live.

Use it during project kick-off, developer onboarding and solution design to decide where a requirement should be built (Webstore, Page Builder, Custom API or Custom Admin) and to avoid changes that cannot be deployed through the Znode CLI.

Overview

Znode 10 is delivered as a set of cooperating applications rather than one monolithic code base. The core commerce engine (Multifront API V1/V2, Admin Console, gateways and supporting microservices) is hosted and managed by Znode on Azure Kubernetes Service (AKS). Partners extend the platform through two downloadable SDKs:

  • The Webstore SDK, a React/Next.js monorepo containing the Webstore and Page Builder applications.
  • The Custom API SDK, a .NET 8 solution that also carries the Custom Admin library.

Both SDKs are downloaded, refreshed and deployed with the Znode CLI. Custom code never touches the Znode database directly; it talks to the platform through the published Znode API clients and the API gateway. Keeping to this separation is what allows Znode to upgrade the core platform without breaking partner work.

Prerequisites

  • Completed Znode tenant onboarding and a non-production (sandbox/DEV) instance assigned to your project.
  • A Znode CLI token for each developer seat and Znode NuGet feed credentials (both issued by Znode Support).
  • Developer workstation meeting the Znode 10 system requirements (see Development Environment and the Znode CLI).
  • A source-control repository (for example GitHub) where your team will commit the downloaded SDK code.

Solution at a Glance

Every Znode 10 tenant is made up of the building blocks below. The key question for partners is the Owner column: hosted components are configured, not recompiled; SDK components are where your code lives.

ComponentTechnologyOwner / HostingPartner role
Multifront API (V1 & V2).NET 8 microservicesZnode-hosted (AKS)Consume through API clients and gateway; changes need a support ticket
Admin Console.NET 8 MVCZnode-hosted (AKS)Configure stores, catalogs, CMS; add custom pages/sections
API Gateway (Ocelot).NET 8Znode-hostedAdd custom routes via CustomOcelot.json
WebstoreReact / Next.js (Nx app)Webstore SDK – partner-ownedBuild and theme the storefront
Page BuilderReact / Next.js + Puck (Nx app)Webstore SDK – partner-ownedCreate widgets and design CMS pages
Custom API.NET 8 Web APICustom API SDK – partner-ownedAdd endpoints, transform requests/responses, integrate third parties
Custom Admin.NET 8 MVC (.cshtml)Inside Custom API SDKBuild admin pages/sections loaded into the Admin Console
Commerce Connector / ERPData Exchange processorsConfigured per tenantBuild custom processors for ERP integration

How the pieces talk to each other

  • The Webstore and Page Builder call the Znode APIs using the values in their .env files (API_URL, API_V2_DOMAIN, API_DOMAIN, API_KEY).
  • The Custom API calls the Multifront API through NuGet client packages (for example Znode.Multifront.API.Client) and is exposed to the outside world through the API gateway.
  • Custom Admin pages are hosted with the Custom API and shown inside the Admin Console through Dev Center > Admin Customizations.
  • All deployable SDK code is built into container images by the Znode CLI and deployed to the tenant's AKS environment.

Important: Custom code has no direct database or Entity Framework access. Any data your customization needs must come through a Znode API, a Custom API, or a separately hosted custom table exposed via a Custom API.

Source article: Solution at a Glance

Development Environment and the Znode CLI

The Znode CLI is the entry point to the partner-owned part of the solution. It downloads the SDKs, refreshes them to newer releases and deploys them to your Znode environments.

Workstation requirements

SoftwareRequired versionUsed for
.NET8.0Custom API SDK, Custom Admin, Znode CLI
Visual Studio2022 or later.NET solutions
Docker Desktop (or IIS Express)LatestLocal hosting; Docker is required for znode deploy
Node.js20.0.0 or higherWebstore SDK
VS CodeLatestWebstore SDK (recommended IDE)

Install the CLI and download the SDKs

  1. Register the Znode NuGet feed with the credentials from Znode Support.
  2. Install the CLI as a global .NET tool.
  3. Authenticate with your personal CLI token (valid for one year; a session lasts six hours).
  4. Create a dedicated working folder (for example D:\Znode10CLI) and run znode setupinside it.
    • Avoid spaces in the path and do not run setup directly at a drive root.
    • Add a release version (for example v10.12.1.0) to download a specific release; otherwise the latest is downloaded.
    • Re-running setup does not overwrite existing source files.
  5. Commit the downloaded code to your project repository before you start customizing.

Commands:

dotnet nuget add source "https://nuget.znode.com/nuget" -n "NugetZnode10xCLI" -u "<username>" -p "<password>" --store-password-in-clear-text

dotnet tool install Znode.CLI -g

znode connect <token>

znode setup # latest release

znode setup --releaseVersion v10.12.1.0

znode get-updated-copy # pull newer Webstore / Custom API SDK changes

Token scope

ScopeWhat it controls
SDK levelA token may allow Webstore only, Custom API only, or All SDKs.
Environment levelDeployment can be limited to specific environments such as DEV, QA or PROD.

Deploying SDK code

The deploy command builds the solution locally, tags a timestamped container image, pushes it to the Azure Container Registry and rolls it out to AKS.

Commands:

znode deploy WebStoreSDK DEV

znode deploy CustomAPISDK DEV [<optional SDK path>]

Tip: If Docker reports the containerd snapshotter storage driver (check with docker info --format '{{.DriverStatus}}'), set BUILDX_NO_DEFAULT_ATTESTATIONS=1 before running znode deploy. CLI logs are written to %UserProfile%\AppData\Local\ZnodeCLILogs\.

Source article: Development Environment and the Znode CLI

Webstore SDK Monorepo Structure

The Webstore SDK (repository root webstore-platform) is an Nx monorepo. It holds two deployable applications and a set of shared libraries, so the storefront and the Page Builder always use the same components and types.

Top-level folders

FolderPurpose
apps/webstore/The customer-facing storefront (Next.js). Has its own .env file.
apps/page-builder/The drag-and-drop CMS editor used by content teams and developers. Has its own .env file.
packages/Shared libraries used by both applications (see Shared packages).
.github/CI/CD workflows for test, lint and deploy.
.husky/Git hooks – pre-commit runs linters/formatters, pre-push runs tests.
.nx/Nx workspace cache and configuration.
.vscode/Recommended editor settings and extensions.
node_modules/Installed dependencies – generated, never commit.

Shared packages

PackageWhat lives here
agents/Wrappers around Znode API calls (fetch/Axios).
base-components/Shared UI building blocks.
clients/Interfaces to third-party services such as payments and maps.
constants/Application-wide static values.
theme1-components/, custom-theme1-components/, custom-theme2-components/Theme-specific layout and styling components.
page-builder/Page Builder configuration, widgets and theme registration (src/configs/…).
logger/Structured logging utility.
types/Shared TypeScript types and interfaces.
utils/Formatters, validators and helper functions.

Key configuration files

FilePurpose
package.json, nx.json, next.config.jsWorkspace root; run all npm and nx commands from here.
tsconfig.base.jsonShared TypeScript settings and path aliases (for example @znode/<theme-name>).
.eslintrc.json / .prettierrcCode-style rules enforced by the Git hooks.
apps/webstore/.env and apps/page-builder/.envAPI endpoints, API key, DEFAULT_THEME, debugging and cache flags.

Where customizations go

RequirementLocation
New component / widget in the existing themepackages/page-builder/src/configs/base-config/widgets/{widget-type}/ (a Config.tsx and a Render.tsx), registered in base-components-config.ts
New themeNew package under packages/{themeName}/ plus packages/page-builder/src/configs/{theme}-config/, registered in get-config.ts and selected with DEFAULT_THEME
Theme stylingtailwind-config/tailwind.config.ts inside the theme, scoped with a data-theme selector
Page content and layoutAdmin Console CMS > Store Experience or CMS > Pages, then Page Builder – no code change

Important: Leave the existing theme and config folders unchanged. Build new themes alongside them so that znode get-updated-copy can bring in future Znode releases with minimal merge conflicts.

Commands:

npm install

npx nx dev webstore # http://localhost:3000

npx nx dev page-builder

npx nx run webstore:build

npx nx reset # clear the Nx cache

Source article: Webstore SDK Monorepo Structure

Custom API SDK Structure

The Custom API SDK is a .NET 8 solution that runs as an isolated service next to the Multifront API. Use it to add endpoints, reshape API requests and responses, and integrate third-party systems without modifying the core platform.

Project / itemContents and purpose
Custom.API.CoreYour business code. Controllers (routes and input), Services (business logic and interfaces), CustomDependencyRegistration (DI for services and clients). References the Znode API client packages.
Engine.Custom.APIThe host. Program.cs (middleware, DI, startup), SwaggerConfig.cs (API docs), Ocelot/ folder with CustomOcelot.json (gateway routes), appsettings.json (ZnodeApiDomainName, CORS and other keys).
Custom.Admin.Core / CustomAdmin/Custom Admin controllers and .cshtml views (covered in Custom Admin Structure).

Znode client packages

TargetNuGet package
Multifront APIZnode.Multifront.API.Client (Swagger at /swagger/index.html)
Payment APIZnode10.Payment.API.Client
Custom Table APIZnode10.Engine.CustomTable.Client

Customization patterns

PatternHow to apply it
POST customizationChange the payload in your service before calling the Multifront API.
GET customizationCall the Multifront API through its client (for example OrderClient) and transform the response after it returns.
Gateway routingAdd routes to CustomOcelot.json with the key customapi and give them a higher priority than the Znode routes so they take precedence.

Start from the sample Get Order List service and controller included in the template.

After deployment the endpoint follows the pattern https://<CustomAPISDKHostedURL>/<Controller>/<Action>.

Tip: To debug a local Custom API against a hosted environment, expose it with a Cloudflare tunnel (cloudflared tunnel --url https://localhost:7222) and point the Admin or Gateway configuration at the tunnel URL. Remove the tunnel URL when you finish.

Source article: Custom API SDK Structure

Custom Admin Structure

Partners do not modify the hosted Admin Console. Instead, they build admin pages and sections inside the Custom API SDK and register their URLs in the Admin Console, which displays them in an iframe.

Folder and naming convention

  • Library:Custom.Admin.Core (downloaded with the Custom API SDK) supplies the controllers for the forms.
  • Views:Engine.Custom.Api\CustomAdmin\Views\{ControllerName}\{ControllerAction}.cshtml – for example StoreController.StoreDetails maps to Views\Store\StoreDetails.cshtml.
  • CORS: add the Admin Console URL to ZnodeAdminURLCorsPolicy in Engine.Custom.Api\appsettings.json (managed by Znode DevOps in hosted environments).
  • Build the root URL from the request context (Context.Request.Scheme + Context.Request.Host), not the parent page.

Registering a custom page or section

  1. Deploy the SDK with znode deploy CustomAPISDK <Environment>.
  2. In the Admin Console go to Dev Center > Admin Customizations and click Add New.
  3. Choose Page or Section as the content area and enter the URL https://<CustomAPISDKHostedURL>/CustomAdmin/<Controller>/<Action>.
  4. Assign the roles that may see it and, for sections, add the documented macros as query-string parameters.
  5. Click Save. Sections then appear on the related entity screen (for example Stores > Manage Store).

Note: The macros #userid#, #useremailaddress#, #roleid# and #rolename# are passed Base64-encoded to both pages and sections.

Source article: Custom Admin Structure

Core API and Admin Source Solutions

Some engagements are granted access to the core platform source for local development and diagnosis. These repositories are permission-controlled and are not part of the standard partner SDK download.

RepositorySolution / startup projectNotes
znode10-api-migrationSolution in Znode.Multifront; start Znode.Engine.Api (V1) and Znode.Engine.ApiV2 (V2) togetherKeep V1 and V2 appsettings.json URLs in sync; each related microservice has its own appsettings.json
znode10-admin-migrationAdmin .sln; startup project Znode.Engine.Admin.csprojAdmin, API V1 and API V2 point to local ports (44375, 44330, 44392)

Shared infrastructure settings

AreaSettings
DatabasesSQL Server connection strings for the entity stores, Hangfire and recommendations, plus a MongoDB log store.
SearchElasticsearch URL in appsettings.json.
CachingZnodeRedisCache (recommended for distributed setups), ZnodeSqlCache or in-memory.
EventBusRabbitMQ for messaging; the management UI runs on port 15672.

Important: Changes to the core Multifront API cannot be deployed by partners. Raise a Znode Support ticket for core changes and keep partner logic in the Custom API SDK.

Source article: Core API and Admin Source Solutions

Frequently Asked Questions

Q: Where should a new business rule go – Webstore or Custom API?

Put presentation and UX behavior in the Webstore SDK. Put data rules, integrations and anything that must also apply to other channels (Admin, headless clients) in the Custom API, then expose it through the gateway.

Q: Can our Custom API read Znode tables directly?

No. Custom code has no database or Entity Framework access. Use the Znode API clients, or host a custom table and expose it through your own Custom API.

Q: How do we take a newer Znode release without losing our changes?

Run znode get-updated-copy from the project folder and merge the changes in source control. Keeping your work in new theme packages and new config folders, rather than editing Znode's base folders, keeps these merges small.

Q: Why do the Webstore and Page Builder need to run at the same time locally?

Page Builder produces the page JSON that the Webstore renders, and previews open the local Webstore. Run both with npx nx dev webstore and npx nx dev page-builder when testing CMS changes.

ArticleLink
Solution at a Glancehttps://support.znode.com/support/solutions/articles/43000760880-getting-started-with-a-znode-10-tenant
Development Environment and the Znode CLIhttps://support.znode.com/support/solutions/articles/43000760827-how-to-install-and-set-up-znode-cli
Webstore SDK Monorepo Structurehttps://support.znode.com/support/solutions/articles/43000761087-webstore-customization-guide
Custom API SDK Structurehttps://support.znode.com/support/solutions/articles/43000761402-api-customization-guide
Custom Admin Structurehttps://support.znode.com/support/solutions/articles/43000761412-admin-customization
Core API and Admin Source Solutionshttps://support.znode.com/support/solutions/articles/43000761221-api-setup-guide-installation-configuration-

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.