This repository provides a template integration for connecting a CMS to the Uniform platform using the Mesh SDK. It serves as a starting point for developers to implement their own CMS integrations, leveraging the flexibility and scalability of Uniform's Mesh capabilities.
- Customizable CMS Integration: Use this template to build a tailored integration for any CMS.
- Support for Published and Unpublished Data: Fetch both published and unpblished content from the CMS.
- Single Entry Selector: Enable users to easily browse and select individual CMS entries.
- Mocked API Support: Simulate API interactions for local development.
- Uniform Mesh SDK Integration: Fully compatible with Uniform's Mesh SDK for seamless integration.
To set up the integration in Uniform:
- Go to the Uniform Dashboard.
- Navigate to Settings and click Custom Integrations.
- Scroll down and click on Add Integration.
- Use one of the following manifest copies:
- Local version: mesh-manifest.local.json
- Vercel version: mesh-manifest.vercel.json
- Save the integration, and you're ready to use it!
- Node.js: Ensure you have Node.js LTS installed.
- Uniform Account: Access to a Uniform project for testing and deployment.
- Clone this repository:
git clone [https://github.com/uniformdev/cms-integration-template]https://github.com/uniformdev/cms-integration-template)
cd cms-integration-template
- Install dependencies:
npm install
- Start the local development server:
npm run dev
- Open your browser and navigate to:
- The local version of the integration will be available for testing.
- Fork or clone this repository.
- Push the repository to your own GitHub account.
- Connect the repository to Vercel.
- Deploy the project using Vercel's interface or CLI:
Once deployed, use the generated Vercel URL in the Mesh App Manifest field to set up the integration in Uniform.
The mocked API provides the following endpoints:
GET /api/mocked-cms: Fetches a list of entries.GET /api/mocked-cms/content-types: Retrieves available content types.- Supports preview mode via the
state=previewquery parameter.
The integration provides the following locations:
- Settings: Accessible at
/settingsfor configuring the integration. - Data Connection Editor: Configure the connection to your CMS at
/data-connection-editor. - Single Entry Editor: Manage single entry types at
/data-types/single-entry-type-editorand/data-types/single-entry-data-editor.